6.3. Solution

To solve the barcode quality issue while retainig maximum portability, our Barcode ActiveX aligns all lengths to the edge of pixels. Moreover, the drawings are now in the unit of pixels, instead of any logical units. Doing this ensures you get a quality barcode even on low resolution devices when you are drawing a width at 1-pixel's width level.

However, this approach brings some side effects. Due to the priority to ensure the constant width, the overall length achieved may vary from device to device. You may find that the same barcode prints much bigger or smaller on a thermal printer than on a laser printer. You have to give up the precision to gain the quality. Secondly, the pixel level drawing only happens when ZoomRatio=1.

As you can see from the table, lengths of the barcodes are almost the same on high resolution printers ( 300 dpi and 600 dpi). But on low-resolution printers, it varies greatly, especially on the computer display.

During the rasterization process, the printer driver is consulted to get the best rendition. Text character usually appear bigger than their renditions on laser printers, and some printer models have problem rendering bold fonts. We recommend you do more testing when working on these low-resolution devices, and stick to one configuration which meets the quality and performance.

On low resolution devices, the choices for the actual NarrowBarWidth are limited, especially when we want the barcode as small as possible. The program calculates the NarrowBarWidth based on the resolution of the target device. Although you can specify different values, you may not get different results because the program only draws bars/spaces to the pixel edge. For example, when Barcode ActiveX draws on a computer display, specifying NarrowBarWidth as 8 mils renders the same barcode as with NarrowBarWidth set to 14 mils. Both lengths turn into 1 pixel at the time of rendering.

With the overall barcode length varying from device to device, the overall layout may look different too.