ooodev.format.writer.modify.para.borders package

Module contents

class ooodev.format.writer.modify.para.borders.Padding(*, left=None, right=None, top=None, bottom=None, all=None, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Bases: ParaStyleBaseMulti

Paragraph Style Padding

New in version 0.9.0.

__init__(*, left=None, right=None, top=None, bottom=None, all=None, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Constructor

Parameters:
  • left (float, UnitT, optional) – Left (in mm units) or Class UnitT.

  • right (float, UnitT, optional) – Right (in mm units) or Class UnitT.

  • top (float, UnitT, optional) – Top (in mm units) or Class UnitT.

  • bottom (float, UnitT, optional) – Bottom (in mm units) or Class UnitT.

  • all (float, UnitT, optional) – Left, right, top, bottom (in mm units) or Class UnitT. If argument is present then left, right, top, and bottom arguments are ignored.

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Return type:

None

classmethod from_style(doc, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Gets instance from Document.

Parameters:
  • doc (Any) – UNO Document Object.

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Returns:

Padding instance from document properties.

Return type:

Padding

property prop_inner: Padding

Gets/Sets Inner Padding instance

Return type:

Padding

property prop_style_name: str

Gets/Sets property Style Name

Return type:

str

class ooodev.format.writer.modify.para.borders.Shadow(*, location=ShadowLocation.BOTTOM_RIGHT, color=8421504, transparent=False, width=1.76, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Bases: ParaStyleBaseMulti

Paragraph Style Shadow

New in version 0.9.0.

__init__(*, location=ShadowLocation.BOTTOM_RIGHT, color=8421504, transparent=False, width=1.76, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Constructor

Parameters:
  • location (ShadowLocation, optional) – contains the location of the shadow. Default to ShadowLocation.BOTTOM_RIGHT.

  • color (Color, optional) – contains the color value of the shadow. Defaults to StandardColor.GRAY.

  • transparent (bool, optional) – Shadow transparency. Defaults to False.

  • width (float, UnitT, optional) – contains the size of the shadow (in mm units) or Class UnitT. Defaults to 1.76.

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Return type:

None

classmethod from_style(doc, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Gets instance from Document.

Parameters:
  • doc (Any) – UNO Document Object.

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Returns:

Shadow instance from document properties.

Return type:

Shadow

property prop_inner: Shadow

Gets/Sets Inner Shadow instance

Return type:

Shadow

property prop_style_name: str

Gets/Sets property Style Name

Return type:

str

class ooodev.format.writer.modify.para.borders.Sides(*, left=None, right=None, top=None, bottom=None, all=None, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Bases: ParaStyleBaseMulti

Paragraph Style Sides (lines)

New in version 0.9.0.

__init__(*, left=None, right=None, top=None, bottom=None, all=None, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Constructor

Parameters:
  • left (Side, optional) – Determines the line style at the left edge.

  • right (Side, optional) – Determines the line style at the right edge.

  • top (Side, optional) – Determines the line style at the top edge.

  • bottom (Side, optional) – Determines the line style at the bottom edge.

  • all (Side, optional) – Determines the line style at the top, bottom, left, right edges. If this argument has a value then arguments top, bottom, left, right are ignored

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Return type:

None

classmethod from_style(doc, style_name=StyleParaKind.STANDARD, style_family='ParagraphStyles')[source]

Gets instance from Document.

Parameters:
  • doc (Any) – UNO Document Object.

  • style_name (StyleParaKind, str, optional) – Specifies the Paragraph Style that instance applies to. Default is Default Paragraph Style.

  • style_family (str, optional) – Style family. Default ParagraphStyles.

Returns:

Sides instance from document properties.

Return type:

Sides

property prop_inner: Sides

Gets/Sets Inner Padding instance

Return type:

Sides

property prop_style_name: str

Gets/Sets property Style Name

Return type:

str