Loading ...
Sorry, an error occurred while loading the content.

24320Re: [Clip] Using toolbar on multiple, separated lines

Expand Messages
  • Alec Burgess
    Jan 26, 2014
      John - its not clear whether all the '1' lines are together (ie. file is sorted or can be sorted and left that way)
      For now - assume yes ...
      (1) use a regex to change all \R to any unique string not present in input data resulting in a single line (say ####)
      (2) Select the line and set sentence case Shift+Ctrl+U or in a clip
      -- ^!Menu Modify/"Text case"/Sentence
      (3) Change all the #### back to \r\n

      If not yes above before (1) use ^!Menu Lines\"Number lines" then a clip replace to swap the line number and the line id and sort ascending then steps 1 to 3 above

      After step 3 to recover original order re-swap line-id and line number, sort ascending and use a regex to remove the line numbers.

      Note: AFAICT the Number lines step requires an [OK] or entry of a line number followed by [OK]. As it happens, the Sample code library contains a Perl numLines script if you want no keyboard entry.
      @anyone - is there any clip commands that avoids the manual entry for ^!Menu Lines\"Number lines"?

      On 2014-01-26 19:22, John Shotsky wrote:
      I'm looking for a way to use the toolbar 'sentence case' command on selected, but separate lines in a a file. Let's just say every line is upper case, is numbered 1-9, and for each line numbered 1, I want to sentence case ALL of them, using ONE command. I realize this is probably not possible, but thought I'd ask. I was thinking the doclist command, maybe in some way. I know how to do it using a 'Find' and a loop to do it, but I didn't want to operate the toolbar command on 1000 lines when it might be possible to do it just once.

      Regards ... Alec (buralex@gmail & WinLiveMess - alec.m.burgess@skype)
    • Show all 12 messages in this topic