A class representing a label for TSPL. More...
#include <Label.h>
Instance Methods | |
(instancetype) | - initWithName: |
Initializes a new instance of the Label class with the specified name. | |
(void) | - addObject: |
Adds an object that can be converted to printer language syntax to the label. | |
(void) | - addRawContent: |
Adds raw content to the label for cases where custom content needs to be added. | |
(NSString *) | - description |
Returns a string that can be sent to the printer. | |
(void) | - SetName: |
Sets the name of the label. | |
Properties | |
TsplForm * | form |
The form associated with the label. | |
Scale * | scale |
The scale associated with the label. | |
NSString * | name |
The name of the label. | |
![]() | |
NSString * | name |
Name of label that may be used to identify it from other labels. | |
A class representing a label for TSPL.
This class implements the ILabel protocol and provides functionality for initializing, adding objects and raw content, and describing labels in TSPL.
- (void) addObject: | (id) | addObject |
Adds an object that can be converted to printer language syntax to the label.
addObject | The object to be added to the label. |
Reimplemented from <ILabel>.
- (void) addRawContent: | (NSString *) | rawContent |
Adds raw content to the label for cases where custom content needs to be added.
Adding raw content allows the addition of printer language commands or other features that may not be available. No formatting of the content is done; the caller is responsible for making sure the content follows printer language syntax.
rawContent | The raw content to be added to the label. |
Reimplemented from <ILabel>.
- (NSString *) description |
Returns a string that can be sent to the printer.
This method generates a string representation of the Label instance that is formatted and ready to be sent to a printer. The string includes all the necessary commands and data required for printing in TSPL.
Reimplemented from <ILabel>.
- (instancetype) initWithName: | (NSString *) | name |
- (void) SetName: | (NSString *) | name |
Sets the name of the label.
name | The new name for the label. |
|
readwritenonatomicstrong |
The form associated with the label.
|
readwritenonatomicstrong |
The name of the label.
|
readwritenonatomicstrong |
The scale associated with the label.