You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm rendering my label in a canvas element. I'm drawing black on white for the label contents.
I'm calling imageToZ64(canvas); to generate the ZPL from my canvas.
What's weird is the ZPL appears to drop all white pixels on the top and left of my canvas, so to get my label to print properly in the center I have to put a black border around the perimeter of the canvas.
Is this expected behavior, or am I doing something wrong?
The text was updated successfully, but these errors were encountered:
Set notrim to true in the options object. If you look at the code, you will see the following callout for the option:
// Create a monochome image, cropped to remove padding.
// The return is a Uint8Array with extra properties width and height.
let mono = monochrome(rgba, width, height, +opts.black || 50, opts.notrim);
I'm rendering my label in a canvas element. I'm drawing black on white for the label contents.
I'm calling
imageToZ64(canvas);
to generate the ZPL from my canvas.What's weird is the ZPL appears to drop all white pixels on the top and left of my canvas, so to get my label to print properly in the center I have to put a black border around the perimeter of the canvas.
Is this expected behavior, or am I doing something wrong?
The text was updated successfully, but these errors were encountered: