#include <wx/richtext/richtextbuffer.h>
Inheritance diagram for wxRichTextProperties:A simple property class using wxVariants.
This is used to give each rich text object the ability to store custom properties that can be used by the application.
<>< =''>:</>&;&;< =''>\ </></>
Public Member Functions | |
| wxRichTextProperties () | |
| Default constructor. | |
| wxRichTextProperties (const wxRichTextProperties &props) | |
| Copy constructor. | |
| void | operator= (const wxRichTextProperties &props) |
| Assignment operator. | |
| bool | operator== (const wxRichTextProperties &props) const |
| Equality operator. | |
| void | Copy (const wxRichTextProperties &props) |
| Copies from props. | |
| const wxVariant & | operator[] (size_t idx) const |
| Returns the variant at the given index. | |
| wxVariant & | operator[] (size_t idx) |
| Returns the variant at the given index. | |
| void | Clear () |
| Clears the properties. | |
| const wxRichTextVariantArray & | GetProperties () const |
| Returns the array of variants implementing the properties. | |
| wxRichTextVariantArray & | GetProperties () |
| Returns the array of variants implementing the properties. | |
| void | SetProperties (const wxRichTextVariantArray &props) |
| Sets the array of variants. | |
| wxArrayString | GetPropertyNames () const |
| Returns all the property names. | |
| size_t | GetCount () const |
| Returns a count of the properties. | |
| bool | HasProperty (const wxString &name) const |
| Returns true if the given property is found. | |
| int | Find (const wxString &name) const |
| Finds the given property. | |
| bool | Remove (const wxString &name) |
| Removes the given property. | |
| const wxVariant & | GetProperty (const wxString &name) const |
| Gets the property variant by name. | |
| wxVariant * | FindOrCreateProperty (const wxString &name) |
| Finds or creates a property with the given name, returning a pointer to the variant. | |
| wxString | GetPropertyString (const wxString &name) const |
| Gets the value of the named property as a string. | |
| long | GetPropertyLong (const wxString &name) const |
| Gets the value of the named property as a long integer. | |
| bool | GetPropertyBool (const wxString &name) const |
| Gets the value of the named property as a boolean. | |
| double | GetPropertyDouble (const wxString &name) const |
| Gets the value of the named property as a double. | |
| void | SetProperty (const wxVariant &variant) |
| Sets the property by passing a variant which contains a name and value. | |
| void | SetProperty (const wxString &name, const wxVariant &variant) |
| Sets a property by name and variant. | |
| void | SetProperty (const wxString &name, const wxString &value) |
| Sets a property by name and string value. | |
| void | SetProperty (const wxString &name, const wxChar *value) |
| Sets a property by name and wxChar* value. | |
| void | SetProperty (const wxString &name, long value) |
| Sets property by name and long integer value. | |
| void | SetProperty (const wxString &name, double value) |
| Sets property by name and double value. | |
| void | SetProperty (const wxString &name, bool value) |
| Sets property by name and boolean value. | |
| void | RemoveProperties (const wxRichTextProperties &properties) |
| Removes the given properties from these properties. | |
| void | MergeProperties (const wxRichTextProperties &properties) |
| Merges the given properties with these properties. | |
Public Member Functions inherited from wxObject | |
| wxObject () | |
| Default ctor; initializes to NULL the internal reference data. | |
| wxObject (const wxObject &other) | |
| Copy ctor. | |
| virtual | ~wxObject () |
| Destructor. | |
| virtual wxClassInfo * | GetClassInfo () const |
| This virtual function is redefined for every class that requires run-time type information, when using the wxDECLARE_CLASS macro (or similar). | |
| wxObjectRefData * | GetRefData () const |
| Returns the wxObject::m_refData pointer, i.e. the data referenced by this object. | |
| bool | IsKindOf (const wxClassInfo *info) const |
| Determines whether this class is a subclass of (or the same class as) the given class. | |
| bool | IsSameAs (const wxObject &obj) const |
| Returns true if this object has the same data pointer as obj. | |
| void | Ref (const wxObject &clone) |
| Makes this object refer to the data in clone. | |
| void | SetRefData (wxObjectRefData *data) |
| Sets the wxObject::m_refData pointer. | |
| void | UnRef () |
| Decrements the reference count in the associated data, and if it is zero, deletes the data. | |
| void | UnShare () |
| This is the same of AllocExclusive() but this method is public. | |
| void | operator delete (void *buf) |
The delete operator is defined for debugging versions of the library only, when the identifier __WXDEBUG__ is defined. | |
| void * | operator new (size_t size, const wxString &filename=NULL, int lineNum=0) |
The new operator is defined for debugging versions of the library only, when the identifier __WXDEBUG__ is defined. | |
Protected Attributes | |
| wxRichTextVariantArray | m_properties |
Protected Attributes inherited from wxObject | |
| wxObjectRefData * | m_refData |
| Pointer to an object which is the object's reference-counted data. | |
Additional Inherited Members | |
Protected Member Functions inherited from wxObject | |
| void | AllocExclusive () |
| Ensure that this object's data is not shared with any other object. | |
| virtual wxObjectRefData * | CreateRefData () const |
| Creates a new instance of the wxObjectRefData-derived class specific to this object and returns it. | |
| virtual wxObjectRefData * | CloneRefData (const wxObjectRefData *data) const |
| Creates a new instance of the wxObjectRefData-derived class specific to this object and initializes it copying data. | |
|
inline |
Default constructor.
|
inline |
Copy constructor.
|
inline |
Clears the properties.
|
inline |
Copies from props.
Finds or creates a property with the given name, returning a pointer to the variant.
|
inline |
Returns a count of the properties.
|
inline |
Returns the array of variants implementing the properties.
|
inline |
Returns the array of variants implementing the properties.
Gets the property variant by name.
Gets the value of the named property as a boolean.
Gets the value of the named property as a double.
Gets the value of the named property as a long integer.
| wxArrayString wxRichTextProperties::GetPropertyNames | ( | ) | const |
Returns all the property names.
Gets the value of the named property as a string.
Returns true if the given property is found.
| void wxRichTextProperties::MergeProperties | ( | const wxRichTextProperties & | properties | ) |
Merges the given properties with these properties.
|
inline |
Assignment operator.
| bool wxRichTextProperties::operator== | ( | const wxRichTextProperties & | props | ) | const |
Equality operator.
Returns the variant at the given index.
Returns the variant at the given index.
| void wxRichTextProperties::RemoveProperties | ( | const wxRichTextProperties & | properties | ) |
Removes the given properties from these properties.
|
inline |
Sets the array of variants.
Sets property by name and boolean value.
Sets a property by name and wxChar* value.
Sets a property by name and string value.
Sets a property by name and variant.
Sets property by name and double value.
Sets property by name and long integer value.
Sets the property by passing a variant which contains a name and value.
|
protected |