QTextListFormat Class Reference |
enum | Style { ListDisc, ListCircle, ListSquare, ListDecimal, ..., ListUpperRoman } |
QTextListFormat () | |
int | indent () const |
bool | isValid () const |
void | setIndent ( int indentation ) |
void | setStyle ( Style style ) |
Style | style () const |
The QTextListFormat class provides formatting information for lists in a QTextDocument.
A list is composed of one or more items, represented as text blocks. The list's format specifies the appearance of items in the list. In particular, it determines the indentation and the style of each item.
The indentation of the items is an integer value that causes each item to be offset from the left margin by a certain amount. This value is read with indent() and set with setIndent().
The style used to decorate each item is set with setStyle() and can be read with the style() function. The style controls the type of bullet points and numbering scheme used for items in the list. Note that lists that use the decimal numbering scheme begin counting at 1 rather than 0.
See also QTextList.
This enum describes the symbols used to decorate list items:
Constant | Value | Description |
---|---|---|
QTextListFormat::ListDisc | -1 | a filled circle |
QTextListFormat::ListCircle | -2 | an empty circle |
QTextListFormat::ListSquare | -3 | a filled square |
QTextListFormat::ListDecimal | -4 | decimal values in ascending order |
QTextListFormat::ListLowerAlpha | -5 | lower case Latin characters in alphabetical order |
QTextListFormat::ListUpperAlpha | -6 | upper case Latin characters in alphabetical order |
QTextListFormat::ListLowerRoman | -7 | lower case roman numerals (supports up to 4999 items only) |
QTextListFormat::ListUpperRoman | -8 | upper case roman numerals (supports up to 4999 items only) |
Constructs a new list format object.
Returns the list format's indentation. The indentation is multiplied by the QTextDocument::indentWidth property to get the effective indent in pixels.
See also setIndent().
Returns true if this list format is valid; otherwise returns false.
Sets the list format's indentation. The indentation is multiplied by the QTextDocument::indentWidth property to get the effective indent in pixels.
See also indent().
Sets the list format's style.
Returns the list format's style.
Cette page est une traduction d'une page de la documentation de Qt, �crite par Nokia Corporation and/or its subsidiary(-ies). Les �ventuels probl�mes r�sultant d'une mauvaise traduction ne sont pas imputables � Nokia. | Qt 4.6 | |
Copyright © 2012 Developpez LLC. Tous droits r�serv�s Developpez LLC. Aucune reproduction, m�me partielle, ne peut �tre faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'� 3 ans de prison et jusqu'� 300 000 E de dommages et int�r�ts. Cette page est d�pos�e � la SACD. | ||
Vous avez d�nich� une erreur ? Un bug ? Une redirection cass�e ? Ou tout autre probl�me, quel qu'il soit ? Ou bien vous d�sirez participer � ce projet de traduction ? N'h�sitez pas � nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com