Is it possible to show the barcode text under the barcode?

392 views
Skip to first unread message

Doug

unread,
Jul 21, 2009, 4:43:08 PM7/21/09
to Barby
Hi,

I'm printing barcodes using the png_outputter. Is there a parameter
to enable printing of the barcode as text under the barcode itself,
preferably centred?

TIA

Doug

aslak hellesoy

unread,
Jul 21, 2009, 5:03:24 PM7/21/09
to ruby-...@googlegroups.com

Barby uses the png gem to generate png barcodes. Version 1.2.0 of the png gem has basic support for small, ugly fonts, but barby doesn't use this (yet).

Aslak


TIA

Doug


Tore Darell

unread,
Jul 22, 2009, 12:49:00 PM7/22/09
to Barby
There's also an RmagickOutputter which can generate PNGs; this
outputter can also create Magick::Image objects, which can be altered
before creating PNGs. I.e. you could create the Image objects, add the
text and then generate the PNGs.

Barby probably won't ever support adding text like this automatically
though, as that's outside of Barby's scope and (IMO) not a good idea
as it would add unnecessary complexity. Most of the time, barcodes
will be included in a format such as a PDF or a HTML document which is
already much more capable of containing text. This has the added
benefit that the text can be treated as such so you can e.g. copy and
paste it..

Tore


> Aslak
>
> > TIA
>
> > Doug
>
>
Reply all
Reply to author
Forward
0 new messages