× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Buck...
Certainly there is a tipping point as to the effort vs. reward. But, the
printed document is what the customer sees and aesthetics should not be
underestimated. 1/10"? Probably OK. 3/4"? Likely not OK. When I did
the PCL stuff, we needed to right justify some things. Could get it
accurate to the dot level.

Vern...
I had a vague recollection of an API that would retrieve the font widths
also.

PAGSEG may be doable. Only about 6 offices to deal with and I could put a
reference in the Office Master table. The gist of things is to soft code
what is now all hard coded and is an issue due to expansion.

One hurdle would be that a given print run (invoices, etc) encompasses
multiple (or all) offices.

Thanks for the suggestions. Need to read up on PAGSEG.


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Vern Hamberg
Sent: Thursday, September 05, 2013 2:03 PM
To: Midrange Systems Technical Discussion
Subject: Re: Centering with proportional font

I thought there were some kind of width tables on the i - vague memory of
digging around once.

----- Original Message -----
On 9/5/2013 4:28 PM, Roger Harman wrote:
A colleague is asking me how to center a variable length text field on a
form using font 5707. It's an office name and varies during the print run.

I've done this years ago with HP fonts by building a width table and using
absolute positioning with PCL.

That's going to be quite precise. Does your office name need to be centred
to a tenth of an inch? Sometimes it helps to nail down how much effort to
expend...

I've not used AFP much except for drawing forms. How do you deal with
variable or relative text postioning this using AFP and proportional fonts?

A first approximation is to divide the length in half and position that way
via POSITION(). Some names will be more skewed than others. If that's not
good enough, you can always go the route of building a custom width table
and doing that calculation. But with AFP there's a third
way: Make the office name an image file as wide as the paper. Centre the
name within the image and print it at position 1 via PAGSEG. Be advised
that PAGSEG won't rotate, so if the page is rotated you'll need a rotated
image.
--buck
--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe,
or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.

--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx To subscribe, unsubscribe,
or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx Before posting, please take a
moment to review the archives at http://archive.midrange.com/midrange-l.



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.