IonicWind Software

IWBasic => GUI Central => Topic started by: Jim Scott on March 28, 2007, 05:08:01 PM

Title: Drawing & Printing in a Dialog
Post by: Jim Scott on March 28, 2007, 05:08:01 PM
Maybe this is a lame question.  I seem to be having trouble drawing lines, placing graphics and printing text in dialog window.  Is there some limitation of dialogs, or some SendMessage() command that I need to issue to do these things in a dialog?  I have no trouble in a regular window doing all of the above, but when I take the same code and rewrite for a dialog, the stuff doesn't appear, no errors or anything.

Jim Scott
Title: Re: Drawing & Printing in a Dialog
Post by: Ionic Wind Support Team on March 28, 2007, 05:11:07 PM
Dialogs are not double buffered like standard Emergence windows are.  so you have two choices, draw in response to @IDPAINT, or use a regular captionless window as a child of the dialog for a drawing surface.

Title: Re: Drawing & Printing in a Dialog
Post by: Jim Scott on March 28, 2007, 05:16:52 PM
Is it possible to dock the captionless window child to the dialog itself?  So that it appears to be part of the dialog?  Kind of like a RichEdit control for text, pictures and lines?
Title: Re: Drawing & Printing in a Dialog
Post by: Ionic Wind Support Team on March 28, 2007, 05:21:15 PM
That's why I said a 'captionless' child window.  Without a caption the window will follow the dialog itself.
Title: Re: Drawing & Printing in a Dialog
Post by: Jim Scott on March 28, 2007, 05:29:17 PM
ok, I'll give that a try.  Now on the Redraw on @IDPaint Message.  Still not sure how I refresh the Client area of the Dialog.

Thanks
Title: Re: Drawing & Printing in a Dialog
Post by: Jim Scott on March 28, 2007, 06:09:29 PM
The child window method works just fine, Thanks Paul.

Jim Scott