Changeset View
Changeset View
Standalone View
Standalone View
libs/basicflakes/tools/KoCreatePathTool_p.h
Show First 20 Lines • Show All 184 Lines • ▼ Show 20 Line(s) | 180 | : KoToolBasePrivate(qq, canvas), | |||
---|---|---|---|---|---|
185 | handleRadius(3), | 185 | handleRadius(3), | ||
186 | mouseOverFirstPoint(false), | 186 | mouseOverFirstPoint(false), | ||
187 | pointIsDragged(false), | 187 | pointIsDragged(false), | ||
188 | finishAfterThisPoint(false), | 188 | finishAfterThisPoint(false), | ||
189 | hoveredPoint(0), | 189 | hoveredPoint(0), | ||
190 | listeningToModifiers(false), | 190 | listeningToModifiers(false), | ||
191 | angleSnapStrategy(0), | 191 | angleSnapStrategy(0), | ||
192 | angleSnappingDelta(15), | 192 | angleSnappingDelta(15), | ||
193 | angleSnapStatus(false), | 193 | angleSnapStatus(false) | ||
194 | strokeWidget(0) { | 194 | { | ||
195 | } | 195 | } | ||
196 | 196 | | |||
197 | KoPathShape *shape; | 197 | KoPathShape *shape; | ||
198 | KoPathPoint *activePoint; | 198 | KoPathPoint *activePoint; | ||
199 | KoPathPoint *firstPoint; | 199 | KoPathPoint *firstPoint; | ||
200 | int handleRadius; | 200 | int handleRadius; | ||
201 | bool mouseOverFirstPoint; | 201 | bool mouseOverFirstPoint; | ||
202 | bool pointIsDragged; | 202 | bool pointIsDragged; | ||
203 | bool finishAfterThisPoint; | 203 | bool finishAfterThisPoint; | ||
204 | PathConnectionPoint existingStartPoint; ///< an existing path point we started a new path at | 204 | PathConnectionPoint existingStartPoint; ///< an existing path point we started a new path at | ||
205 | PathConnectionPoint existingEndPoint; ///< an existing path point we finished a new path at | 205 | PathConnectionPoint existingEndPoint; ///< an existing path point we finished a new path at | ||
206 | KoPathPoint *hoveredPoint; ///< an existing path end point the mouse is hovering on | 206 | KoPathPoint *hoveredPoint; ///< an existing path end point the mouse is hovering on | ||
207 | bool listeningToModifiers; // Fine tune when to begin processing modifiers at the beginning of a stroke. | 207 | bool listeningToModifiers; // Fine tune when to begin processing modifiers at the beginning of a stroke. | ||
208 | 208 | | |||
209 | AngleSnapStrategy *angleSnapStrategy; | 209 | AngleSnapStrategy *angleSnapStrategy; | ||
210 | int angleSnappingDelta; | 210 | int angleSnappingDelta; | ||
211 | bool angleSnapStatus; | 211 | bool angleSnapStatus; | ||
212 | KoStrokeConfigWidget *strokeWidget; | | |||
213 | 212 | | |||
214 | void repaintActivePoint() const { | 213 | void repaintActivePoint() const { | ||
215 | const bool isFirstPoint = (activePoint == firstPoint); | 214 | const bool isFirstPoint = (activePoint == firstPoint); | ||
216 | 215 | | |||
217 | if (!isFirstPoint && !pointIsDragged) | 216 | if (!isFirstPoint && !pointIsDragged) | ||
218 | return; | 217 | return; | ||
219 | 218 | | |||
220 | QRectF rect = activePoint->boundingRect(false); | 219 | QRectF rect = activePoint->boundingRect(false); | ||
▲ Show 20 Lines • Show All 208 Lines • Show Last 20 Lines |