Wt::WCssStyleSheet Class Reference
[Style classes]

A CSS style sheet. More...

#include <Wt/WCssStyleSheet>

List of all members.

Public Member Functions

 WCssStyleSheet ()
 Create a new empty style sheet.
 ~WCssStyleSheet ()
 Destroy a style sheet, and all rules in it.
WCssTextRuleaddRule (const std::string &selector, const WString &declarations, const std::string &ruleName=std::string())
 Add a CSS rule.
WCssTemplateRuleaddRule (const std::string &selector, const WCssDecorationStyle &style, const std::string &ruleName=std::string())
 Add a CSS rule.
WCssRuleaddRule (WCssRule *rule, const std::string &ruleName=std::string())
 Add a CSS rule.
bool isDefined (const std::string &ruleName) const
 Returns if a rule was already defined in this style sheet.
void removeRule (WCssRule *rule)
 Remove a rule.


Detailed Description

A CSS style sheet.

See also:
WApplication::styleSheet()

Member Function Documentation

WCssTextRule * Wt::WCssStyleSheet::addRule ( const std::string &  selector,
const WString declarations,
const std::string &  ruleName = std::string() 
)

Add a CSS rule.

Add a rule using the CSS selector selector, with CSS declarations in declarations. These declarations must be a list separated by semi-colons (;).

Optionally, you may give a ruleName, which may later be used to check if the rule was already defined.

See also:
isDefined(const std::string& ruleName).

WCssTemplateRule * Wt::WCssStyleSheet::addRule ( const std::string &  selector,
const WCssDecorationStyle style,
const std::string &  ruleName = std::string() 
)

Add a CSS rule.

Add a rule using the CSS selector selector, with styles specified in style.

Optionally, you may give a ruleName, which may later be used to check if the rule was already defined.

See also:
isDefined(const std::string& ruleName).

WCssRule * Wt::WCssStyleSheet::addRule ( WCssRule rule,
const std::string &  ruleName = std::string() 
)

Add a CSS rule.

Optionally, you may give a ruleName, which may later be used to check if the rule was already defined.

See also:
isDefined(const std::string& ruleName).

bool Wt::WCssStyleSheet::isDefined ( const std::string &  ruleName  )  const

Returns if a rule was already defined in this style sheet.

Returns whether a rule was added with the given ruleName.

See also:
addRule()


Generated on Mon Nov 3 15:00:59 2008 for Wt by doxygen 1.5.6