• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: width of column id name column
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: width of column id name column


  • Subject: Re: width of column id name column
  • From: Robert Poland <email@hidden>
  • Date: Thu, 23 Jun 2011 06:58:26 -0600

Emmanuel,

set maxName to "christmas_1_2010"
display dialog (measuretext maxName) -- font  {text font:"Arial", text size:40, text spacing:3, line spacing:1.1})

When I run this the result seems to indicate;
text font: 0,0
text size: -5.33447265625
text spacing: 80.4130859375
line spacing: 15.33447265625

While I can believe the line spacing (single line?) the others seem totally bogus.

What am I missing here?

TIA,



Robert Poland - Fort Collins, CO


On Jun 23, 2011, at 3:12 AM, Emmanuel LEVY wrote:

FYI, Smile's "measuretext" command does that:

measuretext "turn left" font {text font:"Arial", text size:40, text spacing:3, line spacing:1.1}
 --  {1.5, -10.0, 160.3984375, 46.0}

Emmanuel


On Jun 23, 2011, at 6:55 AM, Christopher Stone wrote:

On Jun 22, 2011, at 22:40, Robert Poland wrote:
I can find the length of the text in the column id name column but to set it I need this in pixels, not characters.  Since this text is not  fixed width a simple conversion multiplier won't work.

______________________________________________________________________

Hey Bob,

I fooled with that years ago and gave it up as a bad job.

The only way I can think of to manage it is to find out the pixel width of each character in the Finder font and create a conversion table.  You'll either have to measure them yourself or find out which typeface is being used and see if there's an existing chart.

PITA.  :)

I did some looking on the net, and it seems that TCL might have some functions to measure string width in a give font.  TCL is way over my head at the moment though.

--
Best Regards,
Chris

Robert Poland - Fort Collins, CO



 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: width of column id name column
      • From: Shane Stanley <email@hidden>
References: 
 >width of column id name column (From: Robert Poland <email@hidden>)
 >Re: width of column id name column (From: Christopher Stone <email@hidden>)
 >Re: width of column id name column (From: Emmanuel LEVY <email@hidden>)

  • Prev by Date: Tell Acrobat to send doc via email
  • Next by Date: Re: width of column id name column
  • Previous by thread: Re: width of column id name column
  • Next by thread: Re: width of column id name column
  • Index(es):
    • Date
    • Thread