Struct qt_core::TextFormat
source · pub struct TextFormat(/* private fields */);
Expand description
This enum is used in widgets that can display both plain text and rich text, for example 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 QTextEdit::setTextFormat() function.
C++ enum: Qt::TextFormat
.
This enum is used in widgets that can display both plain text and rich text, for example 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 QTextEdit::setTextFormat() function.
Implementations§
source§impl TextFormat
impl TextFormat
sourcepub const PlainText: TextFormat = _
pub const PlainText: TextFormat = _
The text string is interpreted as a plain text string. (C++ enum variant: PlainText = 0
)
sourcepub const RichText: TextFormat = _
pub const RichText: TextFormat = _
The text string is interpreted as a rich text string. See Supported HTML Subset for the definition of rich text. (C++ enum variant: RichText = 1
)
sourcepub const AutoText: TextFormat = _
pub const AutoText: TextFormat = _
The text string is interpreted as for Qt::RichText if Qt::mightBeRichText() returns true
, otherwise as Qt::PlainText. (C++ enum variant: AutoText = 2
)
sourcepub const MarkdownText: TextFormat = _
pub const MarkdownText: TextFormat = _
The text string is interpreted as Markdown-formatted text. This enum value was added in Qt 5.14. (C++ enum variant: MarkdownText = 3
)
Trait Implementations§
source§impl Clone for TextFormat
impl Clone for TextFormat
source§fn clone(&self) -> TextFormat
fn clone(&self) -> TextFormat
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for TextFormat
impl Debug for TextFormat
source§impl From<TextFormat> for c_int
impl From<TextFormat> for c_int
source§fn from(value: TextFormat) -> Self
fn from(value: TextFormat) -> Self
source§impl From<i32> for TextFormat
impl From<i32> for TextFormat
source§impl PartialEq for TextFormat
impl PartialEq for TextFormat
source§fn eq(&self, other: &TextFormat) -> bool
fn eq(&self, other: &TextFormat) -> bool
self
and other
values to be equal, and is used
by ==
.