Description of a style of Sub Station Alpha (SSA/ASS) subtitles.
More...
|
static quint32 | toRgbColor (const QString &value, quint32 defaultColor=0x00FFFFFF) |
| Interpret a string as an RGB color specification. More...
|
|
Description of a style of Sub Station Alpha (SSA/ASS) subtitles.
◆ QtlSubStationAlphaStyle()
QtlSubStationAlphaStyle::QtlSubStationAlphaStyle |
( |
const QString & |
definition = QString() , |
|
|
const QStringList & |
format = QStringList() |
|
) |
| |
Constructor.
- Parameters
-
[in] | definition | Definition the style as in a "Style:" line in a SSA/ASS file. |
[in] | format | List of style fields, as in a "Format:" line, with normalized names. |
◆ name()
QString QtlSubStationAlphaStyle::name |
( |
| ) |
const |
|
inline |
Get the style name.
- Returns
- The style name.
◆ isBold()
bool QtlSubStationAlphaStyle::isBold |
( |
| ) |
const |
|
inline |
Check if the style is bold.
- Returns
- True if the style is bold.
◆ isItalic()
bool QtlSubStationAlphaStyle::isItalic |
( |
| ) |
const |
|
inline |
Check if the style is italic.
- Returns
- True if the style is italic.
◆ isUnderline()
bool QtlSubStationAlphaStyle::isUnderline |
( |
| ) |
const |
|
inline |
Check if the style is underline.
- Returns
- True if the style is underline.
◆ color()
quint32 QtlSubStationAlphaStyle::color |
( |
| ) |
const |
|
inline |
Get the font color in RGB format.
- Returns
- The font color in RGB format.
◆ getInfo()
QString QtlSubStationAlphaStyle::getInfo |
( |
const QString & |
name, |
|
|
const QString & |
defaultValue = QString() |
|
) |
| const |
Get one field of the style.
- Parameters
-
[in] | name | Field name, as specified in the "Format:" line. |
[in] | defaultValue | Default value if the field is not found. |
- Returns
- The field value as a string.
◆ toRgbColor()
quint32 QtlSubStationAlphaStyle::toRgbColor |
( |
const QString & |
value, |
|
|
quint32 |
defaultColor = 0x00FFFFFF |
|
) |
| |
|
static |
Interpret a string as an RGB color specification.
- Parameters
-
[in] | value | A string value, typically a field of the style. |
[in] | defaultColor | The default color if value is incorrect, white by default. |
- Returns
- The color specification.
◆ _name
QString QtlSubStationAlphaStyle::_name |
|
private |
◆ _isBold
bool QtlSubStationAlphaStyle::_isBold |
|
private |
◆ _isItalic
bool QtlSubStationAlphaStyle::_isItalic |
|
private |
◆ _isUnderline
bool QtlSubStationAlphaStyle::_isUnderline |
|
private |
◆ _color
quint32 QtlSubStationAlphaStyle::_color |
|
private |
◆ _info
QMap<QString,QString> QtlSubStationAlphaStyle::_info |
|
private |
Map of style info, using normalized type names as keys.
The documentation for this class was generated from the following files: