[maemo-developers] Moving windows in Maemo

From: Eero Tamminen eero.tamminen at nokia.com
Date: Wed Apr 18 12:20:04 EEST 2007

ext Sean Luke wrote:
>> The problem is not widgets telling what is their maximum size
>> (doesn't fit to available space) or minimum size (doesn't show enough
>> useful information to the user), but somehow things deciding
>> what is the the optimum size for them.  Programmer just hard-coding
>> the widget width in pixels is not really a solution.
>> It's not an easy problem to solve.
> So trying to understand what you're going after, I finally made my way
> here, following some transitivity in Murray's pointer:
>     http://live.gnome.org/MathiasHasselmann/NewLayoutManager
> What I gather here is that GTK widgets can't specify maximum size and,

They can.

> more importantly, they can't specify a "preferred" (as in Java) or
> "natural" (as Mathias puts it) size.

How this works in Java?

> Okay, fine.  But this isn't
> because the problem is "hard".  It's because of a significant misfeature
> in GTK.  If widgets were able to specify at least "natural" sizes, the
> problem would essentially go away, would it not?

How widgets could specify a "preferred" size?  Their contents could
be anything.   The above link is about how widget *containers* can
better deduct what would be best size between the minimum and maximum
- minimum is too small for strings that are set as ellipsizable (...)
- maximum can go out of screen

> But to get back on track: this is essentially orthogonal to the issue of
> giving developers the *option* of moving and resizing dialogs.

Developers already have that.  They can (from code) set dialog to
any size and position at any time they want to.

> Indeed
> the problem will show up in fixed-size dialogs as well: just have the
> user change the default system font size.

Yes, things will break because Gtk cannot yet handle well enough content
which is resizable, it will (usually) show such content as too small,
unless a fixed size is used...  So, some of the dialogs in the device
might have fixed sizes (which is a bad thing).

In ideal situation the Gtk containers could size things so that user
doesn't feel the need for resizing.

> So: why are we restricted to
> being unable to make dialogs which can be dragged and resized?  Why
> can't the developer be given the option to handle these corner cases
> himself?

You're asking for an option to set that dialog should be resizable
and movable?  (that's different from what you asked earlier)

Btw. If you want to know more about the standard for application
and window manager communication, see:

	- Eero

More information about the maemo-developers mailing list