Ask the Expert

Font alignment trouble

I'm having trouble getting the fonts to align correctly on my report. I'm printing on a Dot-Matrix printer (Epson LX-300). I have three columns in the report to be printed on a pre-printed form. For instance, I have three rows to be printed; the second row is not aligned as the first one. Instead, the second row's column two starting position is pushed by one font space. The third row, is aligned properly, i.e., it follows the first row alignment. However, when I display the spool, all of the three rows are aligned correctly. This doesn't happen when I use the laser printer.

When you display a spooled file, it always displays it in fixed-font format. The font you are using is a positional-spacing font. Using a fixed font means that every character is the same width. When you use a positional-spacing font, the position on the form is determined by the characters that were used prior to the column you are currently trying to print. I would suggest you go to a fixed-font.

==================================
MORE INFORMATION ON THIS TOPIC
==================================

The Best Web Links: tips, tutorials and more.

Ask your programming questions--or help out your peers by answering them--in our live discussion forums.

Ask the Experts yourself: Our application development gurus are waiting to answer your programming questions.


This was first published in July 2003

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: