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


返回   几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 » 仿射空间:CAX软件开发(三)二次开发与程序设计 » CAD二次开发 » AutoCAD二次开发 » DirectDWG
用户名
密码
注册 帮助 会员 日历 银行 搜索 今日新帖 标记论坛为已读


 
 
主题工具 搜索本主题 显示模式
旧 2009-05-04, 02:55 PM   #1
yang686526
高级会员
 
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
yang686526 向着好的方向发展
默认 【转帖】2.7.1 svg output text with mixed fonts

2.7.1 svg output text with mixed fonts
2.7.1 svg output text with mixed fonts
hi,
i am using dwgdirect 2.7.1 odamfcapp to export the attached drawing to a svg but the output that not export the text correcly.
please see the attached files and compare "text_with_c_degrees_dwg.jpg" => image from odamfcapp 2.7.1.
with "text_with_c_degrees_svg.jpg" => image of intenet explorer svg view
also with "text_with_c_degrees_list.jpg" => from autocad the using the list comand
could you advice on how to export the text to svg (when text has mixed fonts).
the compiler i am using is "microsoft visual c++ 2005".
regards.
luis
attached images
yes, thee seems to be a bug in svg export.
try the attached file - is it displayed correctly?
(i have some trouble with svg viewer curently - it does not display chinese characters at all)
attached files (2.4 kb, 1 views)

vladimir
hi vkalinin,
i have try your test.svg and it displays correctly please see attached "test_svg.jpg" file.
i wonder if it is possible for you to send me the fix so i can implement it.
with regards to your svg viewer problems, in order to display svg files with foreign languages you need to download the appropriate viewer from:
regards,
luis
attached images (47.6 kb, 3 views)

thanks for the info about the viewer - i wonder - why not to make it to support unicode?
about the fix: it will be available with 2.7.2 but i cannot post it, because it is not compatible with 2.7.1
the problem is that one of the header files required to implement the fix was not public in 2.7.1, and w/o it it is impossible to determine correct bigfont code page, to translate mbcs <-> unicode symbols.
(the bug in export was that in shx font embedded in svg glyph indices were corresponding to mbcs characters, not unicode ones, in case of large asian shx'es)
vladimir
thanks vkalinin,
quote:
i wonder - why not to make it to support unicode?
adobe has stopped developing the viewer.
quote:
adobe svg viewer download area
please note that adobe has announced that it will discontinue support for adobe svg viewer on january 1, 2009.
i wonder if you could help me, i would like to create an application based on the oda example singledoc that will export a dwg/dxf file to a svg. but i do not know how to implement:
code:
...
void codamfcappdoc:nexportsvg()
{
odgsmoduleptr pmodule = :drxdynamiclinker()->loadmodule(l"dd_svgexport.drx");
if (pmodule.isnull())
afxmessagebox( _t("dd_svgexport.drx is missing") );
else
{
// svgout command parameters explanation see in \exports\svgexport\source\svgexport.cpp, svgexportcommand::execute()
if (m_pdb->appservices()->getfiledia())
executecommand(l"svgout 1 6 \n\n.png sans-serif 768 1024 yes yes\n");
else
executecommand(l"svgout ~\n1 6 \n\n.png sans-serif 768 1024 yes yes\n");
}
}
...my basic problem is that i do not know how to get a "oddbcommandcontextptr pcmdctx" from the application. this is how is done in odamfcappdoc.
code:
...
void codamfcappdoc::executecommand(const odstring& scmd, bool becho)
{
odsavestate<int> save_m_ncmdactive(m_ncmdactive);
++m_ncmdactive;
oddbcommandcontextptr pcmdctx = cmdctx();
...
oddbcommandcontextptr codamfcappdoc::cmdctx()
{
if(m_pcmdctx.isnull())
{
m_pcmdctx = exdbcommandcontext::createobject(cmdio(), m_pdb);
}
return m_pcmdctx;
}
...
odedbaseio* codamfcappdoc::cmdio()
{
return this;
}any hints or sample code will be very grateful.
once more thanks for your help.
regards,
luis
you don't need command framework to use the export.
look at the implementation of teh svgout command at the bottom of \exports\svgexport\source\svgexport.cpp
vladimir
yang686526离线中   回复时引用此帖
GDT自动化论坛(仅游客可见)
 


主题工具 搜索本主题
搜索本主题:

高级搜索
显示模式

发帖规则
不可以发表新主题
不可以回复主题
不可以上传附件
不可以编辑您的帖子

vB 代码开启
[IMG]代码开启
HTML代码关闭

相似的主题
主题 主题发起者 论坛 回复 最后发表
【转帖】2.7.1 invalid svg output from drawing with te yang686526 DirectDWG 0 2009-05-04 02:55 PM
计算 yang686526 ObjectARX(AutoLISP) 0 2009-04-27 12:23 PM
【转帖】custom properties for multiple part configurations yang686526 SolidWorks二次开发 0 2009-04-13 10:08 AM
【转帖】linked sketch text now possible1 9sort of0 yang686526 SolidWorks二次开发 0 2009-04-12 09:34 PM
Unicode、UCS、UTF、BMP、BOM huangyhg vc编程 2 2007-01-22 05:43 PM


所有的时间均为北京时间。 现在的时间是 02:50 AM.


于2004年创办,几何尺寸与公差论坛"致力于产品几何量公差标准GD&T | GPS研究/CAD设计/CAM加工/CMM测量"。免责声明:论坛严禁发布色情反动言论及有关违反国家法律法规内容!情节严重者提供其IP,并配合相关部门进行严厉查处,若內容有涉及侵权,请立即联系我们QQ:44671734。注:此论坛须管理员验证方可发帖。
沪ICP备06057009号-2
更多