Skip to content

Commit 82f7b10

Browse files
authored
Remove double-offset from prints (#68)
Somewhere in the V2 rewrite I started setting the initial label offsets to the printer's configured offsets, which was causing double offsets for images. I'll need to expand my printed test pattern suite apparently.
1 parent b867857 commit 82f7b10

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "webzlp",
3-
"version": "2.0.2",
3+
"version": "2.0.3",
44
"description": "A small library using WebUSB to print labels on label printers.",
55
"type": "module",
66
"repository": {

src/Commands/TranspileCommand.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ export function getNewTranspileState(config: PrinterConfig): TranspiledDocumentS
4444
left: -1,
4545
top: -1
4646
},
47-
horizontalOffset: config.mediaPrintOriginOffsetDots.left,
48-
verticalOffset: config.mediaPrintOriginOffsetDots.top,
47+
horizontalOffset: 0,
48+
verticalOffset: 0,
4949
lineSpacingDots: 1,
5050
printWidth: config.mediaWidthDots,
5151
margin: {

0 commit comments

Comments
 (0)