Qt Jambi Home

com.trolltech.qt.core
Enum Qt.TextFormat

java.lang.Object
  extended by java.lang.Enum<Qt.TextFormat>
      extended by com.trolltech.qt.core.Qt.TextFormat
All Implemented Interfaces:
QtEnumerator, java.io.Serializable, java.lang.Comparable<Qt.TextFormat>
Enclosing interface:
Qt

public static enum Qt.TextFormat
extends java.lang.Enum<Qt.TextFormat>
implements QtEnumerator

This enum is used in widgets that can display both plain text and rich text, e.g. QLabel. It is used for deciding whether a text string should be interpreted as one or the other. This is normally done by passing one of the enum values to a setTextFormat() function.


Enum Constant Summary
AutoText
          The text string is interpreted as for Qt::RichText if Qt::mightBeRichText() returns true, otherwise as Qt::PlainText.
LogText
          A special, limited text format which is only used by QTextEdit in an optimized mode.
PlainText
          The text string is interpreted as a plain text string.
RichText
          The text string is interpreted as a rich text string using the current Q3StyleSheet::defaultSheet().
 
Method Summary
static Qt.TextFormat resolve(int value)
           
 int value()
          This function should return an integer value for the enum values of the enumeration that implements this interface.
static Qt.TextFormat valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Qt.TextFormat[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

PlainText

public static final Qt.TextFormat PlainText

The text string is interpreted as a plain text string.


RichText

public static final Qt.TextFormat RichText

The text string is interpreted as a rich text string using the current Q3StyleSheet::defaultSheet().


AutoText

public static final Qt.TextFormat AutoText

The text string is interpreted as for Qt::RichText if Qt::mightBeRichText() returns true, otherwise as Qt::PlainText.


LogText

public static final Qt.TextFormat LogText

A special, limited text format which is only used by QTextEdit in an optimized mode.

Method Detail

values

public static final Qt.TextFormat[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(Qt.TextFormat c : Qt.TextFormat.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static Qt.TextFormat valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name

value

public int value()
Description copied from interface: QtEnumerator
This function should return an integer value for the enum values of the enumeration that implements this interface.

Specified by:
value in interface QtEnumerator

resolve

public static Qt.TextFormat resolve(int value)

Qt Jambi Home