Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #24277
    LTT
    Participant

    1:
    <${1:p}>${2:${SelText}}</$1>$0
    Trigger such a snippet and escape midway.
    Undo.
    ** Unable to Redo the Undone step.

    —————
    2:
    editor.ExecutePlugin( “Snippets.dll”, eePluginUserMessage, 1, “FolderName\\SnippetName” );

    Is it possible to make it support “\” in folder/snippet names?

    And even support folders/snippets with same name?

    #25279
    Yutaka Emura
    Keymaster

    1. We will fix this on the next version.

    2. The next version will allow you to use this second form (notice the 3rd parameter is 2):

    editor.ExecutePlugin( "Snippets.dll", eePluginUserMessage, 2, "/FolderName/SnippetName" );

    The separator character (in this case, ‘/’) must be used as the first character of the string.
    ‘/’ can be any single character. For instance, the following is also OK.

    editor.ExecutePlugin( "Snippets.dll", eePluginUserMessage, 2, "|FolderName|SnippetName" );

    You can still use the old form (3rd parameter is 1) to keep backward compatibility.

    #25409
    LTT
    Participant

    Considerate improvement.
    Thank you for the detailed reply.

    Maybe “Notes” are needed in pages like this:
    emeditor_en.chm::/macro/editor/editor_executeplugin.htm

    But I have to rename the same-named snippets for macro cases? Though Snippets plug-in allows the use.

    #25413
    Yutaka Emura
    Keymaster

    I just need to clarify your question. Do you want the 4th parameter (in this case “|FolderName|Snippets|”) case-insensitive?

    #25418
    LTT
    Participant

    Not really.

    For example,
    Duplicate a snippet by Ctrl+C and Ctrl+V.
    Then change the content of either one.
    I’d rather keep their names identical for some reasons.
    I know it’s not a good habit, but since the plug-in allows same names…

    I wonder if there’s a way in a macro to handle the same-named ones (by order or something).

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.