Viewing 1 post (of 1 total)
  • Author
    Posts
  • #18152
    Stefan
    Participant

    Snippet: please prevent backslash from getting interpreted on pasting, for example with new “#RAW” directive?

    For example:

    Snippet:
    nFound = document.selection.Find(“^\\s*?$”,[ replace,] eeFindNext | eeFindReplaceRegExp | eeReplaceAll );

    Get paste as:
    nFound = document.selection.Find(“^\s*?$”,[ replace,] eeFindNext | eeFindReplaceRegExp | eeReplaceAll );

     

    And snippet:
    LineBreak = “\r\n” ;
    LinesArray = SelText.split(LineBreak);

    Get paste as:
    LineBreak = ”
    ” ;
    LinesArray = SelText.split(LineBreak);

     
     
    I would like a feature to disable this behavior of interpreting backslash sequences as commend.

    Perhaps for example by inventing a third Type, or by just adding a # directive at top of all snippets in question, like #raw, which disable that backslash swallowing.

    Snippet:
    // #RAW // paste this snippet as stored, do not interpret backslashes as commend.
    nFound = document.selection.Find(“^\\s*?$”,[ replace,] eeFindNext | eeFindReplaceRegExp | eeReplaceAll );

     

    I know I could escape each backslash on my own, but that is too much on a daily basic while dealing with many snippets.

     

    Thank you for making EmEditor.

Viewing 1 post (of 1 total)
  • You must be logged in to reply to this topic.