Re: Question about "getting" font width values for same-font characters
Re: Question about "getting" font width values for same-font characters
- Subject: Re: Question about "getting" font width values for same-font characters
- From: Graff <email@hidden>
- Date: Mon, 09 Feb 2004 01:39:44 -0500
On Feb 9, 2004, at 12:27 AM, steve harley wrote:
on 8 Feb 2004, at 5:52 PM, Graff wrote:
Rather than measuring the length of a list of every character you are
often better off using a real example of text since that will better
mimic the average distribution.
uh, thanks for the thought, but no -- i'm familiar with Lorem ipsum,
and i understand where averages can help, but in the system in
question i need to measure the exact width of any specific piece of
text.. for efficiency, i do have a heuristic that takes a worst case
(assumes that all the characters are capital Ws) and if that fits,
doesn't bother computing each character
Ahh, ok. I saw this line and thought you were using it for getting a
handle on the average width of a font:
set test_char_set to
"abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890
,./;'[]\\`-=<>?:\"{}|~!@#$%^&*()_+ "
If that were the case then the "Lorem ipsem" text would probably be a
better example to use.
- Ken
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.