Paper Office
paper-pptxAPI referenceenum.text

MSO_VERTICAL_ANCHOR

paper-pptx 0.2.0 API reference

Specifies the vertical alignment of text in a text frame.

Used with the .vertical_anchor property of the TextFrame object. Note that the vertical_anchor property can also have the value None, indicating there is no directly specified vertical anchor setting and its effective value is inherited from its placeholder if it has one or from the theme. None may also be assigned to remove an explicitly specified vertical anchor setting.

MS API Name: MsoVerticalAnchor

http://msdn.microsoft.com/en-us/library/office/ff865255.aspx

Attributes

BOTTOM

attributeBOTTOM
= (4, 'b', 'Aligns text to bottom of text frame')

Aligns text to bottom of text frame

MIDDLE

attributeMIDDLE
= (3, 'ctr', 'Centers text vertically')

Centers text vertically

MIXED

attributeMIXED
= (-2, '', 'Return value only; indicates a combination of the other states.')

Return value only; indicates a combination of the other states.

TOP

attributeTOP
= (1, 't', 'Aligns text to top of text frame')

Aligns text to top of text frame

xml_value

attributexml_valuestr | None

Functions

from_xml

funcfrom_xml(xml_value: str) -> Self

Enumeration member corresponding to XML attribute value xml_value.

Raises ValueError if xml_value is the empty string ("") or is not an XML attribute value registered on the enumeration. Note that enum members that do not correspond to one of the defined values for an XML attribute have xml_value == "". These "return-value only" members cannot be automatically mapped from an XML attribute value and must be selected explicitly by code, based on the appropriate conditions.

Example::

WD_PARAGRAPH_ALIGNMENT.from_xml("center") WD_PARAGRAPH_ALIGNMENT.CENTER

paramxml_valuestr

Returns

typing_extensions.Self

to_xml

functo_xml(value: int | _T) -> str

XML value of this enum member, generally an XML attribute value.

paramvalueint | _T

Returns

str

validate

funcvalidate(value: _T)

Raise ValueError if value is not an assignable value.

paramvalue_T

On this page