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

Re: [Clip] Extending selection in clip

Expand Messages
  • Scott Fordin
    Thanks to all who replied. I ll give your suggestions a go! Regards, Scott
    Message 1 of 4 , Jul 31, 2000
    • 0 Attachment
      Thanks to all who replied. I'll give your suggestions a go!

      Regards,

      Scott

      At 12:03 PM 7/30/00 -0500, Jody wrote:
      >Hi Scott,
      >
      > > What I've been doing is using ^!Find to get to a block of text
      > > (in this case a specific combination of HTML tags), then using
      > > ^!Keyboard to unselect the found text and set the input
      > > location to the beginning of the text just after the found
      > > block.
      >
      >Try ^!Jump Select_Start instead of ^!Keyboard.
      >
      > > Isn't there a way to extend a selection to an arbitrary found
      > > item? That is, start from any given input location, and then do
      > > a find where the selection extends to the found item.
      >
      >There is a full blown working example of what you want to do in the
      >Utilities Library in a Clip called Select between Tags.
      >
      >Here are two simplified ways:
      >
      ><--- Copy below this line --->
      >H=Tag Select I
      >; Last Updated 07/30/2000, Sojourner@..., jody
      >^!SetScreenUpdate Off
      >:Loop
      >^!Find "<font" S
      >^!IfError End
      >^!Find ">" S
      >^!Jump Select_End
      >^!Set %Start%=^$GetRow$:^$GetCol$
      >^!Find "</font" S
      >^!Jump Select_Start
      >^!SelectTo ^%Start%
      >^!InsertText ^?{Replace with=^$GetSelection$}
      >^!Skip Abort?
      >^!Goto Loop
      >
      >
      >H=Tag Select II
      >; Last Updated 07/30/2000, Sojourner@..., jody
      >^!Set %TagStart%=<^?{Enter start tag name without arrows}
      >^!Set %TagEnd%=^$StrInsert("/";"^%TagStart%";2)$
      >^!SetScreenUpdate Off
      >:Loop
      >^!Find "^%TagStart%" S
      >^!IfError End
      >^!Find ">" S
      >^!Jump Select_End
      >^!Set %Start%=^$GetRow$:^$GetCol$
      >^!Find "^%TagEnd%" S
      >^!Jump Select_Start
      >^!SelectTo ^%Start%
      >^!InsertText ^?{Replace with=^$GetSelection$}
      >^!Skip Abort?
      >^!Goto Loop
      >
      ><--- Copy above this line, right --->
      ><--- click over a Library, and --->
      ><--- choose "Add from Clipboard" --->
      >
      >Happy Clip'n!
      >Jody
      >
      >http://www.sureword.com/notetab
      >
      >Subscribe, UnSubscribe, Options
      >mailto:Ntb-Clips-Subscribe@...
      >mailto:Ntb-Clips-UnSubscribe@...
      >http://www.egroups.com/group/ntb-clips
      >
      >
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.