ooodev.format.inner.direct.calc.alignment.properties module
- class ooodev.format.inner.direct.calc.alignment.properties.Properties(*, wrap_auto=None, hyphen_active=None, shrink_to_fit=None, direction=None)[source]
Bases:
StyleBase
Text Properties
See also
New in version 0.9.0.
- __init__(*, wrap_auto=None, hyphen_active=None, shrink_to_fit=None, direction=None)[source]
Constructor
- Parameters:
wrap_auto (bool, optional) – Specifies wrap text automatically.
hyphen_active (bool, optional) – Specifies hyphenation active.
shrink_to_fit (bool, optional) – Specifies if text will shrink to cell.
direction (TextDirectionKind, optional) – Specifies Text Direction.
- Return type:
None
Note
When
wrap_auto
isTrue
shrink_to_fit
is not used.See also
- classmethod from_obj(obj)[source]
- classmethod from_obj(obj, **kwargs)
- classmethod from_obj(obj, **kwargs)
Gets instance from object
- Parameters:
obj (object) – UNO Object.
- Raises:
NotSupportedError – If
obj
is not supported.- Returns:
Instance that represents text property options.
- Return type:
- property prop_direction: TextDirectionKind | None
Gets/Sets Text Direction Kind.
- Return type:
TextDirectionKind | None
- property prop_format_kind: FormatKind
Gets the kind of style
- Return type:
- property prop_hyphen_active: bool | None
Gets/Sets If text is hyphenation is active.
- Return type:
bool | None
- property prop_shrink_to_fit: bool | None
Gets/Sets If text shrinks to cell size.
- Return type:
bool | None
- property prop_wrap_auto: bool | None
Gets/Sets If text is wrapped automatically.
- Return type:
bool | None
- class ooodev.format.inner.direct.calc.alignment.properties.TextDirectionKind(value)[source]
Bases:
Enum
Describes different writing directions
- LR_TB = 0
Left-to-right (LTR)
Text within lines is written left-to-right. Lines and blocks are placed top-to-bottom. Typically, this is the writing mode for normal
alphabetic
text.
- PAGE = 4
Use super-ordinate object settings
Obtain writing mode from the current page. May not be used in page styles.
- RL_TB = 1
Right-to-left (RTL).
text within a line are written right-to-left. Lines and blocks are placed top-to-bottom. Typically, this writing mode is used in Arabic and Hebrew text.