LibreOffice Module sw (master)  1
PageStylesPanel.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 #include <sal/config.h>
20 #include <svl/intitem.hxx>
21 #include <svx/colorbox.hxx>
22 #include <svx/drawitem.hxx>
23 #include <svx/xfillit0.hxx>
24 #include <svx/xflclit.hxx>
25 #include <svx/xflgrit.hxx>
26 #include <svx/xflhtit.hxx>
27 #include <svx/xbtmpit.hxx>
28 #include <svx/itemwin.hxx>
30 #include "PageStylesPanel.hxx"
31 #include <sfx2/dispatch.hxx>
32 #include <sfx2/bindings.hxx>
33 #include <sfx2/objsh.hxx>
34 #include <cmdid.h>
35 
36 using namespace ::com::sun::star;
37 
38 namespace sw::sidebar{
39 
40 namespace {
41 
42 enum eFillStyle
43 {
44  NONE,
45  SOLID,
46  GRADIENT,
47  HATCH,
48  BITMAP,
49  PATTERN
50 };
51 
52 }
53 
54 const SvxPageUsage aArr[] =
55 {
56  SvxPageUsage::All,
57  SvxPageUsage::Mirror,
58  SvxPageUsage::Right,
59  SvxPageUsage::Left
60 };
61 
62 
63 static sal_uInt16 PageUsageToPos_Impl( SvxPageUsage nUsage )
64 {
65  for ( size_t i = 0; i < SAL_N_ELEMENTS(aArr); ++i )
66  if ( aArr[i] == nUsage )
67  return i;
68  return 3;
69 }
70 
71 static SvxPageUsage PosToPageUsage_Impl( sal_uInt16 nPos )
72 {
73  if ( nPos >= SAL_N_ELEMENTS(aArr) )
74  return SvxPageUsage::NONE;
75  return aArr[nPos];
76 }
77 
78 std::unique_ptr<PanelLayout> PageStylesPanel::Create(weld::Widget* pParent, SfxBindings* pBindings)
79 {
80  if( pParent == nullptr )
81  throw ::com::sun::star::lang::IllegalArgumentException("no parent window given to PageStylesPanel::Create", nullptr, 0);
82  if( pBindings == nullptr )
83  throw ::com::sun::star::lang::IllegalArgumentException("no SfxBindings given to PageStylesPanel::Create", nullptr, 0);
84 
85  return std::make_unique<PageStylesPanel>(pParent, pBindings);
86 }
87 
89  weld::Widget* pParent,
90  SfxBindings* pBindings
91  ) :
92  PanelLayout(pParent, "PageStylesPanel", "modules/swriter/ui/pagestylespanel.ui"),
93  mpBindings( pBindings ),
94  mpPageColumnItem( new SfxInt16Item(SID_ATTR_PAGE_COLUMN) ),
95  mpPageItem( new SvxPageItem(SID_ATTR_PAGE) ),
96  maPageColumnControl(SID_ATTR_PAGE_COLUMN, *pBindings, *this),
97  maPageNumFormatControl( SID_ATTR_PAGE, *pBindings, *this ),
98  maBgColorControl( SID_ATTR_PAGE_COLOR, *pBindings, *this ),
99  maBgHatchingControl( SID_ATTR_PAGE_HATCH, *pBindings, *this ),
100  maBgGradientControl( SID_ATTR_PAGE_GRADIENT, *pBindings, *this ),
101  maBgBitmapControl( SID_ATTR_PAGE_BITMAP, *pBindings, *this ),
102  maBgFillStyleControl(SID_ATTR_PAGE_FILLSTYLE, *pBindings, *this),
103  mxBgColorLB(new ColorListBox(m_xBuilder->weld_menu_button("lbcolor"), [this]{ return GetFrameWeld(); })),
104  mxBgHatchingLB(m_xBuilder->weld_combo_box("lbhatching")),
105  mxBgGradientLB(new ColorListBox(m_xBuilder->weld_menu_button("lbgradient"), [this]{ return GetFrameWeld(); })),
106  mxBgBitmapLB(m_xBuilder->weld_combo_box("lbbitmap")),
107  mxLayoutSelectLB(m_xBuilder->weld_combo_box("layoutbox")),
108  mxColumnCount(m_xBuilder->weld_combo_box("columnbox")),
109  mxNumberSelectLB(new SvxPageNumberListBox(m_xBuilder->weld_combo_box("numberbox"))),
110  mxBgFillType(m_xBuilder->weld_combo_box("bgselect")),
111  mxCustomEntry(m_xBuilder->weld_label("customlabel")),
112  aCustomEntry()
113 {
114  Initialize();
115 }
116 
118 {
119  mxColumnCount.reset();
120  mxNumberSelectLB.reset();
121  mxBgFillType.reset();
122  mxBgColorLB.reset();
123  mxBgHatchingLB.reset();
124  mxBgGradientLB.reset();
125  mxBgBitmapLB.reset();
126  mxLayoutSelectLB.reset();
127  mxCustomEntry.reset();
128 
136 }
137 
139 {
141 
142  aCustomEntry = mxCustomEntry->get_label();
144  mpBindings->Invalidate(SID_ATTR_PAGE);
145  mpBindings->Invalidate(SID_ATTR_PAGE_FILLSTYLE);
146  Update();
147 
148  mxColumnCount->connect_changed( LINK(this, PageStylesPanel, ModifyColumnCountHdl) );
149  SvxNumOptionsTabPageHelper::GetI18nNumbering(mxNumberSelectLB->get_widget(), ::std::numeric_limits<sal_uInt16>::max());
150  mxNumberSelectLB->connect_changed( LINK(this, PageStylesPanel, ModifyNumberingHdl) );
151  mxLayoutSelectLB->connect_changed( LINK(this, PageStylesPanel, ModifyLayoutHdl) );
152  mxBgFillType->connect_changed( LINK(this, PageStylesPanel, ModifyFillStyleHdl));
153  mxBgColorLB->SetSelectHdl( LINK(this, PageStylesPanel, ModifyFillColorListHdl));
154  mxBgGradientLB->SetSelectHdl( LINK(this, PageStylesPanel, ModifyFillColorListHdl));
155  mxBgHatchingLB->connect_changed( LINK(this, PageStylesPanel, ModifyFillColorHdl));
156  mxBgBitmapLB->connect_changed( LINK(this, PageStylesPanel, ModifyFillColorHdl));
157 }
158 
160 {
161  const eFillStyle eXFS = static_cast<eFillStyle>(mxBgFillType->get_active());
163  switch(eXFS)
164  {
165  case NONE:
166  {
167  mxBgColorLB->hide();
168  mxBgHatchingLB->hide();
169  mxBgGradientLB->hide();
170  mxBgBitmapLB->hide();
171  }
172  break;
173  case SOLID:
174  {
175  mxBgBitmapLB->hide();
176  mxBgGradientLB->hide();
177  mxBgHatchingLB->hide();
178  mxBgColorLB->show();
179  const Color aColor = GetColorSetOrDefault();
180  mxBgColorLB->SelectEntry(aColor);
181  }
182  break;
183  case GRADIENT:
184  {
185  mxBgBitmapLB->hide();
186  mxBgHatchingLB->hide();
187  mxBgColorLB->show();
188  mxBgGradientLB->show();
189 
190  const XGradient xGradient = GetGradientSetOrDefault();
191  const Color aStartColor = xGradient.GetStartColor();
192  mxBgColorLB->SelectEntry(aStartColor);
193  const Color aEndColor = xGradient.GetEndColor();
194  mxBgGradientLB->SelectEntry(aEndColor);
195  }
196  break;
197 
198  case HATCH:
199  {
200  mxBgColorLB->hide();
201  mxBgGradientLB->hide();
202  mxBgBitmapLB->hide();
203  mxBgHatchingLB->show();
204  mxBgHatchingLB->clear();
205  SvxFillAttrBox::Fill(*mxBgHatchingLB, pSh->GetItem(SID_HATCH_LIST)->GetHatchList());
206 
207  const OUString aHatchName = GetHatchingSetOrDefault();
208  mxBgHatchingLB->set_active_text( aHatchName );
209  }
210  break;
211 
212  case BITMAP:
213  case PATTERN:
214  {
215  mxBgColorLB->hide();
216  mxBgGradientLB->hide();
217  mxBgHatchingLB->hide();
218  mxBgBitmapLB->show();
219  mxBgBitmapLB->clear();
220  OUString aBitmapName;
221 
222  if( eXFS == BITMAP )
223  {
224  SvxFillAttrBox::Fill(*mxBgBitmapLB, pSh->GetItem(SID_BITMAP_LIST)->GetBitmapList());
225  aBitmapName = GetBitmapSetOrDefault();
226  }
227  else
228  {
229  SvxFillAttrBox::Fill(*mxBgBitmapLB, pSh->GetItem(SID_PATTERN_LIST)->GetPatternList());
230  aBitmapName = GetPatternSetOrDefault();
231  }
232 
233  mxBgBitmapLB->set_active_text( aBitmapName );
234  }
235  break;
236 
237  default:
238  break;
239  }
240 }
241 
243 {
244  if ( !mpBgColorItem )
245  mpBgColorItem.reset( new XFillColorItem( OUString(), Color(0x72, 0x9f, 0xcf) ) );
246 
247  return mpBgColorItem->GetColorValue();
248 }
249 
251 {
252  if( !mpBgGradientItem )
253  {
255  const SvxGradientListItem * pGradListItem = pSh->GetItem(SID_GRADIENT_LIST);
256  const XGradient aGradient = pGradListItem->GetGradientList()->GetGradient(0)->GetGradient();
257  const OUString aGradientName = pGradListItem->GetGradientList()->GetGradient(0)->GetName();
258 
259  mpBgGradientItem.reset( new XFillGradientItem( aGradientName, aGradient ) );
260  }
261 
262  return mpBgGradientItem->GetGradientValue();
263 }
264 
266 {
267  if( !mpBgHatchItem )
268  {
270  const SvxHatchListItem * pHatchListItem = pSh->GetItem(SID_HATCH_LIST);
271  const XHatch aHatch = pHatchListItem->GetHatchList()->GetHatch(0)->GetHatch();
272  const OUString aHatchName = pHatchListItem->GetHatchList()->GetHatch(0)->GetName();
273 
274  mpBgHatchItem.reset( new XFillHatchItem( aHatchName, aHatch ) );
275  }
276 
277  return mpBgHatchItem->GetName();
278 }
279 
281 {
282  if( !mpBgBitmapItem || mpBgBitmapItem->isPattern() )
283  {
285  const SvxBitmapListItem * pBmpListItem = pSh->GetItem(SID_BITMAP_LIST);
286  const GraphicObject aGraphObj = pBmpListItem->GetBitmapList()->GetBitmap(0)->GetGraphicObject();
287  const OUString aBmpName = pBmpListItem->GetBitmapList()->GetBitmap(0)->GetName();
288 
289  mpBgBitmapItem.reset( new XFillBitmapItem( aBmpName, aGraphObj ) );
290  }
291 
292  return mpBgBitmapItem->GetName();
293 }
294 
296 {
297  if( !mpBgBitmapItem || !mpBgBitmapItem->isPattern() )
298  {
300  const SvxPatternListItem * pPatternListItem = pSh->GetItem(SID_PATTERN_LIST);
301  const GraphicObject aGraphObj = pPatternListItem->GetPatternList()->GetBitmap(0)->GetGraphicObject();
302  const OUString aPatternName = pPatternListItem->GetPatternList()->GetBitmap(0)->GetName();
303 
304  mpBgBitmapItem.reset( new XFillBitmapItem( aPatternName, aGraphObj ) );
305  }
306 
307  return mpBgBitmapItem->GetName();
308 }
309 
311  const sal_uInt16 nSid,
312  const SfxItemState eState,
313  const SfxPoolItem* pState)
314 {
315  if (!mxColumnCount) //disposed
316  return;
317 
318  switch(nSid)
319  {
321  {
322  if ( eState >= SfxItemState::DEFAULT &&
323  dynamic_cast< const SfxInt16Item *>( pState ) )
324  {
325  mpPageColumnItem.reset( static_cast<SfxInt16Item*>(pState->Clone()) );
326  if(mpPageColumnItem->GetValue() <= 5)
327  {
328  mxColumnCount->set_active(mpPageColumnItem->GetValue() - 1);
329  int nIndex = mxColumnCount->find_text(aCustomEntry);
330  if (nIndex != -1)
331  mxColumnCount->remove(nIndex);
332  }
333  else
334  {
335  if (mxColumnCount->find_text(aCustomEntry) == -1)
336  mxColumnCount->append_text(aCustomEntry);
337  mxColumnCount->set_active_text(aCustomEntry);
338  }
339  }
340  }
341  break;
342 
343  case SID_ATTR_PAGE:
344  {
345  if( eState >= SfxItemState::DEFAULT &&
346  dynamic_cast< const SvxPageItem*>( pState ) )
347  {
348  mpPageItem.reset( static_cast<SvxPageItem*>(pState->Clone()) );
349  SvxNumType eNumType = mpPageItem->GetNumType();
350  mxNumberSelectLB->set_active_id(eNumType);
351 
352  SvxPageUsage nUse = mpPageItem->GetPageUsage();
353  mxLayoutSelectLB->set_active( PageUsageToPos_Impl( nUse ) );
354  }
355  }
356  break;
357 
358  case SID_ATTR_PAGE_COLOR:
359  {
360  if(eState >= SfxItemState::DEFAULT)
361  {
362  mxBgFillType->set_active( static_cast<sal_Int32>(SOLID) );
363  mpBgColorItem.reset(pState ? static_cast< XFillColorItem* >(pState->Clone()) : nullptr);
364  Update();
365  }
366  }
367  break;
368 
369  case SID_ATTR_PAGE_HATCH:
370  {
371  if(eState >= SfxItemState::DEFAULT)
372  {
373  mxBgFillType->set_active( static_cast<sal_Int32>(HATCH) );
374  mpBgHatchItem.reset(pState ? static_cast < XFillHatchItem* >(pState->Clone()) : nullptr);
375  Update();
376  }
377  }
378  break;
379 
380  case SID_ATTR_PAGE_GRADIENT:
381  {
382  if(eState >= SfxItemState::DEFAULT)
383  {
384  mxBgFillType->set_active( static_cast<sal_Int32>(GRADIENT) );
385  mpBgGradientItem.reset(pState ? static_cast< XFillGradientItem* >(pState->Clone()) : nullptr);
386  Update();
387  }
388  }
389  break;
390  case SID_ATTR_PAGE_BITMAP:
391  {
392  if(eState >= SfxItemState::DEFAULT)
393  {
394  mpBgBitmapItem.reset(pState ? static_cast< XFillBitmapItem* >(pState->Clone()) : nullptr);
395  if (mpBgBitmapItem)
396  {
397  if (mpBgBitmapItem->isPattern())
398  mxBgFillType->set_active( static_cast<sal_Int32>(PATTERN) );
399  else
400  mxBgFillType->set_active( static_cast<sal_Int32>(BITMAP) );
401  }
402  Update();
403  }
404  }
405  break;
406 
407  case SID_ATTR_PAGE_FILLSTYLE:
408  {
409  const XFillStyleItem* pFillStyleItem = nullptr;
410  if (eState >= SfxItemState::DEFAULT)
411  pFillStyleItem = dynamic_cast< const XFillStyleItem* >(pState);
412  if (pFillStyleItem)
413  {
414  css::drawing::FillStyle eXFS = pFillStyleItem->GetValue();
415  switch(eXFS)
416  {
417  case drawing::FillStyle_NONE:
418  mxBgFillType->set_active( static_cast<sal_Int32>(NONE) );
419  break;
420  case drawing::FillStyle_SOLID:
421  mxBgFillType->set_active( static_cast<sal_Int32>(SOLID) );
422  break;
423  case drawing::FillStyle_GRADIENT:
424  mxBgFillType->set_active( static_cast<sal_Int32>(GRADIENT) );
425  break;
426  case drawing::FillStyle_HATCH:
427  mxBgFillType->set_active( static_cast<sal_Int32>(HATCH) );
428  break;
429  case drawing::FillStyle_BITMAP:
430  if (mpBgBitmapItem->isPattern())
431  mxBgFillType->set_active( static_cast<sal_Int32>(PATTERN) );
432  else
433  mxBgFillType->set_active( static_cast<sal_Int32>(BITMAP) );
434  break;
435  default:
436  break;
437  }
438  Update();
439  }
440  }
441  break;
442 
443  default:
444  break;
445  }
446 }
447 
448 IMPL_LINK_NOARG( PageStylesPanel, ModifyColumnCountHdl, weld::ComboBox&, void )
449 {
450  sal_uInt16 nColumnType = mxColumnCount->get_active() + 1;
451  mpPageColumnItem->SetValue( nColumnType );
452  mpBindings->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_COLUMN,
453  SfxCallMode::RECORD, { mpPageColumnItem.get() });
454 }
455 
456 IMPL_LINK_NOARG( PageStylesPanel, ModifyNumberingHdl, weld::ComboBox&, void )
457 {
458  SvxNumType nEntryData = mxNumberSelectLB->get_active_id();
459  mpPageItem->SetNumType(nEntryData);
460  mpBindings->GetDispatcher()->ExecuteList(SID_ATTR_PAGE, SfxCallMode::RECORD, { mpPageItem.get() });
461 }
462 
463 IMPL_LINK_NOARG( PageStylesPanel, ModifyLayoutHdl, weld::ComboBox&, void )
464 {
465  sal_uInt16 nUse = mxLayoutSelectLB->get_active();
466  mpPageItem->SetPageUsage(PosToPageUsage_Impl(nUse));
467  mpBindings->GetDispatcher()->ExecuteList(SID_ATTR_PAGE, SfxCallMode::RECORD, { mpPageItem.get() });
468 }
469 
470 IMPL_LINK_NOARG(PageStylesPanel, ModifyFillStyleHdl, weld::ComboBox&, void)
471 {
472  const eFillStyle eXFS = static_cast<eFillStyle>(mxBgFillType->get_active());
473  Update();
474 
475  switch (eXFS)
476  {
477  case NONE:
478  {
479  const XFillStyleItem aXFillStyleItem(drawing::FillStyle_NONE);
480  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_FILLSTYLE, SfxCallMode::RECORD, { &aXFillStyleItem });
481  }
482  break;
483 
484  case SOLID:
485  {
486  XFillColorItem aItem( OUString(), mpBgColorItem->GetColorValue() );
487  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_COLOR, SfxCallMode::RECORD, { &aItem });
488  }
489  break;
490 
491  case GRADIENT:
492  {
493  XFillGradientItem aItem( mpBgGradientItem->GetName(), mpBgGradientItem->GetGradientValue() );
494  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_GRADIENT, SfxCallMode::RECORD, { &aItem });
495  }
496  break;
497 
498  case HATCH:
499  {
500  XFillHatchItem aItem( mpBgHatchItem->GetName(), mpBgHatchItem->GetHatchValue() );
501  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_HATCH, SfxCallMode::RECORD, { &aItem });
502  }
503  break;
504 
505  case BITMAP:
506  case PATTERN:
507  {
508  XFillBitmapItem aItem( mpBgBitmapItem->GetName(), mpBgBitmapItem->GetGraphicObject() );
509  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_BITMAP, SfxCallMode::RECORD, { &aItem });
510  }
511  break;
512 
513  default:
514  break;
515  }
516 }
517 
519 {
520  const eFillStyle eXFS = static_cast<eFillStyle>(mxBgFillType->get_active());
522  switch(eXFS)
523  {
524  case SOLID:
525  {
526  XFillColorItem aItem(OUString(), mxBgColorLB->GetSelectEntryColor());
527  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_COLOR, SfxCallMode::RECORD, { &aItem });
528  }
529  break;
530  case GRADIENT:
531  {
532  XGradient aGradient;
533  aGradient.SetStartColor(mxBgColorLB->GetSelectEntryColor());
534  aGradient.SetEndColor(mxBgGradientLB->GetSelectEntryColor());
535 
536  XFillGradientItem aItem(aGradient);
537  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_GRADIENT, SfxCallMode::RECORD, { &aItem });
538  }
539  break;
540  case HATCH:
541  {
542  const SvxHatchListItem * pHatchListItem = pSh->GetItem(SID_HATCH_LIST);
543  sal_uInt16 nPos = mxBgHatchingLB->get_active();
544  XHatch aHatch = pHatchListItem->GetHatchList()->GetHatch(nPos)->GetHatch();
545  const OUString aHatchName = pHatchListItem->GetHatchList()->GetHatch(nPos)->GetName();
546 
547  XFillHatchItem aItem(aHatchName, aHatch);
548  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_HATCH, SfxCallMode::RECORD, { &aItem });
549  }
550  break;
551  case BITMAP:
552  case PATTERN:
553  {
554  sal_Int16 nPos = mxBgBitmapLB->get_active();
555  GraphicObject aBitmap;
556  OUString aBitmapName;
557 
558  if ( eXFS == BITMAP )
559  {
560  SvxBitmapListItem const * pBitmapListItem = pSh->GetItem(SID_BITMAP_LIST);
561  aBitmap = pBitmapListItem->GetBitmapList()->GetBitmap(nPos)->GetGraphicObject();
562  aBitmapName = pBitmapListItem->GetBitmapList()->GetBitmap(nPos)->GetName();
563  }
564  else
565  {
566  SvxPatternListItem const * pPatternListItem = pSh->GetItem(SID_PATTERN_LIST);
567  aBitmap = pPatternListItem->GetPatternList()->GetBitmap(nPos)->GetGraphicObject();
568  aBitmapName = pPatternListItem->GetPatternList()->GetBitmap(nPos)->GetName();
569  }
570 
571  XFillBitmapItem aItem(aBitmapName, aBitmap);
572  GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_PAGE_BITMAP, SfxCallMode::RECORD, { &aItem });
573  }
574  break;
575  default:
576  break;
577  }
578 }
579 
580 IMPL_LINK_NOARG(PageStylesPanel, ModifyFillColorHdl, weld::ComboBox&, void)
581 {
582  ModifyFillColor();
583 }
584 
585 IMPL_LINK_NOARG(PageStylesPanel, ModifyFillColorListHdl, ColorListBox&, void)
586 {
587  ModifyFillColor();
588 }
589 
590 }
591 
592 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::unique_ptr< SvxPageNumberListBox > mxNumberSelectLB
const SfxPoolItem * ExecuteList(sal_uInt16 nSlot, SfxCallMode nCall, std::initializer_list< SfxPoolItem const * > args, std::initializer_list< SfxPoolItem const * > internalargs=std::initializer_list< SfxPoolItem const * >())
sal_Int32 nIndex
const XPatternListRef & GetPatternList() const
std::unique_ptr< weld::ComboBox > mxBgBitmapLB
#define SID_ATTR_PAGE_COLUMN
Definition: cmdid.h:860
::sfx2::sidebar::ControllerItem maBgColorControl
virtual SfxPoolItem * Clone(SfxItemPool *pPool=nullptr) const =0
SVX_DLLPUBLIC void Fill(weld::ComboBox &, const XHatchListRef &pList)
void SetEndColor(const Color &rColor)
const XGradientListRef & GetGradientList() const
std::unique_ptr< weld::ComboBox > mxBgHatchingLB
static SfxObjectShell * Current()
void Invalidate(sal_uInt16 nId)
SvxNumType
OUString const & GetPatternSetOrDefault()
::sfx2::sidebar::ControllerItem maPageNumFormatControl
const Color & GetStartColor() const
NONE
::sfx2::sidebar::ControllerItem maBgBitmapControl
::sfx2::sidebar::ControllerItem maPageColumnControl
std::unique_ptr< weld::ComboBox > mxLayoutSelectLB
std::unique_ptr< ColorListBox > mxBgColorLB
::std::unique_ptr< SfxInt16Item > mpPageColumnItem
XGradient const & GetGradientSetOrDefault()
#define SAL_N_ELEMENTS(arr)
weld::Window * GetFrameWeld(const SfxFrame *pFrame)
Definition: dialoghelp.cxx:19
const XHatchListRef & GetHatchList() const
const SfxPoolItem * GetItem(sal_uInt16 nSlotId) const
SVX_DLLPUBLIC void Fill(weld::ComboBox &rListBox)
void SetStartColor(const Color &rColor)
::std::unique_ptr< XFillGradientItem > mpBgGradientItem
int i
constexpr OUStringLiteral PATTERN
std::unique_ptr< weld::Label > mxCustomEntry
virtual void dispose()
::std::unique_ptr< XFillColorItem > mpBgColorItem
static sal_uInt16 PageUsageToPos_Impl(SvxPageUsage nUsage)
PageStylesPanel(weld::Widget *pParent, SfxBindings *pBindings)
const SvxPageUsage aArr[]
::std::unique_ptr< SvxPageItem > mpPageItem
IMPL_LINK_NOARG(PageColumnControl, MoreButtonClickHdl_Impl, weld::Button &, void)
virtual ~PageStylesPanel() override
const XBitmapListRef & GetBitmapList() const
::std::unique_ptr< XFillHatchItem > mpBgHatchItem
::sfx2::sidebar::ControllerItem maBgHatchingControl
SvxPageUsage
::sfx2::sidebar::ControllerItem maBgGradientControl
static SvxPageUsage PosToPageUsage_Impl(sal_uInt16 nPos)
static std::unique_ptr< PanelLayout > Create(weld::Widget *pParent, SfxBindings *pBindings)
SfxItemState
SfxBindings * GetBindings() const
std::unique_ptr< ColorListBox > mxBgGradientLB
std::unique_ptr< weld::ComboBox > mxBgFillType
OUString const & GetBitmapSetOrDefault()
std::unique_ptr< weld::ComboBox > mxColumnCount
::sfx2::sidebar::ControllerItem maBgFillStyleControl
SfxDispatcher * GetDispatcher() const
virtual weld::Window * GetFrameWeld() const
static void GetI18nNumbering(weld::ComboBox &rFmtLB, sal_uInt16 nDoNotRemove)
virtual void NotifyItemUpdate(const sal_uInt16 nSId, const SfxItemState eState, const SfxPoolItem *pState) override
OUString const & GetHatchingSetOrDefault()
const Color & GetEndColor() const
sal_uInt16 nPos
::std::unique_ptr< XFillBitmapItem > mpBgBitmapItem