26 #include <svx/svxids.hrc>
56 #include <osl/diagnose.h>
109 {
"normal", sal_uInt16(SvxCaseMap::NotMapped) },
110 {
"small-caps", sal_uInt16(SvxCaseMap::SmallCaps) },
116 {
"uppercase", sal_uInt16(SvxCaseMap::Uppercase) },
117 {
"lowercase", sal_uInt16(SvxCaseMap::Lowercase) },
118 {
"capitalize", sal_uInt16(SvxCaseMap::Capitalize) },
124 {
"ltr", sal_uInt16(SvxFrameDirection::Horizontal_LR_TB) },
125 {
"rtl", sal_uInt16(SvxFrameDirection::Horizontal_RL_TB) },
126 {
"inherit", sal_uInt16(SvxFrameDirection::Environment) },
157 {
"left", sal_uInt16(SvxAdjust::Left) },
158 {
"center", sal_uInt16(SvxAdjust::Center) },
159 {
"right", sal_uInt16(SvxAdjust::Right) },
160 {
"justify", sal_uInt16(SvxAdjust::Block) },
174 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 };
180 {
"none", CSS1_BS_NONE },
181 {
"dotted", CSS1_BS_DOTTED },
182 {
"dashed", CSS1_BS_DASHED },
183 {
"solid", CSS1_BS_SINGLE },
184 {
"double", CSS1_BS_DOUBLE },
185 {
"groove", CSS1_BS_GROOVE },
186 {
"ridge", CSS1_BS_RIDGE },
187 {
"inset", CSS1_BS_INSET },
188 {
"outset", CSS1_BS_OUTSET },
194 {
"left", sal_uInt16(SvxAdjust::Left) },
195 {
"right", sal_uInt16(SvxAdjust::Right) },
196 {
"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;
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 aItemSet( rItemSet ),
681 OSL_ENSURE(
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 ) :
700 sBaseURL( rBaseURL ),
702 pPropInfo( nullptr ),
703 eDfltEnc( RTL_TEXTENCODING_DONTKNOW ),
704 bIgnoreFontFamily( false )
707 aItemIds.nFont = rPool.
GetTrueWhich( SID_ATTR_CHAR_FONT,
false );
708 aItemIds.nFontCJK = rPool.
GetTrueWhich( SID_ATTR_CHAR_CJK_FONT,
false );
709 aItemIds.nFontCTL = rPool.
GetTrueWhich( SID_ATTR_CHAR_CTL_FONT,
false );
710 aItemIds.nPosture = rPool.
GetTrueWhich( SID_ATTR_CHAR_POSTURE,
false );
711 aItemIds.nPostureCJK = rPool.
GetTrueWhich( SID_ATTR_CHAR_CJK_POSTURE,
false );
712 aItemIds.nPostureCTL = rPool.
GetTrueWhich( SID_ATTR_CHAR_CTL_POSTURE,
false );
713 aItemIds.nWeight = rPool.
GetTrueWhich( SID_ATTR_CHAR_WEIGHT,
false );
714 aItemIds.nWeightCJK = rPool.
GetTrueWhich( SID_ATTR_CHAR_CJK_WEIGHT,
false );
715 aItemIds.nWeightCTL = rPool.
GetTrueWhich( SID_ATTR_CHAR_CTL_WEIGHT,
false );
716 aItemIds.nFontHeight = rPool.
GetTrueWhich( SID_ATTR_CHAR_FONTHEIGHT,
false );
717 aItemIds.nFontHeightCJK = rPool.
GetTrueWhich( SID_ATTR_CHAR_CJK_FONTHEIGHT,
false );
718 aItemIds.nFontHeightCTL = rPool.
GetTrueWhich( SID_ATTR_CHAR_CTL_FONTHEIGHT,
false );
719 aItemIds.nUnderline = rPool.
GetTrueWhich( SID_ATTR_CHAR_UNDERLINE,
false );
720 aItemIds.nOverline = rPool.
GetTrueWhich( SID_ATTR_CHAR_OVERLINE,
false );
721 aItemIds.nCrossedOut = rPool.
GetTrueWhich( SID_ATTR_CHAR_STRIKEOUT,
false );
722 aItemIds.nColor = rPool.
GetTrueWhich( SID_ATTR_CHAR_COLOR,
false );
723 aItemIds.nKerning = rPool.
GetTrueWhich( SID_ATTR_CHAR_KERNING,
false );
724 aItemIds.nCaseMap = rPool.
GetTrueWhich( SID_ATTR_CHAR_CASEMAP,
false );
725 aItemIds.nBlink = rPool.
GetTrueWhich( SID_ATTR_FLASH,
false );
727 aItemIds.nLineSpacing = rPool.
GetTrueWhich( SID_ATTR_PARA_LINESPACE,
false );
728 aItemIds.nAdjust = rPool.
GetTrueWhich( SID_ATTR_PARA_ADJUST,
false );
729 aItemIds.nWidows = rPool.
GetTrueWhich( SID_ATTR_PARA_WIDOWS,
false );
730 aItemIds.nOrphans = rPool.
GetTrueWhich( SID_ATTR_PARA_ORPHANS,
false );
731 aItemIds.nFormatSplit = rPool.
GetTrueWhich( SID_ATTR_PARA_SPLIT,
false );
733 aItemIds.nLRSpace = rPool.
GetTrueWhich( SID_ATTR_LRSPACE,
false );
734 aItemIds.nULSpace = rPool.
GetTrueWhich( SID_ATTR_ULSPACE,
false );
735 aItemIds.nBox = rPool.
GetTrueWhich( SID_ATTR_BORDER_OUTER,
false );
736 aItemIds.nBrush = rPool.
GetTrueWhich( SID_ATTR_BRUSH,
false );
738 aItemIds.nLanguage = rPool.
GetTrueWhich( SID_ATTR_CHAR_LANGUAGE,
false );
739 aItemIds.nLanguageCJK = rPool.
GetTrueWhich( SID_ATTR_CHAR_CJK_LANGUAGE,
false );
740 aItemIds.nLanguageCTL = rPool.
GetTrueWhich( SID_ATTR_CHAR_CTL_LANGUAGE,
false );
741 aItemIds.nDirection = rPool.
GetTrueWhich( SID_ATTR_FRAMEDIRECTION,
false );
745 sizeof(aItemIds) /
sizeof(sal_uInt16) );
746 if( pWhichIds && nWhichIds )
768 CSS1Map::const_iterator itr =
m_Ids.find(rId);
769 return itr ==
m_Ids.end() ?
nullptr : itr->second.get();
781 CSS1Map::const_iterator itr =
m_Classes.find(rClass);
782 return itr ==
m_Classes.end() ?
nullptr : itr->second.get();
790 OUString aKey( rPage );
798 OUString aKey( rPage );
802 CSS1Map::iterator itr =
m_Pages.find(aKey);
803 return itr ==
m_Pages.end() ?
nullptr : itr->second.get();
815 CSS1Map::iterator itr =
m_Tags.find(rTag);
816 return itr ==
m_Tags.end() ?
nullptr : itr->second.get();
826 for (
const std::unique_ptr<CSS1Selector> & rpSelector :
m_Selectors)
850 rItemSet.
ClearItem( aItemIds.nDirection );
857 const OUString &rValue, sal_uInt16& rEnum )
859 while( pPropTable->
pName )
861 if( !rValue.equalsIgnoreAsciiCaseAscii( pPropTable->
pName ) )
867 if( pPropTable->
pName )
868 rEnum = pPropTable->
nEnum;
870 return (pPropTable->
pName !=
nullptr);
877 Size aTwipSz( rWidth, rHeight );
881 rWidth = aTwipSz.
Width();
882 rHeight = aTwipSz.
Height();
892 case 0: nHeight = 8*20;
break;
893 case 1: nHeight = 10*20;
break;
894 case 2: nHeight = 11*20;
break;
895 case 3: nHeight = 12*20;
break;
896 case 4: nHeight = 17*20;
break;
897 case 5: nHeight = 20*20;
break;
899 default: nHeight = 32*20;
break;
915 CSS1Map::iterator itr = rMap.find(rKey);
916 if (itr == rMap.end())
918 rMap.insert(std::make_pair(rKey, std::make_unique<SvxCSS1MapEntry>(rItemSet, rProp)));
936 rTargetSet.
Put( rSrcSet );
940 SvxLRSpaceItem aLRSpace( static_cast<const SvxLRSpaceItem&>(rTargetSet.
Get(aItemIds.nLRSpace)) );
941 SvxULSpaceItem aULSpace( static_cast<const SvxULSpaceItem&>(rTargetSet.
Get(aItemIds.nULSpace)) );
943 rTargetSet.
Put( rSrcSet );
958 rTargetSet.
Put( aLRSpace );
971 rTargetSet.
Put( aULSpace );
975 rTargetInfo.
Merge( rSrcInfo );
988 OSL_ENSURE( pExpr,
"no expression" );
991 sal_uInt16 nPropHeight = 100;
1001 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1006 nHeight =
static_cast<sal_uLong>(nPHeight);
1010 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fHeight);
1016 nPropHeight =
static_cast<sal_uInt16
>(pExpr->
GetNumber());
1034 if( nHeight || nPropHeight!=100 )
1037 aItemIds.nFontHeight );
1038 rItemSet.
Put( aFontHeight );
1039 aFontHeight.SetWhich( aItemIds.nFontHeightCJK );
1040 rItemSet.
Put( aFontHeight );
1041 aFontHeight.SetWhich( aItemIds.nFontHeightCTL );
1042 rItemSet.
Put( aFontHeight );
1051 OSL_ENSURE( pExpr,
"no expression" );
1053 OUStringBuffer
aName;
1057 bool bFound =
false;
1058 while( pExpr && (bFirst ||
','==pExpr->
GetOp() || !pExpr->
GetOp()) )
1069 while( pNext && !pNext->
GetOp() &&
1077 if( !aIdent.isEmpty() )
1079 if( !bFound && pFList )
1082 if(
nullptr != hFont )
1085 if( RTL_TEXTENCODING_DONTKNOW != rFMetric.
GetCharSet() )
1088 if( RTL_TEXTENCODING_SYMBOL == rFMetric.
GetCharSet() )
1089 eEnc = RTL_TEXTENCODING_SYMBOL;
1095 aName.append(aIdent);
1106 eEnc, aItemIds.nFont );
1107 rItemSet.
Put( aFont );
1108 aFont.
SetWhich( aItemIds.nFontCJK );
1109 rItemSet.
Put( aFont );
1110 aFont.
SetWhich( aItemIds.nFontCTL );
1111 rItemSet.
Put( aFont );
1120 OSL_ENSURE( pExpr,
"no expression" );
1131 SvxWeightItem aWeight( static_cast<FontWeight>(nWeight), aItemIds.nWeight );
1132 rItemSet.
Put( aWeight );
1133 aWeight.SetWhich( aItemIds.nWeightCJK );
1134 rItemSet.
Put( aWeight );
1135 aWeight.SetWhich( aItemIds.nWeightCTL );
1136 rItemSet.
Put( aWeight );
1142 sal_uInt16 nWeight =
static_cast<sal_uInt16
>(pExpr->
GetNumber());
1145 rItemSet.
Put( aWeight );
1146 aWeight.SetWhich( aItemIds.nWeightCJK );
1147 rItemSet.
Put( aWeight );
1148 aWeight.SetWhich( aItemIds.nWeightCTL );
1149 rItemSet.
Put( aWeight );
1163 OSL_ENSURE( pExpr,
"no expression" );
1165 bool bPosture =
false;
1166 bool bCaseMap =
false;
1174 for(
int i=0; pExpr &&
i<2; ++i )
1189 eCaseMap = SvxCaseMap::NotMapped;
1194 else if( !bCaseMap &&
1195 rValue.equalsIgnoreAsciiCase(
"small-caps" ) )
1197 eCaseMap = SvxCaseMap::SmallCaps;
1209 rItemSet.
Put( aPosture );
1210 aPosture.SetWhich( aItemIds.nPostureCJK );
1211 rItemSet.
Put( aPosture );
1212 aPosture.SetWhich( aItemIds.nPostureCTL );
1213 rItemSet.
Put( aPosture );
1225 assert(pExpr &&
"no expression");
1232 sal_uInt16 nCaseMap;
1237 aItemIds.nCaseMap ) );
1251 OSL_ENSURE( pExpr,
"no expression" );
1259 sal_uInt16 nCaseMap;
1264 aItemIds.nCaseMap ) );
1278 OSL_ENSURE( pExpr,
"no expression" );
1302 assert(pExpr &&
"no expression");
1306 double columnCount = pExpr->
GetNumber();
1307 if ( columnCount >= 2 )
1319 assert(pExpr &&
"no expression");
1330 static_cast < SvxFrameDirection >( nDir ),
1331 aItemIds.nDirection ) );
1342 "vertical position not at the top" );
1372 "horizontal position not on the left side" );
1404 OSL_ENSURE( pExpr,
"no expression" );
1409 bool bColor =
false, bTransparent =
false;
1412 bool bHori =
false, bVert =
false;
1414 while( pExpr && !pExpr->
GetOp() )
1423 bColor = pExpr->
GetColor( aColor );
1433 bool nonZero = std::trunc(pExpr->
GetNumber()) != 0.0;
1451 sal_uInt16 nPerc =
static_cast<sal_uInt16
>(pExpr->
GetNumber());
1474 if( rValue.equalsIgnoreAsciiCase(
"transparent" ) )
1476 bTransparent =
true;
1485 MergeHori( ePos, static_cast<SvxGraphicPosition>(nEnum) );
1490 MergeVert( ePos, static_cast<SvxGraphicPosition>(nEnum) );
1495 bColor = pExpr->
GetColor( aColor );
1519 if( !bTransparent && !bColor && aURL.isEmpty() )
1529 if( !aURL.isEmpty() )
1535 rItemSet.
Put( aBrushItem );
1543 OSL_ENSURE( pExpr,
"no expression" );
1547 bool bColor =
false, bTransparent =
false;
1552 bColor = pExpr->
GetColor( aColor );
1557 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"transparent" ) )
1559 bTransparent =
true;
1564 bColor = pExpr->
GetColor( aColor );
1571 if( bTransparent || bColor )
1580 rItemSet.
Put( aBrushItem );
1589 OSL_ENSURE( pExpr,
"no expression" );
1591 sal_uInt16 nHeight = 0;
1592 sal_uInt16 nPropHeight = 0;
1597 nHeight =
static_cast<sal_uInt16
>(pExpr->
GetULength());
1602 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1607 nHeight =
static_cast<sal_uInt16
>(nPHeight);
1613 nPropHeight =
static_cast<sal_uInt16
>(pExpr->
GetNumber());
1618 nPropHeight =
static_cast<sal_uInt16
>(pExpr->
GetNumber() * 100);
1634 rItemSet.
Put( aLSItem );
1636 else if( nPropHeight )
1640 if( 100 == nPropHeight )
1644 rItemSet.
Put( aLSItem );
1654 OSL_ENSURE( pExpr,
"no expression" );
1680 OSL_ENSURE( pExpr,
"no expression" );
1687 while( pExpr && !pExpr->
GetOp() &&
1721 if( !pExpr || pExpr->
GetOp() )
1727 rItemSet.
Put( aPosture );
1728 aPosture.SetWhich( aItemIds.nPostureCJK );
1729 rItemSet.
Put( aPosture );
1730 aPosture.SetWhich( aItemIds.nPostureCTL );
1731 rItemSet.
Put( aPosture );
1736 rItemSet.
Put( aWeight );
1737 aWeight.SetWhich( aItemIds.nWeightCJK );
1738 rItemSet.
Put( aWeight );
1739 aWeight.SetWhich( aItemIds.nWeightCTL );
1740 rItemSet.
Put( aWeight );
1752 if(
'/' == pExpr->
GetOp() )
1761 if( !pExpr || pExpr->
GetOp() )
1773 OSL_ENSURE( pExpr,
"no expression" );
1779 aItemIds.nKerning ) );
1785 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
1790 rItemSet.
Put(
SvxKerningItem( static_cast<short>(nPWidth), aItemIds.nKerning ) );
1805 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"normal" ) )
1820 OSL_ENSURE( pExpr,
"no expression" );
1822 bool bUnderline =
false;
1823 bool bOverline =
false;
1824 bool bCrossedOut =
false;
1825 bool bBlink =
false;
1826 bool bBlinkOn =
false;
1835 OUString aValue = pExpr->
GetString().toAsciiLowerCase();
1836 bool bKnown =
false;
1841 if( aValue ==
"none" )
1860 if( aValue ==
"underline" )
1870 if( aValue ==
"overline" )
1880 if( aValue ==
"line-through" )
1890 if( aValue ==
"blink" )
1927 OSL_ENSURE( pExpr,
"no expression" );
1937 aItemIds.nAdjust ) );
1947 OSL_ENSURE( pExpr,
"no expression" );
1954 nIndent =
static_cast<short>(pExpr->
GetSLength());
1960 if (fWidth < SAL_MAX_INT32/2.0 && fWidth >
SAL_MIN_INT32/2.0)
1965 nIndent =
static_cast<short>(nPWidth);
1981 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nLRSpace,
false,
1984 SvxLRSpaceItem aLRItem( *static_cast<const SvxLRSpaceItem*>(pItem) );
1986 rItemSet.
Put( aLRItem );
1992 rItemSet.
Put( aLRItem );
2002 OSL_ENSURE( pExpr,
"no expression" );
2026 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fLeft);
2044 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nLRSpace,
false,
2047 SvxLRSpaceItem aLRItem( *static_cast<const SvxLRSpaceItem*>(pItem) );
2048 aLRItem.
SetTextLeft( static_cast<sal_uInt16>(nLeft) );
2049 rItemSet.
Put( aLRItem );
2054 aLRItem.
SetTextLeft( static_cast<sal_uInt16>(nLeft) );
2055 rItemSet.
Put( aLRItem );
2065 OSL_ENSURE( pExpr,
"no expression" );
2080 if (fRight < SAL_MAX_INT32/2.0 && fRight >
SAL_MIN_INT32/2.0)
2103 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nLRSpace,
false,
2106 SvxLRSpaceItem aLRItem( *static_cast<const SvxLRSpaceItem*>(pItem) );
2107 aLRItem.
SetRight( static_cast<sal_uInt16>(nRight) );
2108 rItemSet.
Put( aLRItem );
2113 aLRItem.
SetRight( static_cast<sal_uInt16>(nRight) );
2114 rItemSet.
Put( aLRItem );
2124 assert(pExpr &&
"no expression");
2126 sal_uInt16 nUpper = 0;
2135 nUpper =
static_cast<sal_uInt16
>(nTmp);
2142 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2149 nUpper =
static_cast<sal_uInt16
>(nPHeight);
2165 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nULSpace,
false,
2168 SvxULSpaceItem aULItem( *static_cast<const SvxULSpaceItem*>(pItem) );
2170 rItemSet.
Put( aULItem );
2176 rItemSet.
Put( aULItem );
2186 OSL_ENSURE( pExpr,
"no expression" );
2188 sal_uInt16 nLower = 0;
2197 nLower =
static_cast<sal_uInt16
>(nTmp);
2204 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2211 nLower =
static_cast<sal_uInt16
>(nPHeight);
2227 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nULSpace,
false,
2230 SvxULSpaceItem aULItem( *static_cast<const SvxULSpaceItem*>(pItem) );
2232 rItemSet.
Put( aULItem );
2238 rItemSet.
Put( aULItem );
2248 OSL_ENSURE( pExpr,
"no expression" );
2251 bool bSetMargins[4] = {
false,
false,
false,
false };
2253 for(
int i=0; pExpr &&
i<4 && !pExpr->
GetOp(); ++
i )
2255 bool bSetThis =
false;
2269 if (fMargin < SAL_MAX_INT32/2.0 && fMargin >
SAL_MIN_INT32/2.0)
2278 SAL_WARN(
"sw.html",
"out-of-size pxlength: " << fMargin);
2298 nMargins[0] = nMargins[1] =nMargins[2] = nMargins[3] = nMargin;
2299 bSetMargins[0] = bSetMargins[1] =
2300 bSetMargins[2] = bSetMargins[3] =
true;
2303 nMargins[1] = nMargins[3] = nMargin;
2304 bSetMargins[1] = bSetMargins[3] =
true;
2307 nMargins[2] = nMargin;
2308 bSetMargins[2] =
true;
2311 nMargins[3] = nMargin;
2312 bSetMargins[3] =
true;
2319 if( bSetMargins[3] || bSetMargins[1] )
2321 if( bSetMargins[3] )
2325 if( nMargins[3] < 0 )
2328 if( bSetMargins[1] )
2332 if( nMargins[1] < 0 )
2337 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nLRSpace,
false,
2340 SvxLRSpaceItem aLRItem( *static_cast<const SvxLRSpaceItem*>(pItem) );
2341 if( bSetMargins[3] )
2342 aLRItem.
SetLeft( static_cast<sal_uInt16>(nMargins[3]) );
2343 if( bSetMargins[1] )
2344 aLRItem.
SetRight( static_cast<sal_uInt16>(nMargins[1]) );
2345 rItemSet.
Put( aLRItem );
2350 if( bSetMargins[3] )
2351 aLRItem.
SetLeft( static_cast<sal_uInt16>(nMargins[3]) );
2352 if( bSetMargins[1] )
2353 aLRItem.
SetRight( static_cast<sal_uInt16>(nMargins[1]) );
2354 rItemSet.
Put( aLRItem );
2358 if( !(bSetMargins[0] || bSetMargins[2]) )
2361 if( nMargins[0] < 0 )
2363 if( nMargins[2] < 0 )
2367 if( SfxItemState::SET == rItemSet.
GetItemState( aItemIds.nULSpace,
false,
2370 SvxULSpaceItem aULItem( *static_cast<const SvxULSpaceItem*>(pItem) );
2371 if( bSetMargins[0] )
2372 aULItem.
SetUpper( static_cast<sal_uInt16>(nMargins[0]) );
2373 if( bSetMargins[2] )
2374 aULItem.
SetLower( static_cast<sal_uInt16>(nMargins[2]) );
2375 rItemSet.
Put( aULItem );
2380 if( bSetMargins[0] )
2381 aULItem.
SetUpper( static_cast<sal_uInt16>(nMargins[0]) );
2382 if( bSetMargins[2] )
2383 aULItem.
SetLower( static_cast<sal_uInt16>(nMargins[2]) );
2384 rItemSet.
Put( aULItem );
2395 OSL_ENSURE( pExpr,
"no expression" );
2398 sal_uInt16 nDist = 0;
2409 nDist =
static_cast<sal_uInt16
>(nTmp);
2416 if (fWidth < SAL_MAX_INT32/2.0 && fWidth >
SAL_MIN_INT32/2.0)
2425 nDist =
static_cast<sal_uInt16
>(nPWidth);
2439 switch( nWhichLine )
2489 while( n<4 && pExpr && !pExpr->GetOp() )
2491 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2514 OSL_ENSURE( pExpr,
"no expression" );
2517 sal_uInt16 nNWidth = 1;
2520 bool bColor =
false;
2522 while( pExpr && !pExpr->
GetOp() )
2544 else if( pExpr->
GetColor( aColor ) )
2552 nWidth =
static_cast<sal_uInt16
>(pExpr->
GetULength());
2561 bool bHori = nWhichLine == SvxBoxItemLine::TOP ||
2562 nWhichLine == SvxBoxItemLine::BOTTOM;
2567 nWidth =
static_cast<sal_uInt16
>(bHori ? nPHeight : nPWidth);
2581 for(
int i=0;
i<4; ++
i )
2586 case 0: nLine = SvxBoxItemLine::TOP;
break;
2587 case 1: nLine = SvxBoxItemLine::BOTTOM;
break;
2588 case 2: nLine = SvxBoxItemLine::LEFT;
break;
2589 case 3: nLine = SvxBoxItemLine::RIGHT;
break;
2592 if( bAll || nLine == nWhichLine )
2610 OSL_ENSURE( pExpr,
"no expression" );
2613 sal_uInt16 nNWidth = 1;
2628 nWidth =
static_cast<sal_uInt16
>(pExpr->
GetULength());
2634 if (fLength < SAL_MAX_INT32/2.0 && fLength >
SAL_MIN_INT32/2.0)
2638 bool bHori = nWhichLine == SvxBoxItemLine::TOP ||
2639 nWhichLine == SvxBoxItemLine::BOTTOM;
2644 nWidth =
static_cast<sal_uInt16
>(bHori ? nPHeight : nPWidth);
2696 while( n<4 && pExpr && !pExpr->GetOp() )
2698 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2713 while( n<4 && pExpr && !pExpr->GetOp() )
2715 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2741 while( n<4 && pExpr && !pExpr->GetOp() )
2743 SvxBoxItemLine nLine = n==0 || n==2 ? SvxBoxItemLine::BOTTOM : SvxBoxItemLine::LEFT;
2803 OSL_ENSURE( pExpr,
"no expression" );
2818 OSL_ENSURE( pExpr,
"no expression" );
2836 if( pExpr->
GetString().equalsIgnoreAsciiCase(
"auto" ) )
2852 if (fLength < SAL_MAX_INT32/2.0 && fLength >
SAL_MIN_INT32/2.0)
2858 rLength = (bHori ? nPHeight : nPWidth);
2915 while( n<2 && pExpr && !pExpr->GetOp() )
2940 if (fHeight < SAL_MAX_INT32/2.0 && fHeight >
SAL_MIN_INT32/2.0)
2999 bool bSetSplit =
false, bSplit =
true;
3028 rItemSet.
Put( aWidowsItem );
3043 rItemSet.
Put( aOrphansItem );
3059 rItemSet.
Put( aLang );
3060 aLang.SetWhich( aItemIds.nLanguageCJK );
3061 rItemSet.
Put( aLang );
3062 aLang.SetWhich( aItemIds.nLanguageCTL );
3063 rItemSet.
Put( aLang );
3079 struct CSS1PropEntry
3087 #define CSS1_PROP_ENTRY(p) \
3088 { sCSS1_P_##p, ParseCSS1_##p }
3152 return strcmp(lhs.pName, rhs.pName) < 0;
3157 return s.compareToIgnoreAsciiCaseAscii(lhs.pName) > 0;
3161 std::unique_ptr<CSS1Expression> pExpr )
3163 OSL_ENSURE(
pItemSet,
"DeclarationParsed() without ItemSet" );
3165 static bool bSortedPropFns =
false;
3167 if( !bSortedPropFns )
3169 assert( std::is_sorted( std::begin(aCSS1PropFnTab), std::end(aCSS1PropFnTab),
3171 bSortedPropFns =
true;
3174 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)
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
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 &)
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)
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)
std::unique_ptr< SfxItemSet > pSheetItemSet
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)
SvxCSS1PropertyInfo * pPropInfo
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 &)
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[]
static OutputDevice * GetDefaultDevice()
a subexpression of a CSS1 declaration
CSS1PropertyEnum const aFontStyleTable[]
css::uno::Any const & rValue
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 &)
static void ParseCSS1_so_language(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &, const SvxCSS1Parser &)
const BorderLinePrimitive2D *pCandidateB assert(pCandidateA)
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 &)
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
std::unique_ptr< SvxCSS1PropertyInfo > pSheetPropInfo
void DestroyBorderInfos()
CSS1PropertyEnum const aBGRepeatTable[]
SfxItemState GetItemState(sal_uInt16 nWhich, bool bSrchInParent=true, const SfxPoolItem **ppItem=nullptr) const
sal_uInt16 m_nRightBorderDistance
CSS1PropertyEnum const aBorderWidthTable[]
rtl_TextEncoding eDfltEnc
std::vector< sal_uInt16 > aWhichMap
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)
Parser of a style element/option.
void SetTextFirstLineOffset(const short nF, const sal_uInt16 nProp=100)
tools::Long Width() const
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
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 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
static void ParseCSS1_padding(const CSS1Expression *pExpr, SfxItemSet &, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &)
static void ParseCSS1_border_top_width(const CSS1Expression *pExpr, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo, const SvxCSS1Parser &rParser)
static sal_uInt16 GetMinFixLineSpace()
void SetLineHeight(const sal_uInt16 nHeight)
bool GetColor(Color &rRGB) const
const o3tl::enumarray< SvxAdjust, unsigned short > aSvxToUnoAdjust USHRT_MAX
void SetWhich(sal_uInt16 nId)
const SvxCSS1MapEntry * GetId(const OUString &rId) const
void BuildWhichTable(std::vector< sal_uInt16 > &rWhichMap, sal_uInt16 const *pWhichIds, sal_uInt16 nWhichIds)
void SetBorderLine(SvxBoxItemLine nLine, SvxBoxItem &rBoxItem) const
tools::Long Height() 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 &)
sal_Handle GetFirstFontMetric(const OUString &rName) const
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)
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
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