Added custom properties to style definitions and style sheets

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71276 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Julian Smart
2012-04-24 11:22:18 +00:00
parent ee1787872d
commit c6182d489c
6 changed files with 95 additions and 10 deletions

View File

@@ -101,11 +101,27 @@ public:
/// Gets the style combined with the base style
virtual wxRichTextAttr GetStyleMergedWithBase(const wxRichTextStyleSheet* sheet) const;
/**
Sets the definition's properties.
*/
wxRichTextProperties& GetProperties() { return m_properties; }
/**
Returns the definition's properties.
*/
const wxRichTextProperties& GetProperties() const { return m_properties; }
/**
Returns the definition's properties.
*/
void SetProperties(const wxRichTextProperties& props) { m_properties = props; }
protected:
wxString m_name;
wxString m_baseStyle;
wxString m_description;
wxRichTextAttr m_style;
wxString m_name;
wxString m_baseStyle;
wxString m_description;
wxRichTextAttr m_style;
wxRichTextProperties m_properties;
};
/*!
@@ -402,6 +418,21 @@ public:
void SetDescription(const wxString& descr) { m_description = descr; }
const wxString& GetDescription() const { return m_description; }
/**
Sets the definition's properties.
*/
wxRichTextProperties& GetProperties() { return m_properties; }
/**
Returns the definition's properties.
*/
const wxRichTextProperties& GetProperties() const { return m_properties; }
/**
Returns the definition's properties.
*/
void SetProperties(const wxRichTextProperties& props) { m_properties = props; }
/// Implementation
/// Add a definition to one of the style lists
@@ -425,6 +456,7 @@ protected:
wxRichTextStyleSheet* m_previousSheet;
wxRichTextStyleSheet* m_nextSheet;
wxRichTextProperties m_properties;
};
#if wxUSE_HTML