SerialFrame#

class SerialFrame[source]#

Bases: ContainerFrame

Container class to group other frames vertically or horizontally This is a frame container for a series of frames that will be printed one after the other.

__init__(parent: ContainerFrame = None, direction: Direction = Direction.VERTICAL, margin_bottom: float = 0.0, margin_right: float = 0.0, margin_top: float = 0.0, margin_left: float = 0.0, use_full_width: bool = False, frame_id: str = '')[source]#

Creates a new container for horizontally or vertically grouped frames

Parameters:
  • parent – Parent frame to which this frame will be added

  • direction – One of the Direction enums

  • margin_bottom – Bottom margin (inherited from ReportFrame)

  • margin_right – Right margin (inherited from ReportFrame)

  • margin_top – top margin (inherited from ReportFrame)

  • margin_left – left margin (inherited from ReportFrame)

  • use_full_width – flag if the full width will be used (inherited from ReportFrame)

  • frame_id – frame id (optional)

property margin_bottom: float#

Bottom margin in the frame

Getter:

Returns the bottom margin

Setter:

Sets the bottom margin

property margin_right: float#

Right margin in the frame

Getter:

Returns the right margin

Setter:

Sets the right margin

property margin_left: float#

Left margin in the frame

Getter:

Returns the left margin

Setter:

Sets the left margin

property margin_top: float#

Top margin in the frame

Getter:

Returns the top margin

Setter:

Sets the top margin

property use_full_width: bool#

Flag if the frame shall use the full possible width for the frame

Getter:

Returns the flag

Setter:

Sets the flag

property direction: Direction#

Direction of the frame

Getter:

Returns the direction

Setter:

Sets the direction

to_dict(data: dict, frame: dict)[source]#

Fills the attribute-values to a dictionary if the attribute has no default value. :param data: global dict for the whole report :param frame: dict for the frame

property frame_id: str#

The frame id

Getter:

Returns the frame id

Setter:

Sets the frame id

from_dict(frame: dict)[source]#

Fills the attributes based on the given dict :param frame:

property h_align: HAlign#

Horizontal alignment of the frame

Getter:

Returns the horizontal alignment of the frame

Setter:

Sets the horizontal alignment of the frame

property keep_together: bool#

Flag if the frame shall be kept together on one page

Getter:

Returns the flag

Setter:

Sets the flag

property max_height: float#

Maximal height for the frame

Getter:

Returns the maximal height

Setter:

Sets the maximal height

property max_width: float#

Maximal width for the frame

Getter:

Returns the maximal width

Setter:

Sets the maximal width

property parent_frame#

The parent frame

Getter:

Returns the parent frame

Setter:

Sets the parent frame

set_margin(margin: float)#

Sets the margin on all four sides to the given value

Parameters:

margin – Margin in mm

property use_full_height: bool#

Flag if the frame shall use the full possible height for the frame

Getter:

Returns the flag

Setter:

Sets the flag

property v_align: VAlign#

Vertical alignment of the frame

Getter:

Returns the vertical alignment of the frame

Setter:

Sets the vertical alignment of the frame