Sign in Join
Wiki copytemporary

IDE Window: EditorMouseOptionsAdvanced/de: what changed

Revision 0 to 1. Removed lines have a minus sign; added lines have a plus sign.

Title: IDE Window: EditorMouseOptionsAdvanced/de

OldNewLine
1+# Der Kontext Baum
2+
3+Bei dem Kontext Baum handelt es sich um die Baum-Struktur direkt links neben der Übersichts-Tabelle. Gegenwärtig hat er folgende Einträge:
4+
5+- **Text**
6+ - **Auswahl**
7+- **Randleiste**
8+ - **Falt** **Baum**
9+ - **Gefaltet** **\[+\]**
10+ - **Entfaltet** **\[-\]**
11+ - **Zeilen** **Nummern**
12+
13+Das Verhalten der einzelnen Maus-Tasten kann Kontext-sensitiv festgelegt werden. Z.B. ein Klick auf den markierten Text kann eine andere Aktion auslösen als ein Klick auf unmarkierten Text.
14+
15+Wenn für einen Kontext kein Verhalten für einen bestimmten Klick definiert ist, dann dient der übergeordnete Kontext als Definition (Rückfall). Z.B. für einen Klick auf markierten Text wird zuerst der Kontext "Markierung" durchsucht. Ist hier kein Eintrag für den Klick vorhanden dann wird der Kontext "Text" durchsucht. (In der Vorgabe-Konfiguration ist die Aktion für "Markierten Text verschieben" (Drag) auf diese Weise definiert.)
16+
17+**Randleiste** und **Text** sind Haupteinträge im Kontext Baum. Sie haben keine Rückfall-Konfigurationen. Die anderen Einträge können jeweils auf ihre übergeordneten Einträge zurückfallen.
18+
19+# Die Klick Konfiguration
20+
21+Welche Reaktion ein Klick mit einer der Maustasten auslöst wird anhand der folgenden Kriterien ermittelt.
22+
23+### Die Maustaste
24+
25+Alle Einstellungen können individuell, jeweils für die Linke, Rechte oder Mittlere Maustaste vorgenommen werden.
26+
27+### Die Zahl der Klicks
28+
29+Alle Einstellungen können individuell, jeweils für einfach, doppel, dreifach oder vierfach Klicks vorgenommen werden.
30+
31+Bitte beachten sie unbedingt den Abschnitt über Doppel bis Vierfach Klicks
32+
33+Es gibt eine spezielle Einstellung "Alle". "Alle" bedeutet das die konfigurierte Aktion für jede der Klickarten (Zahl der Klicks) ausgeführt wird. In diesem Fall würde ein Doppelklick die Aktion zweimal ausführen (zuerst für den Einfach-, dann für den Doppelklick). Sollte der erste Klick eine Status Änderung bewirkt haben, dann bezöge sich der zweit Klick auf den neuen Status.
34+
35+Beispiel
36+
37+Die linke Maustaste ist für den Quelltext-Falt Bereich auf "Alle" eingestellt. Als Folge wird mit jedem Klick zwischen auf- und zugefaltet umgestellt.\
38+Ohne die "Alle" Einstellung müsste man, wenn man versehentlich die falsche Textstelle gefaltet hat, einen Moment warten, bevor man sie mit einem weiteren Klick wieder entfalten kann. (Weil ein schneller zweiter Klick als Doppelklick zählt, und von der Einstellung "Einfach" ignoriert würde)
39+
40+Anmerkungen
41+
42+- Nicht alle von ihnen werden auf allen Plattformen unterstützt.
43+- Derzeit funktionieren **Double**, **Triple** und **Quad** nur für die Linke Taste, und nur für **down** Klicks.
44+
45+### Die Richtung des Klicks
46+
47+Ein Mausklick besteht aus 2 Ereignissen: Dem Drücken der Taste ("**Runter**") und dem Loslassen ("**Rauf**")
48+
49+Für jedes dieser zwei Ereignisse können eigene Einstellungen(Aktionen) vorgenommen werden.
50+
51+Es ist auch Möglich dem **Runter** und **Rauf** Ereignis des selben Klicks zwei verschiedene Aktionen zuzuweisen. Diese werden dann in der entsprechenden Reihenfolge ausgeführt. Es sollte aber beachtet werden, dass sich die beiden Aktionen in unerwünschter Weise beeinflussen können.
52+
53+Anmerkungen:
54+
55+- Einige Aktionen funktionieren nur dann richtig, wenn sie der korrekten Klick-Richtung zugewiesen sind.
56+ - Start Selection, Drag Selection: Only works on **down** events, since it relies on the following mouse-movement-while-button-down. (It has a build in "end" at mouse button up)
57+ - Kontextmenü: On some WidgetSets this will only work reliable on mouse-**up** events
58+
59+### Die Umstelltasten
60+
61+Das Maus-Verhalten kann verändert werden durch das Drücken der **Shift**, **Alt** oder **Strg** Taste (oder einer Kombination von ihnen).
62+
63+At the time of the click-**down** or **up** the state of all three keys is checked. An action can be defined to:
64+
65+- require one, some or all of the modifier keys pressed (Checkbox ticked)
66+- require one, some or all of the modifier keys *not* pressed (Checkbox not ticked)
67+- ignore the state of one, some or all of the modifier keys (Checkbox greyed)
68+
69+For a given combination of Button, Click-Type, Click-Direction there must not be any ambiguity for the modifier keys. Example
70+
71+Bad / Ambiguous
72+
73+- Left, Single, down Click with: Shift required pressed; Alt and Strg ignored
74+- Left, Single, down Click with: Strg required pressed; Alt and Shift ignored
75+
76+
77+Now if you do this click, with both of Shift and Strg pressed, it would be unclear which of the 2 settings to use
78+
79+Correct
80+
81+- Left, Single, down Click with: Shift required pressed; Strg required un-pressed; Alt ignored
82+- Left, Single, down Click with: Strg required pressed; Shift required un-pressed; Alt ignored
83+
84+If you whish Shift to be preferred (the shift action should be taken, if both modifier keys are pressed) then you must at an extra setting:
85+
86+- Left, Single, down Click with: Strg required pressed; Shift required pressed; Alt ignored
87+
88+Default Fallback
89+
90+Es gibt eine Ausnahme von dieser Regel. If all modifier keys are set to be ignored, the entry becomes the fall-back for the button, click-type, click-dir configuration. This is, if no configuration is found which has at least one modifier key required either pressed or un-pressed, then the fallback will be used.
91+
92+Anmerkung
93+
94+The Modifier Combinations used to detect the action on mouse down (or up) has nothing to do with the modifier Key, that certain actions use during there mouse-move phase.\
95+e.g. Dragging uses "strg" to copy the dragged text instead of moving it. However the use of "strg" for copy indication is during mouse move, so you can set start dragging to rely on any other Modifier key. It is however recommended to set **Strg** to greyed, so you can start dragging with the key pressed or un-pressed.\
96+This is different to using "alt" (or others) for column mode selection: Here the decision is made only at the time of click. Later changes of the "alt" key during mouse-move do not change the selection mode.
97+
98+=
99+
100+The Action / Behaviour =
101+
102+Each mouse button event as defined above, can trigger some action. The same action can be assigned to more than one event. (IF 2 events have the same behaviour, then there modifier keys are not checked for ambiguity)
103+
104+Move Caret checkbox
105+With each action you can define, if you whish the caret to be moved. However this only additionally enforces the caret move. If an action implicitly moves the caret, then this will happen, even if you uncheck the this box. (e.g. Selecting a block always moves the caret)
106+
107+Command options
108+Some commands take additional params to refine there behaviour
109+
110+Implicit mouse up action
111+Some events that occur on mouse **down** events implicitly assign a mouse **up** action for the current click.\
112+E.g. dragging implicitly drops (inserts) the text when the button is released.\
113+If any configured action is assigned to the mouse up, then the implicit action is performed first, the configured action is performed second.
114+
115+## No Action Command
116+
117+There are 2 uses for this:
118+
119+Move Caret
120+With "Move Caret" it will set the caret to the mouse location. This will unset an existing selection. It also prevents a new selection from being marked by moving the mouse.\
121+If it occurs on **down** then the caret will be set to the location the mouse was pressed, never mind where you release the button
122+
123+Prevent fallback to parent node
124+In Context-Subnodes this can prevent a click from executing the parent node(s) action.\
125+E.g. this is assigned to the FoldTree. It catches clicks that are neither on a \[+\] or \[-\] node. Otherwise they fall through to the normal Gutter and toggle a breakpoint.
126+
127+## Selection Commands
128+
129+### Block Selection Commands
130+
131+There are 3 Selection commands, for the 3 selection modes supported by SynEdit: **Normal**, **Column** or **Full-Lines**.
132+
133+Note: All of them move the caret implicitly.
134+
135+Each of those can be configured in 2 different *Modes*:
136+
137+Begin
138+Starts a new selection . If an old selection exists, it will be disregarded. The new Selections starts at the current mouse location.
139+
140+Continue
141+If an old selection exists, then it will be extend.\
142+If there was no selection, then a new selection is created, which will start at the position the caret had before the event occurred, and range to the click position.
143+
144+Those events should be assigned to mouse **down** events, in which case the selection will resize with any following mouse-movement until the mouse button is released. (**Implicit mouse up action**)
145+
146+"Begin-Mode" on mouse **up** does nothing, but setting the caret. (Except currently for line mode, which selects the line).\
147+"Continue-Mode" on mouse **up** will extend the selection
148+
149+### Item Selection Commands
150+
151+Allow to select the Word, Line or Paragraph at the mouse position. Once selected the selection will not extend, if the mouse moves.
152+
153+"Line" supports 2 modes, either including leading/trailing spaces of the line or not.
154+
155+Note: All of them move the caret implicitly.
156+
157+### Drag Selection Command
158+
159+Drags (Copies or moves) the current selection to a new position, following mouse movement. It will be pasted there if the button is released. (**Implicit mouse up action**)
160+
161+Independent of the modifier keys pressed at the time of the event occurring (or the configured mod, keys), it will check for the **ctrl** key at the time the dragged text is inserted. If Ctrl is pressed the text will be copied, otherwise moved.
162+
163+Note: moves the caret implicitly.
164+
165+### Quick copy Selection Command
166+
167+Inserts a copy of the currently selected text at the mouse location. If no text is selected, inserts the content of the clipboard.
168+
169+Note: moves the caret implicitly.
170+
171+## Context Popup Menu
172+
173+Note: GTK2: PopUp-Menu is recommended for use with ButtonUp only
174+
175+## Fold Commands
176+
177+Fold commands are commonly assigned to the fold-tree-nodes, but can also be assigned to other context, like the text area.
178+
179+The fold-tree has 3 context-nodes
180+
181+Fold Tree
182+Any area of the fold-tree, this can be \[+\], \[-\], \|, or empty
183+
184+Collapsed
185+The \[+\] only. This means the line has at least one collapsed section. It may have a mix of collapsed/expanded sections
186+
187+Expanded
188+The \[-\] only. This means the line has at at only expanded sections (at least one)
189+
190+Note, that if you configure a specific click (e.g. shift-left-down) for either \[+\] or \[-\] or both, then most likely you should add the same click with "no action" (or other default) to the parent "Fold Tree" node. Otherwise such a click if not on the \[+\]/\[-\] node will fall through to the gutter, and may trigger an action there.
191+
192+### Fold Commands
193+
194+By default only acts on nodes starting on the line at the mouse location.
195+
196+The following modes are available:
197+
198+One
199+Folds the "most inner" unfolded node starting on this line. This is the node that starts at the right most place in the line. Any node already folded is ignored, so if any unfolded node exists, one and exactly one node will be folded.\
200+This is not necessarily the shortest fold-node (in amount of lines folded), as \$region and begin folds can overlap.
201+
202+All
203+Folds all Nodes that start on this line
204+
205+At Caret
206+This only works if configured for the "Text" context. It folds the node which starts under the current mouse location. This allows you to click on a "begin" (or other keyword) to fold it. (Useful if more than one node starts at the line).
207+
208+Current
209+Folds the most inner node containing the current mouse location (the gutter is treated as "at the start of line"). It will search for the first fold-starting keyword (e.g "begin") in front of the current mouse location, whic has a block enclosing the mouse location (end is past mouse location). This may be above the current line.\
210+If assigned to the gutter (or fold tree) this is always above the current line, unless the line starts with a keyword (no spaces before)
211+
212+### Unfold Commands
213+
214+Only acts on nodes starting on the line at the mouse location.
215+
216+The following modes are available:
217+
218+One
219+Folds the "most outer" folded node starting on this line. This is the node that starts at the left most place in the line.
220+
221+All
222+Unfolds all nodes that start at the current line
223+
224+### Fold Popup Menu
225+
226+Note: GTK2: PopUp-Menu is recommended for use with ButtonUp only
227+
228+A pop up menu allowing you to see and change folds enclosing the current line
229+
230+## Source Link Command
231+
232+Trigger jump to implementation.
233+
234+The "underline" argument controls, if the curremt link under the mouse is highlighted (by an underline) while the modifier keys are pressed.
235+
236+If you assign this command to a click with no modifier keys needed, you would get constant highlights (because the expected modifiers (none) are pressed). In this case you cn switch it off.
237+
238+## Breakpoint Command
239+
240+Toggle breakpoint on this line
241+
242+# Doppel bis Vierfach Klicks
243+
244+- Anmerkung: Dies funktioniert gegenwärtig nur mit der linken Maustaste.
245+- Anmerkung: Those are currently only triggering Mouse Down
246+
247+Wenn sie einem Doppel- oder Dreifachklick eine Aktion zuweisen, dann sollten sie daran denken, dass diese immer auch die Aktionen für einen Einfach- bzw. Doppelklick auslösen.
248+
249+This is: Doing a Triple-Click will first do a Single-Click (down and up) with the same Modifier Keys (none, shift, alt, ...), then a double click, then the triple. (At the time of the first click, SynEdit does not know there will be more clicks)
250+
251+You should therefore take care of the actions assigned to those clicks.
252+
253+- With the default (select, select word, select line, select paragraph) this is no problem. Selecting a Line (Triple) is not disturbed by selecting a Word (Double) first.
254+- If However you would assign MouseLink to the Single (or Double), and select Word to the Double (or Tripple, one more than the other), this would not work. Because by the time you do your last click, SynEdit already followed the Link (and will not undo this). In fact, if SynEdit followed a Link to an other File, then a new SynEdit became active, and would see your last click as a single click.
255+- Das ist kein Bug sondern das korrekte Verhalten.
256+
257+# Aktuelle Einschränkungen
258+
259+- Double/Triple/Quad click ist nur für die linke Maustaste und nur für Mouse down verfügbar
260+- Double/Triple/Quad may depend on OS
261+- GTK2: PopUp-Menu is recommended for use with ButtonUp only
262+- OS-Depended: Some clicks may be used by the Window-Manager, and not reach the IDE at all
263+
264+# Useful Examples
265+
266+## Line Numbers in Gutter to select Lines
267+
268+You can set the Line number part of the gutter to select text (full lines) instead of toggling a breakpoint. The Rest of the gutter (left to the line numbers) will still do breakpoints.
269+
270+Context Node
271+Gutter =\> Line Numbers
272+
273+Configuration
274+Left - Any - Down - All modifiers greyed
275+
276+Action
277+Line Selection - Mode: Begin
278+
279+Setting Click to "Any" instead of "Single" means that double-clicks do not accidentally toggle breakpoints.
280+
281+## Fold by clicking on Keyword ("begin")
282+
283+Instead of folding a block by clicking on the \[-\] symbol in the gutter, you can fold a block by clicking on it's start keyword (e.g. "begin" or "\$region"). this is useful if more than one block starts on the same line.
284+
285+Context Node
286+Text
287+
288+Configuration
289+Middle or Right - Single - Down - Ctrl or Alt
290+
291+Action
292+Fold Code - Nodes: At Caret
293+
294+## Fold current block by clicking on vertical fold line
295+
296+You can set a click on the vertical line ("\|" below the \[-\] sign in the fold tree) to fold the enclosing node. This may be useful if the \[-\] is outside the visible area.
297+
298+Context Node
299+Gutter =\> Fold Tree
300+
301+Configuration
302+Left - Any - Down - All modifiers greyed
303+
304+Action
305+Fold Code - Nodes: Current Node
306+
307+This replaces the default "No Action" Entry. The default entry (as will the substitute) prevents Fold-Tree-Gutter clicks to toggle breakpoints.
308+
309+---
310+*From the Free Pascal wiki, page "IDE Window: EditorMouseOptionsAdvanced/de", as it stood on 2010-10-29 after a change by Mischi, 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).*

Back to history