19 #ifndef INCLUDED_SW_SOURCE_FILTER_HTML_SVXCSS1_HXX
20 #define INCLUDED_SW_SOURCE_FILTER_HTML_SVXCSS1_HXX
24 #include <rtl/textenc.h>
92 namespace editeng {
class SvxBorderLine; }
94 #define SVX_CSS1_BORDERINFO_WIDTH 1
95 #define SVX_CSS1_BORDERINFO_COLOR 2
96 #define SVX_CSS1_BORDERINFO_STYLE 4
189 typedef std::map<OUString, std::unique_ptr<SvxCSS1MapEntry>>
CSS1Map;
231 virtual void SelectorParsed( std::unique_ptr<CSS1Selector> pSelector,
bool bFirst )
override;
237 std::unique_ptr<CSS1Expression> pExpr )
override;
242 const OUString& rBaseURL,
243 sal_uInt16
const *pWhichIds, sal_uInt16 nWhichIds );
259 const OUString& rValue, sal_uInt16 &rEnum );
283 void InsertPage(
const OUString& rPage,
bool bPseudo,
static void MergeStyles(const SfxItemSet &rSrcSet, const SvxCSS1PropertyInfo &rSrcInfo, SfxItemSet &rTargetSet, SvxCSS1PropertyInfo &rTargetInfo, bool bSmart)
virtual sal_uInt32 GetFontHeight(sal_uInt16 nSize) const
const OUString & GetBaseURL() const
SvxCSS1LengthType m_eLeftType
void Merge(const SvxCSS1PropertyInfo &rProp)
SvxCSS1LengthType m_eTopType
std::map< OUString, std::unique_ptr< SvxCSS1MapEntry > > CSS1Map
virtual void SelectorParsed(std::unique_ptr< CSS1Selector > pSelector, bool bFirst) override
Will be called when a Selector is parsed.
void ParseStyleOption(const OUString &rIn, SfxItemSet &rItemSet, SvxCSS1PropertyInfo &rPropInfo)
constexpr auto toTwips(N number, Length from)
virtual void SetDfltEncoding(rtl_TextEncoding eEnc)
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)
const SvxCSS1PropertyInfo & GetPropertyInfo() const
virtual const FontList * GetFontList() const
static void InsertMapEntry(const OUString &rKey, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp, CSS1Map &rMap)
SvxCSS1Parser(SfxItemPool &rPool, const OUString &rBaseURL, sal_uInt16 const *pWhichIds, sal_uInt16 nWhichIds)
void CopyBorderInfo(SvxBoxItemLine nSrcLine, SvxBoxItemLine nDstLine, sal_uInt16 nWhat)
rtl_TextEncoding GetDfltEncoding() const
void SetBoxItem(SfxItemSet &rItemSet, sal_uInt16 nMinBorderDist, const SvxBoxItem *pDflt=nullptr)
static void PixelToTwip(tools::Long &nWidth, tools::Long &nHeight)
sal_uInt16 m_nTopBorderDistance
SvxCSS1PageBreak m_ePageBreakBefore
std::unique_ptr< SfxItemSet > m_pSheetItemSet
sal_Unicode m_cBulletChar
SvxCSS1PropertyInfo m_aPropInfo
void SetIgnoreFontFamily(bool bSet)
SvxCSS1LengthType m_eHeightType
SvxCSS1SizeType m_eSizeType
rtl_TextEncoding m_eDefaultEnc
bool IsIgnoreFontFamily() const
virtual void DeclarationParsed(const OUString &rProperty, std::unique_ptr< CSS1Expression > pExpr) override
Will be called for every parsed Property.
SvxCSS1PageBreak m_ePageBreakAfter
SvxCSS1MapEntry * GetTag(const OUString &rTag)
SvxNumType m_nNumberingType
void InsertPage(const OUString &rPage, bool bPseudo, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
virtual ~SvxCSS1Parser() override
sal_uInt16 m_nLeftBorderDistance
SvxCSS1PropertyInfo * m_pPropInfo
void DestroyBorderInfos()
sal_uInt16 m_nRightBorderDistance
static constexpr sal_uInt16 gnMinFixLineSpace
static constexpr sal_uInt16 UNSET_BORDER_DISTANCE
const WhichRangesContainer & GetWhichMap() const
Parser of a style element/option.
tools::Long m_nRightMargin
void InsertClass(const OUString &rClass, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
SvxCSS1Position m_ePosition
SvxCSS1MapEntry(const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
void ParseStyleOption(const OUString &rIn)
parse the content of a HTML style option
SvxCSS1MapEntry * GetPage(const OUString &rPage, bool bPseudo)
tools::Long m_nLeftMargin
SvxCSS1LengthType m_eWidthType
static sal_uInt16 GetMinFixLineSpace()
const SvxCSS1MapEntry * GetId(const OUString &rId) const
CSS1Selectors m_Selectors
void InsertTag(const OUString &rTag, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
const SfxItemSet & GetItemSet() const
SfxItemSet & GetItemSet()
void InsertId(const OUString &rId, const SfxItemSet &rItemSet, const SvxCSS1PropertyInfo &rProp)
std::vector< std::unique_ptr< CSS1Selector > > CSS1Selectors
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
sal_uInt16 m_nBottomBorderDistance
SvxCSS1PropertyInfo & GetPropertyInfo()