nicolasgargano/elm-escpos/1.1.0

Escpos.Internal

Note: you only need this module if you are writing a custom interpreter for Command.

Custom Types

type Command
= Batch (List Attribute) (List Command)
| Raw (List Int)
| None
| Write String
| Newline
| WriteLine String
| HorizontalTab
| VerticalTab
| Initialize
| Cut

The basic building block.

= TextAttribute TextAttribute
| AlignmentAttribute Alignment
| WhiteOverBlack

Attributes.

= Underline
| Bold
| CharacterSize CharacterSizing

Attributes that can be applied to text.

= Small
| SmallDoubleWidth
| SmallDoubleHeight
| SmallDouble
| Normal
| NormalDoubleWidth
| NormalDoubleHeight
| NormalDouble

Size of the characters.

= Left
| Center
| Right

How text should align. Note that you cannot have multiple alignments within the same line.

Convert

toBytes : Command -> Bytes

Convert a command to a series of bytes.