Uses of Class
io.github.chkrishnatej.rp3200.EscPosBuilder
Packages that use EscPosBuilder
Package
Description
Receipt printing for the TVS RP 3200 Lite (and other ESC/POS thermal printers) from a Java
server - typically a Spring Boot web application.
Text templates for receipts:
{{placeholders}} for data plus [markup] for
formatting, compiled once and rendered to ESC/POS bytes.-
Uses of EscPosBuilder in io.github.chkrishnatej.rp3200
Methods in io.github.chkrishnatej.rp3200 that return EscPosBuilderModifier and TypeMethodDescriptionSets the alignment for this and all following lines.Prints a CODE128 barcode at the default height (80 dots) with the text below it.Prints a CODE128 barcode (the most compact 1D code for bill numbers) at the current alignment, with the human-readable text below it.EscPosBuilder.bold(boolean on) Switches bold (emphasised) printing on or off for the following text.EscPosBuilder.center()Shortcut foralign(Align.CENTER).EscPosBuilder.cut()Feeds the paper up to the cutter and makes a full cut.EscPosBuilder.feed(int lines) Feeds blank lines.EscPosBuilder.invert(boolean on) Switches reverse printing (white text on a black background) on or off.EscPosBuilder.left()Shortcut foralign(Align.LEFT).Prints text in the current style and ends the line.EscPosBuilder.newline()Ends the current line (LF).EscPosBuilder.openDrawer()Opens the cash drawer connected to the printer's RJ11 port, using pin 2 (the usual wiring).EscPosBuilder.openDrawer(int pin) Opens the cash drawer using connector pin 2 or pin 5.EscPosBuilder.partialCut()Feeds the paper up to the cutter and makes a partial cut: the receipt stays attached by a small hinge and is torn off by hand.Prints a QR code with the default module size (6) at the current alignment.Prints a QR code (model 2, error correction level M) at the current alignment.EscPosBuilder.raw(byte... bytes) Appends bytes exactly as given, for printer features this builder does not cover.EscPosBuilder.resetStyle()Returns to plain, normal-size text.EscPosBuilder.right()Shortcut foralign(Align.RIGHT).Prints one table row using the current style.EscPosBuilder.row(Columns columns, List<List<Style.Segment>> cells) Likerow(Columns, String...), but each cell is a list of styled segments, so a cell can mix styles - e.g. a bold total next to a normal label.EscPosBuilder.separator()Prints a full-width line of dashes in the current style.EscPosBuilder.separator(char c) Prints a full-width line of the given character, e.g.Sets the character size for the following text.Sets bold, underline, invert and size in one call.Prints text in the current style without ending the line.EscPosBuilder.underline(boolean on) Switches underlining on or off for the following text. -
Uses of EscPosBuilder in io.github.chkrishnatej.rp3200.template
Methods in io.github.chkrishnatej.rp3200.template that return EscPosBuilderModifier and TypeMethodDescriptionReceiptTemplate.renderInto(EscPosBuilder builder, Object data) Appends this template to an existing builder, so templates and Java code can be mixed:Methods in io.github.chkrishnatej.rp3200.template with parameters of type EscPosBuilderModifier and TypeMethodDescriptionReceiptTemplate.renderInto(EscPosBuilder builder, Object data) Appends this template to an existing builder, so templates and Java code can be mixed: