×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

How to print > 80 characters in one line

How to print > 80 characters in one line

How to print > 80 characters in one line

(OP)
I'm printing a file that has more than 80 characters in one line. I find only first 80 printed. Which PCL commands can help?

RE: How to print > 80 characters in one line

You will have to use a smaller font or print in landscape orientation. I assume that you are probably ptinting a courier 10 pitch font. Your maximum printing width is eight inches on letter size so that translates to 80 char at 10 cpi. If you change to 12 cpi, your pagewidth is increased to 96 characters.

The PCL command for 12 cpi is <esc>(s12H

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

(OP)
Thanks, Jim!

I found I actually have same problem as Robert did. I need to change right margin from 1/4" to 1/8". I cannot change font(it must be Courier 12).

I have tried to use Ec&a134M and it does not work.

Any suggestions?

Gene

RE: How to print > 80 characters in one line

There is a way that you can cheat it a little bit, but it requires that you insert some PCL code into the middle of every line the you want expanded. It's only going to yield one more character at 12 cpi. You can effectively gain about 15 dots(at 300dpi) on each side by manipulating the sheet offset. You are in trouble if you are duplexing. This only applies to a LaserJet. Not to DeskJets.

Does your application have the ability to insert the codes?

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

(OP)
Thanks, Jim!

1. We are gernating PCLs from Java. No problem to insert code.

2. Please tell me how.

Gene

RE: How to print > 80 characters in one line

Insert at the beginning of every line

             <esc>&l-65U

Insert in the middle of every line

              <esc>&l65U<esc>&a-130H

On my LJ5000 I get 98 characters at 12 cpi

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

(OP)
Hi Jim,

1. Your solution works!

2. I have a PCL file (generated by print to file) that has correct right and left margin (both of them are 1/5"). This file only needs set up Esc at the begining, but the vertical space is not correct. You may take a look PCL command so that we can have a clean solution (instead of inserting command every line). Here is the code:

E*t600R&u600D*r0F&l0o1E&l0S&l7H&l2a8c1E*p0x0Y*c0t5760x7704Y&l1X*b0M
(19U(s4099t0b0s10h0P&d@*v0o0T*p20Y

Thanks!

Gene

RE: How to print > 80 characters in one line

Gene,

I don't believe there is any alternative but to put the commands that I gave you on every line.

In your code the line spacing is set to 6 lpi.

What did you want instead?

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

(OP)
Jim,

The truth is I got same result (from left and right margin point of view) with the code above as with the code you provides. What is the default line space? Could you change above code so that line space = default? Then we may get a cleaner solution. By the way, which part tells us line space is 6 lpi?

Gene

RE: How to print > 80 characters in one line

In the code you posted, the part that is ...&l2a8c1E

the 8c bit is the line spacing; i.e., 8/48ths of an inch or 6 lpi.

The font is set to 10 picth. I am very doubtful that the setup that you posted is can produce a text width as great as you by inserting the codes on every line.

Use the setup you have, goto 12 ptich and see how many characters you can get on the full line. Now if your original problem could be resolved with a narrower right margin gained by a fatter left margin, then <esc>&l65U at the beginning of file would probably fix you up.

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

(OP)
Jim,

Now I got another problem. When I print my PCL files to D640, I found my font setting does not apply to text after

<esc>&l65U<esc>&a-130H

Any idea?

Thanks!

Gene

RE: How to print > 80 characters in one line

What is D640? An inkjet printer?

The sheet offset command, <esc>&l65U, AFAIK only applies to PCL5 printers. The <esc>&a130H is purely a positioning code so neither affect your fonts.

Jim Asman
jlasman@telus.net

RE: How to print > 80 characters in one line

gweng,
I am looking to print pcl files from java.  Would you be willing to post some code on how you did this?

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close