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

yang686526 2009-05-06 10:05 PM

【转帖】plotsettings paper namesize
 
plotsettings paper name/size
plotsettings paper name/size
i have problems to recognize correct paper in importing/exporting.
oddbplotsettings::canonicalmedianame seems to be different than "paper size:" in "page setup/layout settings dialog" in acad.
is there any way to convert "acad paper name" to the real paper name which is given from printer (through devicecapabilities(..))?
or is there any way to identify paper otherwise?
note!
odamfcapp dont recognize paper either (uses paper name which fails).
hi,
could you describe your situation in more details ? if you have dxf\dwg file with 'bad' plot settings, please, attach it.
ok, lets try again.
- run autocad (my version is 2004)
- make new drawing
- open page setup (modelspace's setup for example)
- select plot device (i have hp deskjet 990c)
- select paper size: a4 (210 x 197 mm)
- save drawing
- open drawing using odamfcapp
- open page setup ( there is wrong paper selected, maybe letter, etc. )
in my tests canonicalmedianame returns simple "a4" when using that "a4 (210 x 197 mm)".
or when using "b5 (182 x 257 mm)" canonicalmedianame returns "b5 (jis)".
atleast these strings are not the same, that are in "paper size:" combo in autocad or odamfcapp.
hi,
it is bug in mfcapp (it is only sample), not in ddt. mfcapp incorrectly proceed with layouts with none_device. you can rewrite code in odamfcappdoc.cpp ( codamfcappdoc::onpagesetup() ).
as example, next code return canonical media name stored in file.
oddbobjectid idlayout = oddbblocktablerecordptr(pdb->getactivelayoutbtrid().safeopenobject())->getlayoutid();
oddblayoutptr playout = idlayout.safeopenobject();
odstring strcanonicalmedianame = playout->getcanonicalmedianame();


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