SynEdit MultiCaret plugin: what changed
Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.
Title: SynEdit MultiCaret plugin
| Old | New | Line | |
|---|---|---|---|
| 1 | + | # General | |
| 2 | + | ||
| 3 | + | The unit SynPluginMultiCaret provides a plugin, that allows to use SynEdit in Multi-Caret mode. | |
| 4 | + | ||
| 5 | + | Animated demo (in IDE) [[New IDE features since|New IDE features since#Multi_Caret]] | |
| 6 | + | ||
| 7 | + | Keys and Mouse can be configured on the Component. When used in the IDE this is the setup is managed by the IDE. | |
| 8 | + | ||
| 9 | + | # Modes | |
| 10 | + | ||
| 11 | + | When working with multiple carets, the editor can be in different modes. | |
| 12 | + | ||
| 13 | + | This affects what will happen when the caret movement keys (up/down/left/right/home/end/next-or-prev word/...) are used. | |
| 14 | + | ||
| 15 | + | Keystrokes can be defined to activate either "Cancel on Caret movements" or "MultiCaret - All follow Caret movements". Activation can either toggle between the 2 modes, or end the "Adding Carets" mode. | |
| 16 | + | ||
| 17 | + | ## Adding Carets | |
| 18 | + | ||
| 19 | + | This mode is active when a caret was added (or removed) using a key-combo. Caret-movement keys will affect the main-caret. All other carets stay where they are. | |
| 20 | + | ||
| 21 | + | This mode is ended, when an edit action takes place (insert/delete char/...). By default the mode changes to "All follow Caret movements", But this can be configured. | |
| 22 | + | ||
| 23 | + | ## MultiCaret - Cancel on Caret movements | |
| 24 | + | ||
| 25 | + | The carets can only be used to edit the text at their current location. Any edit action (insert/delete char/...) will take place at all carets. | |
| 26 | + | ||
| 27 | + | Caret-movement (via up/down/left/right/... keys) will end the multi caret mode. | |
| 28 | + | ||
| 29 | + | ## MultiCaret - All follow Caret movements | |
| 30 | + | ||
| 31 | + | Carets can be used to edit as above. | |
| 32 | + | ||
| 33 | + | Caret-movement (via up/down/left/right/... keys) will move all carets. If 2 or more carets end in the same place they will be merged. | |
| 34 | + | ||
| 35 | + | # Keys | |
| 36 | + | ||
| 37 | + | Keys can be defined to: | |
| 38 | + | ||
| 39 | + | - Set/Remove an extra caret at the position of the main caret. | |
| 40 | + | - Cancel Multi caret mode | |
| 41 | + | - Activate "Cancel on Caret movements" or "MultiCaret - All follow Caret movements". | |
| 42 | + | ||
| 43 | + | # Mouse | |
| 44 | + | ||
| 45 | + | Mouse actions can be defined, to | |
| 46 | + | ||
| 47 | + | - Add, Remove, Toggle an extra caret at the click position | |
| 48 | + | - Create carets from a selection (carets are set at the end of each line that is part of the selection) | |
| 49 | + | ||
| 50 | + | # Column mode selecting | |
| 51 | + | ||
| 52 | + | Column mode selection is usually archived with the alt key. It creates a rectangular selection, covering a text column over several lines. | |
| 53 | + | ||
| 54 | + | Multi caret mode can be activated automatically, if a column mode selection is made. This creates one caret in each line of the selection, on the same side of the selection as the main caret is. | |
| 55 | + | ||
| 56 | + | If an edit action is performed with multiple carets created by column mode selection, then by default "MultiCaret - Cancel on Caret movements" is activated. This can be configured. | |
| 57 | + | ||
| 58 | + | --- | |
| 59 | + | *From the Free Pascal wiki, page "SynEdit MultiCaret plugin", as it stood on 2015-03-28 after a change by Martin, out of the wiki's dump of 2024-05-26. Copyright stays with the author who wrote it, according to the old wiki's [[Licensing]] page. If you have concerns about this material, [message the admin](/wiki-contact).* | |
| 60 | + | Category: SynEdit |
