1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_SVX_SVDMRKV_HXX
21 #define INCLUDED_SVX_SVDMRKV_HXX
23 #include <svx/svdmark.hxx>
24 #include <svx/svdhdl.hxx>
25 #include <svx/svdsnpv.hxx>
26 #include <svx/svdtypes.hxx>
27 #include <svx/svxdllapi.h>
28 #include <o3tl/typed_flags_set.hxx>
32 // The following is not yet implemented, or just partially:
33 enum class SdrSearchOptions
36 DEEP
= 0x0001, /* recursive into group objects */
37 ALSOONMASTER
= 0x0002, /* MasterPages are also scanned */
38 WHOLEPAGE
= 0x0004, /* Not just the ObjList of PageView */
39 TESTMARKABLE
= 0x0008, /* just markable Objekte/Punkte/Handles/... */
40 TESTMACRO
= 0x0010, /* Just objects with macro */
41 TESTTEXTEDIT
= 0x0020, /* Just TextEdit-enabled objects */
42 WITHTEXT
= 0x0040, /* Just objects with text */
43 TESTTEXTAREA
= 0x0080, /* The textarea of objects with text (TextEditHit) */
44 BACKWARD
= 0x0100, /* Backwards search */
45 NEXT
= 0x0200, /* Search starts behind the transferred object/point/... */
46 MARKED
= 0x0400, /* Just marked objects/points/... */
47 PASS2BOUND
= 0x0800, /* In case of empty search results, then 2nd. try with BoundRectHit */
48 PASS3NEAREST
= 0x1000, /* In case of empty search results, then new 3rd. Try with NearestBoundRectHit */
49 BEFOREMARK
= 0x2000, /* if one marked one found, ignore all behind that */
51 IMPISMASTER
= 0x8000, /* MasterPage is being searched right now */
52 PICKMARKABLE
= TESTMARKABLE
,
53 PICKTEXTEDIT
= DEEP
| TESTMARKABLE
| TESTTEXTEDIT
,
54 PICKMACRO
= DEEP
| ALSOONMASTER
| WHOLEPAGE
| TESTMACRO
,
58 template<> struct typed_flags
<SdrSearchOptions
> : is_typed_flags
<SdrSearchOptions
, 0xbfff> {};
65 Handle
, // Marking handle
66 HelpLine
, // Reference line
67 Gluepoint
, // Glue point
68 TextEdit
, // Open OutlinerView was hit
69 TextEditObj
, // Object for SdrBeginTextEdit (Textbereich)
70 UrlField
, // Field in TextObj was hit (while it is currently not edited)
71 Macro
, // Object for BegMacroObj
72 MarkedObject
, // Marked object (e.g. for dragging)
73 UnmarkedObject
, // non-marked Object (e.g. for marking)
74 Cell
// hit on a cell inside a table shape (outside of the cells text area)
77 enum class SdrViewEditMode
{
78 Edit
, // Also known as arrow or pointer mode
79 Create
, // Tool for object creation
80 GluePointEdit
// Glue point editing mode
83 /** options for ImpTakeDescriptionStr() */
84 enum class ImpTakeDescriptionOptions
91 class ImplMarkingOverlay
;
93 class SVX_DLLPUBLIC SdrMarkView
: public SdrSnapView
95 friend class SdrPageView
;
97 // #114409#-3 Migrate selections
98 ImplMarkingOverlay
* mpMarkObjOverlay
;
99 ImplMarkingOverlay
* mpMarkPointsOverlay
;
100 ImplMarkingOverlay
* mpMarkGluePointsOverlay
;
103 SdrObject
* mpMarkedObj
; // If not just one object ( i.e. More than one object ) is marked.
104 SdrPageView
* mpMarkedPV
; // If all marked obects are situated on the same PageView.
106 Point maRef1
; // Persistent - Rotation center / axis of reflection
107 Point maRef2
; // Persistent
108 Point maLastCrookCenter
; // Persistent
109 SdrHdlList maHdlList
;
110 sdr::ViewSelection
* mpSdrViewSelection
;
112 Rectangle maMarkedObjRect
;
113 Rectangle maMarkedObjRectNoOffset
;
114 Rectangle maMarkedPointsRect
;
115 Rectangle maMarkedGluePointsRect
;
117 sal_uInt16 mnFrameHandlesLimit
;
118 sal_uIntPtr mnInsPointNum
; // Number of the InsPoint
120 SdrDragMode meDragMode
; // Persistent
121 SdrViewEditMode meEditMode
; // Persistent
122 SdrViewEditMode meEditMode0
; // Persistent
124 //HMHbool bHdlShown : 1;
125 bool mbDesignMode
: 1; // DesignMode for SdrUnoObj
126 bool mbForceFrameHandles
: 1; // Persistent - FrameDrag also for single objects
127 bool mbPlusHdlAlways
: 1; // Persistent
128 bool mbMarkHdlWhenTextEdit
: 1; // Persistent, default=FALSE
129 bool mbInsPolyPoint
: 1; // at this time InsPolyPointDragging
130 bool mbMarkedObjRectDirty
: 1;
131 bool mbMrkPntDirty
: 1;
132 bool mbMarkedPointsRectsDirty
: 1;
134 // flag to completely disable handles at the view
135 bool mbMarkHandlesHidden
: 1;
138 SVX_DLLPRIVATE
void ImpClearVars();
139 SVX_DLLPRIVATE
void ImpSetPointsRects() const;
140 void UndirtyMrkPnt() const;
143 virtual void Notify(SfxBroadcaster
& rBC
, const SfxHint
& rHint
) override
;
144 virtual void ModelHasChanged() override
; // Is called by the PaintView
145 virtual void SetMarkHandles(SfxViewShell
* pOtherShell
); // maHdlList - fill (List of handles)
146 void SetMarkRects(); // Rects at the PageViews
147 void CheckMarked(); // Scan MarkList after Del and Lock Layer ...
148 void AddDragModeHdl(SdrDragMode eMode
);
149 virtual bool MouseMove(const MouseEvent
& rMEvt
, vcl::Window
* pWin
) override
;
151 // add custom handles (used by other apps, e.g. AnchorPos)
152 virtual void AddCustomHdl();
154 void ForceRefToMarked();
155 void ForceUndirtyMrkPnt() const { if (mbMrkPntDirty
) UndirtyMrkPnt(); }
157 virtual SdrObject
* CheckSingleSdrObjectHit(const Point
& rPnt
, sal_uInt16 nTol
, SdrObject
* pObj
, SdrPageView
* pPV
, SdrSearchOptions nOptions
, const SetOfByte
* pMVisLay
) const;
158 SdrObject
* CheckSingleSdrObjectHit(const Point
& rPnt
, sal_uInt16 nTol
, SdrObjList
* pOL
, SdrPageView
* pPV
, SdrSearchOptions nOptions
, const SetOfByte
* pMVisLay
, SdrObject
*& rpRootObj
) const;
159 SdrObject
* CheckSingleSdrObjectHit(const Point
& rPnt
, sal_uInt16 nTol
, SdrObjList
* pOL
, SdrPageView
* pPV
, SdrSearchOptions nOptions
, const SetOfByte
* pMVisLay
, SdrObject
*& rpRootObj
,const SdrMarkList
* pMarkList
) const;
160 bool ImpIsFrameHandles() const;
161 void ImpTakeDescriptionStr(sal_uInt16 nStrCacheID
, OUString
& rStr
, ImpTakeDescriptionOptions nOpt
=ImpTakeDescriptionOptions::NONE
) const;
163 // Generates a string including degrees symbol, from an angel specification in 1/100deg
164 bool ImpMarkPoint(SdrHdl
* pHdl
, SdrMark
* pMark
, bool bUnmark
);
165 virtual bool MarkPoints(const Rectangle
* pRect
, bool bUnmark
);
166 bool MarkGluePoints(const Rectangle
* pRect
, bool bUnmark
);
168 void SetMoveOutside(bool bOn
);
171 // #i71538# make constructors of SdrView sub-components protected to avoid incomplete incarnations which may get casted to SdrView
172 SdrMarkView(SdrModel
* pModel1
, OutputDevice
* pOut
);
173 virtual ~SdrMarkView() override
;
176 virtual bool IsAction() const override
;
177 virtual void MovAction(const Point
& rPnt
) override
;
178 virtual void EndAction() override
;
179 virtual void BckAction() override
;
180 virtual void BrkAction() override
;
181 virtual void TakeActionRect(Rectangle
& rRect
) const override
;
183 virtual void ClearPageView() override
;
184 virtual void HideSdrPage() override
;
185 bool IsObjMarkable(SdrObject
* pObj
, SdrPageView
* pPV
) const;
187 // Returns sal_True if objects, points or glue points are selected by drawing a frame
188 // (as long as the frame is drawn).
189 bool IsMarking() const { return IsMarkObj() || IsMarkPoints() || IsMarkGluePoints(); }
191 // Marking objects by drawing of a selection frame
192 bool BegMarkObj(const Point
& rPnt
, bool bUnmark
= false);
193 void MovMarkObj(const Point
& rPnt
);
196 bool IsMarkObj() const { return (nullptr != mpMarkObjOverlay
); }
198 // DragModes: SDRDRAG_CREATE,SdrDragMode::Move,SdrDragMode::Resize,SdrDragMode::Rotate,SdrDragMode::Mirror,SdrDragMode::Shear,SdrDragMode::Crook
200 // The interface might maybe be changed in the future because of Ortho-Drag
201 void SetDragMode(SdrDragMode eMode
);
202 SdrDragMode
GetDragMode() const { return meDragMode
; }
203 void SetFrameHandles(bool bOn
);
204 bool IsFrameHandles() const { return mbForceFrameHandles
; }
206 sal_uIntPtr
GetMarkableObjCount() const;
208 void SetEditMode(SdrViewEditMode eMode
);
209 SdrViewEditMode
GetEditMode() const { return meEditMode
; }
211 void SetEditMode(bool bOn
) { SetEditMode(bOn
?SdrViewEditMode::Edit
:SdrViewEditMode::Create
); }
212 bool IsEditMode() const { return meEditMode
==SdrViewEditMode::Edit
; }
213 void SetCreateMode(bool bOn
) { SetEditMode(bOn
?SdrViewEditMode::Create
:SdrViewEditMode::Edit
); }
214 bool IsCreateMode() const { return meEditMode
==SdrViewEditMode::Create
; }
215 void SetGluePointEditMode(bool bOn
) { SetEditMode(bOn
?SdrViewEditMode::GluePointEdit
:meEditMode0
); }
216 bool IsGluePointEditMode() const { return meEditMode
==SdrViewEditMode::GluePointEdit
; }
218 void SetDesignMode(bool bOn
= true);
219 bool IsDesignMode() const { return mbDesignMode
; }
221 void SetFrameDragSingles(bool bOn
=true) { SetFrameHandles(bOn
); }
222 bool IsFrameDragSingles() const { return IsFrameHandles(); }
224 bool HasMarkableObj() const;
227 // migrate selections
230 // all available changing methods
231 SdrMarkList
& GetMarkedObjectListWriteAccess() { return mpSdrViewSelection
->GetMarkedObjectListWriteAccess(); }
234 // all available const methods for read access to selection
235 const SdrMarkList
& GetMarkedObjectList() const { return mpSdrViewSelection
->GetMarkedObjectList(); }
236 // returns SAL_MAX_SIZE if not found
237 size_t TryToFindMarkedObject(const SdrObject
* pObj
) const { return GetMarkedObjectList().FindObject(pObj
); }
238 SdrPageView
* GetSdrPageViewOfMarkedByIndex(size_t nNum
) const { return GetMarkedObjectList().GetMark(nNum
)->GetPageView(); }
239 SdrMark
* GetSdrMarkByIndex(size_t nNum
) const { return GetMarkedObjectList().GetMark(nNum
); }
240 SdrObject
* GetMarkedObjectByIndex(size_t nNum
) const { return (GetMarkedObjectList().GetMark(nNum
))->GetMarkedSdrObj(); }
241 size_t GetMarkedObjectCount() const { return GetMarkedObjectList().GetMarkCount(); }
242 void SortMarkedObjects() const { GetMarkedObjectList().ForceSort(); }
243 bool AreObjectsMarked() const { return 0 != GetMarkedObjectList().GetMarkCount(); }
244 OUString
GetDescriptionOfMarkedObjects() const { return GetMarkedObjectList().GetMarkDescription(); }
245 OUString
GetDescriptionOfMarkedPoints() const { return GetMarkedObjectList().GetPointMarkDescription(); }
246 OUString
GetDescriptionOfMarkedGluePoints() const { return GetMarkedObjectList().GetGluePointMarkDescription(); }
248 // Get a list of all those links which are connected to marked nodes,
249 // but which are not marked themselves.
250 const SdrMarkList
& GetEdgesOfMarkedNodes() const { return mpSdrViewSelection
->GetEdgesOfMarkedNodes(); }
251 const SdrMarkList
& GetMarkedEdgesOfMarkedNodes() const { return mpSdrViewSelection
->GetMarkedEdgesOfMarkedNodes(); }
252 const std::vector
<SdrObject
*>& GetTransitiveHullOfMarkedObjects() const { return mpSdrViewSelection
->GetAllMarkedObjects(); }
255 // mechanism to complete disable handles at the view. Handles will be hidden and deleted
256 // when set, no new ones created, no interaction allowed. Handles will be recreated and shown
257 // when reset. Default is false.
258 void hideMarkHandles();
259 void showMarkHandles();
260 bool areMarkHandlesHidden() const { return mbMarkHandlesHidden
; }
262 bool IsMarkedHit(const Point
& rPnt
, short nTol
=-2) const { return IsMarkedObjHit(rPnt
,nTol
); }
263 bool IsMarkedObjHit(const Point
& rPnt
, short nTol
=-2) const;
265 SdrHdl
* PickHandle(const Point
& rPnt
) const;
267 // Pick: Supported options for nOptions are:
268 // SdrSearchOptions::DEEP SdrSearchOptions::ALSOONMASTER SdrSearchOptions::TESTMARKABLE SdrSearchOptions::TESTTEXTEDIT
269 // SdrSearchOptions::WITHTEXT SdrSearchOptions::TESTTEXTAREA SdrSearchOptions::BACKWARD SdrSearchOptions::MARKED
270 // SdrSearchOptions::WHOLEPAGE
271 SdrObject
* PickObj(const Point
& rPnt
, short nTol
, SdrPageView
*& rpPV
, SdrSearchOptions nOptions
, SdrObject
** ppRootObj
, bool* pbHitPassDirect
=nullptr) const;
272 SdrObject
* PickObj(const Point
& rPnt
, short nTol
, SdrPageView
*& rpPV
, SdrSearchOptions nOptions
=SdrSearchOptions::NONE
) const;
273 bool MarkObj(const Point
& rPnt
, short nTol
=-2, bool bToggle
=false, bool bDeep
=false);
275 // Pick: Supported options for nOptions are SdrSearchOptions::PASS2BOUND und SdrSearchOptions::PASS3NEAREST
276 bool PickMarkedObj(const Point
& rPnt
, SdrObject
*& rpObj
, SdrPageView
*& rpPV
, SdrSearchOptions nOptions
) const;
278 // Selects the most upper of the marked objects (O1) and scans from there
279 // towards bottom direction, selecting the first non-marked object (O2).
280 // In case of success the marking of O1 is deleted, a marking is created at
281 // O2 and TRUE is returned. With the parameter bPrev=sal_True the scan
282 // direction is turned to the other direction.
283 bool MarkNextObj(bool bPrev
=false);
285 // Selects the most upper of the marked objects which is hit by rPnt/nTol
286 // and scans from there to bottom direction, selecting the first non-marked
287 // object (O2). In case of success the marking of O1 is deleted, a marking
288 // is created at O2 and sal_True is returned. With the parameter
289 // bPrev=sal_True the scan direction is turned to the other direction.
290 bool MarkNextObj(const Point
& rPnt
, short nTol
, bool bPrev
);
292 // Mark all objects within a rectangular area
293 // Just objects are marked which are inclosed completely
294 void MarkObj(const Rectangle
& rRect
, bool bUnmark
);
295 void MarkObj(SdrObject
* pObj
, SdrPageView
* pPV
, bool bUnmark
=false, bool bImpNoSetMarkHdl
=false);
296 void MarkAllObj(SdrPageView
* pPV
=nullptr); // pPage=NULL => all displayed pages
297 void UnmarkAllObj(SdrPageView
* pPV
=nullptr); // pPage=NULL => all displayed pages
299 // This function is time-consuming intensive, as the MarkList has to be scanned.
300 bool IsObjMarked(SdrObject
* pObj
) const;
301 // void MarkAll(SdrPageView* pPV=NULL) { MarkAllObj(pPV); } -> replace with inline
302 void UnMarkAll(SdrPageView
* pPV
=nullptr) { UnmarkAllObj(pPV
); }
304 // Request/set the size of the marking handles. Declaration in Pixel.
305 // The value is meant to be the edge length ( link length ).
306 // Pair values are round up to impair values: 3->3, 4->5, 5->5, 6->7, 7->7, ...
307 // Default value is 7, minimum value is 3 Pixels.
308 sal_uInt16
GetMarkHdlSizePixel() const;
309 void SetMarkHdlSizePixel(sal_uInt16 nSiz
);
311 virtual bool HasMarkablePoints() const;
312 virtual sal_uIntPtr
GetMarkablePointCount() const;
313 virtual bool HasMarkedPoints() const;
314 virtual sal_uIntPtr
GetMarkedPointCount() const;
316 // There might be points which can't be marked:
317 virtual bool IsPointMarkable(const SdrHdl
& rHdl
) const;
318 virtual bool MarkPoint(SdrHdl
& rHdl
, bool bUnmark
=false);
320 /** should only be used from outside svx for special ui elements */
321 bool MarkPointHelper(SdrHdl
* pHdl
, SdrMark
* pMark
, bool bUnmark
);
323 bool UnmarkPoint(SdrHdl
& rHdl
) { return MarkPoint(rHdl
,true); }
324 bool IsPointMarked(const SdrHdl
& rHdl
) const { ForceUndirtyMrkPnt(); return rHdl
.IsSelected(); }
325 bool MarkAllPoints() { return MarkPoints(nullptr,false); }
326 bool UnmarkAllPoints() { return MarkPoints(nullptr,true); }
328 // Selects the first marked point (P1) which is hit by rPnt
329 // and from there it searches the first non-marked point(P2).
330 // In case of success the marking of
331 // P1 is deleted, a mark is set at P2 and sal_True is returned.
332 // With the parameter bPrev=sal_True the scan direction is turned to the other direction.
333 bool MarkNextPoint(const Point
& rPnt
, bool bPrev
);
335 // Search for the number of the suitable handle. In case of empty search result,
336 // SAL_MAX_SIZE is returned.
337 size_t GetHdlNum(SdrHdl
* pHdl
) const { return maHdlList
.GetHdlNum(pHdl
); }
338 SdrHdl
* GetHdl(size_t nHdlNum
) const { return maHdlList
.GetHdl(nHdlNum
); }
339 const SdrHdlList
& GetHdlList() const { return maHdlList
; }
341 // Draw a selection frame for marking of points.
342 // This routine will just be started in case that HasMarkablePoints() returns sal_True.
343 bool BegMarkPoints(const Point
& rPnt
, bool bUnmark
= false);
344 void MovMarkPoints(const Point
& rPnt
);
345 bool EndMarkPoints();
346 void BrkMarkPoints();
347 bool IsMarkPoints() const { return (nullptr != mpMarkPointsOverlay
); }
349 // Select that additional handles are displayed permanently.
350 void SetPlusHandlesAlwaysVisible(bool bOn
);
351 bool IsPlusHandlesAlwaysVisible() const { return mbPlusHdlAlways
; }
353 // Are Handles visible during TextEdit (in double size)?
354 // Persistent, default=FALSE
355 void SetMarkHdlWhenTextEdit(bool bOn
) { mbMarkHdlWhenTextEdit
=bOn
; }
357 bool HasMarkableGluePoints() const;
358 bool HasMarkedGluePoints() const;
360 // A gluepoint is clearly identified by the SdrObject
361 // (to which it belongs) as well as by a sal_uInt16 nId (as each SdrObject may consist of
362 // several glue points. Here at the View there is an additional
363 // SdrPageView, which should be defined correctly always.
364 // Alternatively a gluepoint may be characterized by a SdrHdl.
365 // In this case the SdrHdl instance consists of all required information.
366 // And in this case, the glue point are always is marked by enforcement
367 // (Handlers are just situated at marked gluepoints )
368 // Attention: With each change of the glue point status the handle list is re-calculated.
369 // All previously saved SdrHdl* became invalid by this, the same with the point IDs!
370 bool PickGluePoint(const Point
& rPnt
, SdrObject
*& rpObj
, sal_uInt16
& rnId
, SdrPageView
*& rpPV
) const;
371 bool MarkGluePoint(const SdrObject
* pObj
, sal_uInt16 nId
, const SdrPageView
* pPV
, bool bUnmark
=false);
372 void UnmarkGluePoint(const SdrObject
* pObj
, sal_uInt16 nId
, const SdrPageView
* pPV
) { MarkGluePoint(pObj
,nId
,pPV
,true); }
373 bool IsGluePointMarked(const SdrObject
* pObj
, sal_uInt16 nId
) const;
375 // Get the Hdl (handle) of a marked GluePoint. Non-marked
376 // GluePoints don`t have handles
377 SdrHdl
* GetGluePointHdl(const SdrObject
* pObj
, sal_uInt16 nId
) const;
379 // Mark all points within this rectangular (View coordinates)
380 bool MarkAllGluePoints() { return MarkGluePoints(nullptr,false); }
381 bool UnmarkAllGluePoints() { return MarkGluePoints(nullptr,true); }
383 // Selects the first marked point (P1) which is hit by rPnt
384 // and from there it searches the first non-marked point(P2).
385 // In case of success the marking of
386 // P1 is deleted, a mark is set at P2 and sal_True is returned.
387 // With the parameter bPrev=sal_True the scan direction is turned to the other direction.
388 bool MarkNextGluePoint(const Point
& rPnt
, bool bPrev
);
390 // Draw a selection frame for glue point marking.
391 // This routine will just be started in case that HasMarkablePoints() returns sal_True.
392 // The GlueEditMode sal_True is disregarded.
393 // bool BegMarkGluePoints(const Point& rPnt, OutputDevice* pOut);
394 bool BegMarkGluePoints(const Point
& rPnt
, bool bUnmark
= false);
395 void MovMarkGluePoints(const Point
& rPnt
);
396 void EndMarkGluePoints();
397 void BrkMarkGluePoints();
398 bool IsMarkGluePoints() const { return (nullptr != mpMarkGluePointsOverlay
); }
400 // bRestraintPaint=sal_False causes the handles not to be drawn immediately.
401 // AdjustMarkHdl is just called in case of changes; usually this causes an Invalidate
402 // At the end of a redraw the handles are drawn automatically.
403 // The purpose is to avoid unnecessary flickering. -> This does not yet work, that's why sal_True!
404 void AdjustMarkHdl(SfxViewShell
* pOtherShell
= nullptr); //HMHBOOL bRestraintPaint=sal_True);
406 const Rectangle
& GetMarkedObjRect() const; // SnapRects of Objects, without line width
407 Rectangle
GetMarkedObjBoundRect() const; // incl. line width, overlapping rags, ...
408 const Rectangle
& GetMarkedPointsRect() const; // Enclosing rectangle of all marked points
409 const Rectangle
& GetMarkedGluePointsRect() const; // Enclosing rectangle of all marked glue points
410 const Rectangle
& GetAllMarkedRect() const { return GetMarkedObjRect(); }
411 Rectangle
GetAllMarkedBoundRect() const { return GetMarkedObjBoundRect(); }
412 Point
GetGridOffset() const;
414 // Will be always called, if the list of marked objects might be changed.
415 // If you override this method, be sure that you call the
416 // methods of the base class!
417 virtual void MarkListHasChanged();
419 // Entering (Editing) of a maybe marked object group. If there are several
420 // object groups marked, the most upper group is selected. After that
421 // all member objects of the group are directly accessible. All other
422 // objects may not be processed in the meantime (until the next
423 // LeaveGroup()). With markings which overlaps pages, every page is processed
424 // separately. The method returns sal_True, if at least one group was entered.
425 void EnterMarkedGroup();
427 // Is set by DragView automatically when finishing a Crook-Drag.
428 void SetLastCrookCenter(const Point
& rPt
) { maLastCrookCenter
=rPt
; }
430 // Rotation center point and start point of the axis of reflextion, respecively
431 const Point
& GetRef1() const { return maRef1
; }
432 void SetRef1(const Point
& rPt
);
434 // End point of the axis of reflextion
435 const Point
& GetRef2() const { return maRef1
; }
436 void SetRef2(const Point
& rPt
);
437 /// Get access to the view shell owning this draw view, if any.
438 virtual SfxViewShell
* GetSfxViewShell() const;
443 // It has to be declared in logical coordinates. So please translate the
444 // wanted pixel value with PixelToLogic in Logical values.
445 // Taking as example a logical value of 100:
446 // - For a horizontal hairline (Object with height 0), the generated data is +/-100, i.e.
447 // a vertical area of 200 logical units is sensitive.
448 // - For a polygon, a rectangular of the size (200,200) is generated and a
449 // touch test between Poly and this Rect is processed.
450 // - Obects which respond SdrObject::HasEdit()==TRUE ( e.g. a text frame ),
451 // are specially treated: An additional sensitive area with a width of
452 // 2*Tol (200 units for this example) is created around the object.
453 // When an object is directly hit, the Edit method is called.
454 // In opposite, a hit in the surrounding sensitive area enables Dragging.
457 #endif // INCLUDED_SVX_SVDMRKV_HXX
459 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */