ooodev.format.inner.partial.draw.borders.line_properties module

class ooodev.format.inner.partial.draw.borders.line_properties.LineProperties(factory_name, component, lo_inst=None)[source]

Bases: FactoryNameBase

Class for Line Properties.

Parameters:
  • factory_name (str) –

  • component (Any) –

  • lo_inst (LoInst | None) –

__init__(factory_name, component, lo_inst=None)[source]
Parameters:
  • factory_name (str) –

  • component (Any) –

  • lo_inst (LoInst | None) –

Return type:

None

style(color=0, width=0, transparency=0, style=BorderLineKind.CONTINUOUS)[source]

Style Font.

Parameters:
  • color (Color, optional) – Line Color. Defaults to Color(0).

  • width (float | UnitT, optional) – Line Width (in mm units) or Class UnitT. Defaults to 0.

  • transparency (int | Intensity, optional) – Line transparency from 0 to 100. Defaults to 0.

  • style (BorderLineKind, optional) – Line style. Defaults to BorderLineKind.CONTINUOUS.

Raises:

CancelEventError – If the event before_style_border_line is cancelled and not handled.

Returns:

Font Only instance or None if cancelled.

Return type:

LinePropertiesT | None

Hint

  • BorderLineKind can be imported from ooodev.format.inner.preset.preset_border_line

  • Intensity can be imported from ooodev.utils.data_type.intensity

style_get()[source]

Gets the Style.

Raises:

CancelEventError – If the event is cancelled and not handled.

Returns:

Line style or None if cancelled.

Return type:

LinePropertiesT | None