28 #include <svx/svxids.hrc>
57 #include <osl/diagnose.h>
110 {
"normal", sal_uInt16(SvxCaseMap::NotMapped) },
111 {
"small-caps", sal_uInt16(SvxCaseMap::SmallCaps) },
117 {
"uppercase", sal_uInt16(SvxCaseMap::Uppercase) },
118 {
"lowercase", sal_uInt16(SvxCaseMap::Lowercase) },
119 {
"capitalize", sal_uInt16(SvxCaseMap::Capitalize) },
125 {
"ltr", sal_uInt16(SvxFrameDirection::Horizontal_LR_TB) },
126 {
"rtl", sal_uInt16(SvxFrameDirection::Horizontal_RL_TB) },
127 {
"inherit", sal_uInt16(SvxFrameDirection::Environment) },
158 {
"left", sal_uInt16(SvxAdjust::Left) },
159 {
"center", sal_uInt16(SvxAdjust::Center) },
160 {
"right", sal_uInt16(SvxAdjust::Right) },
161 {
"justify", sal_uInt16(SvxAdjust::Block) },
175 enum CSS1BorderStyle { CSS1_BS_NONE, CSS1_BS_SINGLE, CSS1_BS_DOUBLE, CSS1_BS_DOTTED, CSS1_BS_DASHED, CSS1_BS_GROOVE, CSS1_BS_RIDGE, CSS1_BS_INSET, CSS1_BS_OUTSET };
181 {
"none", CSS1_BS_NONE },
182 {
"dotted", CSS1_BS_DOTTED },
183 {
"dashed", CSS1_BS_DASHED },
184 {
"solid", CSS1_BS_SINGLE },
185 {
"double", CSS1_BS_DOUBLE },
186 {
"groove", CSS1_BS_GROOVE },
187 {
"ridge", CSS1_BS_RIDGE },
188 {
"inset", CSS1_BS_INSET },
189 {
"outset", CSS1_BS_OUTSET },
195 {
"left", sal_uInt16(SvxAdjust::Left) },
196 {
"right", sal_uInt16(SvxAdjust::Right) },
197 {
"none", sal_uInt16(SvxAdjust::End) },
260 struct SvxCSS1ItemIds
266 sal_uInt16 nPostureCJK;
267 sal_uInt16 nPostureCTL;
269 sal_uInt16 nWeightCJK;
270 sal_uInt16 nWeightCTL;
271 sal_uInt16 nFontHeight;
272 sal_uInt16 nFontHeightCJK;
273 sal_uInt16 nFontHeightCTL;
274 sal_uInt16 nUnderline;
275 sal_uInt16 nOverline;
276 sal_uInt16 nCrossedOut;
282 sal_uInt16 nLineSpacing;
286 sal_uInt16 nFormatSplit;
293 sal_uInt16 nLanguage;
294 sal_uInt16 nLanguageCJK;
295 sal_uInt16 nLanguageCTL;
296 sal_uInt16 nDirection;
311 aColor(
COL_BLACK ), nAbsWidth( USHRT_MAX ),
312 nNamedWidth( USHRT_MAX ), eStyle( CSS1_BS_NONE )
323 rBoxItem.
SetLine(
nullptr, nLine );
367 rBoxItem.
SetLine( &aBorderLine, nLine );
376 m_aId( rProp.m_aId ),
377 m_bTopMargin( rProp.m_bTopMargin ),
378 m_bBottomMargin( rProp.m_bBottomMargin ),
379 m_bLeftMargin( rProp.m_bLeftMargin ),
380 m_bRightMargin( rProp.m_bRightMargin ),
381 m_bTextIndent( rProp.m_bTextIndent ),
382 m_bNumbering ( rProp.m_bNumbering ),
383 m_bBullet ( rProp.m_bBullet ),
384 m_eFloat( rProp.m_eFloat ),
386 m_nTopBorderDistance( rProp.m_nTopBorderDistance ),
387 m_nBottomBorderDistance( rProp.m_nBottomBorderDistance ),
388 m_nLeftBorderDistance( rProp.m_nLeftBorderDistance ),
389 m_nRightBorderDistance( rProp.m_nRightBorderDistance ),
390 m_nNumberingType ( rProp.m_nNumberingType ),
391 m_cBulletChar( rProp.m_cBulletChar ),
392 m_nColumnCount( rProp.m_nColumnCount ),
393 m_nLeft( rProp.m_nLeft ),
394 m_nTop( rProp.m_nTop ),
395 m_nWidth( rProp.m_nWidth ),
396 m_nHeight( rProp.m_nHeight ),
397 m_nLeftMargin( rProp.m_nLeftMargin ),
398 m_nRightMargin( rProp.m_nRightMargin ),
399 m_eLeftType( rProp.m_eLeftType ),
400 m_eTopType( rProp.m_eTopType ),
401 m_eWidthType( rProp.m_eWidthType ),
402 m_eHeightType( rProp.m_eHeightType ),
403 m_eSizeType( rProp.m_eSizeType ),
404 m_ePageBreakBefore( rProp.m_ePageBreakBefore ),
405 m_ePageBreakAfter( rProp.m_ePageBreakAfter )
488 if( rProp.
m_eFloat != SvxAdjust::End )
538 case SvxBoxItemLine::TOP: nPos = 0;
break;
539 case SvxBoxItemLine::BOTTOM: nPos = 1;
break;
540 case SvxBoxItemLine::LEFT: nPos = 2;
break;
541 case SvxBoxItemLine::RIGHT: nPos = 3;
break;
575 CopyBorderInfo( SvxBoxItemLine::BOTTOM, SvxBoxItemLine::TOP, nWhat );
576 CopyBorderInfo( SvxBoxItemLine::TOP, SvxBoxItemLine::LEFT, nWhat );
580 CopyBorderInfo( SvxBoxItemLine::LEFT, SvxBoxItemLine::RIGHT, nWhat );
585 sal_uInt16 nMinBorderDist,
599 std::shared_ptr<SvxBoxItem> aBoxItem(std::make_shared<SvxBoxItem>(aItemIds.nBox));
601 aBoxItem.reset(pDfltItem->
Clone());
622 sal_uInt16 nDist = 0;
625 case 0: nLine = SvxBoxItemLine::TOP;
629 case 1: nLine = SvxBoxItemLine::BOTTOM;
633 case 2: nLine = SvxBoxItemLine::LEFT;
637 case 3: nLine = SvxBoxItemLine::RIGHT;
643 if( aBoxItem->GetLine( nLine ) )
646 nDist = aBoxItem->GetDistance( nLine );
648 if( nDist < nMinBorderDist )
649 nDist = nMinBorderDist;
656 aBoxItem->SetDistance( nDist, nLine );
659 rItemSet.
Put( *aBoxItem );
666 m_aItemSet( rItemSet ),
681 OSL_ENSURE(
m_pSheetItemSet,
"Where is the Item-Set for Style-Sheets?" );
683 for (
const std::unique_ptr<CSS1Selector> & rpSelection :
m_Selectors)
698 sal_uInt16
const *pWhichIds, sal_uInt16 nWhichIds ) :
699 m_sBaseURL( rBaseURL ),
701 m_pPropInfo( nullptr ),
702 m_eDefaultEnc( RTL_TEXTENCODING_DONTKNOW ),
703 m_bIgnoreFontFamily(
false )
706 auto initTrueWhich = [&rPool,
this](sal_uInt16 rWid)
713 aItemIds.nFont = initTrueWhich( SID_ATTR_CHAR_FONT );
714 aItemIds.nFontCJK = initTrueWhich( SID_ATTR_CHAR_CJK_FONT );
715 aItemIds.nFontCTL = initTrueWhich( SID_ATTR_CHAR_CTL_FONT );
716 aItemIds.nPosture = initTrueWhich( SID_ATTR_CHAR_POSTURE );
717 aItemIds.nPostureCJK = initTrueWhich( SID_ATTR_CHAR_CJK_POSTURE );
718 aItemIds.nPostureCTL = initTrueWhich( SID_ATTR_CHAR_CTL_POSTURE );
719 aItemIds.nWeight = initTrueWhich( SID_ATTR_CHAR_WEIGHT );
720 aItemIds.nWeightCJK = initTrueWhich( SID_ATTR_CHAR_CJK_WEIGHT );
721 aItemIds.nWeightCTL = initTrueWhich( SID_ATTR_CHAR_CTL_WEIGHT );
722 aItemIds.nFontHeight = initTrueWhich( SID_ATTR_CHAR_FONTHEIGHT );
723 aItemIds.nFontHeightCJK = initTrueWhich( SID_ATTR_CHAR_CJK_FONTHEIGHT );
724 aItemIds.nFontHeightCTL = initTrueWhich( SID_ATTR_CHAR_CTL_FONTHEIGHT );
725 aItemIds.nUnderline = initTrueWhich( SID_ATTR_CHAR_UNDERLINE );
726 aItemIds.nOverline = initTrueWhich( SID_ATTR_CHAR_OVERLINE );
727 aItemIds.nCrossedOut = initTrueWhich( SID_ATTR_CHAR_STRIKEOUT );
728 aItemIds.nColor = initTrueWhich( SID_ATTR_CHAR_COLOR );
729 aItemIds.nKerning = initTrueWhich( SID_ATTR_CHAR_KERNING );
730 aItemIds.nCaseMap = initTrueWhich( SID_ATTR_CHAR_CASEMAP );
731 aItemIds.nBlink = initTrueWhich( SID_ATTR_FLASH );
733 aItemIds.nLineSpacing = initTrueWhich( SID_ATTR_PARA_LINESPACE );
734 aItemIds.nAdjust = initTrueWhich( SID_ATTR_PARA_ADJUST );
735 aItemIds.nWidows = initTrueWhich( SID_ATTR_PARA_WIDOWS );
736 aItemIds.nOrphans = initTrueWhich( SID_ATTR_PARA_ORPHANS );
737 aItemIds.nFormatSplit = initTrueWhich( SID_ATTR_PARA_SPLIT );
741 aItemIds.nBox = initTrueWhich( SID_ATTR_BORDER_OUTER );
742 aItemIds.nBrush = initTrueWhich( SID_ATTR_BRUSH );
744 aItemIds.nLanguage = initTrueWhich( SID_ATTR_CHAR_LANGUAGE );
745 aItemIds.nLanguageCJK = initTrueWhich( SID_ATTR_CHAR_CJK_LANGUAGE );
746 aItemIds.nLanguageCTL = initTrueWhich( SID_ATTR_CHAR_CTL_LANGUAGE );
747 aItemIds.nDirection = initTrueWhich( SID_ATTR_FRAMEDIRECTION );
749 if( pWhichIds && nWhichIds )
750 for (sal_uInt16
i = 0;
i < nWhichIds; ++
i)
772 CSS1Map::const_iterator itr =
m_Ids.find(rId);
773 return itr ==
m_Ids.end() ?
nullptr : itr->second.get();
785 CSS1Map::const_iterator itr =
m_Classes.find(rClass);
786 return itr ==
m_Classes.end() ?
nullptr : itr->second.get();
794 OUString aKey( rPage );
802 OUString aKey( rPage );
806 CSS1Map::iterator itr =
m_Pages.find(aKey);
807 return itr ==
m_Pages.end() ?
nullptr : itr->second.get();
819 CSS1Map::iterator itr =
m_Tags.find(rTag);
820 return itr ==
m_Tags.end() ?
nullptr : itr->second.get();
830 for (
const std::unique_ptr<CSS1Selector> & rpSelector :
m_Selectors)
854 rItemSet.
ClearItem( aItemIds.nDirection );
861 const OUString &rValue, sal_uInt16& rEnum )
863 while( pPropTable->
pName )
865 if( !rValue.equalsIgnoreAsciiCaseAscii( pPropTable->
pName ) )
871 if( pPropTable->
pName )
872 rEnum = pPropTable->
nEnum;
874 return (pPropTable->
pName !=
nullptr);
881 Size aTwipSz( rWidth, rHeight );
885 rWidth = aTwipSz.
Width();
886 rHeight = aTwipSz.
Height();
896 case 0: nHeight = 8*20;
break;
897 case 1: nHeight = 10*20;
break;
898 case 2: nHeight = 11*20;
break;
899 case 3: nHeight = 12*20;
break;
900 case 4: nHeight = 17*20;
break;
901 case 5: nHeight = 20*20;
break;
903 default: nHeight = 32*20;
break;
919 CSS1Map::iterator itr = rMap.find(rKey);
920 if (itr == rMap.end())
922 rMap.insert(std::make_pair(rKey, std::make_unique<SvxCSS1MapEntry>(rItemSet, rProp)));
940 rTargetSet.
Put( rSrcSet );
947 rTargetSet.
Put( rSrcSet );
955 aLRSpace.SetLeft( rNewLRSpace.
GetLeft() );
957 aLRSpace.SetRight( rNewLRSpace.
GetRight() );
961 rTargetSet.
Put( aLRSpace );
969 aULSpace.SetUpper( rNewULSpace.
GetUpper() );
971 aULSpace.SetLower( rNewULSpace.
GetLower() );
973 rTargetSet.
Put( aULSpace );
977 rTargetInfo.
Merge( rSrcInfo );
990 OSL_ENSURE( pExpr,
"no expression" );
993 sal_uInt16 nPropHeight = 100;
1003 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1008 nHeight =
static_cast<sal_uLong>(nPHeight);
1012 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fHeight);
1018 nPropHeight = o3tl::narrowing<sal_uInt16>(pExpr->
GetNumber());
1036 if( nHeight || nPropHeight!=100 )
1039 aItemIds.nFontHeight );
1040 rItemSet.
Put( aFontHeight );
1041 aFontHeight.SetWhich( aItemIds.nFontHeightCJK );
1042 rItemSet.
Put( aFontHeight );
1043 aFontHeight.SetWhich( aItemIds.nFontHeightCTL );
1044 rItemSet.
Put( aFontHeight );
1053 OSL_ENSURE( pExpr,
"no expression" );
1055 OUStringBuffer
aName;
1059 bool bFound =
false;
1060 while( pExpr && (bFirst ||
','==pExpr->
GetOp() || !pExpr->
GetOp()) )
1071 while( pNext && !pNext->
GetOp() &&
1079 if( !aIdent.isEmpty() )
1081 if( !bFound && pFList )
1084 if(
nullptr != hFont )
1087 if( RTL_TEXTENCODING_DONTKNOW != rFMetric.
GetCharSet() )
1090 if( RTL_TEXTENCODING_SYMBOL == rFMetric.
GetCharSet() )
1091 eEnc = RTL_TEXTENCODING_SYMBOL;
1097 aName.append(aIdent);
1108 eEnc, aItemIds.nFont );
1109 rItemSet.
Put( aFont );
1110 aFont.
SetWhich( aItemIds.nFontCJK );
1111 rItemSet.
Put( aFont );
1112 aFont.
SetWhich( aItemIds.nFontCTL );
1113 rItemSet.
Put( aFont );
1122 OSL_ENSURE( pExpr,
"no expression" );
1133 SvxWeightItem aWeight( static_cast<FontWeight>(nWeight), aItemIds.nWeight );
1134 rItemSet.
Put( aWeight );
1135 aWeight.SetWhich( aItemIds.nWeightCJK );
1136 rItemSet.
Put( aWeight );
1137 aWeight.SetWhich( aItemIds.nWeightCTL );
1138 rItemSet.
Put( aWeight );
1144 sal_uInt16 nWeight = o3tl::narrowing<sal_uInt16>(pExpr->
GetNumber());
1147 rItemSet.
Put( aWeight );
1148 aWeight.
SetWhich( aItemIds.nWeightCJK );
1149 rItemSet.
Put( aWeight );
1150 aWeight.
SetWhich( aItemIds.nWeightCTL );
1151 rItemSet.
Put( aWeight );
1165 OSL_ENSURE( pExpr,
"no expression" );
1167 bool bPosture =
false;
1168 bool bCaseMap =
false;
1176 for(
int i=0; pExpr &&
i<2; ++i )
1182 const OUString& rValue = pExpr->
GetString();
1191 eCaseMap = SvxCaseMap::NotMapped;
1196 else if( !bCaseMap &&
1197 rValue.equalsIgnoreAsciiCase(
"small-caps" ) )
1199 eCaseMap = SvxCaseMap::SmallCaps;
1211 rItemSet.
Put( aPosture );
1212 aPosture.SetWhich( aItemIds.nPostureCJK );
1213 rItemSet.
Put( aPosture );
1214 aPosture.SetWhich( aItemIds.nPostureCTL );
1215 rItemSet.
Put( aPosture );
1227 assert(pExpr &&
"no expression");
1234 sal_uInt16 nCaseMap;
1239 aItemIds.nCaseMap ) );
1253 OSL_ENSURE( pExpr,
"no expression" );
1261 sal_uInt16 nCaseMap;
1266 aItemIds.nCaseMap ) );
1280 OSL_ENSURE( pExpr,
"no expression" );
1304 assert(pExpr &&
"no expression");
1308 double columnCount = pExpr->
GetNumber();
1309 if ( columnCount >= 2 )
1321 assert(pExpr &&
"no expression");
1332 static_cast < SvxFrameDirection >( nDir ),
1333 aItemIds.nDirection ) );
1344 "vertical position not at the top" );
1374 "horizontal position not on the left side" );
1406 OSL_ENSURE( pExpr,
"no expression" );
1411 bool bColor =
false, bTransparent =
false;
1414 bool bHori =
false, bVert =
false;
1416 while( pExpr && !pExpr->
GetOp() )
1425 bColor = pExpr->
GetColor( aColor );
1435 bool nonZero = std::trunc(pExpr->
GetNumber()) != 0.0;
1453 sal_uInt16 nPerc = o3tl::narrowing<sal_uInt16>(pExpr->
GetNumber());
1475 const OUString &rValue = pExpr->
GetString();
1476 if( rValue.equalsIgnoreAsciiCase(
"transparent" ) )
1478 bTransparent =
true;
1487 MergeHori( ePos, static_cast<SvxGraphicPosition>(nEnum) );
1492 MergeVert( ePos, static_cast<SvxGraphicPosition>(nEnum) );
1497 bColor = pExpr->
GetColor( aColor );
1521 if( !bTransparent && !bColor && aURL.isEmpty() )
1531 if( !aURL.isEmpty() )
1537 rItemSet.
Put( aBrushItem );
1545 OSL_ENSURE( pExpr,
"no expression" );
1549 bool bColor =
false, bTransparent =
false;
1554 bColor = pExpr->
GetColor( aColor );
1559 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"transparent" ) )
1561 bTransparent =
true;
1566 bColor = pExpr->
GetColor( aColor );
1573 if( bTransparent || bColor )
1582 rItemSet.
Put( aBrushItem );
1591 OSL_ENSURE( pExpr,
"no expression" );
1593 sal_uInt16 nHeight = 0;
1594 sal_uInt16 nPropHeight = 0;
1599 nHeight = o3tl::narrowing<sal_uInt16>(pExpr->
GetULength());
1604 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1609 nHeight = o3tl::narrowing<sal_uInt16>(nPHeight);
1615 nPropHeight = o3tl::narrowing<sal_uInt16>(pExpr->
GetNumber());
1620 nPropHeight = o3tl::narrowing<sal_uInt16>(pExpr->
GetNumber() * 100);
1636 rItemSet.
Put( aLSItem );
1638 else if( nPropHeight )
1642 if( 100 == nPropHeight )
1646 rItemSet.
Put( aLSItem );
1656 OSL_ENSURE( pExpr,
"no expression" );
1661 const OUString& rValue = pExpr->
GetString();
1682 OSL_ENSURE( pExpr,
"no expression" );
1689 while( pExpr && !pExpr->
GetOp() &&
1697 const OUString& rValue = pExpr->
GetString();
1723 if( !pExpr || pExpr->
GetOp() )
1729 rItemSet.
Put( aPosture );
1730 aPosture.SetWhich( aItemIds.nPostureCJK );
1731 rItemSet.
Put( aPosture );
1732 aPosture.SetWhich( aItemIds.nPostureCTL );
1733 rItemSet.
Put( aPosture );
1738 rItemSet.
Put( aWeight );
1739 aWeight.SetWhich( aItemIds.nWeightCJK );
1740 rItemSet.
Put( aWeight );
1741 aWeight.SetWhich( aItemIds.nWeightCTL );
1742 rItemSet.
Put( aWeight );
1754 if(
'/' == pExpr->
GetOp() )
1763 if( !pExpr || pExpr->
GetOp() )
1775 OSL_ENSURE( pExpr,
"no expression" );
1781 aItemIds.nKerning ) );
1787 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1792 rItemSet.
Put(
SvxKerningItem( static_cast<short>(nPWidth), aItemIds.nKerning ) );
1807 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"normal" ) )
1822 OSL_ENSURE( pExpr,
"no expression" );
1824 bool bUnderline =
false;
1825 bool bOverline =
false;
1826 bool bCrossedOut =
false;
1827 bool bBlink =
false;
1828 bool bBlinkOn =
false;
1837 OUString aValue = pExpr->
GetString().toAsciiLowerCase();
1838 bool bKnown =
false;
1843 if( aValue ==
"none" )
1862 if( aValue ==
"underline" )
1872 if( aValue ==
"overline" )
1882 if( aValue ==
"line-through" )
1892 if( aValue ==
"blink" )
1929 OSL_ENSURE( pExpr,
"no expression" );
1939 aItemIds.nAdjust ) );
1949 OSL_ENSURE( pExpr,
"no expression" );
1960 "sw.html",
"clamping length " << n <<
" to short range");
1961 nIndent =
static_cast<short>(
1964 double(std::numeric_limits<short>::max())));
1971 if (fWidth < SAL_MAX_INT32/2.0 && fWidth >
SAL_MIN_INT32/2.0)
1976 nIndent =
static_cast<short>(nPWidth);
1995 rItemSet.
Put( aLRItem );
2001 rItemSet.
Put( aLRItem );
2011 OSL_ENSURE( pExpr,
"no expression" );
2035 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fLeft);
2055 aLRItem.
SetTextLeft( o3tl::narrowing<sal_uInt16>(nLeft) );
2056 rItemSet.
Put( aLRItem );
2061 aLRItem.
SetTextLeft( o3tl::narrowing<sal_uInt16>(nLeft) );
2062 rItemSet.
Put( aLRItem );
2072 OSL_ENSURE( pExpr,
"no expression" );
2087 if (fRight < SAL_MAX_INT32/2.0 && fRight >
SAL_MIN_INT32/2.0)
2112 aLRItem.
SetRight( o3tl::narrowing<sal_uInt16>(nRight) );
2113 rItemSet.
Put( aLRItem );
2118 aLRItem.
SetRight( o3tl::narrowing<sal_uInt16>(nRight) );
2119 rItemSet.
Put( aLRItem );
2129 assert(pExpr &&
"no expression");
2131 sal_uInt16 nUpper = 0;
2140 nUpper = o3tl::narrowing<sal_uInt16>(nTmp);
2147 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2154 nUpper = o3tl::narrowing<sal_uInt16>(nPHeight);
2173 rItemSet.
Put( aULItem );
2179 rItemSet.
Put( aULItem );
2189 OSL_ENSURE( pExpr,
"no expression" );
2191 sal_uInt16 nLower = 0;
2200 nLower = o3tl::narrowing<sal_uInt16>(nTmp);
2207 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2214 nLower = o3tl::narrowing<sal_uInt16>(nPHeight);
2233 rItemSet.
Put( aULItem );
2239 rItemSet.
Put( aULItem );
2249 OSL_ENSURE( pExpr,
"no expression" );
2252 bool bSetMargins[4] = {
false,
false,
false,
false };
2254 for(
int i=0; pExpr &&
i<4 && !pExpr->
GetOp(); ++
i )
2256 bool bSetThis =
false;
2270 if (fMargin < SAL_MAX_INT32/2.0 && fMargin >
SAL_MIN_INT32/2.0)
2279 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fMargin);
2299 nMargins[0] = nMargins[1] =nMargins[2] = nMargins[3] = nMargin;
2300 bSetMargins[0] = bSetMargins[1] =
2301 bSetMargins[2] = bSetMargins[3] =
true;
2304 nMargins[1] = nMargins[3] = nMargin;
2305 bSetMargins[1] = bSetMargins[3] =
true;
2308 nMargins[2] = nMargin;
2309 bSetMargins[2] =
true;
2312 nMargins[3] = nMargin;
2313 bSetMargins[3] =
true;
2320 if( bSetMargins[3] || bSetMargins[1] )
2322 if( bSetMargins[3] )
2326 if( nMargins[3] < 0 )
2329 if( bSetMargins[1] )
2333 if( nMargins[1] < 0 )
2340 if( bSetMargins[3] )
2341 aLRItem.
SetLeft( o3tl::narrowing<sal_uInt16>(nMargins[3]) );
2342 if( bSetMargins[1] )
2343 aLRItem.
SetRight( o3tl::narrowing<sal_uInt16>(nMargins[1]) );
2344 rItemSet.
Put( aLRItem );
2349 if( bSetMargins[3] )
2350 aLRItem.
SetLeft( o3tl::narrowing<sal_uInt16>(nMargins[3]) );
2351 if( bSetMargins[1] )
2352 aLRItem.
SetRight( o3tl::narrowing<sal_uInt16>(nMargins[1]) );
2353 rItemSet.
Put( aLRItem );
2357 if( !(bSetMargins[0] || bSetMargins[2]) )
2360 if( nMargins[0] < 0 )
2362 if( nMargins[2] < 0 )
2368 if( bSetMargins[0] )
2369 aULItem.
SetUpper( o3tl::narrowing<sal_uInt16>(nMargins[0]) );
2370 if( bSetMargins[2] )
2371 aULItem.
SetLower( o3tl::narrowing<sal_uInt16>(nMargins[2]) );
2372 rItemSet.
Put( aULItem );
2377 if( bSetMargins[0] )
2378 aULItem.
SetUpper( o3tl::narrowing<sal_uInt16>(nMargins[0]) );
2379 if( bSetMargins[2] )
2380 aULItem.
SetLower( o3tl::narrowing<sal_uInt16>(nMargins[2]) );
2381 rItemSet.
Put( aULItem );
2392 OSL_ENSURE( pExpr,
"no expression" );
2395 sal_uInt16 nDist = 0;
2406 nDist = o3tl::narrowing<sal_uInt16>(nTmp);
2413 if (fWidth < SAL_MAX_INT32/2.0 && fWidth >
SAL_MIN_INT32/2.0)
2422 nDist = o3tl::narrowing<sal_uInt16>(nPWidth);
2436 switch( nWhichLine )
2486 while( n<4 && pExpr && !pExpr->GetOp() )
2488 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2511 OSL_ENSURE( pExpr,
"no expression" );
2513 sal_uInt16 nWidth = USHRT_MAX;
2514 sal_uInt16 nNWidth = 1;
2517 bool bColor =
false;
2519 while( pExpr && !pExpr->
GetOp() )
2531 const OUString& rValue = pExpr->
GetString();
2541 else if( pExpr->
GetColor( aColor ) )
2549 nWidth = o3tl::narrowing<sal_uInt16>(pExpr->
GetULength());
2558 bool bHori = nWhichLine == SvxBoxItemLine::TOP ||
2559 nWhichLine == SvxBoxItemLine::BOTTOM;
2564 nWidth = o3tl::narrowing<sal_uInt16>(bHori ? nPHeight : nPWidth);
2578 for(
int i=0;
i<4; ++
i )
2583 case 0: nLine = SvxBoxItemLine::TOP;
break;
2584 case 1: nLine = SvxBoxItemLine::BOTTOM;
break;
2585 case 2: nLine = SvxBoxItemLine::LEFT;
break;
2586 case 3: nLine = SvxBoxItemLine::RIGHT;
break;
2589 if( bAll || nLine == nWhichLine )
2607 OSL_ENSURE( pExpr,
"no expression" );
2609 sal_uInt16 nWidth = USHRT_MAX;
2610 sal_uInt16 nNWidth = 1;
2625 nWidth = o3tl::narrowing<sal_uInt16>(pExpr->
GetULength());
2631 if (fLength < SAL_MAX_INT32/2.0 && fLength >
SAL_MIN_INT32/2.0)
2635 bool bHori = nWhichLine == SvxBoxItemLine::TOP ||
2636 nWhichLine == SvxBoxItemLine::BOTTOM;
2641 nWidth = o3tl::narrowing<sal_uInt16>(bHori ? nPHeight : nPWidth);
2693 while( n<4 && pExpr && !pExpr->GetOp() )
2695 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2710 while( n<4 && pExpr && !pExpr->GetOp() )
2712 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2738 while( n<4 && pExpr && !pExpr->GetOp() )
2740 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2800 OSL_ENSURE( pExpr,
"no expression" );
2815 OSL_ENSURE( pExpr,
"no expression" );
2833 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"auto" ) )
2849 if (fLength < SAL_MAX_INT32/2.0 && fLength >
SAL_MIN_INT32/2.0)
2855 rLength = (bHori ? nPHeight : nPWidth);
2910 while( n<2 && pExpr && !pExpr->GetOp() )
2935 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2994 bool bSetSplit =
false, bSplit =
true;
3023 rItemSet.
Put( aWidowsItem );
3038 rItemSet.
Put( aOrphansItem );
3054 rItemSet.
Put( aLang );
3055 aLang.SetWhich( aItemIds.nLanguageCJK );
3056 rItemSet.
Put( aLang );
3057 aLang.SetWhich( aItemIds.nLanguageCTL );
3058 rItemSet.
Put( aLang );
3074 struct CSS1PropEntry
3082 #define CSS1_PROP_ENTRY(p) \
3083 { sCSS1_P_##p, ParseCSS1_##p }
3147 return strcmp(lhs.pName, rhs.pName) < 0;
3152 return s.compareToIgnoreAsciiCaseAscii(lhs.pName) > 0;
3156 std::unique_ptr<CSS1Expression> pExpr )
3158 OSL_ENSURE(
m_pItemSet,
"DeclarationParsed() without ItemSet" );
3160 static bool bSortedPropFns =
false;
3162 if( !bSortedPropFns )
3164 assert( std::is_sorted( std::begin(aCSS1PropFnTab), std::end(aCSS1PropFnTab),
3166 bSortedPropFns =
true;
3169 auto it = std::lower_bound( std::begin(aCSS1PropFnTab), std::end(aCSS1PropFnTab), rProperty,
static void ParseCSS1_margin_bottom(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static void MergeStyles(const SfxItemSet &rSrcSet, const SvxCSS1PropertyInfo &rSrcInfo, SfxItemSet &rTargetSet, SvxCSS1PropertyInfo &rTargetInfo, bool bSmart)
SwNodeOffset min(const SwNodeOffset &a, const SwNodeOffset &b)
static void ParseCSS1_width(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
virtual sal_uInt32 GetFontHeight(sal_uInt16 nSize) const
const OUString & GetBaseURL() const
#define SVX_CSS1_BORDERINFO_COLOR
void SetBorderLineStyle(SvxBorderLineStyle nNew)
SvxCSS1LengthType m_eLeftType
static const sal_Int16 VeryThin
void Merge(const SvxCSS1PropertyInfo &rProp)
SvxCSS1LengthType m_eTopType
void SetRight(const tools::Long nR, const sal_uInt16 nProp=100)
static void ParseCSS1_margin(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
void SetWidth(tools::Long nWidth)
std::map< OUString, std::unique_ptr< SvxCSS1MapEntry > > CSS1Map
static void ParseCSS1_visibility(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
const T * GetItemIfSet(TypedWhichId< T > nWhich, bool bSrchInParent=true) const
static void ParseCSS1_text_transform(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
virtual void SelectorParsed(std::unique_ptr< CSS1Selector > pSelector, bool bFirst) override
Will be called when a Selector is parsed.
static void ParseCSS1_border_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static void ParseCSS1_border_color(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
void ParseStyleOption(const OUString &rIn, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo)
static void ParseCSS1_font_variant(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
sal_uInt16 GetLower() const
virtual void SetDfltEncoding(rtl_TextEncoding eEnc)
#define SVX_CSS1_BORDERINFO_STYLE
static void ParseCSS1_border_right(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
CSS1PropertyEnum const aBGVertPosTable[]
#define CSS1_PROP_ENTRY(p)
WhichRangesContainer m_aWhichMap
virtual void StyleParsed(const CSS1Selector *pSelector, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo)
std::array< std::unique_ptr< SvxCSS1BorderInfo >, 4 > m_aBorderInfos
SvxCSS1BorderInfo * GetBorderInfo(SvxBoxItemLine nLine, bool bCreate=true)
static void ParseCSS1_top(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
const SvxCSS1PropertyInfo & GetPropertyInfo() const
tools::Long GetRight() const
constexpr::Color COL_TRANSPARENT(ColorTransparency, 0xFF, 0xFF, 0xFF, 0xFF)
static void ParseCSS1_padding_left(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static void ParseCSS1_direction(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
virtual const FontList * GetFontList() const
SVX_NUM_CHARS_UPPER_LETTER
CSS1PropertyEnum const aFontVariantTable[]
static void InsertMapEntry(const OUString &rKey, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp, CSS1Map &rMap)
static void ParseCSS1_length(const CSS1Expression *pExpr, tools::Long &rLength, SvxCSS1LengthType &rLengthType, bool bHori)
static void ParseCSS1_height(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
void Set(CSS1Token eTyp, const OUString &rVal, double nVal)
CSS1PropertyEnum const aBorderStyleTable[]
SvxCSS1Parser(SfxItemPool &rPool, const OUString &rBaseURL, sal_uInt16 const *pWhichIds, sal_uInt16 nWhichIds)
static void ParseCSS1_page_break_before(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
void CopyBorderInfo(SvxBoxItemLine nSrcLine, SvxBoxItemLine nDstLine, sal_uInt16 nWhat)
static void ParseCSS1_text_align(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
static void ParseCSS1_letter_spacing(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
rtl_TextEncoding GetDfltEncoding() const
#define SVX_CSS1_BORDERINFO_WIDTH
static void ParseCSS1_border_xxx(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &, SvxBoxItemLine nWhichLine, bool bAll)
void SetBoxItem(SfxItemSet &rItemSet, sal_uInt16 nMinBorderDist, const SvxBoxItem *pDflt=nullptr)
sal_Unicode GetOp() const
CSS1PropertyEnum const aPositionTable[]
CSS1PropertyEnum const aTextAlignTable[]
static void PixelToTwip(tools::Long &nWidth, tools::Long &nHeight)
sal_uInt16 m_nTopBorderDistance
CSS1PropertyEnum const aNumberStyleTable[]
SvxCSS1PageBreak m_ePageBreakBefore
void SetLineSpaceRule(SvxLineSpaceRule e)
css::chart::ChartAxisLabelPosition ePos
static void ParseCSS1_widows(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
std::unique_ptr< SfxItemSet > m_pSheetItemSet
sal_Unicode m_cBulletChar
static SvxCSS1ItemIds aItemIds
static void ParseCSS1_font_family(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &rParser)
static void ParseCSS1_line_height(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
CSS1PropertyEnum const aFontSizeTable[]
CSS1PropertyEnum const aBulletStyleTable[]
void(* FnParseCSS1Prop)(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
type of functions to parse CSS1 properties
static void ParseCSS1_font_weight(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
static void ParseCSS1_border_top(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
sal_uInt16 const aBorderWidths[]
sal_Handle GetFirstFontMetric(std::u16string_view rName) const
static OutputDevice * GetDefaultDevice()
a subexpression of a CSS1 declaration
constexpr tools::Long Width() const
CSS1PropertyEnum const aFontStyleTable[]
static void ParseCSS1_border_left(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
SvxCSS1LengthType m_eHeightType
SvxCSS1SizeType m_eSizeType
static void ParseCSS1_font_style(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
void SetTextLeft(const tools::Long nL, const sal_uInt16 nProp=100)
static LanguageType convertToLanguageTypeWithFallback(const OUString &rBcp47)
void SetPropLineSpace(const sal_uInt16 nProp)
static void ParseCSS1_padding_right(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
rtl_TextEncoding m_eDefaultEnc
static void ParseCSS1_so_language(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
bool IsIgnoreFontFamily() const
CSS1PropEntry const aCSS1PropFnTab[]
static void ParseCSS1_color(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
static void ParseCSS1_background_color(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
virtual void DeclarationParsed(const OUString &rProperty, std::unique_ptr< CSS1Expression > pExpr) override
Will be called for every parsed Property.
SvxCSS1PageBreak m_ePageBreakAfter
CSS1PropertyEnum const aBGHoriPosTable[]
SvxCSS1MapEntry * GetTag(const OUString &rTag)
CSS1PropertyEnum const aTextTransformTable[]
static void ParseCSS1_padding_top(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
#define HTML_BULLETCHAR_DISC
static void ParseCSS1_border_right_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
sal_uInt16 GetTrueWhich(sal_uInt16 nSlot, bool bDeep=true) const
static void ParseCSS1_font_size(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &rParser)
static void ParseCSS1_border_bottom_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static void MergeHori(SvxGraphicPosition &ePos, SvxGraphicPosition eHori)
static void ParseCSS1_border_bottom(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
void SetColor(const Color &rCol)
const CSS1Expression * GetNext() const
void SetLower(const sal_uInt16 nL, const sal_uInt16 nProp=100)
static void ParseCSS1_border_style(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
SvxNumType m_nNumberingType
CSS1PropertyEnum const aDirectionTable[]
void InsertPage(const OUString &rPage, bool bPseudo, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
virtual ~SvxCSS1Parser() override
sal_uInt16 m_nLeftBorderDistance
static void ParseCSS1_size(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
SvxCSS1PropertyInfo * m_pPropInfo
static void ParseCSS1_position(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static bool CSS1PropEntryFindCompare(CSS1PropEntry const &lhs, OUString const &s)
sal_uInt16 ClearItem(sal_uInt16 nWhich=0)
SVX_NUM_CHARS_LOWER_LETTER
void DestroyBorderInfos()
CSS1PropertyEnum const aBGRepeatTable[]
sal_uInt16 m_nRightBorderDistance
CSS1PropertyEnum const aBorderWidthTable[]
static void ParseCSS1_padding_bottom(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static constexpr sal_uInt16 UNSET_BORDER_DISTANCE
static void ParseCSS1_column_count(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static void ParseCSS1_margin_right(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
CSS1PropertyEnum const aFloatTable[]
static void ParseCSS1_page_break_inside(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
tools::Long GetLeft() const
static void ParseCSS1_background(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &rParser)
void SetTextFirstLineOffset(const short nF, const sal_uInt16 nProp=100)
tools::Long m_nRightMargin
void InsertClass(const OUString &rClass, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
#define LANGUAGE_DONTKNOW
static void ParseCSS1_left(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
SvxCSS1Position m_ePosition
short GetTextFirstLineOffset() const
SvxCSS1MapEntry(const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
virtual SvxBoxItem * Clone(SfxItemPool *pPool=nullptr) const override
#define HTML_BULLETCHAR_CIRCLE
static void MergeVert(SvxGraphicPosition &ePos, SvxGraphicPosition eVert)
sal_uInt32 GetULength() const
void ParseStyleOption(const OUString &rIn)
parse the content of a HTML style option
SAL_WARN_UNUSED_RESULT WhichRangesContainer MergeRange(sal_uInt16 nFrom, sal_uInt16 nTo) const
SAL_WARN_UNUSED_RESULT Point PixelToLogic(const Point &rDevicePt) const
void SetGraphicPos(SvxGraphicPosition eNew)
SvxCSS1MapEntry * GetPage(const OUString &rPage, bool bPseudo)
CSS1PropertyEnum const aPageBreakTable[]
static void ParseCSS1_border(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static bool ParseCSS1_padding_xxx(const CSS1Expression *pExpr, SvxCSS1PropertyInfo &rPropInfo, SvxBoxItemLine nWhichLine)
static bool CSS1PropEntryCompare(const CSS1PropEntry &lhs, const CSS1PropEntry &rhs)
const SfxPoolItem * Put(const SfxPoolItem &rItem, sal_uInt16 nWhich)
static void ParseCSS1_border_xxx_width(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &, SvxBoxItemLine nWhichLine)
void SetInterLineSpaceRule(SvxInterLineSpaceRule e)
tools::Long m_nLeftMargin
SvxCSS1LengthType m_eWidthType
static const sal_Int16 Hairline
static void ParseCSS1_margin_top(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
const OUString & GetString() const
sal_Int32 GetSLength() const
void SetLeft(const tools::Long nL, const sal_uInt16 nProp=100)
const SfxPoolItem & Get(sal_uInt16 nWhich, bool bSrchInParent=true) const
#define SAL_WARN_IF(condition, area, stream)
static void ParseCSS1_padding(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
constexpr tools::Long Height() const
static void ParseCSS1_border_top_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static sal_uInt16 GetMinFixLineSpace()
static const sal_Int16 Thin
void SetLineHeight(const sal_uInt16 nHeight)
bool GetColor(Color &rRGB) const
void SetWhich(sal_uInt16 nId)
const SvxCSS1MapEntry * GetId(const OUString &rId) const
void SetBorderLine(SvxBoxItemLine nLine, SvxBoxItem &rBoxItem) const
static void ParseCSS1_margin_left(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
const ::std::vector< Color > ImpSvNumberformatScan::StandardColor COL_BLACK
static void ParseCSS1_text_decoration(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
CSS1Token GetType() const
static void ParseCSS1_page_break_after(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
CSS1Selectors m_Selectors
static void ParseCSS1_border_left_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static void ParseCSS1_page_break_xxx(const CSS1Expression *pExpr, SvxCSS1PageBreak &rPBreak)
static void ParseCSS1_text_indent(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
CSS1PropertyEnum const aSizeTable[]
static void ParseCSS1_orphans(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
CSS1PropertyEnum const aFontWeightTable[]
#define SAL_WARN(area, stream)
void GetURL(OUString &rURL) const
void InsertTag(const OUString &rTag, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
void SetGraphicLink(const OUString &rNew)
const SfxItemSet & GetItemSet() const
static void ParseCSS1_font(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
void InsertId(const OUString &rId, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
static void ParseCSS1_float(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
void SetUpper(const sal_uInt16 nU, const sal_uInt16 nProp=100)
#define HTML_BULLETCHAR_SQUARE
const SvxCSS1MapEntry * GetClass(const OUString &rClass) const
static bool GetEnum(const CSS1PropertyEnum *pPropTable, const OUString &rValue, sal_uInt16 &rEnum)
std::unique_ptr< SvxCSS1PropertyInfo > m_pSheetPropInfo
sal_uInt16 m_nColumnCount
static void ParseCSS1_list_style_type(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static const FontMetric & GetFontMetric(sal_Handle hFontMetric)
rtl_TextEncoding GetCharSet() const
sal_uInt16 GetUpper() const
bool m_bDetectedRangeSegmentation false
void SetLine(const editeng::SvxBorderLine *pNew, SvxBoxItemLine nLine)
SVL_DLLPUBLIC OUString SmartRel2Abs(INetURLObject const &rTheBaseURIRef, OUString const &rTheRelURIRef, Link< OUString *, bool > const &rMaybeFileHdl=Link< OUString *, bool >(), bool bCheckFileExists=true, bool bIgnoreFragment=false, INetURLObject::EncodeMechanism eEncodeMechanism=INetURLObject::EncodeMechanism::WasEncoded, INetURLObject::DecodeMechanism eDecodeMechanism=INetURLObject::DecodeMechanism::ToIUri, rtl_TextEncoding eCharset=RTL_TEXTENCODING_UTF8, FSysStyle eStyle=FSysStyle::Detect)
sal_uInt16 m_nBottomBorderDistance