Android Question How to print text in graphic mode?

vecino

Well-Known Member
Licensed User
Longtime User
Hi, a customer has some portable bluetooth printers that only print English and Chinese characters.

I need to print these characters:
á é í ó ú Á É Í Ó Ú ñ Ñ ç Ç €

The printers are ESC/POS compatible, but the characters are "cut out" in all the codepages and there are no characters from other languages.

I made a question to the manufacturer and he has indicated that I must use the graphic mode to get these characters to print.
Can anyone explain to me how to do this?
Thank you very much.
 
Last edited:

vecino

Well-Known Member
Licensed User
Longtime User
These are the characters available in text mode:

aToacVA.jpg
 
Upvote 0

vecino

Well-Known Member
Licensed User
Longtime User
I can't do that, what is printed are sales tickets that usually take up quite a lot of space.

FrSBfpF.jpg
 
Upvote 0

TILogistic

Expert
Licensed User
Longtime User
EDIT:
Have you tried printing a PDF with the characters you want?

Note:
to understand how printers work
 
Last edited:
Upvote 0

TILogistic

Expert
Licensed User
Longtime User
EDIT:
Have you tried printing a PDF with the characters you want?

Note:
to understand how printers work
And run a test printing the PDF with this.
 
Upvote 0

vecino

Well-Known Member
Licensed User
Longtime User
What brand and model is it?
Should have check the specs and what character sets are supported before purchase the hardware.
It is a new customer who already has printers and all the hardware. I'm just going to sell him my software.
 
Upvote 0

vecino

Well-Known Member
Licensed User
Longtime User
If I were you, I will suggest him to get another model which support the charset. BT thermal printers aren't expensive.
If I tell the customer that, then he says, "Then your software is too bad, I'll stick with the one I have because the printers work perfectly."
:rolleyes:
 
Upvote 0

vecino

Well-Known Member
Licensed User
Longtime User
The printers do not have these characters, they print in graphic mode.
How do you print in graphic mode? That's what I want to know ;)
 
Upvote 0

aeric

Expert
Licensed User
Longtime User
How do you print in graphic mode?
Have you made a search?
There are many posts using ESC/POS to print image with BT thermal printer.

 
Upvote 0

vecino

Well-Known Member
Licensed User
Longtime User
Have you made a search?
There are many posts using ESC/POS to print image with BT thermal printer.
Yes, the printer works perfectly with my software.
The only problem is that I can't print: Á É Í Ó Ú Ñ €
Because the printer does not have them, they have all been replaced by Chinese characters.
 
Upvote 0

aeric

Expert
Licensed User
Longtime User
Yes, the printer works perfectly with my software.
The only problem is that I can't print: Á É Í Ó Ú Ñ €
Because the printer does not have them, they have all been replaced by Chinese characters.
There is nothing you can do if the printer does not support the charset or encoding. The only way is to print as image.

I would use one (or more) panel(s) as B4XView and load the receipt content to Label which is place inside the B4XView. Label can support these characters. Convert the B4XBitmap to black and white and print to the printer.

B4X:
Dim Panel1 As B4XView
Dim bmp As B4XBitmap = Panel1.Snapshot

or maybe just
B4X:
Dim Label1 As B4XView
Dim bmp As B4XBitmap = Label1.Snapshot
Note: I never tested with Label as B4XView.
 
Last edited:
Upvote 0
Top