Re: [gtk-list] Re: gtk draw shadow ?



gtk_draw_shadow  (preview->style,preview->window,
       GTK_STATE_NORMAL,
       GTK_SHADOW_OUT,0,0,32,32);

You have to send it a window...but the window id of preview
isn't valid yet. preview has to be realized before the window
id is valid, it's NULL until then...thus the error you are seeing.
(The widget id is valid, but a window id hasn't yet been assigned).

(I think the suggestion to add a frame is a good one, since it handles the
outline for you, and stays at the widget level.....)

HTH,
Donna

----- Original Message -----
From: Andreas Scherf <scherfa@fh-trier.de>
To: <gtk-list@redhat.com>
Sent: Thursday, March 16, 2000 5:46 PM
Subject: [gtk-list] Re: gtk draw shadow ?


> On Thu, 16 Mar 2000, Nicolas GEORGE wrote:
>  CRITICAL **: file gtkstyle.c: line 1346 (gtk_default_draw_shadow):
assertion
> `window != NULL' failed. >
> > The gdk_* functions are functions that deal directly with the display.
You
> > must draw the shadow when the widget gets displayed, that is when you
catch
> > expose events. But here, I think you should try to add a gtk_frame
around
> > your event box.
> But this isnīt a gdk_* function it is from gtk_style !! Anybody has an
answr ??
>
> Mfg
>
> Andreas Scherf
>
> scherfa@fh-trier.de
> http://www.fh-trier.de/~scherfa
>
> "It said uses Windows 98 or better, so I loaded Linux!"
>
> --
> To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com <
/dev/null
>
>



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]