Re: gnome canvas and gtk menu questions



On 23 Jun 2003 08:47:18 BST, Michael Meeks wrote: 
>On Fri, 2003-06-20 at 19:31, John Heidemann wrote:
>> Ok, I suppose.  The original (now deprecated) gtk_window_set_policy()
>> API seems a lot cleaner, though, don't you think?
>
>	No. Having to write thousands of extra lines of code to fit all widgets
>to (somehow) manage to render themselves smaller than their allocation,
>without over-rendering other widgets / looking completely aweful is
>unfeasibly difficult, particularly when compared with just expanding
>from a small requisition.

I think we're speaking past each other.  My original point was that
the manual said "no one needs to do this (allow shrinkable windows)",
my app is a counter example.

I agree with you that widgets shouldn't try to render themselves
smaller than they can.

I wasn't saying they should.  But for my app, the widget CAN make
itself smaller.  Surely, Gtk shouldn't disallow this as an option?

But perhaps a better question is how to allow shrinking some cleaner
way.  Going back, you suggested:

} 	Then simply ensure that your canvas requests a really small size; like
} 2x2 - and you can fiddle with it on 'size_allocate'. It's a bad idea to
} allocate less than the request I'm sure.

I didn't really want to subsclass my own canvas and change its code.
But I found I can force the WM's geometry choice via
gtk_window_set_geometry_hints.
With that, it can shrink and I don't have to use
gtk_window_set_policy().

   -John Heidemann





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