几何尺寸与公差论坛------致力于产品几何量公差标准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)
-   -   【转帖】ext From Oddbtexttextstring90 (http://www.dimcax.com/hust/showthread.php?t=18723)

yang686526 2009-05-07 04:44 PM

【转帖】ext From Oddbtexttextstring90
 
text from oddbtext::textstring()
text from oddbtext::textstring()
i'm using the oddbtext::textstring() to read contents of a text entity and the output is as follows:
\fsimplex.shx;\w0.7000000000;\t1.0000000000;\o\lb2 0
it should be:
b20
what am i doing wrong?
i would try this:
odstring strtipo=pent->isa()->name();
odstring stattribute=oddbattribute::desc()->name();
odstring stacdbattributedefinition=oddbattributedefinition: :desc()->name();
odstring strig;
if (strtipo==stattribute)
{
strig= ((oddbattributedefinitionptr) pent)->tag();
}
else
if (strtipo==stacdbattributedefinition)
{
strig= ((oddbattributedefinitionptr) pent)->tag();
}
else
{
strig=((oddbtextptr) pent)->textstring();
}
are you sure its oddbtext not oddbmtext?
mtext can contain special character sequences switching font, height, color etc.
sergey slezkin


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