We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When setting other sizes other than 1x1, 1x2, 2x1 or 2x2, text height is always 1, and width whatever you put on it.
I had to add a function on commands.js.. but it works fine and I didn't have to add 64 lines of literals possibilities.
I changed/added on commands.js:
_.TEXT_FORMAT = { ... TXT_OTHER_SIZE : function(width, height){ // other sizes var charsPreSize = '\x1d\x21'; var decWidth = (width - 1) * 16; var decHeight = height - 1; var charPostSize = String.fromCharCode(decWidth+decHeight) return charsPreSize + charPostSize; },
And on printer.js on size function:
Printer.prototype.size = function(width, height) { if (2 >= width && 2 >= height) { ... } else { this.buffer.write(_.TEXT_FORMAT.TXT_OTHER_SIZE(width,height)); }
The text was updated successfully, but these errors were encountered:
I ran into the same issue as the one you described. Thanks for putting up a potential solution. I'll give it a try if I find that I need it. :)
Sorry, something went wrong.
b6ac6b4
Why was this issue closed? I can't see the changes in b6ac6b4, only code formating. I will make a pull request about this so it's easier.
#43
song940
No branches or pull requests
When setting other sizes other than 1x1, 1x2, 2x1 or 2x2, text height is always 1, and width whatever you put on it.
I had to add a function on commands.js.. but it works fine and I didn't have to add 64 lines of literals possibilities.
I changed/added on commands.js:
And on printer.js on size function:
The text was updated successfully, but these errors were encountered: