高级会员
注册日期: 06-11
帖子: 14579
精华: 1
现金: 224494 标准币
资产: 234494 标准币
|
【转帖】odamfcapp and library ctb problem
odamfcapp and library ctb problem
odamfcapp and library ctb problem
hi,
1. i can't make odamfcapp (1.14.02 nor 2.2) use ctb files.
in 1.14.02 i don't see any option regarding ctb.
in 2.2 i open the file, use file->plot style manager and run vectorization. the drawing looks like without ctb use.
2. i use version 1.14.02 of the library in my application. the colors after use ctb are different than color without ctb, but they are different also than colors in acad with ctb.
is this a bug?
regards,
michal sliwka
attached files
in odamfcapp 2.2:
open the dwg file.
view/set active layout - choose one of ps layouts.
file/page setup - set plot style table to your .ctb file and be sure to check "display plot styles" checkbox.
vectorize
the drawing is displayed with plot styles.
note:
the .ctb file should be accessible via paths specified in ddplotstylepaths environment variable.
in model layout "display plot styles" checkbox is off and disabled so plot styles are not used.
sergey slezkin
in 1.14.02 there's no such option in page setup.
in 2.20:
- the '...' button for plot style table do not work.
- when i paste/write full path path to ctb combo, it's truncated to some number of characters.
- when i write only 100006.ctb and click display plot styles check box, 100006.ctb changes to 'none', so i write again 100006.ctb and click ok.
after vectorize, ctb is not used. when i open page setup again, it's "none" again, not 100006.ctb.
so, i still can't use ctb in odamfcapp to check if i make a mistake in my app (ctb is used, but colors are bad.) could you check please if ctb gives the same effect on files attached in my previos message ad in acad? (attached also pdf from acad)
thanks,
michal sliwka
as i wrote in previous post to have it working in odamfcapp
the .ctb file should be accessible via paths specified in ddplotstylepaths environment variable.
sergey slezkin
unfortunately it still does not work even after restarting system with set env. variables. i've tried directory path and path with ctb file name.
thanks,
michal sliwka
plotsettingsvalidator used in odamfcapp is available with sources.
try to look at and/or set breakpoint in odplotsettingsvalidatorpeimpl::getplotstylesheetli st() at the end of plotsettingsvalidatorpeimpl.cpp
btw, odamfcapp initializes this variable in
void codamfcappapp::initplotstylesheetenv()
at the end of odamfcapp.cpp
it sets it to autocad's folder found in registry.
this will not work without autocad on computer.
sergey slezkin
ok, i'm able to select my ctb from combo now. but the drawing (in paper space) still looks like without ctb using.
i do have plotsettingsvalidator_2.02_7.drx and plotstyleservices_2.02_7.drx in my app dir.
thanks for any help,
michal sliwka
and what about "display plot styles" checkbox?
sergey slezkin
quote:
originally posted by sergey slezkin
and what about "display plot styles" checkbox?
it's checked.
have you got any idea how to make ctb working in odamfcapp? or maybe any simpler example? i have a lot of ctb files, which are used wrong in my app and i'm wondering is it opendwg or our problem. i need odamfcapp ctb to check it.
thanks,
micha? ?liwka
hi,
i just test mfcapp 2.2. i works fine witn ctb.
please try - open file with filled paper space. change active layout to paper space. open pagesetup dialog. change printer device to my printer, select grayscale.ctb. enable display plot styles. click ok. vectorize it -> all are in grey.
what is your results?
no ctb using. i don't have autocad on machine, but i've set ddplotstylepaths to folder containing .ctb files and combo in pagesetup dialog is filled. i perform steps you suggest and the result is no ctb is used.
did you change codamfcappapp::findfile also ?
if ( ext == l".stb" || ext == l".ctb")
return findconfigfile( l"printerstylesheetdir", file, pss );
plotstylelist is filled by files from ddplotstylepaths folder, but ctb file loading search it via codamfcappapp::findfile.
last edited by sslezkin; 16th march 2007 at 07:32 amfff">.
ok, i've got it now, thanks.
in odamfxapp using ctb in modelspace is disabled. does it mean that in my app ctb files may work bad in modelspace? i use it in modelspace and get strange behaviour.
regards,
micha? ?liwka
there is no paper in model space, so lineweight parameter has different implementation from paper space. colors should work normally.
|