FontLab Forum
2012-02-08, 19:42:53 *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: Welcome to the FontLab forum, read how to use it! Update: Archives from old MSN forums are now available on our forum.
 
   Home   Help Search Calendar Downloads Tags Login Register  
Del.icio.us Digg FURL FaceBook Stumble Upon Reddit SlashDot

Pages: [1]
  Print  
Author Topic: Bug in TTH object?  (Read 1499 times)
Eigi
Beta: FontLab Studio Mac
Hero Member
***

Karma: +7/-0
Germany Germany

Posts: 55



WWW
« on: 2010-05-19, 04:21:44 »

Hello,

I try to figure out the position of a node in a hinted truetype outline at a specific ppm size.
I use the following code:
Code:

nodeIndex = 15    # top left corner
ppmRange = range(15, 30)
tth = TTH(fl.glyph, fl.font)
tth.LoadProgram()
for ppm in ppmRange:
tth.SetPPM(ppm)
tth.RunProgram()
print 'ppm = %s, height = %4s' % (ppm, tth.outline[nodeIndex].y)


This works fine, except when it returns wrong values.

As you can see in the attached screenshot.

For a ppm size of 23 the script calculates a y-value of 12 for node 0 (top left corner). But in the glyph window the y-position of this node is 11.
Is there something wrong with my script or is this a bug in FontLabs TTH object?

If you want to reproduce the problem, you may use the vfb file in the attached zip.

Regards
Eigi
« Last Edit: 2010-05-19, 04:24:24 by Eigi » Logged
Tags:
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!