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>
61 #include <editeng/colritem.hxx>
62 
64 
65 namespace
66 {
67  void lcl_convertStringArguments(sal_uInt16 nSlot, const std::unique_ptr<SfxItemSet>& pArgs)
68  {
69  Color aColor;
70  const SfxPoolItem* pItem = nullptr;
71 
72  if (SfxItemState::SET == pArgs->GetItemState(SID_ATTR_LINE_WIDTH_ARG, false, &pItem))
73  {
74  double fValue = static_cast<const SvxDoubleItem*>(pItem)->GetValue();
75  // FIXME: different units...
76  int nPow = 100;
77  int nValue = fValue * nPow;
78 
79  XLineWidthItem aItem(nValue);
80  pArgs->Put(aItem);
81  }
82  else if (SfxItemState::SET == pArgs->GetItemState(SID_ATTR_COLOR_STR, false, &pItem))
83  {
84  OUString sColor = static_cast<const SfxStringItem*>(pItem)->GetValue();
85 
86  if (sColor == "transparent")
87  aColor = COL_TRANSPARENT;
88  else
89  aColor = Color(sColor.toInt32(16));
90 
91  switch (nSlot)
92  {
93  case SID_ATTR_LINE_COLOR:
94  {
95  XLineColorItem aLineColorItem(OUString(), aColor);
96  pArgs->Put(aLineColorItem);
97  break;
98  }
99 
100  case SID_ATTR_FILL_COLOR:
101  {
102  XFillColorItem aFillColorItem(OUString(), aColor);
103  pArgs->Put(aFillColorItem);
104  break;
105  }
106 
107  case SID_ATTR_SHADOW_COLOR:
108  {
109  XColorItem aItem(SDRATTR_SHADOWCOLOR, aColor);
110  pArgs->Put(aItem);
111  break;
112  }
113  }
114  }
115  if (SfxItemState::SET == pArgs->GetItemState(SID_FILL_GRADIENT_JSON, false, &pItem))
116  {
117  const SfxStringItem* pJSON = static_cast<const SfxStringItem*>(pItem);
118  if (pJSON)
119  {
120  XGradient aGradient = XGradient::fromJSON(pJSON->GetValue());
121  XFillGradientItem aItem(aGradient);
122  pArgs->Put(aItem);
123  }
124  }
125  }
126 }
127 
129 {
131  SfxVisibilityFlags::Standard | SfxVisibilityFlags::Server,
132  ToolbarId::Draw_Objectbar);
133 
135 
136  GetStaticInterface()->RegisterChildWindow(SvxFontWorkChildWindow::GetChildWindowId());
137 }
138 
139 // disable the unwanted Accelerators
140 
142 {
143  SfxWhichIter aIter(rSet);
144  sal_uInt16 nWhich = aIter.FirstWhich();
145 
146  while (nWhich)
147  {
148  rSet.DisableItem( nWhich );
149  nWhich = aIter.NextWhich();
150  }
151 }
152 
153 static void lcl_setModified( const SfxObjectShell* pShell )
154 {
155  if ( pShell )
156  {
157  css::uno::Reference< css::util::XModifiable > xModif( pShell->GetModel(), css::uno::UNO_QUERY );
158  if ( xModif.is() )
159  xModif->setModified( true );
160  }
161 }
162 
163 static void lcl_invalidateTransformAttr(const ScTabViewShell* pViewShell)
164 {
165  SfxBindings& rBindings=pViewShell->GetViewFrame()->GetBindings();
166  rBindings.Invalidate(SID_ATTR_TRANSFORM_WIDTH);
167  rBindings.Invalidate(SID_ATTR_TRANSFORM_HEIGHT);
168  rBindings.Invalidate(SID_ATTR_TRANSFORM_POS_X);
169  rBindings.Invalidate(SID_ATTR_TRANSFORM_POS_Y);
170  rBindings.Invalidate(SID_ATTR_TRANSFORM_ANGLE);
171  rBindings.Invalidate(SID_ATTR_TRANSFORM_ROT_X);
172  rBindings.Invalidate(SID_ATTR_TRANSFORM_ROT_Y);
173  rBindings.Invalidate(SID_ATTR_TRANSFORM_AUTOWIDTH);
174  rBindings.Invalidate(SID_ATTR_TRANSFORM_AUTOHEIGHT);
175 }
176 
178 {
179  sal_uInt16 nSlot = rReq.GetSlot();
183 
184  const SdrMarkList& rMarkList = pView->GetMarkedObjectList();
185  const size_t nMarkCount = rMarkList.GetMarkCount();
186  SdrObject* pSingleSelectedObj = nullptr;
187  if ( nMarkCount > 0 )
188  pSingleSelectedObj = rMarkList.GetMark( 0 )->GetMarkedSdrObj();
189 
190  switch ( nSlot )
191  {
192  case SID_ASSIGNMACRO:
193  {
194  if ( pSingleSelectedObj )
195  ExecuteMacroAssign(pSingleSelectedObj, pWin ? pWin->GetFrameWeld() : nullptr);
196  }
197  break;
198 
199  case SID_TEXT_STANDARD: // delete hard text attributes
200  {
202  pView->SetAttributes(aEmptyAttr, true);
203  }
204  break;
205 
206  case SID_ATTR_LINE_STYLE:
207  case SID_ATTR_LINEEND_STYLE:
208  case SID_ATTR_LINE_START:
209  case SID_ATTR_LINE_END:
210  case SID_ATTR_LINE_DASH:
211  case SID_ATTR_LINE_WIDTH:
212  case SID_ATTR_LINE_COLOR:
213  case SID_ATTR_LINE_TRANSPARENCE:
214  case SID_ATTR_LINE_JOINT:
215  case SID_ATTR_LINE_CAP:
216  case SID_ATTR_FILL_STYLE:
217  case SID_ATTR_FILL_COLOR:
218  case SID_ATTR_FILL_GRADIENT:
219  case SID_ATTR_FILL_HATCH:
220  case SID_ATTR_FILL_BITMAP:
221  case SID_ATTR_FILL_TRANSPARENCE:
222  case SID_ATTR_FILL_FLOATTRANSPARENCE:
223 
224  // #i25616#
225  case SID_ATTR_FILL_SHADOW:
226  case SID_ATTR_SHADOW_TRANSPARENCE:
227  case SID_ATTR_SHADOW_COLOR:
228  case SID_ATTR_SHADOW_XDISTANCE:
229  case SID_ATTR_SHADOW_YDISTANCE:
230  {
231  // if toolbar is vertical :
232  if ( !rReq.GetArgs() )
233  {
234  switch ( nSlot )
235  {
236  case SID_ATTR_LINE_STYLE:
237  case SID_ATTR_LINE_DASH:
238  case SID_ATTR_LINE_WIDTH:
239  case SID_ATTR_LINE_COLOR:
240  case SID_ATTR_LINE_TRANSPARENCE:
241  case SID_ATTR_LINE_JOINT:
242  case SID_ATTR_LINE_CAP:
243  ExecuteLineDlg( rReq );
244  break;
245 
246  case SID_ATTR_FILL_STYLE:
247  case SID_ATTR_FILL_COLOR:
248  case SID_ATTR_FILL_GRADIENT:
249  case SID_ATTR_FILL_HATCH:
250  case SID_ATTR_FILL_BITMAP:
251  case SID_ATTR_FILL_TRANSPARENCE:
252  case SID_ATTR_FILL_FLOATTRANSPARENCE:
253 
254  // #i25616#
255  case SID_ATTR_FILL_SHADOW:
256  case SID_ATTR_SHADOW_TRANSPARENCE:
257  case SID_ATTR_SHADOW_COLOR:
258  case SID_ATTR_SHADOW_XDISTANCE:
259  case SID_ATTR_SHADOW_YDISTANCE:
260  ExecuteAreaDlg( rReq );
261  break;
262 
263  default:
264  break;
265  }
266 
267  return;
268 
269  }
270 
271  if( pView->AreObjectsMarked() )
272  {
273  std::unique_ptr<SfxItemSet> pNewArgs = rReq.GetArgs()->Clone();
274  lcl_convertStringArguments( rReq.GetSlot(), pNewArgs );
275  pView->SetAttrToMarked( *pNewArgs, false );
276  }
277  else
278  pView->SetDefaultAttr( *rReq.GetArgs(), false);
279  pView->InvalidateAttribs();
280  }
281  break;
282 
283  case SID_ATTRIBUTES_LINE:
284  ExecuteLineDlg( rReq );
285  break;
286 
287  case SID_ATTRIBUTES_AREA:
288  ExecuteAreaDlg( rReq );
289  break;
290 
291  case SID_MEASURE_DLG:
292  ExecuteMeasureDlg( rReq );
293  break;
294 
295  case SID_DRAWTEXT_ATTR_DLG:
296  ExecuteTextAttrDlg( rReq );
297  break;
298 
299  case SID_DRAW_HLINK_EDIT:
300  if ( pSingleSelectedObj )
301  rViewData.GetDispatcher().Execute( SID_HYPERLINK_DIALOG );
302  break;
303 
304  case SID_DRAW_HLINK_DELETE:
305  if ( pSingleSelectedObj )
306  SetHlinkForObject( pSingleSelectedObj, OUString() );
307  break;
308 
309  case SID_OPEN_HYPERLINK:
310  if ( nMarkCount == 1 )
311  {
312  SdrObject* pObj = rMarkList.GetMark( 0 )->GetMarkedSdrObj();
313  if ( pObj->IsGroupObject() )
314  {
315  SdrPageView* pPV = nullptr;
316  SdrObject* pHit = pView->PickObj(pWin->PixelToLogic(rViewData.GetMousePosPixel()), pView->getHitTolLog(), pPV, SdrSearchOptions::DEEP);
317  if (pHit)
318  pObj = pHit;
319  }
320 
321  ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj );
322  if ( pInfo && !pInfo->GetHlink().isEmpty() )
323  ScGlobal::OpenURL( pInfo->GetHlink(), OUString(), true );
324  }
325  break;
326 
327  case SID_ATTR_TRANSFORM:
328  {
329  if ( pView->AreObjectsMarked() )
330  {
331  const SfxItemSet* pArgs = rReq.GetArgs();
332 
333  if( !pArgs )
334  {
335  if( rMarkList.GetMark(0) != nullptr )
336  {
337  SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
338  std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
339 
340  if( pObj->GetObjIdentifier() == OBJ_CAPTION )
341  {
342  // Caption Itemset
343  SfxItemSet aNewAttr(pDoc->GetItemPool());
344  pView->GetAttributes(aNewAttr);
345  // Size and Position Itemset
346  SfxItemSet aNewGeoAttr(pView->GetGeoAttrFromMarked());
347 
349  VclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateCaptionDialog(pWin ? pWin->GetFrameWeld() : nullptr, pView));
350 
351  const sal_uInt16* pRange = pDlg->GetInputRanges( *aNewAttr.GetPool() );
352  SfxItemSet aCombSet( *aNewAttr.GetPool(), pRange );
353  aCombSet.Put( aNewAttr );
354  aCombSet.Put( aNewGeoAttr );
355  pDlg->SetInputSet( &aCombSet );
356 
357  pDlg->StartExecuteAsync([pDlg, pRequest, pView, this](
358  sal_Int32 nResult){
359  if (nResult == RET_OK)
360  {
361  pRequest->Done(*(pDlg->GetOutputItemSet()));
362  pView->SetAttributes(*pDlg->GetOutputItemSet());
363  pView->SetGeoAttrToMarked(*pDlg->GetOutputItemSet());
364  }
365 
367  pDlg->disposeOnce();
368  });
369  }
370  else
371  {
372  SfxItemSet aNewAttr(pView->GetGeoAttrFromMarked());
374  VclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateSvxTransformTabDialog(pWin ? pWin->GetFrameWeld() : nullptr, &aNewAttr, pView));
375 
376  pDlg->StartExecuteAsync([pDlg, pRequest, pView, this](
377  sal_Int32 nResult){
378  if (nResult == RET_OK)
379  {
380  pRequest->Done(*(pDlg->GetOutputItemSet()));
381  pView->SetGeoAttrToMarked(*pDlg->GetOutputItemSet());
382  }
383 
385  pDlg->disposeOnce();
386  });
387  }
388  }
389 
390  }
391  else
392  pView->SetGeoAttrToMarked( *pArgs );
393  }
394 
396  }
397  break;
398 
399  case SID_ATTR_GLOW_COLOR:
400  case SID_ATTR_GLOW_RADIUS:
401  case SID_ATTR_GLOW_TRANSPARENCY:
402  case SID_ATTR_SOFTEDGE_RADIUS:
403  if (const SfxItemSet* pNewArgs = rReq.GetArgs())
404  pView->SetAttrToMarked(*pNewArgs, false);
405  rReq.Done();
406  break;
407 
408  default:
409  break;
410  }
411 }
412 
414 {
415  SvxMacroItem aItem ( SfxGetpApp()->GetPool().GetWhich( SID_ATTR_MACROITEM ) );
416  ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj, true );
417  if ( !pInfo->GetMacro().isEmpty() )
418  {
419  SvxMacroTableDtor aTab;
420  const OUString& sMacro = pInfo->GetMacro();
421  aTab.Insert(SvMacroItemId::OnClick, SvxMacro(sMacro, OUString()));
422  aItem.SetMacroTable( aTab );
423  }
424 
425  // create empty itemset for macro-dlg
427  pItemSet->Put ( aItem );
428 
429  SfxEventNamesItem aNamesItem(SID_EVENTCONFIG);
430  aNamesItem.AddEvent( ScResId(RID_SCSTR_ONCLICK), OUString(), SvMacroItemId::OnClick );
431  pItemSet->Put( aNamesItem );
432 
433  css::uno::Reference < css::frame::XFrame > xFrame;
434  if (GetViewShell())
436 
438  ScopedVclPtr<SfxAbstractDialog> pMacroDlg(pFact->CreateEventConfigDialog( pWin, *pItemSet, xFrame ));
439  if ( pMacroDlg->Execute() != RET_OK )
440  return;
441 
442  const SfxItemSet* pOutSet = pMacroDlg->GetOutputItemSet();
443  const SfxPoolItem* pItem;
444  if( SfxItemState::SET != pOutSet->GetItemState( SID_ATTR_MACROITEM, false, &pItem ))
445  return;
446 
447  OUString sMacro;
448  const SvxMacro* pMacro = static_cast<const SvxMacroItem*>(pItem)->GetMacroTable().Get( SvMacroItemId::OnClick );
449  if ( pMacro )
450  sMacro = pMacro->GetMacName();
451 
452  if ( pObj->IsGroupObject() )
453  {
454  SdrObjList* pOL = pObj->GetSubList();
455  const size_t nObj = pOL->GetObjCount();
456  for ( size_t index=0; index<nObj; ++index )
457  {
458  pInfo = ScDrawLayer::GetMacroInfo( pOL->GetObj(index), true );
459  pInfo->SetMacro( sMacro );
460  }
461  }
462  else
463  pInfo->SetMacro( sMacro );
465 }
466 
468 {
470  bool bHasMarked = pView->AreObjectsMarked();
471  const SdrObject* pObj = nullptr;
472  const SdrMarkList& rMarkList = pView->GetMarkedObjectList();
473 
474  std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
475 
476  if( rMarkList.GetMarkCount() == 1 )
477  pObj = rMarkList.GetMark(0)->GetMarkedSdrObj();
478 
479  SfxItemSet aNewAttr( pView->GetDefaultAttr() );
480  if( bHasMarked )
481  pView->MergeAttrFromMarked( aNewAttr, false );
482 
485  &aNewAttr,
487  pObj,
488  bHasMarked));
489 
490  pDlg->StartExecuteAsync([=](sal_Int32 nResult){
491  if ( nResult == RET_OK )
492  {
493  if( bHasMarked )
494  pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
495  else
496  pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
497 
498  pView->InvalidateAttribs();
499  pRequest->Done();
500  }
501  pDlg->disposeOnce();
502  });
503 }
504 
506 {
508  bool bHasMarked = pView->AreObjectsMarked();
509 
510  std::shared_ptr<SfxRequest> pRequest = std::make_shared<SfxRequest>(rReq);
511 
512  SfxItemSet aNewAttr( pView->GetDefaultAttr() );
513  if( bHasMarked )
514  pView->MergeAttrFromMarked( aNewAttr, false );
515 
519  pWin, &aNewAttr,
520  rViewData.GetDocument().GetDrawLayer(), true));
521 
522  pDlg->StartExecuteAsync([=](sal_Int32 nResult){
523  if ( nResult == RET_OK )
524  {
525  if( bHasMarked )
526  pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
527  else
528  pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
529 
530  pView->InvalidateAttribs();
531  pRequest->Done();
532  }
533  pDlg->disposeOnce();
534  });
535 }
536 
538 {
540  bool bHasMarked = pView->AreObjectsMarked();
541  SfxItemSet aNewAttr ( pView->GetDefaultAttr() );
542 
543  if( bHasMarked )
544  pView->MergeAttrFromMarked( aNewAttr, false );
545 
548  ScopedVclPtr<SfxAbstractTabDialog> pDlg(pFact->CreateTextTabDialog(pWin, &aNewAttr, pView));
549 
550  sal_uInt16 nResult = pDlg->Execute();
551 
552  if ( RET_OK == nResult )
553  {
554  if ( bHasMarked )
555  pView->SetAttributes( *pDlg->GetOutputItemSet() );
556  else
557  pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
558 
559  pView->InvalidateAttribs();
560  rReq.Done();
561  }
562 }
563 
565 {
567  bool bHasMarked = pView->AreObjectsMarked();
568  SfxItemSet aNewAttr ( pView->GetDefaultAttr() );
569 
570  if( bHasMarked )
571  pView->MergeAttrFromMarked( aNewAttr, false );
572 
575  ScopedVclPtr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog(pWin, aNewAttr, pView, RID_SVXPAGE_MEASURE));
576 
577  sal_uInt16 nResult = pDlg->Execute();
578 
579  if ( RET_OK == nResult )
580  {
581  if ( bHasMarked )
582  pView->SetAttrToMarked( *pDlg->GetOutputItemSet(), false );
583  else
584  pView->SetDefaultAttr( *pDlg->GetOutputItemSet(), false );
585 
586  pView->InvalidateAttribs();
587  rReq.Done();
588  }
589 }
590 
591 void ScDrawShell::SetHlinkForObject( SdrObject* pObj, const OUString& rHlnk )
592 {
593  if ( pObj )
594  {
595  ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj, true );
596  pInfo->SetHlink( rHlnk );
598  }
599 }
600 
601 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
SfxViewFrame * GetViewFrame() const
ScViewData & rViewData
Definition: drawsh.hxx:42
SvxMacro & Insert(SvMacroItemId nEvent, const SvxMacro &rMacro)
size_t GetMarkCount() const
#define SFX_IMPL_INTERFACE(Class, SuperClass)
static SfxInterface * GetStaticInterface()
const OUString & GetMacro() const
Definition: userdat.hxx:84
virtual const SfxItemSet * GetOutputItemSet() const =0
std::string GetValue
static XGradient fromJSON(const OUString &rJSON)
bool AreObjectsMarked() const
static SvxAbstractDialogFactory * Create()
void RegisterObjectBar(sal_uInt16, SfxVisibilityFlags nFlags, ToolbarId eId)
static ScMacroInfo * GetMacroInfo(SdrObject *pObj, bool bCreate=false)
Definition: drwlayer.cxx:2321
Reference< XFrame > xFrame
void SetGeoAttrToMarked(const SfxItemSet &rAttr)
SdrObject * GetObj(size_t nNum) const
size_t GetObjCount() const
virtual VclPtr< SfxAbstractDialog > CreateEventConfigDialog(weld::Widget *pParent, const SfxItemSet &rAttr, const css::uno::Reference< css::frame::XFrame > &rFrame)=0
void InvalidateAttribs()
Definition: drawview.cxx:151
static void OpenURL(const OUString &rURL, const OUString &rTarget, bool bIgnoreSettings=false)
Open the specified URL.
Definition: global.cxx:760
sal_uInt16 FirstWhich()
void Done(bool bRemove=false)
SdrMark * GetMark(size_t nNum) const
ScDocument & GetDocument() const
Definition: viewdata.hxx:380
css::uno::Reference< css::frame::XModel > GetModel() const
void MergeAttrFromMarked(SfxItemSet &rAttr, bool bOnlyHardAttr) const
const SfxItemSet * GetArgs() const
void Invalidate(sal_uInt16 nId)
void RegisterPopupMenu(const OUString &)
virtual SdrObjList * GetSubList() const
sal_uInt16 NextWhich()
virtual const sal_uInt16 * GetInputRanges(const SfxItemPool &)=0
SfxApplication * SfxGetpApp()
SfxItemSet GetGeoAttrFromMarked() const
virtual void SetInputSet(const SfxItemSet *pInSet)=0
weld::Window * GetFrameWeld() const
void SetAttrToMarked(const SfxItemSet &rAttr, bool bReplaceAll)
constexpr::Color COL_TRANSPARENT(0xFF, 0xFF, 0xFF, 0xFF)
OBJ_CAPTION
static void lcl_invalidateTransformAttr(const ScTabViewShell *pViewShell)
Definition: drawsh.cxx:163
SfxFrame & GetFrame() const
constexpr TypedWhichId< XColorItem > SDRATTR_SHADOWCOLOR(SDRATTR_SHADOW_FIRST+1)
virtual VclPtr< SfxAbstractDialog > CreateSfxDialog(weld::Window *pParent, const SfxItemSet &rAttr, const SdrView *pView, sal_uInt32 nResId)=0
const SfxItemSet & GetDefaultAttr() const
void RegisterChildWindow(sal_uInt16, bool bContext=false)
ScDrawView * GetScDrawView()
Definition: viewdata.cxx:3074
SfxItemPool & GetPool() const
ScTabViewShell * GetViewShell() const
Definition: viewdata.hxx:357
SdrObject * GetMarkedSdrObj() const
SdrObject * PickObj(const Point &rPnt, short nTol, SdrPageView *&rpPV, SdrSearchOptions nOptions, SdrObject **ppRootObj, bool *pbHitPassDirect=nullptr) const
SC_DLLPUBLIC ScDrawLayer * GetDrawLayer()
Definition: document.hxx:1059
void AddEvent(const OUString &, const OUString &, SvMacroItemId)
SfxItemState GetItemState(sal_uInt16 nWhich, bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
void SetHlinkForObject(SdrObject *pObj, const OUString &rHlnk)
Definition: drawsh.cxx:591
virtual sal_uInt16 GetObjIdentifier() const
SfxBindings & GetBindings()
void SetHlink(const OUString &rHlink)
Definition: userdat.hxx:86
const OUString & GetValue() const
const SdrMarkList & GetMarkedObjectList() const
bool SetAttributes(const SfxItemSet &rSet, bool bReplaceAll=false)
void SetMacro(const OUString &rMacro)
Definition: userdat.hxx:83
static void lcl_setModified(const SfxObjectShell *pShell)
Definition: drawsh.cxx:153
OUString ScResId(const char *pId)
Definition: scdll.cxx:95
ScGridWindow * GetActiveWin()
Definition: viewdata.cxx:3062
bool IsGroupObject() const
tuple index
void SetDefaultAttr(const SfxItemSet &rAttr, bool bReplaceAll)
weld::Window * GetDialogParent()
Definition: viewdata.cxx:3056
void ExecuteAreaDlg(const SfxRequest &rReq)
Definition: drawsh.cxx:505
SfxViewShell * GetViewShell() const
static void InitInterface_Impl()
SfxInterface initializer.
Definition: drawsh.cxx:128
const css::uno::Reference< css::frame::XFrame > & GetFrameInterface() const
#define SFX_OBJECTBAR_OBJECT
static void StateDisableItems(SfxItemSet &rSet)
Definition: drawsh.cxx:141
Point PixelToLogic(const Point &rDevicePt) const
Point GetMousePosPixel()
Definition: viewdata.cxx:3889
virtual VclPtr< SfxAbstractTabDialog > CreateTextTabDialog(weld::Window *pParent, const SfxItemSet *pAttrSet, SdrView *pView)=0
sal_uInt16 GetSlot() const
void ExecuteTextAttrDlg(SfxRequest &rReq)
Definition: drawsh.cxx:537
void DisableItem(sal_uInt16 nWhich)
#define GetWhich(nSlot)
virtual std::unique_ptr< SfxItemSet > Clone(bool bItems=true, SfxItemPool *pToPool=nullptr) const
virtual VclPtr< AbstractSvxAreaTabDialog > CreateSvxAreaTabDialog(weld::Window *pParent, const SfxItemSet *pAttr, SdrModel *pModel, bool bShadow)=0
void SetMacroTable(const SvxMacroTableDtor &rTbl)
void ExecDrawAttr(SfxRequest &rReq)
Definition: drawsh.cxx:177
void GetAttributes(SfxItemSet &rTargetSet, bool bOnlyHardAttr=false) const
SfxDispatcher & GetDispatcher()
Definition: viewdata.cxx:3040
RET_OK
const OUString & GetHlink() const
Definition: userdat.hxx:87
const SfxItemPool & GetItemPool() const
const SfxPoolItem * Execute(sal_uInt16 nSlot, SfxCallMode nCall=SfxCallMode::SLOT, const SfxPoolItem **pArgs=nullptr, sal_uInt16 nModi=0, const SfxPoolItem **pInternalArgs=nullptr)
void ExecuteLineDlg(const SfxRequest &rReq)
Definition: drawsh.cxx:467
sal_uInt16 getHitTolLog() const
void ExecuteMacroAssign(SdrObject *pObj, weld::Window *pWin)
Definition: drawsh.cxx:413
const OUString & GetMacName() const
virtual SfxObjectShell * GetObjectShell()
virtual VclPtr< SfxAbstractTabDialog > CreateSvxLineTabDialog(weld::Window *pParent, const SfxItemSet *pAttr, SdrModel *pModel, const SdrObject *pObj, bool bHasObj)=0
sal_Int16 nValue
void ExecuteMeasureDlg(SfxRequest &rReq)
Definition: drawsh.cxx:564