Applies styles to IlvStylable
objects.
More...
#include <ilviews/base/stylist.h>
Public Member Functions | |
virtual IlvStylist * | getParentStylist () const =0 |
Returns the parent stylist. More... | |
void | removeStyling () |
Removes all styling information from the stylist. | |
IlBoolean | setStyleSheet (const char *text, size_t length) |
Applies styling information to this stylist. More... | |
IlBoolean | setStyleSheet (std::istream &file) |
Applies styling information to this stylist. More... | |
Applies styles to IlvStylable
objects.
Library: xviews or winviews or mviews (mutually exclusive)
A stylist is responsible for applying the styles that are stored in the style sheets attached to it to the stylable object it is in charge of.
IlvStylable
.
|
pure virtual |
Returns the parent stylist.
Stylist hierarchy is how cascading styling is done: if no style apply for a given stylable in this stylist, the parent stylist will be queried, recursively until there is no parent stylist anymore.
0
if there is none. Implemented in IlvAbstractView, and IlvDisplay.
IlBoolean IlvStylist::setStyleSheet | ( | const char * | text, |
size_t | length | ||
) |
Applies styling information to this stylist.
The style sheet is queried for styling information if the look & feel handler is set to CSS. Calling this method again overwrites the previous styling information. After setting the stylesheet notifyStyleChanges() must be called to recalculate the style and redraw.
text. | A pointer to the css styling text. |
length. | Length of the styling text. |
IlTrue
if the style sheet was applied succesfully, and IlFalse
if a problem occured. removeStyling()
. IlBoolean IlvStylist::setStyleSheet | ( | std::istream & | file | ) |
Applies styling information to this stylist.
The style sheet is queried for styling information if the look & feel handler is set to CSS. Calling this method again overwrites the previous styling information. After setting the stylesheet notifyStyleChanges() must be called to recalculate the style and redraw.
file. | An input stream to the style sheet file containing the style information. If there was already a style sheet applied to this stylist, this method overwrites the previous one. |
IlTrue
if the style sheet was applied succesfully, and IlFalse
if a problem occured.