#include <q3stylesheet.h>
Inheritance diagram for Q3StyleSheet:


By creating Q3StyleSheetItem objects for a style sheet you build a definition of a set of tags. This definition will be used by the internal rich text rendering system to parse and display text documents to which the style sheet applies. Rich text is normally visualized in a QTextEdit or a QTextBrowser. However, QLabel, QWhatsThis and QMessageBox also support it, and other classes are likely to follow. With QSimpleRichText it is possible to use the rich text renderer for custom widgets as well.
The default Q3StyleSheet object has the following style bindings, sorted by structuring bindings, anchors, character style bindings (i.e. inline styles), special elements such as horizontal lines or images, and other tags. In addition, rich text supports simple HTML tables.
The structuring tags are Structuring tags Notes {<qt>}...{</qt>} A Qt rich text document. It understands the following attributes: title -- The caption of the document. This attribute is easily accessible with QTextEdit::documentTitle(). type -- The type of the document. The default type is page. It indicates that the document is displayed in a page of its own. Another style is detail, which can be used to explain certain expressions in more detail in a few sentences. For detail, QTextBrowser will then keep the current page and display the new document in a small popup similar to QWhatsThis. Note that links will not work in documents with {<qt type="detail">...</qt>}. bgcolor -- The background color, for example bgcolor="yellow" or bgcolor="#0000FF". background -- The background pixmap, for example background="granite.xpm". The pixmap name will be resolved by a Q3MimeSourceFactory(). text -- The default text color, for example text="red". link -- The link color, for example link="green". {
} A top-level heading. {
} A sublevel heading. {
} A sub-sublevel heading. {
...} A left-aligned paragraph. Adjust the alignment with the align attribute. Possible values are left, right and center. {
{{<blockquote>...}{</blockquote>} An indented paragraph that is useful for quotes. {type=disc; other types are circle and square. {type="1"; other types are "a" and "A". {...} A list item. This tag can be used only within the context of {{{...} For larger chunks of code. Whitespaces in the contents are preserved. For small bits of code use the inline-style
code.
Anchors and links are done with a single tag: Anchor tags Notes {...} An anchor or link. A link is created by using an href attribute, for example
{Link Text}. Links to targets within a document are achieved in the same way as for HTML, e.g.
{Link Text}. A target is created by using a name attribute, for example
{
}.
The default character style bindings are Style tags Notes {...} Emphasized. By default this is the same as {...} (italic). {...} Strong. By default this is the same as {...} (bold). {...} Italic font style. {...} Bold font style. {<u>...</u>} Underlined font style. {<s>...</s>} Strike out font style. {<big>...</big>} A larger font size. {...} A smaller font size. {...} Subscripted text {...} Superscripted text {...} Indicates code. By default this is the same as {...} (typewriter). For larger chunks of code use the block-tag {<}{pre>}. {...} Typewriter font style. {<font>...</font>} Customizes the font size, family and text color. The tag understands the following attributes: color -- The text color, for example color="red" or color="FF0000". size -- The logical size of the font. Logical sizes 1 to 7 are supported. The value may either be absolute (for example, size=3) or relative (size=-2). In the latter case the sizes are simply added. face -- The family of the font, for example face=times.
Special elements are: Special tags Notes {} An image. The image name for the mime source factory is given in the source attribute, for example {
width and height that determine the size of the image. If the pixmap does not fit the specified size it will be scaled automatically (by using QImage::smoothScale()).
The align attribute determines where the image is placed. By default, an image is placed inline just like a normal character. Specify left or right to place the image at the respective side. {
{{<nobr>...</nobr>} No break. Prevents word wrap. In addition, rich text supports simple HTML tables. A table consists of one or more rows each of which contains one or more cells. Cells are either data cells or header cells, depending on their content. Cells which span rows and columns are supported.
Table tags Notes {
} A table. Tables support the following attributes: bgcolor -- The background color. width -- The table width. This is either an absolute pixel width or a relative percentage of the table's width, for example width=80%. border -- The width of the table border. The default is 0 (= no border). cellspacing -- Additional space around the table cells. The default is 2. cellpadding -- Additional space around the contents of table cells. The default is 1. {
...} A table row. This is only valid within a table. Rows support the following attribute: bgcolor -- The background color. {
...} A table header cell. Similar to td, but defaults to center alignment and a bold font. {
...} A table data cell. This is only valid within a tr. Cells support the following attributes: bgcolor -- The background color. width -- The cell width. This is either an absolute pixel width or a relative percentage of table's width, for example width=50%. colspan -- Specifies how many columns this cell spans. The default is 1. rowspan -- Specifies how many rows this cell spans. The default is 1. align -- Qt::Alignment; possible values are left, right, and center. The default is left. valign -- Qt::Vertical alignment; possible values are top, middle, and bottom. The default is middle.
Definition at line 176 of file q3stylesheet.h.
Public Member Functions | |
| Q3StyleSheet (QObject *parent=0, const char *name=0) | |
| virtual | ~Q3StyleSheet () |
| Q3StyleSheetItem * | item (const QString &name) |
| const Q3StyleSheetItem * | item (const QString &name) const |
| void | insert (Q3StyleSheetItem *item) |
| virtual void | scaleFont (QFont &font, int logicalSize) const |
| virtual void | error (const QString &) const |
Static Public Member Functions | |
| static Q3StyleSheet * | defaultSheet () |
| static void | setDefaultSheet (Q3StyleSheet *) |
| static QString | escape (const QString &) |
| static QString | convertFromPlainText (const QString &, Q3StyleSheetItem::WhiteSpaceMode mode=Q3StyleSheetItem::WhiteSpacePre) |
| static bool | mightBeRichText (const QString &) |
Private Member Functions | |
| void | init () |
Private Attributes | |
| QHash< QString, Q3StyleSheetItem * > | styles |
| Q3StyleSheetItem * | nullstyle |
| Q3StyleSheet::Q3StyleSheet | ( | QObject * | parent = 0, |
|
| const char * | name = 0 | |||
| ) |
Creates a style sheet called name, with parent parent. Like any QObject it will be deleted when its parent is destroyed (if the child still exists).
By default the style sheet has the tag definitions defined above.
Definition at line 1065 of file q3stylesheet.cpp.
References init(), and QObject::setObjectName().
Referenced by defaultSheet().
01066 : QObject(parent) 01067 { 01068 setObjectName(name); 01069 init(); 01070 }
Here is the call graph for this function:

| Q3StyleSheet::~Q3StyleSheet | ( | ) | [virtual] |
Destroys the style sheet. All styles inserted into the style sheet will be deleted.
Definition at line 1076 of file q3stylesheet.cpp.
References QHash< Key, T >::begin(), QHash< Key, T >::end(), styles, and QHash< Key, T >::value().
01077 { 01078 QHash<QString, Q3StyleSheetItem *>::iterator it = styles.begin(); 01079 while (it != styles.end()) { 01080 delete it.value(); 01081 ++it; 01082 } 01083 }
Here is the call graph for this function:

| Q3StyleSheet * Q3StyleSheet::defaultSheet | ( | ) | [static] |
Returns the application-wide default style sheet. This style sheet is used by rich text rendering classes such as QSimpleRichText, QWhatsThis and QMessageBox to define the rendering style and available tags within rich text documents. It also serves as the initial style sheet for the more complex render widgets, QTextEdit and QTextBrowser.
Definition at line 1274 of file q3stylesheet.cpp.
References defaultsheet, Q3StyleSheet(), and qt_cleanup_stylesheet.
Referenced by Q3TextDocument::init().
01275 { 01276 if (!defaultsheet) { 01277 defaultsheet = new Q3StyleSheet(); 01278 qt_cleanup_stylesheet.set(&defaultsheet); 01279 } 01280 return defaultsheet; 01281 }
Here is the call graph for this function:

| void Q3StyleSheet::setDefaultSheet | ( | Q3StyleSheet * | sheet | ) | [static] |
Sets the application-wide default style sheet to sheet, deleting any style sheet previously set. The ownership is transferred to Q3StyleSheet.
Definition at line 1290 of file q3stylesheet.cpp.
References defaultsheet, and qt_cleanup_stylesheet.
01291 { 01292 if (defaultsheet != sheet) { 01293 if (defaultsheet) 01294 qt_cleanup_stylesheet.reset(); 01295 delete defaultsheet; 01296 } 01297 defaultsheet = sheet; 01298 if (defaultsheet) 01299 qt_cleanup_stylesheet.set(&defaultsheet); 01300 }
| Q3StyleSheetItem * Q3StyleSheet::item | ( | const QString & | name | ) |
Returns the style called name or 0 if there is no such style.
Definition at line 1316 of file q3stylesheet.cpp.
References name, styles, and QHash< Key, T >::value().
Referenced by Q3TextEdit::optimSetTextFormat(), Q3TextDocument::parseTable(), Q3TextDocument::richText(), Q3TextDocument::setRichTextInternal(), and Q3TextDocument::tag().
Here is the call graph for this function:

| const Q3StyleSheetItem * Q3StyleSheet::item | ( | const QString & | name | ) | const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Returns the style called name or 0 if there is no such style (const version)
Definition at line 1329 of file q3stylesheet.cpp.
References name, styles, and QHash< Key, T >::value().
Here is the call graph for this function:

| void Q3StyleSheet::insert | ( | Q3StyleSheetItem * | item | ) |
Definition at line 1307 of file q3stylesheet.cpp.
References QHash< Key, T >::insert(), Q3StyleSheetItem::name(), and styles.
Referenced by Q3StyleSheetItem::Q3StyleSheetItem().
Here is the call graph for this function:

Auxiliary function. Converts the plain text string plain to a rich text formatted string with any HTML meta-characters escaped.
Definition at line 1357 of file q3stylesheet.cpp.
References Qt::escape().
01358 { 01359 return Qt::escape(plain); 01360 }
Here is the call graph for this function:

| QString Q3StyleSheet::convertFromPlainText | ( | const QString & | plain, | |
| Q3StyleSheetItem::WhiteSpaceMode | mode = Q3StyleSheetItem::WhiteSpacePre | |||
| ) | [static] |
Auxiliary function. Converts the plain text string plain to a rich text formatted paragraph while preserving most of its look.
mode defines the whitespace mode. Possible values are Q3StyleSheetItem::WhiteSpacePre (no wrapping, all whitespaces preserved) and Q3StyleSheetItem::WhiteSpaceNormal (wrapping, simplified whitespaces).
Definition at line 1346 of file q3stylesheet.cpp.
References Qt::convertFromPlainText().
01347 { 01348 return Qt::convertFromPlainText(plain, Qt::WhiteSpaceMode(mode)); 01349 }
Here is the call graph for this function:

| bool Q3StyleSheet::mightBeRichText | ( | const QString & | text | ) | [static] |
Returns true if the string text is likely to be rich text; otherwise returns false.
This function uses a fast and therefore simple heuristic. It mainly checks whether there is something that looks like a tag before the first line break. Although the result may be correct for common cases, there is no guarantee.
Definition at line 1373 of file q3stylesheet.cpp.
References Qt::mightBeRichText().
Referenced by Q3TextEdit::append(), and Q3TextDocument::setText().
01374 { 01375 return Qt::mightBeRichText(text); 01376 }
Here is the call graph for this function:

| void Q3StyleSheet::scaleFont | ( | QFont & | font, | |
| int | logicalSize | |||
| ) | const [virtual] |
Scales the font font to the appropriate physical point size corresponding to the logical font size logicalSize.
When calling this function, font has a point size corresponding to the logical font size 3.
Logical font sizes range from 1 to 7, with 1 being the smallest.
Definition at line 1408 of file q3stylesheet.cpp.
References QFont::pixelSize(), QFont::pointSize(), s, QFont::setPixelSize(), and QFont::setPointSize().
Referenced by Q3TextFormat::makeTextFormat(), and Q3TextFormatCollection::updateDefaultFormat().
01409 { 01410 if (logicalSize < 1) 01411 logicalSize = 1; 01412 if (logicalSize > 7) 01413 logicalSize = 7; 01414 int baseSize = font.pointSize(); 01415 bool pixel = false; 01416 if (baseSize == -1) { 01417 baseSize = font.pixelSize(); 01418 pixel = true; 01419 } 01420 int s; 01421 switch (logicalSize) { 01422 case 1: 01423 s = 7*baseSize/10; 01424 break; 01425 case 2: 01426 s = (8 * baseSize) / 10; 01427 break; 01428 case 4: 01429 s = (12 * baseSize) / 10; 01430 break; 01431 case 5: 01432 s = (15 * baseSize) / 10; 01433 break; 01434 case 6: 01435 s = 2 * baseSize; 01436 break; 01437 case 7: 01438 s = (24 * baseSize) / 10; 01439 break; 01440 default: 01441 s = baseSize; 01442 } 01443 if (pixel) 01444 font.setPixelSize(s); 01445 else 01446 font.setPointSize(s); 01447 }
Here is the call graph for this function:

| void Q3StyleSheet::error | ( | const QString & | msg | ) | const [virtual] |
This virtual function is called when an error occurs when processing rich text. Reimplement it if you need to catch error messages.
Errors might occur if some rich text strings contain tags that are not understood by the stylesheet, if some tags are nested incorrectly, or if tags are not closed properly.
msg is the error message.
Definition at line 1392 of file q3stylesheet.cpp.
Referenced by Q3TextDocument::setRichTextInternal().
| void Q3StyleSheet::init | ( | ) | [private] |
Definition at line 1089 of file q3stylesheet.cpp.
References Qt::AlignCenter, QFont::Bold, Q3StyleSheetItem::DisplayBlock, Q3StyleSheetItem::DisplayListItem, Q3StyleSheetItem::DisplayNone, QString::fromLatin1(), Q3StyleSheetItem::ListDecimal, Q3StyleSheetItem::ListDisc, Q3StyleSheetItem::MarginBottom, Q3StyleSheetItem::MarginHorizontal, Q3StyleSheetItem::MarginLeft, Q3StyleSheetItem::MarginTop, Q3StyleSheetItem::MarginVertical, nullstyle, Q3StyleSheetItem::setAlignment(), Q3StyleSheetItem::setAnchor(), Q3StyleSheetItem::setContexts(), Q3StyleSheetItem::setDisplayMode(), Q3StyleSheetItem::setFontFamily(), Q3StyleSheetItem::setFontItalic(), Q3StyleSheetItem::setFontStrikeOut(), Q3StyleSheetItem::setFontUnderline(), Q3StyleSheetItem::setFontWeight(), Q3StyleSheetItem::setListStyle(), Q3StyleSheetItem::setLogicalFontSize(), Q3StyleSheetItem::setLogicalFontSizeStep(), Q3StyleSheetItem::setMargin(), Q3StyleSheetItem::setNumberOfColumns(), Q3StyleSheetItem::setSelfNesting(), Q3StyleSheetItem::setVerticalAlignment(), Q3StyleSheetItem::setWhiteSpaceMode(), Q3StyleSheetItem::VAlignSub, Q3StyleSheetItem::VAlignSuper, Q3StyleSheetItem::WhiteSpaceNoWrap, and Q3StyleSheetItem::WhiteSpacePre.
Referenced by Q3StyleSheet().
01090 { 01091 nullstyle = new Q3StyleSheetItem(this, QString::fromLatin1("")); 01092 01093 Q3StyleSheetItem *style; 01094 01095 style = new Q3StyleSheetItem(this, "qml"); // compatibility 01096 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01097 01098 style = new Q3StyleSheetItem(this, QString::fromLatin1("qt")); 01099 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01100 01101 style = new Q3StyleSheetItem(this, QString::fromLatin1("a")); 01102 style->setAnchor(true); 01103 01104 style = new Q3StyleSheetItem(this, QString::fromLatin1("em")); 01105 style->setFontItalic(true); 01106 01107 style = new Q3StyleSheetItem(this, QString::fromLatin1("i")); 01108 style->setFontItalic(true); 01109 01110 style = new Q3StyleSheetItem(this, QString::fromLatin1("big")); 01111 style->setLogicalFontSizeStep(1); 01112 style = new Q3StyleSheetItem(this, QString::fromLatin1("large")); // compatibility 01113 style->setLogicalFontSizeStep(1); 01114 01115 style = new Q3StyleSheetItem(this, QString::fromLatin1("small")); 01116 style->setLogicalFontSizeStep(-1); 01117 01118 style = new Q3StyleSheetItem(this, QString::fromLatin1("strong")); 01119 style->setFontWeight(QFont::Bold); 01120 01121 style = new Q3StyleSheetItem(this, QString::fromLatin1("b")); 01122 style->setFontWeight(QFont::Bold); 01123 01124 style = new Q3StyleSheetItem(this, QString::fromLatin1("h1")); 01125 style->setFontWeight(QFont::Bold); 01126 style->setLogicalFontSize(6); 01127 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01128 style-> setMargin(Q3StyleSheetItem::MarginTop, 18); 01129 style-> setMargin(Q3StyleSheetItem::MarginBottom, 12); 01130 01131 style = new Q3StyleSheetItem(this, QString::fromLatin1("h2")); 01132 style->setFontWeight(QFont::Bold); 01133 style->setLogicalFontSize(5); 01134 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01135 style-> setMargin(Q3StyleSheetItem::MarginTop, 16); 01136 style-> setMargin(Q3StyleSheetItem::MarginBottom, 12); 01137 01138 style = new Q3StyleSheetItem(this, QString::fromLatin1("h3")); 01139 style->setFontWeight(QFont::Bold); 01140 style->setLogicalFontSize(4); 01141 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01142 style-> setMargin(Q3StyleSheetItem::MarginTop, 14); 01143 style-> setMargin(Q3StyleSheetItem::MarginBottom, 12); 01144 01145 style = new Q3StyleSheetItem(this, QString::fromLatin1("h4")); 01146 style->setFontWeight(QFont::Bold); 01147 style->setLogicalFontSize(3); 01148 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01149 style-> setMargin(Q3StyleSheetItem::MarginVertical, 12); 01150 01151 style = new Q3StyleSheetItem(this, QString::fromLatin1("h5")); 01152 style->setFontWeight(QFont::Bold); 01153 style->setLogicalFontSize(2); 01154 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01155 style-> setMargin(Q3StyleSheetItem::MarginTop, 12); 01156 style-> setMargin(Q3StyleSheetItem::MarginBottom, 4); 01157 01158 style = new Q3StyleSheetItem(this, QString::fromLatin1("p")); 01159 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01160 style-> setMargin(Q3StyleSheetItem::MarginVertical, 12); 01161 style->setSelfNesting(false); 01162 01163 style = new Q3StyleSheetItem(this, QString::fromLatin1("center")); 01164 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01165 style->setAlignment(Qt::AlignCenter); 01166 01167 style = new Q3StyleSheetItem(this, QString::fromLatin1("twocolumn")); 01168 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01169 style->setNumberOfColumns(2); 01170 01171 style = new Q3StyleSheetItem(this, QString::fromLatin1("multicol")); 01172 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01173 (void) new Q3StyleSheetItem(this, QString::fromLatin1("font")); 01174 01175 style = new Q3StyleSheetItem(this, QString::fromLatin1("ul")); 01176 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01177 style->setListStyle(Q3StyleSheetItem::ListDisc); 01178 style-> setMargin(Q3StyleSheetItem::MarginVertical, 12); 01179 style->setMargin(Q3StyleSheetItem::MarginLeft, 40); 01180 01181 style = new Q3StyleSheetItem(this, QString::fromLatin1("ol")); 01182 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01183 style->setListStyle(Q3StyleSheetItem::ListDecimal); 01184 style-> setMargin(Q3StyleSheetItem::MarginVertical, 12); 01185 style->setMargin(Q3StyleSheetItem::MarginLeft, 40); 01186 01187 style = new Q3StyleSheetItem(this, QString::fromLatin1("li")); 01188 style->setDisplayMode(Q3StyleSheetItem::DisplayListItem); 01189 style->setSelfNesting(false); 01190 01191 style = new Q3StyleSheetItem(this, QString::fromLatin1("code")); 01192 style->setFontFamily(QString::fromLatin1("Courier New,courier")); 01193 01194 style = new Q3StyleSheetItem(this, QString::fromLatin1("tt")); 01195 style->setFontFamily(QString::fromLatin1("Courier New,courier")); 01196 01197 new Q3StyleSheetItem(this, QString::fromLatin1("img")); 01198 new Q3StyleSheetItem(this, QString::fromLatin1("br")); 01199 new Q3StyleSheetItem(this, QString::fromLatin1("hr")); 01200 01201 style = new Q3StyleSheetItem(this, QString::fromLatin1("sub")); 01202 style->setVerticalAlignment(Q3StyleSheetItem::VAlignSub); 01203 style = new Q3StyleSheetItem(this, QString::fromLatin1("sup")); 01204 style->setVerticalAlignment(Q3StyleSheetItem::VAlignSuper); 01205 01206 style = new Q3StyleSheetItem(this, QString::fromLatin1("pre")); 01207 style->setFontFamily(QString::fromLatin1("Courier New,courier")); 01208 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01209 style->setWhiteSpaceMode(Q3StyleSheetItem::WhiteSpacePre); 01210 style-> setMargin(Q3StyleSheetItem::MarginVertical, 12); 01211 01212 style = new Q3StyleSheetItem(this, QString::fromLatin1("blockquote")); 01213 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01214 style->setMargin(Q3StyleSheetItem::MarginHorizontal, 40); 01215 01216 style = new Q3StyleSheetItem(this, QString::fromLatin1("head")); 01217 style->setDisplayMode(Q3StyleSheetItem::DisplayNone); 01218 style = new Q3StyleSheetItem(this, QString::fromLatin1("body")); 01219 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01220 style = new Q3StyleSheetItem(this, QString::fromLatin1("div")); 01221 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock) ; 01222 style = new Q3StyleSheetItem(this, QString::fromLatin1("span")); 01223 style = new Q3StyleSheetItem(this, QString::fromLatin1("dl")); 01224 style-> setMargin(Q3StyleSheetItem::MarginVertical, 8); 01225 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01226 style = new Q3StyleSheetItem(this, QString::fromLatin1("dt")); 01227 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01228 style->setContexts(QString::fromLatin1("dl")); 01229 style = new Q3StyleSheetItem(this, QString::fromLatin1("dd")); 01230 style->setDisplayMode(Q3StyleSheetItem::DisplayBlock); 01231 style->setMargin(Q3StyleSheetItem::MarginLeft, 30); 01232 style->setContexts(QString::fromLatin1("dt dl")); 01233 style = new Q3StyleSheetItem(this, QString::fromLatin1("u")); 01234 style->setFontUnderline(true); 01235 style = new Q3StyleSheetItem(this, QString::fromLatin1("s")); 01236 style->setFontStrikeOut(true); 01237 style = new Q3StyleSheetItem(this, QString::fromLatin1("nobr")); 01238 style->setWhiteSpaceMode(Q3StyleSheetItem::WhiteSpaceNoWrap); 01239 01240 // compatibily with some minor 3.0.x Qt versions that had an 01241 // undocumented <wsp> tag. ### Remove 3.1 01242 style = new Q3StyleSheetItem(this, QString::fromLatin1("wsp")); 01243 style->setWhiteSpaceMode(Q3StyleSheetItem::WhiteSpacePre); 01244 01245 // tables 01246 style = new Q3StyleSheetItem(this, QString::fromLatin1("table")); 01247 style = new Q3StyleSheetItem(this, QString::fromLatin1("tr")); 01248 style->setContexts(QString::fromLatin1("table")); 01249 style = new Q3StyleSheetItem(this, QString::fromLatin1("td")); 01250 style->setContexts(QString::fromLatin1("tr")); 01251 style = new Q3StyleSheetItem(this, QString::fromLatin1("th")); 01252 style->setFontWeight(QFont::Bold); 01253 style->setAlignment(Qt::AlignCenter); 01254 style->setContexts(QString::fromLatin1("tr")); 01255 01256 style = new Q3StyleSheetItem(this, QString::fromLatin1("html")); 01257 }
Here is the call graph for this function:

QHash<QString, Q3StyleSheetItem *> Q3StyleSheet::styles [private] |
Q3StyleSheetItem* Q3StyleSheet::nullstyle [private] |
1.5.1