Class GenericUnitSize

class ooodev.utils.data_type.generic_unit_size.GenericUnitSize(width, height)[source]

Size Width and Height.

New in version 0.14.0.

__init__(width, height)[source]

Constructor

Parameters:
  • width (UnitT) – Specifies width

  • height (UnitT) – Specifies height

Return type:

None

convert_to(unit_length)[source]

Converts current values to specified unit length.

Parameters:

unit_length (UnitLength) – Unit length to convert to.

Returns:

Converted Units.

Return type:

GenericUnitSize[UnitT, Union[int, float]]

get_size()[source]

Gets instance value as Size

Return type:

GenericSize[TypeVar(TNum, bound= Union[int, float])]

get_uno_size()[source]

Gets current values as Size

Returns:

UNO Size instance

Return type:

Size

property height: _T

Gets/Sets height

Return type:

TypeVar(_T, bound= UnitT)

property width: _T

Gets/Sets width

Return type:

TypeVar(_T, bound= UnitT)