How to add to the selection ?
Tony Balinski
ajbj at free.fr
Fri Oct 5 10:07:14 CEST 2007
Quoting Tony Balinski <ajbj at free.fr>:
> Quoting Greg Edwards <gedwards2 at gmail.com>:
>
> > Team,
> >
> > I was sure that Nedit could "add to the current selection", so that I
> > could eg. go down a text file and copy sequences of lines from here
> > and there, and then paste them all into a new buffer as one unit. But
> > I can't find the command or any refernce to it in the doco. Am I right
> > ?
> >
> > Thanks !
> > GE.
>
> No. You can only select a single contiguous range or rectangular block
> at a time. You can extend a selection (using shift), but you only get
> one.
>
> There is a way to do what you want quite easily, though. If you split
> your window into two panes (using the Window menu), you can set your
> destination position in one pane and move around in the other, using
> the scroll bar. In this source pane, you can "secondary select" text
> with the middle mouse button (it appears underlined). When you let go
> of the mouse button, this text will be copied to the cursor's position
> in the destination window. (Use escape while selecting if you want to
> cancel the operation.) This works between documents too, in different
> windows. For more details about using secondary selections, see the
> NEdit menu entry Help> Basic Operation> Using the Mouse. (It's one of
> my favourite NEdit features, and pretty unique.)
Oops, I would do well to read your text properly! Although the same
advice applies: secondary selection from your source documents to your
new buffer (window). I find it easier to do this when the destination
is a separate window rather than just a tab, since you can see the
pieces being copied in.
If you want multiple "selections" at a time, you can try writing rangeset
macros. A rangeset (rs) will let you backlight various ranges of
non-contiguous text, then manipulate them in some way. One way would be
to copy all text over which the rangeset is defined into a single string,
then to put it somewhere (eg in a new buffer). But you'll need to write
the macros.
Tony
More information about the Discuss
mailing list