Page 1 of 1

Posted: 01 Aug 2009, 13:56
by pansoul
Hello

The draw pad example module does not work when i try to print it in the interface builder, do you have the same behaviour ?

I ask this question because i try to create a module with a graphic interface too large for the control panel and in window mode i have some bugs (probably generated during the repaint step perhaps when i move the entire window). so i try to see it in the IB , it doesnot work but i realize that it is the same for draw pad.

Posted: 02 Aug 2009, 11:29
by martignasse
hi pansoul,
The draw pad example module does not work when i try to print it in the interface builder, do you have the same behaviour ?
Very strange, no problems on my side. with release and debug version all is ok in the interface builder.

Are you sure the drawpad sources are not modified ? maybe retry with a fresh sdk download.

are you on Win XP, or Vista ? (i'm on XP)

can you describ the bugs you have ?

Posted: 11 Aug 2009, 15:13
by pansoul
ok i used a modified version of drawpad. it works in IB mode.
About my repaint problem, perhaps it cames from the IsBackGroundBitMapUsed() line but I can't use this method for my module. perhaps an inheritance i didn't implement.
i am on xp. i can't say exactly when the problem occurs (perhaps more frequently when i move the entire window of the module)

Posted: 14 Aug 2009, 18:20
by martignasse
hi pansoul,
About my repaint problem, perhaps it cames from the IsBackGroundBitMapUsed() line but I can't use this method for my module. perhaps an inheritance i didn't implement.
Well, if you haven't access to this method, you have a serious problem.

did you make your module class a child of the TUserModule class ?

Code: Select all

// your module class
class TYourModule : public TUserModule
{
    ...
}
and to acces the IsBackGroundBitMapUsed() methode, you have to do it thru a TYourModule pointer :

Code: Select all

// make convenient pointer to the module
TYourModule * pYourModule  = ((TYourModule *)pModule);

...
pYourModule->IsBackGroundBitMapUsed();
other than that, i don't see.
Maybe you can email me your code (project folder), like that, i can reproduce the problem and help you more efficiently ?

Posted: 17 Aug 2009, 10:11
by pansoul
Yes i created a class TMyModule and called it creating with a pointer.
But impossible to find the problem. So i created another module based on userdrawpad and copy my code into it.
Now it works for the isbackgroundcolor but still have problems.

i need to redimension manualy my panel because if i change this line

pModuleInfo->DefaultWidth = pMasterInfo->PanelWidth;
pModuleInfo->DefaultHeight = DEFAULT_MODULEHEIGHT;

with

pModuleInfo->DefaultWidth = 1000;
pModuleInfo->DefaultHeight = 800;

to have for example a 1000*800 module panel
nothing appears in the IB interface

It also seems that my repaint problem come from the mousemove callback that generate internal error. i erase it because i don't need it but still have repaint problem !

Now my panel redraw only if i change the focus application on my computer and that i come back on usine. My call to repaint seems to be ignore even if i put it in all process loop and if i put my module in window mode my module is redraw when i resize it even if i supress repaint function in resize method.

I feel that when a problem disappears another appears !!

I send you my module by mail
thanks for you help

Edit : What is your mail when i click on your name it's a link to wiki and lsd project and i have no myspace to see your adress.

Posted: 17 Aug 2009, 11:03
by martignasse
you can mail me you"r project code to mfleurent(at)free(dot)fr