[jedit:feature-requests] #36 filtered - selective Line Editing
J L Turriff via jEdit-devel <[email protected]>
| Newsgroups | gmane.editors.jedit.devel |
|---|---|
| Message-ID | </p/jedit/feature-requests/36/b40375f8ca25c786423112c866cb491ead912892.feature-requests@jedit.p.sourceforge.net> |
Even before Kedit, this feature was provided in the z/VM CMS Xedit editor with the **all** command; its syntax there is ~~~ all /*string*/... ~~~ where **/*string*/** is any string delimited by **/** or any other special character not present in ***string***; if **/*string*/** is preceded by **¬** (**not**) the match is inverted; multiple strings may be joined by **|** (**or**) or **&** (**and**); in jEdit, a regular expression could do the same. A similar **all** command is provided by the X2 text editor. --- ** [feature-requests:#36] filtered - selective Line Editing** **Status:** open **Group:** v5.2 **Labels:** core **Created:** Tue Aug 15, 2006 07:31 PM UTC by Vadim Pesochinskiy **Last Updated:** Sat Apr 30, 2022 04:32 PM UTC **Owner:** nobody Hi\! I wanted to submit this feature request earlier posted by Pierre Métras at http://marc.theaimsgroup.com/?l=jedit-users&m=98960814101033&w=2 I found this feature very useful in SlickEdit. Interface can be just opening a "search" dialog box with text feild to enter a regular expression filter. In his example below you would just enter without quotes "blue|product". I hope you will give it some consideration. Thanks. "This is one of KEDIT's most popular features. The selective editing facility lets you focus on a subset of the lines in a file, such as all lines containing a particular string. You can have KEDIT display only this subset of your file, and you can perform editing operations that affect only this subset. You can then return to viewing and working with the entire file, with the lines in the selected subset \(as modified by your editing\) remaining in their original position in the file. " For instance, you have a file that contains a list of products, with their manufacturer, color and material \(that's a flat database, to make the example easier, but such cases happen in source code too\). You want to change the manufacturer's name of the blue products, if they are not in plastic, and all products if they are in leather.. With KEDIT, the operations are: \- "all /blue" This displays only the blue products and folds the other lines. \- "less/plastic" Removes the plastic products from the display - "more/leather" Add the leater products to the display \(unfold the "leather" lines that were folded" Then you work in the resulting display and do a serach/replace only on the visible lines. And "all" to restore the full view. No need for regular expressions here: what you see is what you edit. Imagine folding and bookmarks combined. You can place \(or remove\) bookmarks on certain lines that match a criteria you give. Then you are able to fold the edit buffer on all the lines that don't have a bookmark. And then, you can apply operations \(search, replace, Uppercase, macros...\) only on the visible lines \(in other words, you apply an operation on lines with a bookmark\). Please comment as I haven't the courage to try version 3.1 as my 3.0 final works well \(now\) with my usual puggins..." --- Sent from sourceforge.net because [email protected] is subscribed to https://sourceforge.net/p/jedit/feature-requests/ To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/jedit/admin/feature-requests/options. Or, if this is a mailing list, you can unsubscribe from the mailing list. -- ----------------------------------------------- jEdit Developers' List [email protected] https://lists.sourceforge.net/lists/listinfo/jedit-devel