UniPRT SDK v2.0.0.0
 
Loading...
Searching...
No Matches
LabelMaker.PGL.Text.Text Class Reference

A class representing a text object. More...

Inheritance diagram for LabelMaker.PGL.Text.Text:
LabelMaker.Interfaces.IText.AText LabelMaker.Interfaces.IText.IText LabelMaker.Interfaces.IText.ITextSettings LabelMaker.Interfaces.IFont.IFont LabelMaker.Interfaces.IFont.IFontStyle LabelMaker.Interfaces.IFont.IFontSizeUnits LabelMaker.Interfaces.ISettings.IRotation

Public Member Functions

 __init__ (self, Optional[ITextItem] text=None)
 Initializes a new instance of the Text class.
 
str __str__ (self)
 Returns a string that can be sent to the printer.
 
IFontSize get_font_size_pgl (self, IFontSize font_size, FontSizeUnitsEnum font_units, Optional[IRuler] ruler)
 
- Public Member Functions inherited from LabelMaker.Interfaces.IText.AText
 __init__ (self, Optional[ITextItem] text_item=None)
 Initializes a text object with optional text item.
 
str __str__ (self)
 Returns a string representation of the text object.
 
str to_string_with_print_plane (self, Optional[object] print_plane)
 Converts the text object to a string with an optional print plane.
 
- Public Member Functions inherited from LabelMaker.Interfaces.IText.IText
str __str__ (self)
 

Additional Inherited Members

- Public Attributes inherited from LabelMaker.Interfaces.IText.AText
Optional[IRulerruler = None
 
Optional[str] font_name = None
 
str font_style = FontStyleEnum.NORMAL
 
str font_size_units = FontSizeUnitsEnum.POINTS
 
str alignment = AlignEnum.DEFAULT
 
str rotation = RotateEnum.NONE
 
- Static Public Attributes inherited from LabelMaker.Interfaces.IText.IText
List text [ITextItem]
 

Detailed Description

A class representing a text object.

This class inherits from AText and provides functionality for initializing, configuring, and describing text objects for printing purposes. Text objects can be configured with various font styles, sizes, and alignments.

Constructor & Destructor Documentation

◆ __init__()

LabelMaker.PGL.Text.Text.__init__ ( self,
Optional[ITextItem] text = None )

Initializes a new instance of the Text class.

This constructor sets up a new Text object using the provided list of text items, which use the same text settings.

Parameters
textList of text items that use the same text settings.

Member Function Documentation

◆ __str__()

str LabelMaker.PGL.Text.Text.__str__ ( self)

Returns a string that can be sent to the printer.

This method generates a string representation of the Text instance that is formatted and ready to be sent to a printer. The string includes all the necessary commands and data required for printing.

Returns
A string description of the Text instance.

◆ get_font_size_pgl()

IFontSize LabelMaker.PGL.Text.Text.get_font_size_pgl ( self,
IFontSize font_size,
FontSizeUnitsEnum font_units,
Optional[IRuler] ruler )

The documentation for this class was generated from the following file: