ooodev.format.inner.direct.write.frame.frame_type.position module
Module for Fill Transparency.
New in version 0.9.0.
- class ooodev.format.inner.direct.write.frame.frame_type.position.HoriOrient(value)[source]
Bases:
Enum
Horizontal Orientation
- CENTER = 2
The object is aligned at the middle.
- FROM_LEFT_OR_INSIDE = 0
No hard alignment is applied. When frame is mirrored the value is
From Inside
; Otherwise,From Left
.
- LEFT_OR_INSIDE = 3
The object is aligned at the left side. When frame is mirrored the value is
Inside
; Otherwise,Left
.
- RIGHT_OR_OUTSIDE = 1
The object is aligned at the right side. When frame is mirrored the value is
Outside
; Otherwise,Right
.
- class ooodev.format.inner.direct.write.frame.frame_type.position.Horizontal(position, rel, amount=0.0)[source]
Bases:
object
Horizontal Frame Position. Not used when Anchor is set to
As Character
.- Parameters:
position (HoriOrient) –
rel (RelHoriOrient) –
amount (float | UnitT) –
- __init__(position, rel, amount=0.0)[source]
Constructor
- Parameters:
position (HoriOrient) – Specifies Horizontal Position.
rel (RelHoriOrient) – Specifies Relative Orientation.
amount (float, UnitT, optional) – Specifies Amount in
mm
units or Class UnitT. Only effective when position isHoriOrient.FROM_LEFT
. Defaults to0.0
.
- Return type:
None
- property amount: UnitMM
Gets/Sets Amount in
mm
units. Only effective when position isHoriOrient.FROM_LEFT
.Setting also allows
Unit100MM
instance.- Return type:
- property position: HoriOrient
Gets/Sets Horizontal Position.
- Return type:
- property rel: RelHoriOrient
Gets/Sets Relative Orientation
- Return type:
- class ooodev.format.inner.direct.write.frame.frame_type.position.Position(*, horizontal=None, vertical=None, keep_boundaries=None, mirror_even=None)[source]
Bases:
StyleBase
Fill Transparency
New in version 0.9.0.
- __init__(*, horizontal=None, vertical=None, keep_boundaries=None, mirror_even=None)[source]
Constructor
- Parameters:
horizontal (Horizontal, optional) – Specifies the Horizontal position options. Not used when Anchor is set to
As Character
.vertical (Vertical, optional) – Specifies the Vertical position options.
keep_boundaries (bool, optional) – Specifies keep inside text boundaries.
mirror_even (bool, optional) – Specifies mirror on even pages. Not used when Anchor is set to
As Character
.
- Return type:
None
- copy()[source]
- copy(**kwargs)
- copy(**kwargs)
Gets a copy of instance as a new instance
- Return type:
TypeVar
(_TPosition
, bound= Position)- Parameters:
self (_TPosition) –
- classmethod from_obj(obj)[source]
- classmethod from_obj(obj, **kwargs)
- classmethod from_obj(obj, **kwargs)
Gets instance from object
- Parameters:
obj (object) – UNO Object.
- Returns:
Instance that represents Frame Position.
- Return type:
- property prop_format_kind: FormatKind
Gets the kind of style
- Return type:
- property prop_horizontal: Horizontal | None
Gets/Sets horizontal value
- Return type:
Horizontal | None
- property prop_keep_boundaries: bool | None
Gets/Sets keep inside text boundaries
- Return type:
bool | None
- property prop_mirror_even: bool | None
Gets/Sets Mirror on even pages
- Return type:
bool | None
- class ooodev.format.inner.direct.write.frame.frame_type.position.RelHoriOrient(value)[source]
Bases:
Enum
An enumeration.
- CHARACTER = 2
As character. Only used when Anchor is set
To character
.
- ENTIRE_PAGE = 7
Page includes margins for page-anchored frames identical with
PARAGRAPH_AREA
.
- LEFT_PAGE_BORDER = 3
Inside the left page margin.
- LEFT_PARAGRAPH_BORDER = 5
Inside the left paragraph margin. Only used when Anchor is set
To paragraph
orTo Character
.
- PAGE_TEXT_AREA = 8
Page without borders (for page anchored frames identical with
PARAGRAPH_TEXT_AREA
).
- PARAGRAPH_AREA = 0
Paragraph, including margins. Only used when Anchor is set
To paragraph
orTo Character
.
- PARAGRAPH_TEXT_AREA = 1
Paragraph, without margins. Only used when Anchor is set
To paragraph
orTo Character
.
- RIGHT_PAGE_BORDER = 4
Inside the right page margin
- RIGHT_PARAGRAPH_BORDER = 6
Inside the right paragraph margin. Only used when Anchor is set
To paragraph
orTo Character
.
- class ooodev.format.inner.direct.write.frame.frame_type.position.RelVertOrient(value)[source]
Bases:
Enum
An enumeration.
- CHARACTER = 2
As character. Only used when Anchor is set
To character
.
- ENTIRE_PAGE_OR_ROW = 7
Page includes margins for page-anchored frames identical with
PARAGRAPH_AREA
. Only used when Anchor is setTo page
,To paragraph
,To character
orAs character
.
- LINE_OF_TEXT = 9
at the top of the text line, only sensible for vertical orientation. Only used when Anchor
To character
andVertOrient
isTOP
,BOTTOM
,CENTER
orFROM_TOP_OR_BOTTOM
.
- MARGIN = 0
Paragraph, including margins. Only used when Anchor is set
To paragraph
orTo character
.
- PAGE_TEXT_AREA = 8
Page without borders (for page anchored frames identical with
PARAGRAPH_TEXT_AREA
). Only used when Anchor is setTo page
,To paragraph
orTo character
.
- PARAGRAPH_TEXT_AREA_OR_BASE_LINE = 1
Paragraph, without margins. Only used when Anchor is set
To paragraph
,To character
orAs character
.
- class ooodev.format.inner.direct.write.frame.frame_type.position.VertOrient(value)[source]
Bases:
Enum
Vertical Orientation
- BELOW_CHAR = 6
Aligned at the bottom of a character (anchored to character). Only used when Anchor is set
To character
.
- BOTTOM = 3
Aligned at the bottom
- CENTER = 2
Aligned at the center
- FROM_TOP_OR_BOTTOM = 0
No hard alignment. From Top is only used when Anchor is
To character
. From Bottom is only used when Anchor isTo character
orAs character
.
- TOP = 1
Aligned at the top
- class ooodev.format.inner.direct.write.frame.frame_type.position.Vertical(position, rel, amount=0.0)[source]
Bases:
object
Vertical Frame Position.
- Parameters:
position (VertOrient) –
rel (RelVertOrient) –
amount (float | UnitT) –
- __init__(position, rel, amount=0.0)[source]
Constructor
- Parameters:
position (VertOrient) – Specifies Vertical Position.
rel (RelVertOrient) – Specifies Relative Orientation.
amount (float, UnitT, optional) – Specifies Amount in
mm
units or Class UnitT. Only effective when position isVertOrient.FROM_TOP
. Defaults to0.0
.
- Return type:
None
- property amount: UnitMM
Gets/Sets Amount in
mm
units. Only effective when position isVertOrient.FROM_TOP
.Setting also allows
Unit100MM
instance.- Return type:
- property position: VertOrient
Gets/Sets Vertical Position.
- Return type:
- property rel: RelVertOrient
Gets/Sets Relative Orientation
- Return type: