Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #10376
    user
    Participant

    hello!

    can anyone write a script that will remove all trailing (one next to other) white characters (spaces, tabs, etc) and replace them with one space?

    also remove all white characters in the begining and end of all lines (and not replace them with one space)

    thanks!

    #10377
    webern
    Member

    1.
    document.selection.Replace(“( |t)+?$”,” “, eeReplaceAll | eeFindReplaceRegExp);

    2.
    document.selection.Replace(“( |t)+?$”,””, eeReplaceAll | eeFindReplaceRegExp);
    document.selection.Replace(“^( |t)+?”,””, eeReplaceAll | eeFindReplaceRegExp);

    #10378
    user
    Participant

    mmm, it doesnt work!

    in a text like this:
    sdf[5 spaces here]sdf
    nothing happens!

    any fix?

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