Re: [gtk-list] Re: Can't refresh drawing area
- From: "Benoit Gagnon" <gagb02 my-deja com>
- To: gtk-list redhat com
- Subject: Re: [gtk-list] Re: Can't refresh drawing area
- Date: Thu, 08 Jul 1999 10:02:51 -0700
On Thu, 08 Jul 1999 09:52:51 Benoit Gagnon wrote:
>On Thu, 8 Jul 1999 11:46:59 Havoc Pennington wrote:
>>
>>On Thu, 8 Jul 1999, wrote:
>>>
>>> I have a drawing area contained in a scroll window. I have a button
>>> that is supposed to change the drawing in the drawing area when it's
>>> pressed. Changing the drawing is not the problem, the problem is that
>>> I have to scroll or make the window bigger to see the changes in the
>>> drawing area. I thought of sending an expose event to the drawing
>>> area, but I haven't been able to. Any ideas?
>>>
>>
>>What does your code do? If it draws to area->window then it should work.
>>If it draws to a pixmap you have to copy the pixmap onscreen.
>>
>I draw onto a pixmap and then I use gdk_draw_pixmap to copy the pixmap to a drawing area. It works whith the first drawing, but not if I change the drawing (as I mentionned, I have to scroll or resize for it to appear on the screen)
>
It finally worked! This is just to serve as future reference if others comme upon a similar problem. I tried using the gtk_widget_queue_resize() function and not only did the drawing area resize correctly, but it refreshed automatically (I did not have to scroll or resize the window).
Hope that this can help others with similar problems.
Thanks for the help
Ben
--== Sent via Deja.com http://www.deja.com/ ==--
Share what you know. Learn what you don't.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]