On Wed, 12 Mar 2008 07:50:55 +0100, Joerg Desch <[EMAIL PROTECTED]> wrote:

> On Sun, 09 Mar 2008 14:07:00 -0700
> chuck <[EMAIL PROTECTED]> wrote:
> 
> > Suppose you want to change the variable names so they all have 2-digit 
> > numbers leading with a zero; so the first line would read
> > char *fill_01 = "Chapter 1";
> 
> Both examples could be done very easily with Geany using a column
> selection together with find+replace. IMO it's much better than a
> zero-width selection.
> 
> A nice feature for a "fill column selection" would be "auto-increment". So
> if I copy a variable several times, ...
> 
> char *fill_1 = "Chapter 1";
> char *fill_1 = "Chapter 1";
> char *fill_1 = "Chapter 1";
> char *fill_1 = "Chapter 1";
> char *fill_1 = "Chapter 1";
> 
> ..it would be very handy to select the 1's as column block, press the magic 
> key and all the 1's would be replaced like this. The auto-increment has to 
> read the first character (the '1' in this case) and use this as starting 
> point.
> 
> char *fill_1 = "Chapter 1";
> char *fill_2 = "Chapter 1";
> char *fill_3 = "Chapter 1";
> char *fill_4 = "Chapter 1";
> char *fill_5 = "Chapter 1";
> 
> This is just an idea. But I think this better should be plugin or a LUA 
> script.
Or any other kind of script/program which can read text from stdin and
print the changed text on stdout. Then you can use the "Send selection
to" command in Geany(*). The only thing you have to do, is to write this
script/program that handles the input, mangles it in some way and
prints it out. Geany will take care of the selection handling.


(*) which should be used with care on Windows, it might work, it might
fail.

Regards,
Enrico

-- 
Get my GPG key from http://www.uvena.de/pub.key

Attachment: pgpNWjcthCrMM.pgp
Description: PGP signature

_______________________________________________
Geany mailing list
Geany@uvena.de
http://lists.uvena.de/cgi-bin/mailman/listinfo/geany

Reply via email to