Charles,

I'm jumping in late in the game, and basing my memory of what you're trying to do on my quick read through of your original message yesterday. If I understand it correctly, you are trying to accurately position some kind of diacritical markings above specific letters in a text field? Let me suggest an alternative that might avoid the cross-platform font metric issues. I did a project similar to this a couple of years ago, in which I needed to position Pinyin tone marks above vowels in romanized Chinese syllables. The tone marks were images. I used the formattedWidth property of the chunk of text up to and including the letter to be marked, then calculated the horizontal distance from the edge of the card to the letter in question and positioned the image there. For example:

|                 _________________
|<- left of card  |chunk in fld    |
|                 |<- left of fld  |
|                 |                |
|                 |                |
|                 _________________|

If I wanted to position the mark over the "u" in "chunk" I would use
the left of fld "myfld" + the formattedWidth of char 1 to 3 of fld "myfld" as the baseline x value, then by trial and error find the proper x and y adjustments to get my image to display at the desired spot.

This method should work regardless of font and size because the formattedWidth takes the current font settings of the chunk into account.

HTH

Devin

Devin Asay
Humanities Technology and Research Support Center
Brigham Young University

_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to