LibreOffice Module svx (master)  1
rulritem.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/svxids.hrc>
21 #include <svx/rulritem.hxx>
22 #include <svx/unomid.hxx>
23 #include <tools/debug.hxx>
24 #include <tools/mapunit.hxx>
25 #include <osl/diagnose.h>
26 #include <sal/log.hxx>
27 #include <com/sun/star/awt/Rectangle.hpp>
28 #include <com/sun/star/frame/status/LeftRightMargin.hpp>
29 #include <com/sun/star/frame/status/UpperLowerMargin.hpp>
30 
35 SfxPoolItem* SvxObjectItem::CreateDefault() { SAL_WARN( "svx", "No SvxObjectItem factory available"); return nullptr; }
36 
37 /* SvxLongLRSpaceItem */
38 
40 {
41  return SfxPoolItem::operator==(rCmp) &&
42  mlLeft == static_cast<const SvxLongLRSpaceItem &>(rCmp).mlLeft &&
43  mlRight == static_cast<const SvxLongLRSpaceItem &>(rCmp).mlRight;
44 }
45 
46 bool SvxLongLRSpaceItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
47 {
48  bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
49  nMemberId &= ~CONVERT_TWIPS;
50 
51  sal_Int32 nVal;
52  switch( nMemberId )
53  {
54  case 0:
55  {
56  css::frame::status::LeftRightMargin aLeftRightMargin;
57  aLeftRightMargin.Left = bConvert ? convertTwipToMm100( mlLeft ) : mlLeft;
58  aLeftRightMargin.Right = bConvert ? convertTwipToMm100( mlRight ) : mlRight;
59  rVal <<= aLeftRightMargin;
60  return true;
61  }
62 
63  case MID_LEFT:
64  nVal = mlLeft;
65  break;
66  case MID_RIGHT:
67  nVal = mlRight;
68  break;
69  default:
70  OSL_FAIL("Wrong MemberId!");
71  return false;
72  }
73 
74  if ( bConvert )
75  nVal = convertTwipToMm100( nVal );
76 
77  rVal <<= nVal;
78  return true;
79 }
80 
81 bool SvxLongLRSpaceItem::PutValue( const css::uno::Any& rVal, sal_uInt8 nMemberId )
82 {
83  bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
84  nMemberId &= ~CONVERT_TWIPS;
85 
86  sal_Int32 nVal = 0;
87  if ( nMemberId == 0 )
88  {
89  css::frame::status::LeftRightMargin aLeftRightMargin;
90  if ( rVal >>= aLeftRightMargin )
91  {
92  mlLeft = bConvert ? convertMm100ToTwip(aLeftRightMargin.Left) : aLeftRightMargin.Left;
93  mlRight = bConvert ? convertMm100ToTwip(aLeftRightMargin.Right) : aLeftRightMargin.Right;
94  return true;
95  }
96  }
97  else if ( rVal >>= nVal )
98  {
99  if ( bConvert )
100  nVal = convertMm100ToTwip( nVal );
101 
102  switch( nMemberId )
103  {
104  case MID_LEFT:
105  mlLeft = nVal;
106  break;
107  case MID_RIGHT:
108  mlRight = nVal;
109  break;
110  default:
111  OSL_FAIL("Wrong MemberId!");
112  return false;
113  }
114 
115  return true;
116  }
117 
118  return false;
119 }
120 
122  SfxItemPresentation /*ePres*/,
123  MapUnit /*eCoreUnit*/,
124  MapUnit /*ePresUnit*/,
125  OUString& /*rText*/,
126  const IntlWrapper& /*rWrapper*/) const
127 {
128  return false;
129 }
130 
132 {
133  return new SvxLongLRSpaceItem(*this);
134 }
135 
136 SvxLongLRSpaceItem::SvxLongLRSpaceItem(long lLeft, long lRight, sal_uInt16 nId) :
137  SfxPoolItem (nId),
138  mlLeft (lLeft),
139  mlRight (lRight)
140 {}
141 
143  SfxPoolItem (0),
144  mlLeft (0),
145  mlRight (0)
146 {}
147 
148 void SvxLongLRSpaceItem::SetLeft(long lArgLeft)
149 {
150  mlLeft = lArgLeft;
151 }
152 
153 void SvxLongLRSpaceItem::SetRight(long lArgRight)
154 {
155  mlRight = lArgRight;
156 }
157 
158 /* SvxLongULSpaceItem */
159 
161 {
162  return SfxPoolItem::operator==(rCmp) &&
163  mlLeft == static_cast<const SvxLongULSpaceItem&>(rCmp).mlLeft &&
164  mlRight == static_cast<const SvxLongULSpaceItem&>(rCmp).mlRight;
165 }
166 
167 bool SvxLongULSpaceItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
168 {
169  bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
170  nMemberId &= ~CONVERT_TWIPS;
171 
172  sal_Int32 nVal;
173  switch( nMemberId )
174  {
175  case 0:
176  {
177  css::frame::status::UpperLowerMargin aUpperLowerMargin;
178  aUpperLowerMargin.Upper = bConvert ? convertTwipToMm100( mlLeft ) : mlLeft;
179  aUpperLowerMargin.Lower = bConvert ? convertTwipToMm100( mlRight ) : mlRight;
180  rVal <<= aUpperLowerMargin;
181  return true;
182  }
183 
184  case MID_UPPER:
185  nVal = mlLeft;
186  break;
187  case MID_LOWER:
188  nVal = mlRight;
189  break;
190  default: OSL_FAIL("Wrong MemberId!"); return false;
191  }
192 
193  if ( bConvert )
194  nVal = convertTwipToMm100( nVal );
195 
196  rVal <<= nVal;
197  return true;
198 }
199 
200 bool SvxLongULSpaceItem::PutValue( const css::uno::Any& rVal, sal_uInt8 nMemberId )
201 {
202  bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
203  nMemberId &= ~CONVERT_TWIPS;
204 
205  sal_Int32 nVal = 0;
206  if ( nMemberId == 0 )
207  {
208  css::frame::status::UpperLowerMargin aUpperLowerMargin;
209  if ( rVal >>= aUpperLowerMargin )
210  {
211  mlLeft = bConvert ? convertMm100ToTwip( aUpperLowerMargin.Upper ) : aUpperLowerMargin.Upper;
212  mlRight = bConvert ? convertMm100ToTwip( aUpperLowerMargin.Lower ) : aUpperLowerMargin.Lower;
213  return true;
214  }
215  }
216  else if ( rVal >>= nVal )
217  {
218  if ( bConvert )
219  nVal = convertMm100ToTwip( nVal );
220 
221  switch( nMemberId )
222  {
223  case MID_UPPER:
224  mlLeft = nVal;
225  break;
226  case MID_LOWER:
227  mlRight = nVal;
228  break;
229  default:
230  OSL_FAIL("Wrong MemberId!");
231  return false;
232  }
233 
234  return true;
235  }
236 
237  return false;
238 }
239 
241  SfxItemPresentation /*ePres*/,
242  MapUnit /*eCoreUnit*/,
243  MapUnit /*ePresUnit*/,
244  OUString& /*rText*/,
245  const IntlWrapper& /*rWrapper*/ ) const
246 {
247  return false;
248 }
249 
251 {
252  return new SvxLongULSpaceItem(*this);
253 }
254 
255 SvxLongULSpaceItem::SvxLongULSpaceItem(long lLeft, long lRight, sal_uInt16 nId) :
256  SfxPoolItem (nId),
257  mlLeft (lLeft),
258  mlRight (lRight)
259 {}
260 
262  SfxPoolItem (0),
263  mlLeft (0),
264  mlRight (0)
265 {}
266 
267 
268 void SvxLongULSpaceItem::SetUpper(long lArgLeft)
269 {
270  mlLeft = lArgLeft;
271 }
272 
273 void SvxLongULSpaceItem::SetLower(long lArgRight)
274 {
275  mlRight = lArgRight;
276 }
277 
278 /* SvxPagePosSizeItem */
279 
281 {
282  return SfxPoolItem::operator==(rCmp) &&
283  aPos == static_cast<const SvxPagePosSizeItem &>(rCmp).aPos &&
284  lWidth == static_cast<const SvxPagePosSizeItem &>(rCmp).lWidth &&
285  lHeight == static_cast<const SvxPagePosSizeItem &>(rCmp).lHeight;
286 }
287 
288 bool SvxPagePosSizeItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
289 {
290  nMemberId &= ~CONVERT_TWIPS;
291 
292  sal_Int32 nVal;
293  switch ( nMemberId )
294  {
295  case 0 :
296  {
297  css::awt::Rectangle aPagePosSize;
298  aPagePosSize.X = aPos.X();
299  aPagePosSize.Y = aPos.Y();
300  aPagePosSize.Width = lWidth;
301  aPagePosSize.Height = lHeight;
302  rVal <<= aPagePosSize;
303  return true;
304  }
305 
306  case MID_X: nVal = aPos.X(); break;
307  case MID_Y: nVal = aPos.Y(); break;
308  case MID_WIDTH: nVal = lWidth; break;
309  case MID_HEIGHT: nVal = lHeight; break;
310 
311  default: OSL_FAIL("Wrong MemberId!"); return false;
312  }
313 
314  rVal <<= nVal;
315  return true;
316 }
317 
318 bool SvxPagePosSizeItem::PutValue( const css::uno::Any& rVal, sal_uInt8 nMemberId )
319 {
320  nMemberId &= ~CONVERT_TWIPS;
321 
322  sal_Int32 nVal = 0;
323  if ( nMemberId == 0 )
324  {
325  css::awt::Rectangle aPagePosSize;
326  if ( rVal >>= aPagePosSize )
327  {
328  aPos.setX( aPagePosSize.X );
329  aPos.setY( aPagePosSize.Y );
330  lWidth = aPagePosSize.Width;
331  lHeight = aPagePosSize.Height;
332  return true;
333  }
334  else
335  return false;
336  }
337  else if ( rVal >>= nVal )
338  {
339  switch ( nMemberId )
340  {
341  case MID_X: aPos.setX( nVal ); break;
342  case MID_Y: aPos.setY( nVal ); break;
343  case MID_WIDTH: lWidth = nVal; break;
344  case MID_HEIGHT: lHeight = nVal; break;
345 
346  default: OSL_FAIL("Wrong MemberId!"); return false;
347  }
348 
349  return true;
350  }
351 
352  return false;
353 }
354 
356  SfxItemPresentation /*ePres*/,
357  MapUnit /*eCoreUnit*/,
358  MapUnit /*ePresUnit*/,
359  OUString& /*rText*/,
360  const IntlWrapper& /*rWrapper*/ ) const
361 {
362  return false;
363 }
364 
366 {
367  return new SvxPagePosSizeItem(*this);
368 }
369 
370 SvxPagePosSizeItem::SvxPagePosSizeItem(const Point &rP, long lW, long lH) :
371  SfxPoolItem (SID_RULER_PAGE_POS),
372  aPos (rP),
373  lWidth (lW),
374  lHeight (lH)
375 {}
376 
378  SfxPoolItem (0),
379  aPos (0, 0),
380  lWidth (0),
381  lHeight (0)
382 {}
383 
384 /* SvxColumnItem */
385 
386 bool SvxColumnItem::operator==(const SfxPoolItem& rCmp) const
387 {
388  if(!SfxPoolItem::operator==(rCmp) ||
389  nActColumn != static_cast<const SvxColumnItem&>(rCmp).nActColumn ||
390  nLeft != static_cast<const SvxColumnItem&>(rCmp).nLeft ||
391  nRight != static_cast<const SvxColumnItem&>(rCmp).nRight ||
392  bTable != static_cast<const SvxColumnItem&>(rCmp).bTable ||
393  Count() != static_cast<const SvxColumnItem&>(rCmp).Count())
394  return false;
395 
396  const sal_uInt16 nCount = static_cast<const SvxColumnItem&>(rCmp).Count();
397  for(sal_uInt16 i = 0; i < nCount;++i)
398  {
399  if( (*this)[i] != static_cast<const SvxColumnItem&>(rCmp)[i] )
400  return false;
401  }
402  return true;
403 }
404 
405 SvxColumnItem::SvxColumnItem( sal_uInt16 nAct ) :
406  SfxPoolItem (SID_RULER_BORDERS),
407  nLeft (0),
408  nRight (0),
409  nActColumn (nAct),
410  bTable (false),
411  bOrtho (true)
412 
413 {}
414 
415 SvxColumnItem::SvxColumnItem( sal_uInt16 nActCol, sal_uInt16 left, sal_uInt16 right ) :
416  SfxPoolItem (SID_RULER_BORDERS),
417  nLeft (left),
418  nRight (right),
419  nActColumn (nActCol),
420  bTable (true),
421  bOrtho (true)
422 {}
423 
425  SfxItemPresentation /*ePres*/,
426  MapUnit /*eCoreUnit*/,
427  MapUnit /*ePresUnit*/,
428  OUString& /*rText*/,
429  const IntlWrapper& /*rWrapper*/ ) const
430 {
431  return false;
432 }
433 
435 {
436  return new SvxColumnItem(*this);
437 }
438 
440 {
441  const sal_uInt16 nCount = Count();
442  DBG_ASSERT(nCount >= 2, "no columns");
443  if(nCount < 2)
444  return false;
445 
446  long nColWidth = (*this)[0].GetWidth();
447  for(sal_uInt16 i = 1; i < nCount; ++i) {
448  if( (*this)[i].GetWidth() != nColWidth)
449  return false;
450  }
452  return true;
453 }
454 
455 bool SvxColumnItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
456 {
457  nMemberId &= ~CONVERT_TWIPS;
458  switch ( nMemberId )
459  {
460  case MID_COLUMNARRAY:
461  return false;
462  case MID_RIGHT:
463  rVal <<= nRight;
464  break;
465  case MID_LEFT:
466  rVal <<= nLeft;
467  break;
468  case MID_ORTHO:
469  rVal <<= bOrtho;
470  break;
471  case MID_ACTUAL:
472  rVal <<= static_cast<sal_Int32>(nActColumn);
473  break;
474  case MID_TABLE:
475  rVal <<= bTable;
476  break;
477  default:
478  // SfxDispatchController_Impl::StateChanged calls this with hardcoded 0 triggering this;
479  OSL_FAIL("Wrong MemberId!");
480  return false;
481  }
482 
483  return true;
484 }
485 
486 bool SvxColumnItem::PutValue( const css::uno::Any& rVal, sal_uInt8 nMemberId )
487 {
488  nMemberId &= ~CONVERT_TWIPS;
489  sal_Int32 nVal = 0;
490  switch ( nMemberId )
491  {
492  case MID_COLUMNARRAY:
493  {
494  return false;
495  }
496  case MID_RIGHT:
497  rVal >>= nRight;
498  break;
499  case MID_LEFT:
500  rVal >>= nLeft;
501  break;
502  case MID_ORTHO:
503  rVal >>= nVal;
504  bOrtho = static_cast<bool>(nVal);
505  break;
506  case MID_ACTUAL:
507  rVal >>= nVal;
508  nActColumn = static_cast<sal_uInt16>(nVal);
509  break;
510  case MID_TABLE:
511  rVal >>= nVal;
512  bTable = static_cast<bool>(nVal);
513  break;
514  default:
515  OSL_FAIL("Wrong MemberId!");
516  return false;
517  }
518 
519  return true;
520 }
521 
522 sal_uInt16 SvxColumnItem::Count() const
523 {
524  return aColumns.size();
525 }
526 
528 {
529  return aColumns[index];
530 }
531 
533 {
534  return aColumns[GetActColumn()];
535 }
536 
538 {
539  return aColumns[index];
540 }
541 
542 const SvxColumnDescription& SvxColumnItem::operator[](sal_uInt16 index) const
543 {
544  return aColumns[index];
545 }
546 
548 {
549  aColumns.push_back(rDesc);
550 }
551 
552 void SvxColumnItem::SetLeft(long left)
553 {
554  nLeft = left;
555 }
556 
557 void SvxColumnItem::SetRight(long right)
558 {
559  nRight = right;
560 }
561 
562 
564 {
565  return nActColumn == 0;
566 }
567 
569 {
570  return nActColumn == Count() - 1;
571 }
572 
573 SvxColumnDescription::SvxColumnDescription(long start, long end, bool bVis) :
574  nStart (start),
575  nEnd (end),
576  bVisible (bVis),
577  nEndMin (0),
578  nEndMax (0)
579 {}
580 
581 SvxColumnDescription::SvxColumnDescription(long start, long end, long endMin, long endMax, bool bVis) :
582  nStart (start),
583  nEnd (end),
584  bVisible (bVis),
585  // fdo#85858 hack: clamp these to smaller value to prevent overflow
586  nEndMin(std::min<long>(endMin, std::numeric_limits<unsigned short>::max())),
587  nEndMax(std::min<long>(endMax, std::numeric_limits<unsigned short>::max()))
588 {}
589 
591 {
592  return nStart == rCmp.nStart
593  && bVisible == rCmp.bVisible
594  && nEnd == rCmp.nEnd
595  && nEndMin == rCmp.nEndMin
596  && nEndMax == rCmp.nEndMax;
597 }
598 
600 {
601  return !operator==(rCmp);
602 }
603 
605 {
606  return nEnd - nStart;
607 }
608 
609 /* SvxColumnItem */
610 void SvxColumnItem::SetOrtho(bool bVal)
611 {
612  bOrtho = bVal;
613 }
614 
616 {
617  return nActColumn < aColumns.size();
618 }
619 
620 bool SvxObjectItem::operator==( const SfxPoolItem& rCmp ) const
621 {
622  return SfxPoolItem::operator==(rCmp) &&
623  nStartX == static_cast<const SvxObjectItem&>(rCmp).nStartX &&
624  nEndX == static_cast<const SvxObjectItem&>(rCmp).nEndX &&
625  nStartY == static_cast<const SvxObjectItem&>(rCmp).nStartY &&
626  nEndY == static_cast<const SvxObjectItem&>(rCmp).nEndY &&
627  bLimits == static_cast<const SvxObjectItem&>(rCmp).bLimits;
628 }
629 
631  SfxItemPresentation /*ePres*/,
632  MapUnit /*eCoreUnit*/,
633  MapUnit /*ePresUnit*/,
634  OUString& /*rText*/,
635  const IntlWrapper& /*rWrapper*/ ) const
636 {
637  return false;
638 }
639 
641 {
642  return new SvxObjectItem(*this);
643 }
644 
645 SvxObjectItem::SvxObjectItem( long nSX, long nEX,
646  long nSY, long nEY ) :
647  SfxPoolItem (SID_RULER_OBJECT),
648  nStartX (nSX),
649  nEndX (nEX),
650  nStartY (nSY),
651  nEndY (nEY),
652  bLimits (false)
653 {}
654 
655 bool SvxObjectItem::QueryValue( css::uno::Any& rVal, sal_uInt8 nMemberId ) const
656 {
657  nMemberId &= ~CONVERT_TWIPS;
658  switch (nMemberId)
659  {
660  case MID_START_X:
661  rVal <<= nStartX;
662  break;
663  case MID_START_Y:
664  rVal <<= nStartY;
665  break;
666  case MID_END_X:
667  rVal <<= nEndX;
668  break;
669  case MID_END_Y:
670  rVal <<= nEndY;
671  break;
672  case MID_LIMIT:
673  rVal <<= bLimits;
674  break;
675  default:
676  OSL_FAIL( "Wrong MemberId" );
677  return false;
678  }
679 
680  return true;
681 }
682 
683 bool SvxObjectItem::PutValue( const css::uno::Any& rVal, sal_uInt8 nMemberId )
684 {
685  nMemberId &= ~CONVERT_TWIPS;
686  bool bRet = false;
687  switch (nMemberId)
688  {
689  case MID_START_X:
690  bRet = (rVal >>= nStartX);
691  break;
692  case MID_START_Y:
693  bRet = (rVal >>= nStartY);
694  break;
695  case MID_END_X:
696  bRet = (rVal >>= nEndX);
697  break;
698  case MID_END_Y:
699  bRet = (rVal >>= nEndY);
700  break;
701  case MID_LIMIT:
702  bRet = (rVal >>= bLimits);
703  break;
704  default: OSL_FAIL( "Wrong MemberId" );
705  }
706 
707  return bRet;
708 }
709 
710 
711 void SvxObjectItem::SetStartX(long lValue)
712 {
713  nStartX = lValue;
714 }
715 
716 void SvxObjectItem::SetEndX(long lValue)
717 {
718  nEndX = lValue;
719 }
720 
721 void SvxObjectItem::SetStartY(long lValue)
722 {
723  nStartY = lValue;
724 }
725 
726 void SvxObjectItem::SetEndY(long lValue)
727 {
728  nEndY = lValue;
729 }
730 
731 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
bool IsFirstAct() const
Definition: rulritem.cxx:563
bool bVisible
#define MID_WIDTH
#define MID_X
virtual bool operator==(const SfxPoolItem &) const =0
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Definition: rulritem.cxx:683
virtual bool operator==(const SfxPoolItem &) const override
Definition: rulritem.cxx:620
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
Definition: rulritem.cxx:288
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
Definition: rulritem.cxx:655
#define MID_HEIGHT
#define MID_ACTUAL
Definition: unomid.hxx:57
void Append(const SvxColumnDescription &rDesc)
Definition: rulritem.cxx:547
virtual bool operator==(const SfxPoolItem &) const override
Definition: rulritem.cxx:280
bool IsLastAct() const
Definition: rulritem.cxx:568
SvxObjectItem(long nStartX, long nEndX, long nStartY, long nEndY)
Definition: rulritem.cxx:645
#define MID_COLUMNARRAY
Definition: unomid.hxx:56
#define MID_Y
#define max(a, b)
virtual SvxObjectItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: rulritem.cxx:640
#define MID_START_Y
Definition: unomid.hxx:50
std::vector< SvxColumnDescription > aColumns
Definition: rulritem.hxx:145
bool operator!=(const SvxColumnDescription &rCmp) const
Definition: rulritem.cxx:599
void SetLeft(long aLeft)
Definition: rulritem.cxx:552
virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, MapUnit ePresMetric, OUString &rText, const IntlWrapper &) const override
Definition: rulritem.cxx:121
void SetStartY(long lValue)
Definition: rulritem.cxx:721
void SetUpper(long lArgLeft)
Definition: rulritem.cxx:268
#define MID_START_X
Definition: unomid.hxx:49
virtual bool operator==(const SfxPoolItem &) const override
Definition: rulritem.cxx:160
virtual SvxLongULSpaceItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: rulritem.cxx:250
#define min(a, b)
SvxColumnDescription & operator[](sal_uInt16 index)
Definition: rulritem.cxx:537
static SfxPoolItem * CreateDefault()
Definition: rulritem.cxx:31
void SetRight(long lArgRight)
Definition: rulritem.cxx:153
int nCount
static SfxPoolItem * CreateDefault()
Definition: rulritem.cxx:34
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Definition: rulritem.cxx:318
sal_uInt16 nActColumn
Definition: rulritem.hxx:150
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Definition: rulritem.cxx:486
long GetWidth() const
Definition: rulritem.cxx:604
bool CalcOrtho() const
Definition: rulritem.cxx:439
SfxItemPresentation
void SetEndY(long lValue)
Definition: rulritem.cxx:726
#define DBG_ASSERT(sCon, aError)
int i
SvxColumnDescription & At(sal_uInt16 index)
Definition: rulritem.cxx:527
virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, MapUnit ePresMetric, OUString &rText, const IntlWrapper &) const override
Definition: rulritem.cxx:630
#define MID_TABLE
Definition: unomid.hxx:58
static SfxPoolItem * CreateDefault()
Definition: rulritem.cxx:33
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
Definition: rulritem.cxx:46
#define MID_END_X
Definition: unomid.hxx:51
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Definition: rulritem.cxx:200
#define MID_END_Y
Definition: unomid.hxx:52
sal_uInt16 Count() const
Definition: rulritem.cxx:522
void SetEndX(long lValue)
Definition: rulritem.cxx:716
void SetStartX(long lValue)
Definition: rulritem.cxx:711
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
Definition: rulritem.cxx:455
virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, MapUnit ePresMetric, OUString &rText, const IntlWrapper &) const override
Definition: rulritem.cxx:355
constexpr sal_Int64 convertTwipToMm100(sal_Int64 n)
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Definition: rulritem.cxx:81
unsigned char sal_uInt8
virtual SvxLongLRSpaceItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: rulritem.cxx:131
virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, MapUnit ePresMetric, OUString &rText, const IntlWrapper &) const override
Definition: rulritem.cxx:424
sal_uInt16 GetActColumn() const
Definition: rulritem.hxx:182
static SfxPoolItem * CreateDefault()
Definition: rulritem.cxx:35
#define MID_LIMIT
Definition: unomid.hxx:53
virtual bool operator==(const SfxPoolItem &) const override
Definition: rulritem.cxx:39
void SetRight(long aRight)
Definition: rulritem.cxx:557
SvxColumnDescription(long start, long end, bool bVis)
Definition: rulritem.cxx:573
constexpr sal_Int64 convertMm100ToTwip(sal_Int64 n)
#define MID_ORTHO
Definition: unomid.hxx:59
MapUnit
#define SAL_WARN(area, stream)
SvxColumnItem(sal_uInt16 nAct=0)
Definition: rulritem.cxx:405
void SetLower(long lArgRight)
Definition: rulritem.cxx:273
virtual bool GetPresentation(SfxItemPresentation ePres, MapUnit eCoreMetric, MapUnit ePresMetric, OUString &rText, const IntlWrapper &) const override
Definition: rulritem.cxx:240
bool IsConsistent() const
Definition: rulritem.cxx:615
SvxColumnDescription & GetActiveColumnDescription()
Definition: rulritem.cxx:532
virtual bool operator==(const SfxPoolItem &) const override
Definition: rulritem.cxx:386
void SetOrtho(bool bVal)
Definition: rulritem.cxx:610
virtual SvxPagePosSizeItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: rulritem.cxx:365
static SfxPoolItem * CreateDefault()
Definition: rulritem.cxx:32
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
Definition: rulritem.cxx:167
virtual SvxColumnItem * Clone(SfxItemPool *pPool=nullptr) const override
Definition: rulritem.cxx:434
bool operator==(const SvxColumnDescription &rCmp) const
Definition: rulritem.cxx:590
#define CONVERT_TWIPS
#define MID_LEFT
Definition: unomid.hxx:93
void SetLeft(long lArgLeft)
Definition: rulritem.cxx:148