ooodev.format.inner.direct.structs.table_border_distances_struct module

class ooodev.format.inner.direct.structs.table_border_distances_struct.TableBorderDistancesStruct(*, left=0.0, right=0.0, top=0.0, bottom=0.0, all=None)[source]

Bases: StructBase

Crop struct.

Any properties starting with prop_ set or get current instance values.

All methods starting with fmt_ can be used to chain together Border Table properties.

New in version 0.9.0.

__init__(*, left=0.0, right=0.0, top=0.0, bottom=0.0, all=None)[source]

Constructor

Parameters:
  • left (float, UnitT, optional) – Specifies left distance in mm units or Class UnitT. Default 0.0.

  • right (float, UnitT, optional) – Specifies right distance in mm units or Class UnitT. Default 0.0.

  • top (float, UnitT, optional) – Specifies top distance in mm units or Class UnitT. Default 0.0.

  • bottom (float, UnitT, optional) – Specifies bottom distance in mm units or Class UnitT. Default 0.0.

  • all (float, UnitT, optional) – Specifies left, right, top, and bottom in mm units or Class UnitT. If set all other parameters are ignored.

Return type:

None

apply(obj: Any)[source]
apply(obj, **kwargs)

Applies tab properties to obj

Parameters:

obj (object) – UNO object.

Return type:

None

fmt_all(value)[source]

Gets copy of instance with left, right, top, bottom set.

Parameters:
  • value (float, UnitT) – Specifies crop in mm units or Class UnitT.

  • self (_TTableBorderDistancesStruct) –

Returns:

Border Table

Return type:

CropStruct

fmt_bottom(value)[source]

Gets a copy of instance with bottom set.

Parameters:
  • value (float, UnitT) – Specifies bottom crop in mm units or Class UnitT.

  • self (_TTableBorderDistancesStruct) –

Return type:

CropStruct

fmt_left(value)[source]

Gets a copy of instance with left set.

Parameters:
  • value (float, UnitT) – Specifies left crop in mm units or Class UnitT.

  • self (_TTableBorderDistancesStruct) –

Return type:

CropStruct

fmt_right(value)[source]

Gets a copy of instance with right set.

Parameters:
  • value (float, UnitT) – Specifies right crop in mm units or Class UnitT.

  • self (_TTableBorderDistancesStruct) –

Return type:

CropStruct

fmt_top(value)[source]

Gets a copy of instance with top set.

Parameters:
  • value (float, UnitT) – Specifies top crop in mm units or Class UnitT.

  • self (_TTableBorderDistancesStruct) –

Return type:

CropStruct

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:

PropertyNotFoundError – If obj does not have required property

Returns:

TableBorderDistancesStruct instance that represents obj crop properties.

Return type:

TableBorderDistancesStruct

classmethod from_uno_struct(value)[source]
classmethod from_uno_struct(value, **kwargs)
classmethod from_uno_struct(value, **kwargs)

Converts a TableBorderDistances instance to a TableBorderDistancesStruct.

Parameters:

value (TableBorderDistances) – UNO TableBorderDistances.

Returns:

TableBorderDistancesStruct set with TableBorderDistances properties.

Return type:

TableBorderDistancesStruct

get_uno_struct()[source]

Gets UNO TableBorderDistances from instance.

Returns:

TableBorderDistances instance

Return type:

TableBorderDistances

property prop_bottom: UnitMM

Gets/Sets bottom value in mm units.

Return type:

UnitMM

property prop_format_kind: FormatKind

Gets the kind of style

Return type:

FormatKind

property prop_left: UnitMM

Gets/Sets left value in mm units.

Return type:

UnitMM

property prop_right: UnitMM

Gets/Sets right value in mm units.

Return type:

UnitMM

property prop_top: UnitMM

Gets/Sets top value in mm units.

Return type:

UnitMM