25#include <svx/svxids.hrc>
44#define ShellClass_BezierObjectBar
62 :
SfxShell(pSdViewShell->GetViewShell()),
64 mpViewSh(pSdViewShell)
91 if(
auto pFuSelection =
dynamic_cast< const FuSelection *
>( xFunc.get() ))
93 sal_uInt16 nEditMode = pFuSelection->GetEditMode();
98 sal_uInt16 nEditMode = pFuPolygon->GetEditMode();
123 IPolyPolygonEditorController* pIPPEC =
nullptr;
129 if ( !pIPPEC || !pIPPEC->IsRipUpAtMarkedPointsPossible())
133 if (!pIPPEC || !pIPPEC->IsDeleteMarkedPointsPossible())
137 if (!pIPPEC || !pIPPEC->IsSetMarkedSegmentsKindPossible())
147 case SdrPathSegmentKind::Line :
rSet.
Put(
SfxBoolItem(SID_BEZIER_CONVERT,
false));
break;
148 case SdrPathSegmentKind::Curve :
rSet.
Put(
SfxBoolItem(SID_BEZIER_CONVERT,
true));
break;
152 if (!pIPPEC || !pIPPEC->IsSetMarkedPointsSmoothPossible())
163 case SdrPathSmoothKind::DontCare :
break;
164 case SdrPathSmoothKind::Angular :
rSet.
Put(
SfxBoolItem(SID_BEZIER_EDGE,
true));
break;
165 case SdrPathSmoothKind::Asymmetric:
rSet.
Put(
SfxBoolItem(SID_BEZIER_SMOOTH,
true));
break;
166 case SdrPathSmoothKind::Symmetric :
rSet.
Put(
SfxBoolItem(SID_BEZIER_SYMMTR,
true));
break;
169 if (!pIPPEC || !pIPPEC->IsOpenCloseMarkedObjectsPossible())
198 sal_uInt16 nSId = rReq.
GetSlot();
202 case SID_BEZIER_CUTLINE:
203 case SID_BEZIER_CONVERT:
204 case SID_BEZIER_DELETE:
205 case SID_BEZIER_EDGE:
206 case SID_BEZIER_SMOOTH:
207 case SID_BEZIER_SYMMTR:
208 case SID_BEZIER_CLOSE:
212 IPolyPolygonEditorController* pIPPEC =
nullptr;
222 case SID_BEZIER_DELETE:
226 case SID_BEZIER_CUTLINE:
227 pIPPEC->RipUpAtMarkedPoints();
230 case SID_BEZIER_CONVERT:
232 pIPPEC->SetMarkedSegmentsKind(SdrPathSegmentKind::Toggle);
236 case SID_BEZIER_EDGE:
237 case SID_BEZIER_SMOOTH:
238 case SID_BEZIER_SYMMTR:
245 case SID_BEZIER_EDGE: eKind = SdrPathSmoothKind::Angular;
break;
246 case SID_BEZIER_SMOOTH: eKind = SdrPathSmoothKind::Asymmetric;
break;
247 case SID_BEZIER_SYMMTR: eKind = SdrPathSmoothKind::Symmetric;
break;
250 pIPPEC->SetMarkedPointsSmooth(eKind);
254 case SID_BEZIER_CLOSE:
282 case SID_BEZIER_ELIMINATE_POINTS:
290 case SID_BEZIER_MOVE:
291 case SID_BEZIER_INSERT:
297 if(
auto pFuSelection =
dynamic_cast<FuSelection *
>( xFunc.get() ))
299 pFuSelection->SetEditMode(rReq.
GetSlot());
303 pFuPolygon->SetEditMode(rReq.
GetSlot());
SAL_DLLPRIVATE SfxItemPool & GetPool()
virtual bool IsAction() const override
bool IsResizeAllowed(bool bProp=false) const
bool IsUndoEnabled() const
bool IsMoveAllowed() const
void AddUndo(std::unique_ptr< SdrUndoAction > pUndo)
size_t GetMarkCount() const
SdrMark * GetMark(size_t nNum) const
const SdrMarkList & GetMarkedObjectList() const
bool AreObjectsMarked() const
SdrObject * GetMarkedSdrObj() const
SdrUndoFactory & GetSdrUndoFactory() const
SdrModel & GetModel() const
void DeleteMarkedPoints() override
void SetEliminatePolyPoints(bool bOn)
bool IsEliminatePolyPoints() const
virtual std::unique_ptr< SdrUndoAction > CreateUndoGeoObject(SdrObject &rObject)
const SfxPoolItem * Execute(sal_uInt16 nSlot, SfxCallMode nCall=SfxCallMode::SLOT, const SfxPoolItem **pArgs=nullptr, sal_uInt16 nModi=0, const SfxPoolItem **pInternalArgs=nullptr)
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
void DisableItem(sal_uInt16 nWhich)
void InvalidateItem(sal_uInt16 nWhich)
sal_uInt16 GetSlot() const
void Done(bool bRemove=false)
void SetUndoManager(SfxUndoManager *pNewUndoMgr)
SfxItemPool & GetPool() const
void SetRepeatTarget(SfxRepeatTarget *pTarget)
virtual void Invalidate(sal_uInt16 nId=0)
void SetPool(SfxItemPool *pNewPool)
SfxDispatcher * GetDispatcher()
void GetAttrState(SfxItemSet &rSet)
Status of attribute items.
virtual ~BezierObjectBar() override
BezierObjectBar(ViewShell *pSdViewShell, View *pSdView)
void Execute(SfxRequest &rReq)
Process SfxRequests.
virtual SfxUndoManager * GetUndoManager() override
Base class of the stacked shell hierarchy.
SD_DLLPUBLIC DrawDocShell * GetDocSh() const
const rtl::Reference< FuPoor > & GetCurrentFunction() const
SD_DLLPUBLIC SfxViewFrame * GetViewFrame() const
virtual void GetAttributes(SfxItemSet &rTargetSet, bool bOnlyHardAttr=false) const
SmartTagSet & getSmartTags()
SdDrawDocument & GetDoc() const
OUString SdResId(TranslateId aId)
#define SFX_IMPL_INTERFACE(Class, SuperClass)