LibreOffice Module lotuswordpro (master) 1
|
Style for all drawing object, which can includes line style, area style, wrap style. More...
#include <xfdrawstyle.hxx>
Public Member Functions | |
XFDrawStyle () | |
virtual | ~XFDrawStyle () override |
void | SetLineStyle (double width, XFColor color) |
@descr Set drawing object border line. More... | |
void | SetLineDashStyle (enumXFLineStyle style, double len1, double len2, double space) |
@descr Set drawing object dash border style. More... | |
void | SetAreaColor (XFColor const &color) |
@descr Set drawing object area fill color. More... | |
void | SetAreaLineStyle (enumXFAreaLineStyle style, sal_Int32 angle, double space, XFColor lineColor) |
@descr Set drawing object area grid style. More... | |
void | SetArrowStart (const OUString &start, double size) |
@descr Set drawing object arrow start style,only lines can have arrows. More... | |
void | SetArrowEnd (const OUString &end, double size) |
@descr Set drawing object arrow end style,only lines can have arrows. More... | |
void | SetFontWorkStyle (enumXFFWStyle eStyle, enumXFFWAdjust eAdjust) |
virtual enumXFStyle | GetStyleFamily () override |
@descr get style family. More... | |
virtual void | ToXml (IXFStream *pStrm) override |
Public Member Functions inherited from XFStyle | |
XFStyle () | |
virtual | ~XFStyle () override |
XFStyle (XFStyle const &)=default | |
XFStyle (XFStyle &&)=default | |
XFStyle & | operator= (XFStyle const &)=default |
XFStyle & | operator= (XFStyle &&)=default |
virtual OUString | GetStyleName () override |
@descr get style name. More... | |
virtual void | SetStyleName (const OUString &styleName) override |
@descr set style name. More... | |
virtual OUString | GetParentStyleName () override |
@descr set parent style name. More... | |
virtual void | SetParentStyleName (const OUString &styleName) override |
@descr return parent style name. More... | |
virtual enumXFStyle | GetStyleFamily () override |
@descr get style family. More... | |
virtual bool | Equal (IXFStyle *pStyle) override |
@descr decide whether two style are equal. More... | |
Public Member Functions inherited from IXFStyle | |
IXFStyle ()=default | |
IXFStyle (IXFStyle const &)=default | |
IXFStyle (IXFStyle &&)=default | |
IXFStyle & | operator= (IXFStyle const &)=default |
IXFStyle & | operator= (IXFStyle &&)=default |
virtual | ~IXFStyle () |
virtual OUString | GetStyleName ()=0 |
@descr: return the style name. More... | |
virtual void | SetStyleName (const OUString &styleName)=0 |
@descr: set the name of the style. More... | |
virtual OUString | GetParentStyleName ()=0 |
@descr return the parent style name. More... | |
virtual void | SetParentStyleName (const OUString &parent)=0 |
@descr: Parent paragraph style. More... | |
virtual enumXFStyle | GetStyleFamily ()=0 |
@descr: return the style family. More... | |
virtual bool | Equal (IXFStyle *pStyle)=0 |
@descr: Compare whatever two style object are the same. More... | |
virtual void | ToXml (IXFStream *stream)=0 |
Private Attributes | |
std::unique_ptr< XFFontWorkStyle > | m_pFontWorkStyle |
XFDrawLineStyle * | m_pLineStyle |
XFDrawAreaStyle * | m_pAreaStyle |
OUString | m_strArrowStart |
OUString | m_strArrowEnd |
double | m_fArrowStartSize |
double | m_fArrowEndSize |
bool | m_bArrowStartCenter |
bool | m_bArrowEndCenter |
bool | m_bLineStyleRegistered |
bool | m_bAreaStyleRegistered |
Additional Inherited Members | |
Protected Attributes inherited from XFStyle | |
OUString | m_strStyleName |
OUString | m_strParentStyleName |
Style for all drawing object, which can includes line style, area style, wrap style.
Line style includes line type, line width and line color. Area style can be divided into 5 kinds, color fill, hatch, bitmap, gradient.I only support color fill and hatch now.
Definition at line 79 of file xfdrawstyle.hxx.
XFDrawStyle::XFDrawStyle | ( | ) |
Definition at line 67 of file xfdrawstyle.cxx.
|
overridevirtual |
Definition at line 78 of file xfdrawstyle.cxx.
References m_bAreaStyleRegistered, m_bLineStyleRegistered, m_pAreaStyle, and m_pLineStyle.
|
overridevirtual |
@descr get style family.
Reimplemented from XFStyle.
Definition at line 158 of file xfdrawstyle.cxx.
References enumXFStyleGraphics.
void XFDrawStyle::SetAreaColor | ( | XFColor const & | color | ) |
@descr Set drawing object area fill color.
Definition at line 130 of file xfdrawstyle.cxx.
References XFGlobal::GenAreaName(), m_pAreaStyle, XFDrawAreaStyle::SetBackColor(), and XFStyle::SetStyleName().
Referenced by LwpDrawObj::SetFillStyle().
void XFDrawStyle::SetAreaLineStyle | ( | enumXFAreaLineStyle | style, |
sal_Int32 | angle, | ||
double | space, | ||
XFColor | lineColor | ||
) |
@descr Set drawing object area grid style.
Definition at line 140 of file xfdrawstyle.cxx.
References XFStyleManager::AddStyle(), enumXFAreaHatch, XFGlobal::GenAreaName(), LwpGlobalMgr::GetInstance(), LwpGlobalMgr::GetXFStyleManager(), m_bAreaStyleRegistered, m_pAreaStyle, XFDrawAreaStyle::SetAreaStyle(), XFDrawAreaStyle::SetLineAngle(), XFDrawAreaStyle::SetLineColor(), XFDrawAreaStyle::SetLineSpace(), XFDrawAreaStyle::SetLineStyle(), and XFStyle::SetStyleName().
Referenced by LwpDrawObj::SetFillStyle().
|
inline |
@descr Set drawing object arrow end style,only lines can have arrows.
Definition at line 146 of file xfdrawstyle.hxx.
References end, m_bArrowEndCenter, m_fArrowEndSize, m_strArrowEnd, and size.
Referenced by LwpDrawObj::SetArrowHead().
|
inline |
@descr Set drawing object arrow start style,only lines can have arrows.
Definition at line 138 of file xfdrawstyle.hxx.
References m_bArrowStartCenter, m_fArrowStartSize, m_strArrowStart, size, and start.
Referenced by LwpDrawObj::SetArrowHead().
void XFDrawStyle::SetFontWorkStyle | ( | enumXFFWStyle | eStyle, |
enumXFFWAdjust | eAdjust | ||
) |
Definition at line 118 of file xfdrawstyle.cxx.
References m_pFontWorkStyle.
void XFDrawStyle::SetLineDashStyle | ( | enumXFLineStyle | style, |
double | len1, | ||
double | len2, | ||
double | space | ||
) |
@descr Set drawing object dash border style.
Definition at line 100 of file xfdrawstyle.cxx.
References XFStyleManager::AddStyle(), XFGlobal::GenStrokeDashName(), LwpGlobalMgr::GetInstance(), LwpGlobalMgr::GetXFStyleManager(), m_bLineStyleRegistered, m_pLineStyle, XFDrawLineStyle::SetDot1Length(), XFDrawLineStyle::SetDot1Number(), XFDrawLineStyle::SetDot2Length(), XFDrawLineStyle::SetDot2Number(), XFDrawLineStyle::SetLineStyle(), XFDrawLineStyle::SetSpace(), and XFStyle::SetStyleName().
Referenced by LwpDrawObj::SetLineStyle().
void XFDrawStyle::SetLineStyle | ( | double | width, |
XFColor | color | ||
) |
@descr Set drawing object border line.
Definition at line 88 of file xfdrawstyle.cxx.
References XFGlobal::GenStrokeDashName(), m_pLineStyle, XFDrawLineStyle::SetColor(), XFStyle::SetStyleName(), XFDrawLineStyle::SetTransparency(), and XFDrawLineStyle::SetWidth().
Referenced by LwpDrawObj::SetLineStyle().
|
overridevirtual |
Implements IXFStyle.
Definition at line 165 of file xfdrawstyle.cxx.
References IXFAttrList::AddAttribute(), aStr, IXFAttrList::Clear(), IXFStream::EndElement(), enumXFAreaHatch, enumXFAreaSolid, enumXFFWAdjustAutosize, enumXFFWAdjustCenter, enumXFFWAdjustLeft, enumXFFWAdustRight, enumXFFWOff, enumXFFWRotate, enumXFFWSlantX, enumXFFWSlantY, enumXFFWUpright, XFDrawAreaStyle::GetAreaStyle(), IXFStream::GetAttrList(), XFDrawAreaStyle::GetBackColor(), XFDrawLineStyle::GetColor(), XFStyle::GetStyleName(), XFDrawLineStyle::GetTransparency(), XFDrawLineStyle::GetWidth(), XFDrawLineStyle::IsSolid(), m_bArrowEndCenter, m_bArrowStartCenter, m_fArrowEndSize, m_fArrowStartSize, m_pAreaStyle, m_pFontWorkStyle, m_pLineStyle, m_strArrowEnd, m_strArrowStart, and IXFStream::StartElement().
|
private |
Definition at line 135 of file xfdrawstyle.hxx.
Referenced by SetAreaLineStyle(), and ~XFDrawStyle().
|
private |
Definition at line 133 of file xfdrawstyle.hxx.
Referenced by SetArrowEnd(), and ToXml().
|
private |
Definition at line 132 of file xfdrawstyle.hxx.
Referenced by SetArrowStart(), and ToXml().
|
private |
Definition at line 134 of file xfdrawstyle.hxx.
Referenced by SetLineDashStyle(), and ~XFDrawStyle().
|
private |
Definition at line 131 of file xfdrawstyle.hxx.
Referenced by SetArrowEnd(), and ToXml().
|
private |
Definition at line 130 of file xfdrawstyle.hxx.
Referenced by SetArrowStart(), and ToXml().
|
private |
Definition at line 127 of file xfdrawstyle.hxx.
Referenced by SetAreaColor(), SetAreaLineStyle(), ToXml(), and ~XFDrawStyle().
|
private |
Definition at line 125 of file xfdrawstyle.hxx.
Referenced by SetFontWorkStyle(), and ToXml().
|
private |
Definition at line 126 of file xfdrawstyle.hxx.
Referenced by SetLineDashStyle(), SetLineStyle(), ToXml(), and ~XFDrawStyle().
|
private |
Definition at line 129 of file xfdrawstyle.hxx.
Referenced by SetArrowEnd(), and ToXml().
|
private |
Definition at line 128 of file xfdrawstyle.hxx.
Referenced by SetArrowStart(), and ToXml().