LibreOffice Module sc (master) 1
drawsh.cxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
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 .
18 */
19
20#include <svx/svxdlg.hxx>
21#include <svx/dialogs.hrc>
22#include <sc.hrc>
23
24#include <editeng/eeitem.hxx>
25#include <svx/fontwork.hxx>
26#include <svx/svdpage.hxx>
27#include <sfx2/app.hxx>
28#include <sfx2/objface.hxx>
29#include <sfx2/objsh.hxx>
30#include <sfx2/request.hxx>
31#include <sfx2/dispatch.hxx>
32#include <sfx2/viewfrm.hxx>
33#include <svl/whiter.hxx>
34
35#include <drawsh.hxx>
36#include <drwlayer.hxx>
37#include <strings.hrc>
38#include <viewdata.hxx>
39#include <document.hxx>
40#include <drawview.hxx>
41#include <scresid.hxx>
42#include <svx/svdobj.hxx>
43#include <tabvwsh.hxx>
44#include <gridwin.hxx>
45#include <sfx2/bindings.hxx>
46
47#define ShellClass_ScDrawShell
48#include <scslots.hxx>
49
50#include <userdat.hxx>
51#include <svl/macitem.hxx>
52#include <sfx2/evntconf.hxx>
53#include <sfx2/viewsh.hxx>
54#include <com/sun/star/util/XModifiable.hpp>
55#include <memory>
56#include <svx/xlnwtit.hxx>
57#include <svx/chrtitem.hxx>
58#include <svx/xlnclit.hxx>
59#include <svx/xflclit.hxx>
60#include <svx/xflgrit.hxx>
62#include <comphelper/lok.hxx>
63#include <vcl/unohelp2.hxx>
64
65using namespace css;
66
68
69namespace
70{
71 void lcl_convertStringArguments(SfxItemSet& rArgs)
72 {
73 if (const SvxDoubleItem* pWidthItem = rArgs.GetItemIfSet(SID_ATTR_LINE_WIDTH_ARG, false))
74 {
75 double fValue = pWidthItem->GetValue();
76 // FIXME: different units...
77 int nPow = 100;
78 int nValue = fValue * nPow;
79
81 rArgs.Put(aItem);
82 }
83 if (const SfxStringItem* pJSON = rArgs.GetItemIfSet(SID_FILL_GRADIENT_JSON, false))
84 {
85 basegfx::BGradient aGradient = basegfx::BGradient::fromJSON(pJSON->GetValue());
86 XFillGradientItem aItem(aGradient);
87 rArgs.Put(aItem);
88 }
89 }
90}
91
93{
95 SfxVisibilityFlags::Standard | SfxVisibilityFlags::Server,
96 ToolbarId::Draw_Objectbar);
97
99
100 GetStaticInterface()->RegisterChildWindow(SvxFontWorkChildWindow::GetChildWindowId());
101}
102
103// disable the unwanted Accelerators
104
106{
107 SfxWhichIter aIter(rSet);
108 sal_uInt16 nWhich = aIter.FirstWhich();
109
110 while (nWhich)
111 {
112 rSet.DisableItem( nWhich );
113 nWhich = aIter.NextWhich();
114 }
115}
116
118{
119 const SfxObjectShell* pShell = GetObjectShell();
120 if ( pShell )
121 {
122 css::uno::Reference< css::util::XModifiable > xModif( pShell->GetModel(), css::uno::UNO_QUERY );
123 if ( xModif.is() )
124 xModif->setModified( true );
125 }
126}
127
128static void lcl_invalidateTransformAttr(const ScTabViewShell* pViewShell)
129{
130 SfxBindings& rBindings=pViewShell->GetViewFrame().GetBindings();
131 rBindings.Invalidate(SID_ATTR_TRANSFORM_WIDTH);
132 rBindings.Invalidate(SID_ATTR_TRANSFORM_HEIGHT);
133 rBindings.Invalidate(SID_ATTR_TRANSFORM_POS_X);
134 rBindings.Invalidate(SID_ATTR_TRANSFORM_POS_Y);
135 rBindings.Invalidate(SID_ATTR_TRANSFORM_ANGLE);
136 rBindings.Invalidate(SID_ATTR_TRANSFORM_ROT_X);
137 rBindings.Invalidate(SID_ATTR_TRANSFORM_ROT_Y);
138 rBindings.Invalidate(SID_ATTR_TRANSFORM_AUTOWIDTH);
139 rBindings.Invalidate(SID_ATTR_TRANSFORM_AUTOHEIGHT);
140}
141
143{
144 sal_uInt16 nSlot = rReq.GetSlot();
148
149 const SdrMarkList& rMarkList = pView->GetMarkedObjectList();
150 const size_t nMarkCount = rMarkList.GetMarkCount();
151 SdrObject* pSingleSelectedObj = nullptr;
152 if ( nMarkCount > 0 )
153 pSingleSelectedObj = rMarkList.GetMark( 0 )->GetMarkedSdrObj();
154
155 switch ( nSlot )
156 {
157 case SID_ASSIGNMACRO:
158 {
159 if ( pSingleSelectedObj )
160 ExecuteMacroAssign(pSingleSelectedObj, pWin ? pWin->GetFrameWeld() : nullptr);
161 }
162 break;
163
164 case SID_CELL_FORMAT_RESET:
165 case SID_TEXT_STANDARD:
166 {
169
170 if (ScDrawLayer::IsNoteCaption(pSingleSelectedObj))
171 aEmptyAttr.Put(pView->GetAttrFromMarked(true));
172
173 pView->SetAttributes(aEmptyAttr, true);
174 }
175 break;
176 case SID_MOVE_SHAPE_HANDLE:
177 {
178 const SfxItemSet *pArgs = rReq.GetArgs ();
179 if (pArgs && pArgs->Count () >= 3)
180 {
181 const SfxUInt32Item* handleNumItem = rReq.GetArg<SfxUInt32Item>(FN_PARAM_1);
182 const SfxUInt32Item* newPosXTwips = rReq.GetArg<SfxUInt32Item>(FN_PARAM_2);
183 const SfxUInt32Item* newPosYTwips = rReq.GetArg<SfxUInt32Item>(FN_PARAM_3);
184 const SfxInt32Item* OrdNum = rReq.GetArg<SfxInt32Item>(FN_PARAM_4);
185
186 const sal_uLong handleNum = handleNumItem->GetValue();
187 const sal_uLong newPosX = convertTwipToMm100(newPosXTwips->GetValue());
188 const sal_uLong newPosY = convertTwipToMm100(newPosYTwips->GetValue());
189
191 pView->MoveShapeHandle(handleNum, Point(bNegateX ? -static_cast<tools::Long>(newPosX) : newPosX, newPosY), OrdNum ? OrdNum->GetValue() : -1);
192 }
193 }
194 break;
195
196 case SID_ATTR_LINE_STYLE:
197 case SID_ATTR_LINEEND_STYLE:
198 case SID_ATTR_LINE_START:
199 case SID_ATTR_LINE_END:
200 case SID_ATTR_LINE_DASH:
201 case SID_ATTR_LINE_WIDTH:
202 case SID_ATTR_LINE_COLOR:
203 case SID_ATTR_LINE_TRANSPARENCE:
204 case SID_ATTR_LINE_JOINT:
205 case SID_ATTR_LINE_CAP:
206 case SID_ATTR_FILL_STYLE:
207 case SID_ATTR_FILL_COLOR:
208 case SID_ATTR_FILL_GRADIENT:
209 case SID_ATTR_FILL_HATCH:
210 case SID_ATTR_FILL_BITMAP:
211 case SID_ATTR_FILL_TRANSPARENCE:
212 case SID_ATTR_FILL_FLOATTRANSPARENCE:
213
214 // #i25616#
215 case SID_ATTR_FILL_SHADOW:
216 case SID_ATTR_SHADOW_TRANSPARENCE:
217 case SID_ATTR_SHADOW_COLOR:
218 case SID_ATTR_SHADOW_XDISTANCE:
219 case SID_ATTR_SHADOW_YDISTANCE:
220 {
221 // if toolbar is vertical :
222 if ( !rReq.GetArgs() )
223 {
224 switch ( nSlot )
225 {
226 case SID_ATTR_LINE_STYLE:
227 case SID_ATTR_LINE_DASH:
228 case SID_ATTR_LINE_WIDTH:
229 case SID_ATTR_LINE_COLOR:
230 case SID_ATTR_LINE_TRANSPARENCE:
231 case SID_ATTR_LINE_JOINT:
232 case SID_ATTR_LINE_CAP:
233 ExecuteLineDlg( rReq );
234 break;
235
236 case SID_ATTR_FILL_STYLE:
237 case SID_ATTR_FILL_COLOR:
238 case SID_ATTR_FILL_GRADIENT:
239 case SID_ATTR_FILL_HATCH:
240 case SID_ATTR_FILL_BITMAP:
241 case SID_ATTR_FILL_TRANSPARENCE:
242 case SID_ATTR_FILL_FLOATTRANSPARENCE:
243
244 // #i25616#
245 case SID_ATTR_FILL_SHADOW:
246 case SID_ATTR_SHADOW_TRANSPARENCE:
247 case SID_ATTR_SHADOW_COLOR:
248 case SID_ATTR_SHADOW_XDISTANCE:
249 case SID_ATTR_SHADOW_YDISTANCE:
250 ExecuteAreaDlg( rReq );
251 break;
252
253 default:
254 break;
255 }
256
257 return;
258
259 }
260
261 if( pView->AreObjectsMarked() )
262 {
263 std::unique_ptr<SfxItemSet> aNewArgs = rReq.GetArgs()->Clone();
264 lcl_convertStringArguments(*aNewArgs);
265 pView->SetAttrToMarked(*aNewArgs, false);
266 }
267 else
268 pView->SetDefaultAttr( *rReq.GetArgs(), false);
269 pView->InvalidateAttribs();
270 }
271 break;
272
273 case SID_ATTRIBUTES_LINE:
274 ExecuteLineDlg( rReq );
275 break;
276
277 case SID_ATTRIBUTES_AREA:
278 ExecuteAreaDlg( rReq );
279 break;
280
281 case SID_MEASURE_DLG:
282 ExecuteMeasureDlg( rReq );
283 break;
284
285 case SID_DRAWTEXT_ATTR_DLG:
286 ExecuteTextAttrDlg( rReq );
287 break;
288
289 case SID_EDIT_HYPERLINK:
290 if ( pSingleSelectedObj )
291 rViewData.GetDispatcher().Execute( SID_HYPERLINK_DIALOG );
292 break;
293
294 case SID_REMOVE_HYPERLINK:
295 if ( pSingleSelectedObj )
296 {
297 pSingleSelectedObj->setHyperlink(OUString());
298 setModified();
299 }
300 break;
301
302 case SID_OPEN_HYPERLINK:
303 case SID_COPY_HYPERLINK_LOCATION:
304 if ( nMarkCount == 1 )
305 {
306 SdrObject* pObj = rMarkList.GetMark( 0 )->GetMarkedSdrObj();
307 if ( pObj->IsGroupObject() )
308 {
309 SdrPageView* pPV = nullptr;
310 SdrObject* pHit = pView->PickObj(pWin->PixelToLogic(rViewData.GetMousePosPixel()), pView->getHitTolLog(), pPV, SdrSearchOptions::DEEP);
311 if (pHit)
312 pObj = pHit;
313 }
314
315 if (!pObj->getHyperlink().isEmpty())
316 {
317 if (nSlot == SID_OPEN_HYPERLINK)
318 {
319 ScGlobal::OpenURL(pObj->getHyperlink(), OUString(), true);
320 }
321 else if (nSlot == SID_COPY_HYPERLINK_LOCATION)
322 {
323 uno::Reference<datatransfer::clipboard::XClipboard> xClipboard
326 }
327 }
328 }
329 break;
330
331 case SID_ATTR_TRANSFORM:
332 {
333 if ( pView->AreObjectsMarked() )
334 {
335 const SfxItemSet* pArgs = rReq.GetArgs();
336
337 if( !pArgs )
338 {
339 if( rMarkList.GetMark(0) != nullptr )
340 {
341 SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
342 std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
343
344 if( pObj->GetObjIdentifier() == SdrObjKind::Caption )
345 {
346 // Caption Itemset
347 SfxItemSet aNewAttr(pDoc->GetItemPool());
348 pView->GetAttributes(aNewAttr);
349 // Size and Position Itemset
350 SfxItemSet aNewGeoAttr(pView->GetGeoAttrFromMarked());
351
353 VclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateCaptionDialog(pWin ? pWin->GetFrameWeld() : nullptr, pView));
354
355 const WhichRangesContainer& pRange = pDlg->GetInputRanges( *aNewAttr.GetPool() );
356 SfxItemSet aCombSet( *aNewAttr.GetPool(), pRange );
357 aCombSet.Put( aNewAttr );
358 aCombSet.Put( aNewGeoAttr );
359 pDlg->SetInputSet( &aCombSet );
360
361 pDlg->StartExecuteAsync([pDlg, pRequest, pView, this](
362 sal_Int32 nResult){
363 if (nResult == RET_OK)
364 {
365 pRequest->Done(*(pDlg->GetOutputItemSet()));
366 pView->SetAttributes(*pDlg->GetOutputItemSet());
367 pView->SetGeoAttrToMarked(*pDlg->GetOutputItemSet());
368 }
369
371 pDlg->disposeOnce();
372 });
373 }
374 else
375 {
376 SfxItemSet aNewAttr(pView->GetGeoAttrFromMarked());
378 VclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxTransformTabDialog(pWin ? pWin->GetFrameWeld() : nullptr, &aNewAttr, pView));
379
380 pDlg->StartExecuteAsync([pDlg, pRequest, pView, this](
381 sal_Int32 nResult){
382 if (nResult == RET_OK)
383 {
384 pRequest->Done(*(pDlg->GetOutputItemSet()));
385 pView->SetGeoAttrToMarked(*pDlg->GetOutputItemSet());
386 }
387
389 pDlg->disposeOnce();
390 });
391 }
392 }
393
394 }
395 else
396 pView->SetGeoAttrToMarked( *pArgs );
397 }
398
400 }
401 break;
402
403 case SID_ATTR_GLOW_COLOR:
404 case SID_ATTR_GLOW_RADIUS:
405 case SID_ATTR_GLOW_TRANSPARENCY:
406 case SID_ATTR_SOFTEDGE_RADIUS:
407 case SID_ATTR_TEXTCOLUMNS_NUMBER:
408 case SID_ATTR_TEXTCOLUMNS_SPACING:
409 if (const SfxItemSet* pNewArgs = rReq.GetArgs())
410 pView->SetAttrToMarked(*pNewArgs, false);
411 rReq.Done();
412 break;
413
414 default:
415 break;
416 }
417}
418
420{
421 SvxMacroItem aItem ( SfxGetpApp()->GetPool().GetWhich( SID_ATTR_MACROITEM ) );
422 ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj, true );
423 if ( !pInfo->GetMacro().isEmpty() )
424 {
426 const OUString& sMacro = pInfo->GetMacro();
427 aTab.Insert(SvMacroItemId::OnClick, SvxMacro(sMacro, OUString()));
428 aItem.SetMacroTable( aTab );
429 }
430
431 // create empty itemset for macro-dlg
433 aItemSet.Put ( aItem );
434
435 SfxEventNamesItem aNamesItem(SID_EVENTCONFIG);
436 aNamesItem.AddEvent( ScResId(RID_SCSTR_ONCLICK), OUString(), SvMacroItemId::OnClick );
437 aItemSet.Put( aNamesItem );
438
439 css::uno::Reference < css::frame::XFrame > xFrame;
440 if (GetViewShell())
442
444 ScopedVclPtr<SfxAbstractDialog> pMacroDlg(pFact->CreateEventConfigDialog( pWin, aItemSet, xFrame ));
445 if ( pMacroDlg->Execute() != RET_OK )
446 return;
447
448 const SfxItemSet* pOutSet = pMacroDlg->GetOutputItemSet();
449 const SvxMacroItem* pItem = pOutSet->GetItemIfSet( SID_ATTR_MACROITEM, false );
450 if( !pItem )
451 return;
452
453 OUString sMacro;
454 const SvxMacro* pMacro = pItem->GetMacroTable().Get( SvMacroItemId::OnClick );
455 if ( pMacro )
456 sMacro = pMacro->GetMacName();
457
458 if ( pObj->IsGroupObject() )
459 {
460 SdrObjList* pOL = pObj->GetSubList();
461 const size_t nObj = pOL->GetObjCount();
462 for ( size_t index=0; index<nObj; ++index )
463 {
464 pInfo = ScDrawLayer::GetMacroInfo( pOL->GetObj(index), true );
465 pInfo->SetMacro( sMacro );
466 }
467 }
468 else
469 pInfo->SetMacro( sMacro );
470 setModified();
471}
472
474{
476 bool bHasMarked = pView->AreObjectsMarked();
477 const SdrObject* pObj = nullptr;
478 const SdrMarkList& rMarkList = pView->GetMarkedObjectList();
479
480 std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
481
482 if( rMarkList.GetMarkCount() == 1 )
483 pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
484
485 SfxItemSet aNewAttr( pView->GetDefaultAttr() );
486 if( bHasMarked )
487 pView->MergeAttrFromMarked( aNewAttr, false );
488
491 &aNewAttr,
493 pObj,
494 bHasMarked));
495
496 pDlg->StartExecuteAsync([=](sal_Int32 nResult){
497 if ( nResult == RET_OK )
498 {
499 if( bHasMarked )
500 pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
501 else
502 pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
503
504 pView->InvalidateAttribs();
505 pRequest->Done();
506 }
507 pDlg->disposeOnce();
508 });
509}
510
512{
514 bool bHasMarked = pView->AreObjectsMarked();
515
516 std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
517
518 SfxItemSet aNewAttr( pView->GetDefaultAttr() );
519 if( bHasMarked )
520 pView->MergeAttrFromMarked( aNewAttr, false );
521
525 pWin, &aNewAttr,
526 rViewData.GetDocument().GetDrawLayer(), true, false));
527
528 pDlg->StartExecuteAsync([=](sal_Int32 nResult){
529 if ( nResult == RET_OK )
530 {
531 if( bHasMarked )
532 pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
533 else
534 pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
535
536 pView->InvalidateAttribs();
537 pRequest->Done();
538 }
539 pDlg->disposeOnce();
540 });
541}
542
544{
546 bool bHasMarked = pView->AreObjectsMarked();
547 SfxItemSet aNewAttr ( pView->GetDefaultAttr() );
548
549 if( bHasMarked )
550 pView->MergeAttrFromMarked( aNewAttr, false );
551
554 ScopedVclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog(pWin, &aNewAttr, pView));
555
556 sal_uInt16 nResult = pDlg->Execute();
557
558 if ( RET_OK == nResult )
559 {
560 if ( bHasMarked )
561 pView->SetAttributes( *pDlg->GetOutputItemSet() );
562 else
563 pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
564
565 pView->InvalidateAttribs();
566 rReq.Done();
567 }
568}
569
571{
573 bool bHasMarked = pView->AreObjectsMarked();
574 SfxItemSet aNewAttr ( pView->GetDefaultAttr() );
575
576 if( bHasMarked )
577 pView->MergeAttrFromMarked( aNewAttr, false );
578
581 ScopedVclPtr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog(pWin, aNewAttr, pView, RID_SVXPAGE_MEASURE));
582
583 sal_uInt16 nResult = pDlg->Execute();
584
585 if ( RET_OK == nResult )
586 {
587 if ( bHasMarked )
588 pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
589 else
590 pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
591
592 pView->InvalidateAttribs();
593 rReq.Done();
594 }
595}
596
597/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
constexpr auto convertTwipToMm100(N n)
SfxApplication * SfxGetpApp()
#define GetWhich(nSlot)
sal_uInt32 GetValue() const
SC_DLLPUBLIC ScDrawLayer * GetDrawLayer()
Definition: document.hxx:1084
SC_DLLPUBLIC bool IsLayoutRTL(SCTAB nTab) const
Definition: document.cxx:974
static bool IsNoteCaption(SdrObject *pObj)
Returns true, if the passed object is the caption of a cell note.
Definition: drwlayer.cxx:2901
static ScMacroInfo * GetMacroInfo(SdrObject *pObj, bool bCreate=false)
Definition: drwlayer.cxx:2913
void ExecuteLineDlg(const SfxRequest &rReq)
Definition: drawsh.cxx:473
void ExecDrawAttr(SfxRequest &rReq)
Definition: drawsh.cxx:142
void ExecuteAreaDlg(const SfxRequest &rReq)
Definition: drawsh.cxx:511
void ExecuteTextAttrDlg(SfxRequest &rReq)
Definition: drawsh.cxx:543
void ExecuteMacroAssign(SdrObject *pObj, weld::Window *pWin)
Definition: drawsh.cxx:419
static void InitInterface_Impl()
SfxInterface initializer.
Definition: drawsh.cxx:92
ScViewData & rViewData
Definition: drawsh.hxx:41
void ExecuteMeasureDlg(SfxRequest &rReq)
Definition: drawsh.cxx:570
void setModified()
Definition: drawsh.cxx:117
static void StateDisableItems(SfxItemSet &rSet)
Definition: drawsh.cxx:105
void InvalidateAttribs()
Definition: drawview.cxx:153
static void OpenURL(const OUString &rURL, const OUString &rTarget, bool bIgnoreSettings=false)
Open the specified URL.
Definition: global.cxx:810
const OUString & GetMacro() const
Definition: userdat.hxx:82
void SetMacro(const OUString &rMacro)
Definition: userdat.hxx:81
SfxDispatcher & GetDispatcher()
Definition: viewdata.cxx:3140
Point GetMousePosPixel()
Definition: viewdata.cxx:4001
SCTAB GetTabNo() const
Definition: viewdata.hxx:395
ScDocument & GetDocument() const
Definition: viewdata.hxx:380
ScGridWindow * GetActiveWin()
Definition: viewdata.cxx:3162
ScTabViewShell * GetViewShell() const
Definition: viewdata.hxx:357
weld::Window * GetDialogParent()
Definition: viewdata.cxx:3156
ScDrawView * GetScDrawView()
Definition: viewdata.cxx:3174
SfxItemSet GetAttrFromMarked(bool bOnlyHardAttr) const
void SetAttrToMarked(const SfxItemSet &rAttr, bool bReplaceAll)
void SetGeoAttrToMarked(const SfxItemSet &rAttr, bool addPageMargin=false)
void MergeAttrFromMarked(SfxItemSet &rAttr, bool bOnlyHardAttr) const
SfxItemSet GetGeoAttrFromMarked() const
size_t GetMarkCount() const
SdrMark * GetMark(size_t nNum) const
const SdrMarkList & GetMarkedObjectList() const
bool AreObjectsMarked() const
SdrObject * PickObj(const Point &rPnt, short nTol, SdrPageView *&rpPV, SdrSearchOptions nOptions, SdrObject **ppRootObj, bool *pbHitPassDirect=nullptr) const
SdrObject * GetMarkedSdrObj() const
const SfxItemPool & GetItemPool() const
SdrObject * GetObj(size_t nNum) const
size_t GetObjCount() const
const OUString & getHyperlink() const
virtual SdrObjList * GetSubList() const
bool IsGroupObject() const
virtual SdrObjKind GetObjIdentifier() const
void setHyperlink(const OUString &sHyperlink)
const SfxItemSet & GetDefaultAttr() const
void SetDefaultAttr(const SfxItemSet &rAttr, bool bReplaceAll)
sal_uInt16 getHitTolLog() const
bool SetAttributes(const SfxItemSet &rSet, bool bReplaceAll=false)
bool MoveShapeHandle(const sal_uInt32 handleNum, const Point &aEndPoint, const sal_Int32 aObjectOrdNum=-1)
void GetAttributes(SfxItemSet &rTargetSet, bool bOnlyHardAttr=false) const
void Invalidate(sal_uInt16 nId)
const SfxPoolItem * Execute(sal_uInt16 nSlot, SfxCallMode nCall=SfxCallMode::SLOT, const SfxPoolItem **pArgs=nullptr, sal_uInt16 nModi=0, const SfxPoolItem **pInternalArgs=nullptr)
void AddEvent(const OUString &, const OUString &, SvMacroItemId)
const css::uno::Reference< css::frame::XFrame > & GetFrameInterface() const
void RegisterPopupMenu(const OUString &)
void RegisterChildWindow(sal_uInt16, bool bContext=false)
void RegisterObjectBar(sal_uInt16, SfxVisibilityFlags nFlags, ToolbarId eId)
SfxItemPool * GetPool() const
sal_uInt16 Count() const
virtual std::unique_ptr< SfxItemSet > Clone(bool bItems=true, SfxItemPool *pToPool=nullptr) const
const T * GetItemIfSet(TypedWhichId< T > nWhich, bool bSrchInParent=true) const
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
void DisableItem(sal_uInt16 nWhich)
css::uno::Reference< css::frame::XModel3 > GetModel() const
sal_uInt16 GetSlot() const
const SfxItemSet * GetArgs() const
const T * GetArg(sal_uInt16 nSlotId) const
void Done(bool bRemove=false)
SfxItemPool & GetPool() const
virtual SfxObjectShell * GetObjectShell()
static SfxInterface * GetStaticInterface()
SfxViewShell * GetViewShell() const
SfxBindings & GetBindings()
SfxFrame & GetFrame() const
SfxViewFrame & GetViewFrame() const
vcl::Window * GetWindow() const
sal_uInt16 FirstWhich()
sal_uInt16 NextWhich()
virtual VclPtr< AbstractSvxAreaTabDialog > CreateSvxAreaTabDialog(weld::Window *pParent, const SfxItemSet *pAttr, SdrModel *pModel, bool bShadow, bool bSlideBackground)=0
virtual VclPtr< SfxAbstractTabDialog > CreateTextTabDialog(weld::Window *pParent, const SfxItemSet *pAttrSet, SdrView *pView)=0
virtual VclPtr< SfxAbstractDialog > CreateEventConfigDialog(weld::Widget *pParent, const SfxItemSet &rAttr, const css::uno::Reference< css::frame::XFrame > &rFrame)=0
virtual VclPtr< AbstractSvxTransformTabDialog > CreateSvxTransformTabDialog(weld::Window *pParent, const SfxItemSet *pAttr, const SdrView *pView, SvxAnchorIds nAnchorTypes=SvxAnchorIds::NONE)=0
virtual VclPtr< SfxAbstractDialog > CreateSfxDialog(weld::Window *pParent, const SfxItemSet &rAttr, const SdrView *pView, sal_uInt32 nResId)=0
virtual VclPtr< AbstractSvxCaptionDialog > CreateCaptionDialog(weld::Window *pParent, const SdrView *pView, SvxAnchorIds nAnchorTypes=SvxAnchorIds::NONE)=0
virtual VclPtr< SfxAbstractTabDialog > CreateSvxLineTabDialog(weld::Window *pParent, const SfxItemSet *pAttr, SdrModel *pModel, const SdrObject *pObj, bool bHasObj)=0
static SvxAbstractDialogFactory * Create()
const SvxMacroTableDtor & GetMacroTable() const
void SetMacroTable(const SvxMacroTableDtor &rTbl)
SvxMacro & Insert(SvMacroItemId nEvent, const SvxMacro &rMacro)
const SvxMacro * Get(SvMacroItemId nEvent) const
const OUString & GetMacName() const
static BGradient fromJSON(std::u16string_view rJSON)
Point PixelToLogic(const Point &rDevicePt) const
weld::Window * GetFrameWeld() const
css::uno::Reference< css::datatransfer::clipboard::XClipboard > GetClipboard()
static void CopyStringTo(const OUString &rContent, const css::uno::Reference< css::datatransfer::clipboard::XClipboard > &rxClipboard, const vcl::ILibreOfficeKitNotifier *pNotifier=nullptr)
static void lcl_invalidateTransformAttr(const ScTabViewShell *pViewShell)
Definition: drawsh.cxx:128
sal_Int16 nValue
index
long Long
#define SFX_OBJECTBAR_OBJECT
OUString ScResId(TranslateId aId)
Definition: scdll.cxx:90
static SfxItemSet & rSet
#define SFX_IMPL_INTERFACE(Class, SuperClass)
sal_uIntPtr sal_uLong
Reference< XFrame > xFrame
constexpr TypedWhichId< SdrMetricItem > SDRATTR_TEXT_MAXFRAMEHEIGHT(SDRATTR_MISC_FIRST+9)
constexpr TypedWhichId< SdrMetricItem > SDRATTR_TEXT_MINFRAMEHEIGHT(SDRATTR_MISC_FIRST+1)
constexpr TypedWhichId< SdrMetricItem > SDRATTR_TEXT_MAXFRAMEWIDTH(SDRATTR_MISC_FIRST+11)
RET_OK