几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   DirectDWG (http://www.dimcax.com/hust/forumdisplay.php?f=89)
-   -   【转帖】oddbtext attributes (http://www.dimcax.com/hust/showthread.php?t=17619)

yang686526 2009-05-06 08:16 PM

【转帖】oddbtext attributes
 
oddbtext attributes.
oddbtext attributes.
hello:
i磎 writing a dwg file that is intended to represent exactly a gdi drawing.
i磛e met no problem until i磎 writing text entities.
this is an old problem to me, the problem to know the exact size of a given windows font.
the gdi text formatting functions consider that the characters are into a "text cell", with a bunch of attributes that vary from one font type to another and make very difficult to establish a method of write the text strings as oddbtext entities.
i use the text height in order to obtain the text position.
one thing i'd like to know is: 縲hat does the value height i pass to oddbtext::setheight(height) represent, just the "text height", or the text height plus any kind of internal or external leading?
can you give me an advice in order to make an acceptable translation of text entities from gdi to dwg using dwgdirect?.
thanks.

in autocad text height is the height of "a" character (0x41).
sergey slezkin


所有的时间均为北京时间。 现在的时间是 11:05 PM.