Skip to content
New issue

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

not support Thai language #104

Open
SatanCros opened this issue Nov 5, 2022 · 2 comments
Open

not support Thai language #104

SatanCros opened this issue Nov 5, 2022 · 2 comments

Comments

@SatanCros
Copy link

SatanCros commented Nov 5, 2022

I'm try

printables.add(TextPrintable.Builder()
.setText("สวัสดี ร้านแก๊ส World 1")
.setAlignment(DefaultPrinter.ALIGNMENT_CENTER)
.setEmphasizedMode(DefaultPrinter.EMPHASIZED_MODE_BOLD)
.setFontSize(DefaultPrinter.FONT_SIZE_NORMAL)
.setUnderlined(DefaultPrinter.UNDERLINED_MODE_ON)
.setCharacterCode(DefaultPrinter.CHARCODE_THAI16) // try everything
.setLineSpacing(DefaultPrinter.LINE_SPACING_60)
.setNewLinesAfter(1)
.build())

val CHARCODE_THAI42: Byte = 0x15 // Thai character code 42
val CHARCODE_THAI11: Byte = 0x16 // Thai character code 11
val CHARCODE_THAI13: Byte = 0x17 // Thai character code 13
val CHARCODE_THAI14: Byte = 0x18// Thai character code 14
val CHARCODE_THAI16: Byte = 0x19// Thai character code 16
val CHARCODE_THAI17: Byte = 0x1a // Thai character code 17
val CHARCODE_THAI18: Byte = 0x1b // Thai character code 18

but English is work

@SatanCros
Copy link
Author

use printer : Xprinter - XP-P101

@setifa
Copy link

setifa commented Feb 28, 2023

best thing is working whith images ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants