Skip to content

setPrintWidth not working as expected  #6

Open
@dnyanesh2700

Description

@dnyanesh2700

var escpos = Neodynamic.JSESCPOSBuilder;
var doc = new escpos.Document();
var new_doc = new escpos.Document();
var header = doc

                                                            .align(escpos.TextAlignment.Center)
                                                             . setPrintWidth(48)          
                                                            .image(logo, escpos.BitmapDensity.D24)
                                                            .font(escpos.FontFamily.A)
                                                            .style([escpos.FontStyle.Bold])
                                                            .size(0, 1)
                                                         
                                                            .font(escpos.FontFamily.A)
                                                            .style([escpos.FontStyle.Bold])
                                                            .size(0, 0.5)
                                                            .newLine()
                                                            .cut(partial_feed,partial_cut)
                                                            .generateUInt8Array();
                                                            cpj.binaryPrinterCommands = header;
                                                            cpj.sendToClient();

When I am trying to set width from Script it is getting print as:

image_1

when I am chang width in lib file of JSESCPOSBuilder.js at line 244 it work correctly, but from script not working correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions