22 #include <com/sun/star/style/VerticalAlignment.hpp>
23 #include <com/sun/star/text/ColumnSeparatorStyle.hpp>
24 #include <com/sun/star/text/WrapTextMode.hpp>
25 #include <com/sun/star/text/TextContentAnchorType.hpp>
26 #include <com/sun/star/container/XIndexContainer.hpp>
27 #include <com/sun/star/text/TextGridMode.hpp>
28 #include <com/sun/star/text/XTextColumns.hpp>
32 #include <osl/diagnose.h>
55 #include <section.hxx>
84 #include <strings.hrc>
91 #include <drawdoc.hxx>
94 #include <unoprnms.hxx>
110 switch (rOrientation)
112 case text::RelOrientation::CHAR:
113 case text::RelOrientation::FRAME:
114 rOrientation = text::RelOrientation::PAGE_FRAME;
116 case text::RelOrientation::PRINT_AREA:
117 if (isIgnorePrintArea)
123 rOrientation = text::RelOrientation::PAGE_PRINT_AREA;
126 case text::RelOrientation::FRAME_LEFT:
127 rOrientation = text::RelOrientation::PAGE_LEFT;
129 case text::RelOrientation::FRAME_RIGHT:
130 rOrientation = text::RelOrientation::PAGE_RIGHT;
143 sal_Int16 nVal = text::RelOrientation::FRAME;
144 if (!(rVal >>= nVal))
145 SAL_WARN(
"sw.core",
"lcl_IntToRelation: read from Any failed!");
154 pFormat->
Remove( pToRemove );
168 if (dynamic_cast<const SwFrame*>(pLast) ==
nullptr)
189 pNode = & aIdx.GetNode();
191 while ( aIdx < nEnd )
193 if ( pNode->IsContentNode() &&
204 pNode = & aIdx.GetNode();
213 OSL_ENSURE( pNode,
"A big problem." );
236 m_eFrameHeightType( eSize ),
239 m_nWidthPercent = m_eWidthPercentRelation = m_nHeightPercent = m_eHeightPercentRelation = 0;
244 assert(SfxPoolItem::operator==(rAttr));
247 SvxSizeItem::operator==(rAttr)&&
328 Size aTmp(aVal.Width, aVal.Height);
374 bool bSet = *o3tl::doAccess<bool>(rVal);
383 bool bSet = *o3tl::doAccess<bool>(rVal);
433 bool bSet = *o3tl::doAccess<bool>(rVal);
456 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatFrameSize"));
457 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(Which()).getStr()));
459 std::stringstream aSize;
461 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"size"), BAD_CAST(aSize.str().c_str()));
463 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eFrameHeightType"), BAD_CAST(OString::number(static_cast<int>(
m_eFrameHeightType)).getStr()));
464 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eFrameWidthType"), BAD_CAST(OString::number(static_cast<int>(
m_eFrameWidthType)).getStr()));
465 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nWidthPercent"), BAD_CAST(OString::number(
m_nWidthPercent).getStr()));
466 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eWidthPercentRelation"), BAD_CAST(OString::number(
m_eWidthPercentRelation).getStr()));
467 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nHeightPercent"), BAD_CAST(OString::number(
m_nHeightPercent).getStr()));
468 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eHeightPercentRelation"), BAD_CAST(OString::number(
m_eHeightPercentRelation).getStr()));
470 (
void)xmlTextWriterEndElement(pWriter);
492 m_bActive( pHeaderFormat )
498 SwClient( const_cast<
sw::BroadcastingModify*>(static_cast<const
sw::BroadcastingModify*>(rCpy.GetRegisteredIn())) ),
499 m_bActive( rCpy.IsActive() )
518 assert(SfxPoolItem::operator==(rAttr));
537 m_bActive( pFooterFormat )
543 SwClient( const_cast<
sw::BroadcastingModify*>(static_cast<const
sw::BroadcastingModify*>(rCpy.GetRegisteredIn())) ),
544 m_bActive( rCpy.IsActive() )
568 assert(SfxPoolItem::operator==(rAttr));
603 assert(SfxPoolItem::operator==(rAttr));
607 return ( *m_pStartNode == *static_cast<const SwFormatContent&>(rAttr).
GetContentIdx() );
618 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatContent"));
619 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
622 (
void)xmlTextWriterWriteAttribute(
623 pWriter, BAD_CAST(
"startNode"),
624 BAD_CAST(OString::number(sal_Int32(
m_pStartNode->GetNode().GetIndex())).getStr()));
625 (
void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST(
"startNodePtr"),
"%p",
628 (
void)xmlTextWriterEndElement(pWriter);
635 m_oNumOffset( rCpy.m_oNumOffset ),
636 m_pDefinedIn( nullptr )
643 m_pDefinedIn( nullptr )
669 assert(SfxPoolItem::operator==(rAttr));
682 if (
const SwPageDescHint* pHint = dynamic_cast<const SwPageDescHint*>(&rHint))
690 if(
auto pContentNode = dynamic_cast<const SwContentNode*>(pMod))
692 else if(
auto pFormat = dynamic_cast<const SwFormat*>(pMod))
693 const_cast<SwFormat*>(pFormat)->SetFormatAttr( aDfltDesc );
696 SAL_WARN(
"sw.core",
"SwFormatPageDesc registered at " <<
typeid(pMod).
name() <<
".");
704 else if (rHint.
GetId() == SfxHintId::SwLegacyModify)
732 rVal <<= static_cast<sal_Int16>(*oOffset);
755 OSL_ENSURE(
false,
"unknown MemberId" );
770 sal_Int16 nOffset = 0;
775 else if (rVal >>= nOffset)
788 OSL_ENSURE(
false,
"unknown MemberId" );
796 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatPageDesc"));
797 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
799 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"oNumOffset"), BAD_CAST(OString::number(*m_oNumOffset).getStr()));
801 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"oNumOffset"), BAD_CAST(
"none"));
802 (
void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST(
"pPageDesc"),
"%p",
GetPageDesc());
804 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"presentation"), BAD_CAST(pPageDesc->GetName().toUtf8().getStr()));
805 (
void)xmlTextWriterEndElement(pWriter);
827 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwColumn"));
828 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nWish"), BAD_CAST(OString::number(
m_nWish).getStr()));
829 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nUpper"), BAD_CAST(OString::number(0).getStr()));
830 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nLower"), BAD_CAST(OString::number(0).getStr()));
831 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nLeft"), BAD_CAST(OString::number(
m_nLeft).getStr()));
832 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nRight"), BAD_CAST(OString::number(
m_nRight).getStr()));
833 (
void)xmlTextWriterEndElement(pWriter);
838 m_eLineStyle( rCpy.m_eLineStyle ),
839 m_nLineWidth( rCpy.m_nLineWidth),
840 m_aLineColor( rCpy.m_aLineColor),
841 m_nLineHeight( rCpy.GetLineHeight() ),
842 m_eAdj( rCpy.GetLineAdj() ),
843 m_nWidth( rCpy.GetWishWidth() ),
844 m_aWidthAdjustValue( rCpy.m_aWidthAdjustValue ),
845 m_bOrtho( rCpy.IsOrtho() )
883 m_nLineHeight( 100 ),
885 m_nWidth( USHRT_MAX ),
886 m_aWidthAdjustValue( 0 ),
893 assert(SfxPoolItem::operator==(rAttr));
956 sal_uInt16 nHalf = nNew / 2;
975 for ( sal_uInt16
i = 0;
i < nNumCols; ++
i )
982 Calc( nGutterWidth, nAct );
989 Calc( nGutterWidth, nAct );
1000 return sal_uInt16(nW);
1011 nRet = nRet - pCol->
GetLeft();
1023 const sal_uInt16 nGutterHalf = nGutterWidth ? nGutterWidth / 2 : 0;
1026 sal_uInt16 nSpacings;
1027 bool bFail = o3tl::checked_multiply<sal_uInt16>(
GetNumCols() - 1, nGutterWidth, nSpacings);
1030 SAL_WARN(
"sw.core",
"SwFormatVertOrient::Calc: overflow");
1034 const sal_uInt16 nPrtWidth = (nAct - nSpacings) /
GetNumCols();
1035 sal_uInt16 nAvail = nAct;
1038 const sal_uInt16 nLeftWidth = nPrtWidth + nGutterHalf;
1043 nAvail = nAvail - nLeftWidth;
1046 const sal_uInt16 nMidWidth = nPrtWidth + nGutterWidth;
1054 nAvail = nAvail - nMidWidth;
1061 rLastCol.
SetLeft(nGutterHalf);
1070 rCol.SetWishWidth(sal_uInt16(nTmp));
1080 OSL_FAIL(
"not implemented");
1085 css::uno::UNO_QUERY_THROW);
1086 uno::Reference<beans::XPropertySet> xProps(xCols, css::uno::UNO_QUERY_THROW);
1092 sal_Int32 nAutoDistance =
IsOrtho() ? USHRT_MAX == nItemGutterWidth
1094 :
static_cast<sal_Int32
>(nItemGutterWidth)
1101 auto aTextColumns = xCols->getColumns();
1102 text::TextColumn* pColumns = aTextColumns.getArray();
1104 for (sal_Int32
i = 0;
i < aTextColumns.getLength(); ++
i)
1112 xCols->setColumns(aTextColumns);
1127 case SvxBorderLineStyle::SOLID:
1128 nStyle = css::text::ColumnSeparatorStyle::SOLID;
1130 case SvxBorderLineStyle::DOTTED:
1131 nStyle = css::text::ColumnSeparatorStyle::DOTTED;
1133 case SvxBorderLineStyle::DASHED:
1134 nStyle = css::text::ColumnSeparatorStyle::DASHED;
1136 case SvxBorderLineStyle::NONE:
1143 style::VerticalAlignment eAlignment;
1147 eAlignment = style::VerticalAlignment_TOP;
1150 eAlignment = style::VerticalAlignment_BOTTOM;
1155 eAlignment = style::VerticalAlignment_MIDDLE;
1157 aVal <<= eAlignment;
1171 OSL_FAIL(
"not implemented");
1175 uno::Reference< text::XTextColumns > xCols;
1179 uno::Sequence<text::TextColumn> aSetColumns = xCols->getColumns();
1180 const text::TextColumn* pArray = aSetColumns.getConstArray();
1183 sal_uInt16
nCount =
std::min( o3tl::narrowing<sal_uInt16>(aSetColumns.getLength()),
1184 sal_uInt16(0x3fff) );
1185 sal_uInt16 nWidthSum = 0;
1189 for(sal_uInt16
i = 0;
i < nCount;
i++)
1193 nWidthSum = nWidthSum + pArray[
i].Width;
1202 if (uno::Reference<beans::XPropertySet> xProps{ xCols, css::uno::UNO_QUERY })
1207 if (sal_Int32 nHeight;
1216 case css::text::ColumnSeparatorStyle::SOLID:
1219 case css::text::ColumnSeparatorStyle::DOTTED:
1222 case css::text::ColumnSeparatorStyle::DASHED:
1233 default: OSL_ENSURE(
false,
"unknown alignment" );
break;
1243 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatCol"));
1244 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1245 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eLineStyle"), BAD_CAST(OString::number(static_cast<sal_Int16>(
m_eLineStyle)).getStr()));
1246 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nLineWidth"), BAD_CAST(OString::number(
m_nLineWidth).getStr()));
1248 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nLineHeight"), BAD_CAST(OString::number(
m_nLineHeight).getStr()));
1249 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eAdj"), BAD_CAST(OString::number(
m_eAdj).getStr()));
1250 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nWidth"), BAD_CAST(OString::number(
m_nWidth).getStr()));
1251 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nWidthAdjustValue"), BAD_CAST(OString::number(
m_aWidthAdjustValue).getStr()));
1252 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"bOrtho"), BAD_CAST(OString::boolean(
m_bOrtho).getStr()));
1254 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"aColumns"));
1256 rColumn.dumpAsXml(pWriter);
1257 (
void)xmlTextWriterEndElement(pWriter);
1259 (
void)xmlTextWriterEndElement(pWriter);
1271 assert(SfxPoolItem::operator==(rAttr));
1272 return (
GetValue() == static_cast<const SwFormatSurround&>(rAttr).
GetValue() &&
1293 switch ( nMemberId )
1308 OSL_ENSURE(
false,
"unknown MemberId" );
1319 switch ( nMemberId )
1324 if( eVal >= css::text::WrapTextMode_NONE && eVal <= css::text::WrapTextMode_RIGHT )
1343 OSL_ENSURE(
false,
"unknown MemberId" );
1351 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatSurround"));
1352 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1353 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"value"), BAD_CAST(OString::number(static_cast<sal_Int32>(
GetValue())).getStr()));
1355 OUString aPresentation;
1357 GetPresentation(SfxItemPresentation::Nameless, MapUnit::Map100thMM, MapUnit::Map100thMM, aPresentation, aIntlWrapper);
1358 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"presentation"), BAD_CAST(aPresentation.toUtf8().getStr()));
1360 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"bAnchorOnly"), BAD_CAST(OString::boolean(
m_bAnchorOnly).getStr()));
1361 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"bContour"), BAD_CAST(OString::boolean(
m_bContour).getStr()));
1362 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"bOutside"), BAD_CAST(OString::boolean(
m_bOutside).getStr()));
1364 (
void)xmlTextWriterEndElement(pWriter);
1378 assert(SfxPoolItem::operator==(rAttr));
1379 return (
m_nYPos == static_cast<const SwFormatVertOrient&>(rAttr).
m_nYPos &&
1394 switch ( nMemberId )
1408 OSL_ENSURE(
false,
"unknown MemberId" );
1419 switch ( nMemberId )
1443 OSL_ENSURE(
false,
"unknown MemberId" );
1451 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatVertOrient"));
1452 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1453 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nYPos"), BAD_CAST(OString::number(
m_nYPos).getStr()));
1454 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eOrient"), BAD_CAST(OString::number(
m_eOrient).getStr()));
1455 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eRelation"), BAD_CAST(OString::number(
m_eRelation).getStr()));
1456 (
void)xmlTextWriterEndElement(pWriter);
1461 sal_Int16 eRel,
bool bPos )
1465 m_eRelation( eRel ),
1466 m_bPosToggle( bPos )
1471 assert(SfxPoolItem::operator==(rAttr));
1472 return (
m_nXPos == static_cast<const SwFormatHoriOrient&>(rAttr).
m_nXPos &&
1488 switch ( nMemberId )
1505 OSL_ENSURE(
false,
"unknown MemberId" );
1516 switch ( nMemberId )
1533 if(!(rVal >>= nVal))
1544 OSL_ENSURE(
false,
"unknown MemberId" );
1552 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatHoriOrient"));
1553 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1554 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"nXPos"), BAD_CAST(OString::number(
m_nXPos).getStr()));
1555 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eOrient"), BAD_CAST(OString::number(
m_eOrient).getStr()));
1556 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"eRelation"), BAD_CAST(OString::number(
m_eRelation).getStr()));
1557 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"bPosToggle"), BAD_CAST(OString::boolean(
m_bPosToggle).getStr()));
1558 (
void)xmlTextWriterEndElement(pWriter);
1564 m_eAnchorId( nRnd ),
1565 m_nPageNumber( nPage ),
1567 m_nOrder( ++s_nOrderCounter )
1572 , m_pContentAnchor( (rCpy.GetContentAnchor())
1573 ? new
SwPosition( *rCpy.GetContentAnchor() ) : nullptr )
1574 , m_eAnchorId( rCpy.GetAnchorId() )
1575 , m_nPageNumber( rCpy.GetPageNum() )
1577 , m_nOrder( ++s_nOrderCounter )
1605 if (
this != &rAnchor)
1621 assert(SfxPoolItem::operator==(rAttr));
1622 SwFormatAnchor const& rFormatAnchor(static_cast<SwFormatAnchor const&>(rAttr));
1648 switch ( nMemberId )
1652 text::TextContentAnchorType eRet;
1655 case RndStdIds::FLY_AT_CHAR:
1656 eRet = text::TextContentAnchorType_AT_CHARACTER;
1658 case RndStdIds::FLY_AT_PAGE:
1659 eRet = text::TextContentAnchorType_AT_PAGE;
1661 case RndStdIds::FLY_AT_FLY:
1662 eRet = text::TextContentAnchorType_AT_FRAME;
1664 case RndStdIds::FLY_AS_CHAR:
1665 eRet = text::TextContentAnchorType_AS_CHARACTER;
1669 eRet = text::TextContentAnchorType_AT_PARAGRAPH;
1674 rVal <<= static_cast<sal_Int16>(
GetPageNum());
1683 uno::Reference<text::XTextFrame>
const xRet(
1691 OSL_ENSURE(
false,
"unknown MemberId" );
1702 switch ( nMemberId )
1709 case text::TextContentAnchorType_AS_CHARACTER:
1710 eAnchor = RndStdIds::FLY_AS_CHAR;
1712 case text::TextContentAnchorType_AT_PAGE:
1713 eAnchor = RndStdIds::FLY_AT_PAGE;
1722 case text::TextContentAnchorType_AT_FRAME:
1723 eAnchor = RndStdIds::FLY_AT_FLY;
1725 case text::TextContentAnchorType_AT_CHARACTER:
1726 eAnchor = RndStdIds::FLY_AT_CHAR;
1730 eAnchor = RndStdIds::FLY_AT_PARA;
1739 if((rVal >>= nVal) && nVal > 0)
1759 OSL_ENSURE(
false,
"unknown MemberId" );
1767 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatAnchor"));
1768 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1772 std::stringstream aContentAnchor;
1774 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"m_pContentAnchor"), BAD_CAST(aContentAnchor.str().c_str()));
1777 (
void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST(
"m_pContentAnchor"),
"%p",
m_pContentAnchor.get());
1778 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"m_eAnchorType"), BAD_CAST(OString::number(static_cast<int>(
m_eAnchorId)).getStr()));
1779 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"m_nPageNumber"), BAD_CAST(OString::number(
m_nPageNumber).getStr()));
1780 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"m_nOrder"), BAD_CAST(OString::number(
m_nOrder).getStr()));
1781 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"s_nOrderCounter"), BAD_CAST(OString::number(
s_nOrderCounter).getStr()));
1782 OUString aPresentation;
1784 GetPresentation(SfxItemPresentation::Nameless, MapUnit::Map100thMM, MapUnit::Map100thMM, aPresentation, aIntlWrapper);
1785 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"presentation"), BAD_CAST(aPresentation.toUtf8().getStr()));
1787 (
void)xmlTextWriterEndElement(pWriter);
1793 m_bIsServerMap(
false )
1799 m_sTargetFrameName( rURL.GetTargetFrameName() ),
1802 m_bIsServerMap( rURL.IsServerMap() )
1814 assert(SfxPoolItem::operator==(rAttr));
1851 switch ( nMemberId )
1864 uno::Reference< uno::XInterface > xInt;
1874 uno::Reference< container::XIndexContainer > xCont(xInt, uno::UNO_QUERY);
1882 OSL_ENSURE(
false,
"unknown MemberId" );
1893 switch ( nMemberId )
1918 uno::Reference<container::XIndexContainer> xCont;
1921 else if(rVal >>= xCont)
1935 OSL_ENSURE(
false,
"unknown MemberId" );
1963 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFormatNoBalancedColumns"));
1964 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"whichId"), BAD_CAST(OString::number(
Which()).getStr()));
1965 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"value"), BAD_CAST(OString::boolean(
GetValue()).getStr()));
1966 (
void)xmlTextWriterEndElement(pWriter);
2015 default:
return false;
2028 bool bVal = *o3tl::doAccess<bool>(rVal);
2037 bool bVal = *o3tl::doAccess<bool>(rVal);
2056 bool bVal = *o3tl::doAccess<bool>(rVal);
2078 OUString sVal; rVal >>= sVal;
2084 OUString sVal; rVal >>= sVal;
2088 default: bRet =
false;
2111 assert(SfxPoolItem::operator==(rAttr));
2154 switch ( nMemberId )
2165 OSL_ENSURE(
false,
"unknown MemberId" );
2185 assert(SfxPoolItem::operator==(rAttr));
2201 switch ( nMemberId )
2210 OSL_ENSURE(
false,
"unknown MemberId" );
2221 switch ( nMemberId )
2236 OSL_ENSURE(
false,
"unknown MemberId" );
2244 , m_nBaseHeight( 400 ), m_nRubyHeight( 200 ), m_eGridType(
GRID_NONE )
2245 , m_bRubyTextBelow(
false ), m_bPrintGrid( true ), m_bDisplayGrid( true )
2246 , m_nBaseWidth(400), m_bSnapToChars( true ), m_bSquaredMode(true)
2256 assert(SfxPoolItem::operator==(rAttr));
2257 SwTextGridItem const& rOther(static_cast<SwTextGridItem const&>(rAttr));
2299 "This value needs TWIPS-MM100 conversion" );
2303 OSL_ENSURE( (nMemberId & CONVERT_TWIPS) != 0,
2304 "This value needs TWIPS-MM100 conversion" );
2308 OSL_ENSURE( (nMemberId & CONVERT_TWIPS) != 0,
2309 "This value needs TWIPS-MM100 conversion" );
2319 rVal <<= text::TextGridMode::LINES;
2322 rVal <<= text::TextGridMode::LINES_AND_CHARS;
2325 OSL_FAIL(
"unknown SwTextGrid value");
2337 OSL_FAIL(
"Unknown SwTextGridItem member");
2353 bRet = (rVal >>= nTmp);
2361 bRet = (rVal >>= nTmp);
2362 if( bRet && (nTmp >= 0) )
2363 SetLines( o3tl::narrowing<sal_uInt16>(nTmp) );
2382 "This value needs TWIPS-MM100 conversion" );
2384 bRet = (rVal >>= nTmp);
2391 #define MIN_TEXTGRID_SIZE 100
2412 bRet = (rVal >>= nTmp);
2420 case text::TextGridMode::LINES:
2423 case text::TextGridMode::LINES_AND_CHARS:
2438 bool bStandard = *o3tl::doAccess<bool>(rVal);
2443 OSL_FAIL(
"Unknown SwTextGridItem member");
2518 const char* pFormatNm,
2520 sal_uInt16 nFormatWhich,
2522 :
SwFormat(rPool, pFormatNm, pWhichRange, pDrvdFrame, nFormatWhich),
2529 const OUString &rFormatNm,
2531 sal_uInt16 nFormatWhich,
2533 :
SwFormat(rPool, rFormatNm, pWhichRange, pDrvdFrame, nFormatWhich),
2540 if( !
GetDoc()->IsInDtor())
2569 bool const renamed =
2590 if (rHint.
GetId() != SfxHintId::SwLegacyModify)
2593 const sal_uInt16 nNewWhich = pLegacy->
m_pNew ? pLegacy->m_pNew->
Which() : 0;
2597 const SwPosition* pNewAnchorPosition =
nullptr;
2602 pNewAttrSetChg =
static_cast<const SwAttrSetChg*
>(pLegacy->m_pNew);
2610 for(
const SfxPoolItem* pItem = aIter.GetCurItem(); pItem; pItem = aIter.NextItem())
2623 assert(pNewAnchorPosition ==
nullptr ||
2642 pNewAnchorPosition =
static_cast<const SwFormatAnchor*
>(pLegacy->m_pNew)->GetContentAnchor();
2645 const sal_uInt16 nOldWhich = pLegacy->m_pOld ? pLegacy->m_pOld->
Which() : 0;
2646 const SwPosition* pOldAnchorPosition =
nullptr;
2652 pOldAttrSetChg =
static_cast<const SwAttrSetChg*
>(pLegacy->m_pOld);
2657 assert(pOldAnchorPosition ==
nullptr ||
2663 pOldAnchorPosition =
static_cast<const SwFormatAnchor*
>(pLegacy->m_pOld)->GetContentAnchor();
2666 SetXObject(uno::Reference<uno::XInterface>(
nullptr));
2670 assert(nOldWhich == nNewWhich || !nOldWhich || !nNewWhich);
2682 if(pOldAnchorPosition !=
nullptr && (pNewAnchorPosition ==
nullptr || pOldAnchorPosition->
nNode.
GetIndex() != pNewAnchorPosition->
nNode.
GetIndex()))
2684 if(pNewAnchorPosition !=
nullptr && (pOldAnchorPosition ==
nullptr || pOldAnchorPosition->
nNode.
GetIndex() != pNewAnchorPosition->
nNode.
GetIndex()))
2690 rFormat.
Add(
this );
2702 }
while(
nullptr != ( pLast = aIter.
Next() ));
2714 if(
auto pSectionFormat = dynamic_cast<const SwSectionFormat*>(
this ))
2721 pFrame = aTmp.NextFrame();
2723 if( pFrame && !pFrame->KnowsFormat(*
this) )
2731 aRet = pFrame->getFramePrintArea();
2734 aRet = pFrame->getFrameArea();
2735 aRet.
Pos().AdjustY( -1 );
2744 std::pair<Point, bool> tmp;
2747 tmp.first = *pPoint;
2750 pFrame =
::GetFrameOfModify(
nullptr, *
this, nFrameType,
nullptr, pPoint ? &tmp :
nullptr);
2768 std::pair<Point, bool>
const tmp(aNullPt,
false);
2799 for( n = 0; n < rFormats.
size(); ++n )
2803 if( pIdx && pFlyNd == &pIdx->
GetNode() )
2805 if( pFormat ==
this )
2809 if ((RndStdIds::FLY_AT_PAGE == pAnchor->
GetAnchorId()) ||
2820 if( n >= rFormats.
size() )
2822 OSL_ENSURE(
false,
"Fly section but no format found" );
2844 return text::PositionLayoutDir::PositionInLayoutDirOfAnchor;
2858 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(
"SwFrameFormat"));
2859 (
void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST(
"ptr"),
"%p",
this);
2860 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"name"), BAD_CAST(
GetName().toUtf8().getStr()));
2861 (
void)xmlTextWriterWriteFormatAttribute(pWriter, BAD_CAST(
"whichId"),
"%d",
Which());
2863 const char* pWhich =
nullptr;
2867 pWhich =
"fly frame format";
2870 pWhich =
"draw frame format";
2874 (
void)xmlTextWriterWriteAttribute(pWriter, BAD_CAST(
"which"), BAD_CAST(pWhich));
2884 pSdrObject->dumpAsXml(pWriter);
2886 (
void)xmlTextWriterEndElement(pWriter);
2891 (
void)xmlTextWriterStartElement(pWriter, BAD_CAST(pName));
2893 pFormat->dumpAsXml(pWriter);
2894 (
void)xmlTextWriterEndElement(pWriter);
2910 }
while(
nullptr != ( pLast = aIter.
Next() ));
2938 case RndStdIds::FLY_AS_CHAR:
2939 case RndStdIds::FLY_AT_PARA:
2940 case RndStdIds::FLY_AT_CHAR:
2947 case RndStdIds::FLY_AT_FLY:
2958 if ( pCNd ==
nullptr )
2970 if ( pModify ==
nullptr )
2974 for(
size_t i = 0;
i < rFormats.
size(); ++
i )
2980 pModify = pFlyFormat;
2988 case RndStdIds::FLY_AT_PAGE:
2996 for (
SwFrame* pFrame = aIter.
First(); pFrame !=
nullptr; pFrame = aIter.
Next() )
3031 bool bAdd = !pFrame->IsContentFrame() ||
3034 if ( RndStdIds::FLY_AT_FLY == aAnchorAttr.
GetAnchorId() && !pFrame->IsFlyFrame() )
3043 aAnchorAttr.
SetType( RndStdIds::FLY_AT_PARA );
3054 case RndStdIds::FLY_AS_CHAR:
3055 case RndStdIds::FLY_AT_PARA:
3056 case RndStdIds::FLY_AT_CHAR:
3058 assert(pFrame->IsTextFrame());
3067 if (bAdd && pFrame->GetDrawObjs())
3075 if( pObj->DynCastFlyFrame() !=
nullptr &&
3076 (&pObj->GetFrameFormat()) ==
this )
3089 case RndStdIds::FLY_AT_FLY:
3093 case RndStdIds::FLY_AT_PARA:
3094 case RndStdIds::FLY_AT_CHAR:
3098 case RndStdIds::FLY_AS_CHAR:
3103 assert(
false &&
"New anchor type" );
3105 pFrame->AppendFly( pFly );
3117 std::pair<Point, bool> tmp;
3120 tmp.first = *pPoint;
3143 switch( rInfo.
Which() )
3163 OSL_ENSURE( pMasterObject,
"<SwFlyFrameFormat::SetObjTitle(..)> - missing <SdrObject> instance" );
3165 if ( !pMasterObject )
3182 OSL_ENSURE( pMasterObject,
"<SwFlyFrameFormat::GetObjTitle(..)> - missing <SdrObject> instance" );
3183 if ( !pMasterObject )
3187 if (!pMasterObject->
GetTitle().isEmpty())
3206 OSL_ENSURE( pMasterObject,
"<SwFlyFrameFormat::SetDescription(..)> - missing <SdrObject> instance" );
3208 if ( !pMasterObject )
3225 OSL_ENSURE( pMasterObject,
"<SwFlyFrameFormat::GetDescription(..)> - missing <SdrObject> instance" );
3226 if ( !pMasterObject )
3257 aBackground->GetColor().IsTransparent() &&
3265 const GraphicObject *pTmpGrf = aBackground->GetGraphicObject();
3298 !(aBackground->GetGraphicObject()) )
3310 : mrFlyFrameFormat( _rFlyFrameFormat ),
3311 mbAnchorNodeChanged(
false ),
3316 if ( ((nNewAnchorType == RndStdIds::FLY_AT_PARA) ||
3317 (nNewAnchorType == RndStdIds::FLY_AT_CHAR)) &&
3321 if ( aOldAnchorFormat.GetAnchorId() == nNewAnchorType &&
3322 aOldAnchorFormat.GetContentAnchor() &&
3323 aOldAnchorFormat.GetContentAnchor()->nNode.GetNode().GetContentNode() &&
3324 aOldAnchorFormat.GetContentAnchor()->nNode !=
3328 sal_uInt32 nOldNumOfAnchFrame( 0 );
3330 *(aOldAnchorFormat.GetContentAnchor()->nNode.GetNode().GetContentNode()) );
3333 ++nOldNumOfAnchFrame;
3336 sal_uInt32 nNewNumOfAnchFrame( 0 );
3341 ++nNewNumOfAnchFrame;
3343 if ( nOldNumOfAnchFrame != nNewNumOfAnchFrame )
3351 if ( pFrame != _pKeepThisFlyFrame )
3356 }
while(
nullptr != ( pFrame = aIter.
Next() ));
3364 if (aOldAnchorFormat.GetContentAnchor()
3365 && aOldAnchorFormat.GetAnchorId() == RndStdIds::FLY_AT_CHAR)
3370 if (_pKeepThisFlyFrame)
3486 switch ( _nPositionLayoutDir )
3488 case text::PositionLayoutDir::PositionInHoriL2R:
3489 case text::PositionLayoutDir::PositionInLayoutDirOfAnchor:
3496 OSL_FAIL(
"<SwDrawFrameFormat::SetPositionLayoutDir(..)> - invalid attribute value." );
3517 aResult =
SwResId(STR_GRAPHIC);
3543 pRef = pFly->
Lower();
3555 Point aPos( rPoint );
3564 sal_uInt32 nFlags = 0;
3568 GetMirrorGrf().GetValue();
3577 return const_cast<ImageMap*
>(rURL.
GetMap())->GetHitIMapObject( aOrigSz,
3578 aActSz, aPos, nFlags );
3597 OSL_ENSURE(
false,
"getSdrAllFillAttributesHelper() call only valid for RES_FLYFRMFMT and RES_FRMFMT (!)");
3620 if (!pFlyFrameFormat)
3634 if (pFrame == pHeader)
3644 #if OSL_DEBUG_LEVEL > 0 && !defined NDEBUG
3649 SwNode const*
const pNode(rNodes[
i]);
3651 for (
const auto& rpFly : rFlys)
3654 assert(&rAnchor.GetContentAnchor()->nNode.GetNode() == pNode);
3658 if (!pSpzFrameFormats)
3661 for (
auto it = pSpzFrameFormats->begin(); it != pSpzFrameFormats->end(); ++it)
3664 if (RndStdIds::FLY_AT_PAGE == rAnchor.GetAnchorId())
3666 assert(!rAnchor.GetContentAnchor()
3673 SwNode & rNode(rAnchor.GetContentAnchor()->nNode.GetNode());
3674 std::vector<SwFrameFormat*>
const& rFlys(rNode.GetAnchoredFlys());
3675 assert(std::find(rFlys.begin(), rFlys.end(), *it) != rFlys.end());
3676 switch (rAnchor.GetAnchorId())
3678 case RndStdIds::FLY_AT_FLY:
3679 assert(rNode.IsStartNode());
3681 case RndStdIds::FLY_AT_PARA:
3682 assert(rNode.IsTextNode() || rNode.IsTableNode());
3684 case RndStdIds::FLY_AS_CHAR:
3685 case RndStdIds::FLY_AT_CHAR:
3686 assert(rNode.IsTextNode());
OUString AsRGBHexString() const
sal_uInt16 m_nWish
Desired width, borders included.
const SwAttrSet * GetChgSet() const
What has changed.
#define MID_GRID_SNAPTOCHARS
virtual ~FindSdrObjectHint() override
SvxNumType GetNumberingType() const
Starts a section of nodes in the document model.
SwNodeOffset min(const SwNodeOffset &a, const SwNodeOffset &b)
const sw::BroadcastingModify * GetDefinedIn() const
Query / set where attribute is anchored.
const SwVirtFlyDrawObj * GetVirtDrawObj() const
Base class of the Writer layout elements.
tools::Long GetWidth() const
constexpr TypedWhichId< SwFormatPageDesc > RES_PAGEDESC(93)
const ::std::optional< sal_uInt16 > & GetNumOffset() const
constexpr TypedWhichId< SwFormatSurround > RES_SURROUND(101)
virtual void SwClientNotify(const SwModify &, const SfxHint &rHint) override
constexpr TypedWhichId< SwFormatFillOrder > RES_FILL_ORDER(RES_FRMATR_BEGIN)
SVX_NUM_CHARS_UPPER_LETTER_N
constexpr TypedWhichId< SwStringMsgPoolItem > RES_TITLE_CHANGED(188)
void Add(SwClient *pDepend)
virtual const SwFlyFrameFormat * GetFormat() const override
#define MID_SURROUND_SURROUNDTYPE
Marks a position in the document model.
void dumpAsXml(xmlTextWriterPtr pWriter) const
std::vector< SwColumn > SwColumns
SwContentNode * GetNode(SwPaM &rPam, bool &rbFirst, SwMoveFnCollection const &fnMove, bool const bInReadOnly, SwRootFrame const *const i_pLayout)
This function returns the next node in direction of search.
Pagedescriptor Client of SwPageDesc that is "described" by the attribute.
void SetHeight(tools::Long n)
SwFlyFrameFormat & mrFlyFrameFormat
constexpr auto toTwips(N number, Length from)
virtual SwFrameFormat * MakeLayoutFormat(RndStdIds eRequest, const SfxItemSet *pSet)=0
SwPageDesc * GetPageDesc()
void setWidth(tools::Long nWidth)
constexpr TypedWhichId< SwTableBoxNumFormat > RES_BOXATR_FORMAT(RES_BOXATR_BEGIN)
bool IsLowerOf(const SwLayoutFrame *pUpper) const
virtual const SwRootFrame * GetCurrentLayout() const =0
bool GetDisplayGrid() const
sal_uInt16 GetBaseWidth() const
constexpr TypedWhichId< SwFormatHeader > RES_HEADER(96)
constexpr TypedWhichId< SwFormatChg > RES_FMT_CHG(162)
#define MID_FRMSIZE_SIZE_TYPE
constexpr TypedWhichId< SwFormatCol > RES_COL(109)
constexpr TypedWhichId< SwPtrMsgPoolItem > RES_REMOVE_UNO_OBJECT(181)
void SetLeft(sal_uInt16 nNew)
constexpr TypedWhichId< SwFormatFrameSize > RES_FRM_SIZE(89)
std::unique_ptr< SwPosition > mpCommentAnchor
If the fly frame has a comment, this points to the old comment anchor.
virtual SwFormatContent * Clone(SfxItemPool *pPool=nullptr) const override
virtual bool HasMetrics() const
SwFrameType GetType() const
virtual ~GetZOrderHint() override
#define MID_FRMSIZE_IS_SYNC_WIDTH_TO_HEIGHT
#define MID_FRMSIZE_REL_WIDTH
virtual Size GetTwipSize() const =0
#define SAL_INFO_IF(condition, area, stream)
-""- and with own numberformat
constexpr::Color COL_TRANSPARENT(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
const SwRect & getFramePrintArea() const
OUString GetDescription() const
sal_uInt16 m_nLeft
Left border.
const SwPosition * GetMark() const
void SetRight(sal_uInt16 nNew)
bool Pop(SwCursorShell::PopMode=SwCursorShell::PopMode::DeleteStack)
virtual void ScaleMetrics(tools::Long lMult, tools::Long lDiv)
constexpr Point convert(const Point &rPoint, o3tl::Length eFrom, o3tl::Length eTo)
#define MID_VERTORIENT_RELATION
#define MID_URL_HYPERLINKNAME
void dumpAsXml(xmlTextWriterPtr pWriter) const
#define MID_PAGEDESC_PAGENUMOFFSET
const SfxPoolItem * m_pNew
void SetRubyHeight(sal_uInt16 nNew)
bool SvUnoImageMap_fillImageMap(const Reference< XInterface > &xImageMap, ImageMap &rMap)
#define MIN_TEXTGRID_SIZE
void dumpAsXml(xmlTextWriterPtr pWriter) const override
bool GetRubyTextBelow() const
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
Content, content of frame (header, footer, fly).
void DestroyCursor()
transform TableCursor to normal cursor, nullify Tablemode
static void DestroyFrame(SwFrame *const pFrame)
this is the only way to delete a SwFrame instance
virtual ~SwTextGridItem() override
void Pos(const Point &rNew)
#define MID_SURROUND_ANCHORONLY
Dialog to specify the properties of date form field.
IDocumentUndoRedo & GetIDocumentUndoRedo()
constexpr::Color COL_LIGHTGRAY(0xC0, 0xC0, 0xC0)
Of course Writer needs its own rectangles.
#define MID_PAGEDESC_PAGEDESCNAME
SwClient * Remove(SwClient *pDepend)
IDocumentContentOperations const & getIDocumentContentOperations() const
virtual SwTextGridItem * Clone(SfxItemPool *pPool=nullptr) const override
EmbeddedObjectRef * pObject
css::uno::Reference< css::uno::XInterface > SvxXTextColumns_createInstance() noexcept
virtual ~CreatePortionHint() override
SwHandleAnchorNodeChg(SwFlyFrameFormat &_rFlyFrameFormat, const SwFormatAnchor &_rNewAnchorFormat, SwFlyFrame const *_pKeepThisFlyFrame=nullptr)
checks, if re-creation of fly frames for an anchor node change at the given fly frame format is neces...
virtual bool GetInfo(SfxPoolItem &) const override
#define MID_ANCHOR_PAGENUM
const SwFrameFormats * GetSpzFrameFormats() const
void SetNewContentIdx(const SwNodeIndex *pIdx)
void SetDisplayGrid(bool bNew)
Value in Var-direction gives minimum (can be exceeded but not be less).
constexpr TypedWhichId< SwFlyFrameFormat > RES_FLYFRMFMT(156)
constexpr SwTwips DEF_GUTTER_WIDTH
const OUString & GetName() const
#define UNO_NAME_SEPARATOR_LINE_WIDTH
sal_uInt16 GetPhyPageNum() const
void AddAnchoredFly(SwFrameFormat *)
constexpr auto convertTwipToMm100(N n)
Used by the UI to modify the document model.
OUString SwResId(TranslateId aId)
constexpr tools::Long Width() const
virtual bool operator==(SfxPoolItem const &other) const override
void SetSquaredMode(bool bNew)
constexpr TypedWhichId< SwFormatVertOrient > RES_VERT_ORIENT(102)
#define MID_FRMSIZE_HEIGHT
bool GetSnapToChars() const
wrapper class for the positioning of Writer fly frames and drawing objects
void SetRubyTextBelow(bool bNew)
constexpr TypedWhichId< SwDrawFrameFormat > RES_DRAWFRMFMT(159)
void SetBaseWidth(sal_uInt16 nNew)
constexpr TypedWhichId< SwFormatHoriOrient > RES_HORI_ORIENT(103)
virtual ~RestoreFlyAnchorHint() override
const SwRect & getFrameArea() const
#define MID_GRID_STANDARD_MODE
void dumpAsXml(xmlTextWriterPtr pWriter) const override
#define UNO_NAME_SEPARATOR_LINE_IS_ON
std::shared_ptr< SdrAllFillAttributesHelper > SdrAllFillAttributesHelperPtr
static sal_Int16 lcl_IntToRelation(const uno::Any &rVal)
virtual ~CollectTextObjectsHint() override
virtual void DeleteSection(SwNode *pNode)=0
Delete section containing the node.
std::vector< SwFrameFormat * > const & GetAnchoredFlys() const
#define UNO_NAME_SEPARATOR_LINE_RELATIVE_HEIGHT
#define suppress_fun_call_w_exception(expr)
const SwFormatField & GetFormatField() const
#define MID_LINENUMBER_STARTVALUE
bool IsTransparent() const
SwNodeOffset GetIndex() const
virtual OUString GetName() const override
SwFlyFrame * FindFlyFrame()
void SetColor(const Color &rCol)
virtual SwFormatEndAtTextEnd * Clone(SfxItemPool *pPool=nullptr) const override
#define MID_COLUMN_SEPARATOR_LINE
#define MID_SURROUND_CONTOUR
void PlaceFly(SwFlyFrame *pFly, SwFlyFrameFormat *pFormat)
sw::BroadcastingModify * m_pDefinedIn
Points to the object in which the attribute was set (ContentNode/Format).
bool GetAtPageRelOrientation(sal_Int16 &rOrientation, bool const isIgnorePrintArea)
#define MID_FRMSIZE_WIDTH
#define MID_CHAIN_NEXTNAME
PaM is Point and Mark: a selection of the document model.
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
#define MID_ANCHOR_ANCHORTYPE
#define MID_HORIORIENT_POSITION
#define MID_URL_CLIENTMAP
#define MID_GRID_BASEHEIGHT
void Broadcast(const SfxHint &rHint)
SwPaM * CreateCursor()
delete the current cursor and make the following into the current
const SwPosition * GetPoint() const
#define MID_FRMSIZE_WIDTH_TYPE
void SetValue(EnumT nTheValue)
#define MID_GRID_RUBYHEIGHT
const GraphicAttr & GetAttr() const
virtual ~SwFormatPageDesc() override
SwPageFrame * FindPageFrame()
void Push()
store a copy of the current cursor on the cursor stack
void ParkCursor(const SwNodeIndex &rIdx)
Remove selections and additional cursors of all shells.
constexpr TypedWhichId< SwFormatURL > RES_URL(111)
#define MID_VERTORIENT_POSITION
const SwFrame * Lower() const
virtual bool operator==(const SfxPoolItem &) const override
"Pure virtual methods" of SfxPoolItem.
SwContentNode * GetContentNode()
SwNodeOffset GetIndex() const
SwNoTextNode * GetNoTextNode()
virtual SwCursor & GetCurrentShellCursor() override
Return the current shell cursor.
constexpr TypedWhichId< SwStringMsgPoolItem > RES_DESCRIPTION_CHANGED(189)
SwLayoutFrame * GetUpper()
constexpr sal_uInt16 XATTR_FILL_FIRST(XATTRSET_LINE+1)
constexpr TypedWhichId< SwAttrSetChg > RES_ATTRSET_CHG(163)
OUString GetTitle() const
SwFormatPageDesc(const SwPageDesc *pDesc=nullptr)
bool KnowsPageDesc() const
Layout frame for SwNoTextNode, i.e. graphics and OLE nodes (including charts).
void SetBaseHeight(sal_uInt16 nNew)
Marks a node in the document model.
#define MID_SURROUND_CONTOUROUTSIDE
const SwAttrSet * GetTheChgdSet() const
Where it has changed.
static void lcl_DelHFFormat(SwClient *pToRemove, SwFrameFormat *pFormat)
SwTextField * GetFieldTextAttrAt(const sal_Int32 nIndex, const bool bIncludeInputFieldAtStart=false) const
#define MID_FRMSIZE_IS_AUTO_HEIGHT
void SSize(const Size &rNew)
tools::Long GetHeight() const
A page of the document layout.
SVX_NUM_CHARS_LOWER_LETTER_N
Frame cannot be moved in Var-direction.
IDocumentLayoutAccess const & getIDocumentLayoutAccess() const
constexpr TypedWhichId< SwFormatContent > RES_CNTNT(95)
sal_uInt16 GetLines() const
virtual bool operator==(const SfxPoolItem &) const override
void SetWidth(tools::Long n)
SwFieldType * GetTyp() const
at end of the current text end
const SwNodeIndex * GetContentIdx() const
bool Delete()
Delete content of all ranges.
SvtBroadcaster & GetNotifier()
virtual OUString GetURL() const override
virtual ~SwFormatContent() override
SwFormatContent(const SwStartNode *pStartNode=nullptr)
SwTextNode is a paragraph in the document model.
#define MID_HORIORIENT_ORIENT
bool IsFlyFrameFormatInHeader(const SwFrameFormat &rFormat)
#define MID_FRMSIZE_REL_HEIGHT_RELATION
virtual ~WW8AnchorConvHint() override
constexpr TypedWhichId< SwFormatChain > RES_CHAIN(114)
sal_uInt16 GetWishWidth() const
#define UNO_NAME_AUTOMATIC_DISTANCE
virtual bool PutValue(const css::uno::Any &rVal, sal_uInt8 nMemberId) override
void SetWishWidth(sal_uInt16 nNew)
constexpr TypedWhichId< SwTextGridItem > RES_TEXTGRID(115)
virtual ~GetObjectConnectedHint() override
#define MID_ANCHOR_ANCHORFRAME
#define MID_CHAIN_PREVNAME
general base class for all free-flowing frames
sal_uInt16 GetRight() const
SwPageFrame * FindPageFrameOfAnchor()
method to determine the page frame, on which the 'anchor' of the given anchored object is...
void SwitchPaperMode(bool bNew)
~SwHandleAnchorNodeChg()
calls , if re-creation of fly frames is necessary.
constexpr tools::Long Height() const
#define MID_VERTORIENT_ORIENT
void SetSnapToChars(bool bNew)
#define MID_FRMSIZE_IS_SYNC_HEIGHT_TO_WIDTH
#define MID_FRMSIZE_REL_WIDTH_RELATION
virtual bool QueryValue(css::uno::Any &rVal, sal_uInt8 nMemberId=0) const override
#define MID_GRID_BASEWIDTH
const Color & GetColor() const
bool IsNoTextFrame() const
static void FillProgName(const OUString &rName, OUString &rFillName, SwGetPoolIdFromName)
void RemoveAnchoredFly(SwFrameFormat *)
std::unique_ptr< SwNodeIndex > m_pStartNode
const SwModify * GetRegisteredIn() const
static SW_DLLPUBLIC css::uno::Reference< css::text::XTextFrame > CreateXTextFrame(SwDoc &rDoc, SwFrameFormat *pFrameFormat)
void SetDescription(const OUString &rStr)
SwTableBox is one table cell in the document model.
void SetSize(const Size &rSize)
#define UNO_NAME_IS_AUTOMATIC
bool operator==(const SwColumn &) const
SwFormatPageDesc & operator=(const SwFormatPageDesc &rCpy)
const SwAttrSet & GetSwAttrSet() const
Does node has already its own auto-attributes? Access to SwAttrSet.
virtual void CallSwClientNotify(const SfxHint &rHint) const override
-""- and with own number sequence
constexpr TypedWhichId< SwStringMsgPoolItem > RES_NAME_CHANGED(187)
#define UNO_NAME_SEPARATOR_LINE_COLOR
#define MID_HORIORIENT_PAGETOGGLE
#define MID_HORIORIENT_RELATION
sal_uInt16 GetLeft() const
void setHeight(tools::Long nHeight)
#define MID_FRMSIZE_REL_HEIGHT
constexpr TypedWhichId< SwFormatFooter > RES_FOOTER(97)
Reference< XInterface > SvUnoImageMap_createInstance()
::std::optional< sal_uInt16 > m_oNumOffset
Offset page number.
#define SAL_WARN(area, stream)
void SetNumOffset(const ::std::optional< sal_uInt16 > &oNum)
constexpr TypedWhichId< SwFormatLineNumber > RES_LINENUMBER(116)
struct _xmlTextWriter * xmlTextWriterPtr
constexpr sal_uInt16 XATTR_FILL_LAST(XATTR_FILLBACKGROUND)
bool GetSquaredMode() const
virtual OUString GetComment() const override
SwTextGrid GetGridType() const
SwSectionNode * GetSectionNode()
#define UNO_NAME_SEPARATOR_LINE_VERTIVAL_ALIGNMENT
virtual bool operator==(const SfxPoolItem &) const override
"Pure virtual methods" of SfxPoolItem.
virtual void SetMark()
Unless this is called, the getter method of Mark will return Point.
#define MID_GRID_RUBY_BELOW
const SwFrame * GetAnchorFrame() const
#define UNO_NAME_SEPARATOR_LINE_STYLE
#define MID_URL_SERVERMAP
void SetPrintGrid(bool bNew)
void SetNumberingType(SvxNumType nSet)
SwFormatEndAtTextEnd(SwFootnoteEndPosEnum ePos=FTNEND_ATPGORDOCEND)
Frame is variable in Var-direction.
bool IsInvalidItem(const SfxPoolItem *pItem)
sal_uInt16 GetBaseHeight() const
const SfxPoolItem * GetItem(sal_uInt16 nWhich, bool bSearchInParent=true) const
virtual SwFormatPageDesc * Clone(SfxItemPool *pPool=nullptr) const override
SwViewShell * GetCurrShell() const
void RegisterToPageDesc(SwPageDesc &)
class for collecting anchored objects
constexpr TypedWhichId< SwPtrMsgPoolItem > RES_CONTENT_VISIBLE(185)
const SvEventDescription * sw_GetSupportedMacroItems()
void SetTitle(const OUString &rStr)
SwContentNode * GoNext(SwNodeIndex *) const
sal_uInt16 GetRubyHeight() const
bool GetPrintGrid() const
SwRootFrame * getRootFrame()
sal_Int32 GetEnumAsInt32(const css::uno::Any &rVal)
void SetGridType(SwTextGrid eNew)
constexpr TypedWhichId< SwPtrMsgPoolItem > RES_OBJECTDYING(RES_MSG_BEGIN)
const Size & GetSize() const
void SetLines(sal_uInt16 nNew)
constexpr TypedWhichId< SwFormatAnchor > RES_ANCHOR(104)
sal_uInt16 m_nRight
Right border.
bool m_bDetectedRangeSegmentation false
void CheckAnchoredFlyConsistency(SwDoc const &rDoc)
Base class of the Writer document model elements.
#define MID_LINENUMBER_COUNT