[Gambas-devel] gb3, qt4 Windows

Kadaitcha Man nospam.nospam.nospam at ...176...
Wed Dec 30 23:38:05 CET 2009


2009/12/30 Benoît Minisini <gambas at ...1...>:
>> Gentlemen, and ladies if there are any reading this list,
>>
>> Is there any way to get rid of the minimise button on a Window?
>>
>> I am creating a modal dialog using dialog management that has
>> SkipTaskbar set to true, however because the minimise button is
>> displayed by default, the user can minimise the dialog box by mistake
>> and never, ever get back to the dialog box because, with SkipTaskbar
>> set to true, alt+tab doesn't show the minimised window. The
>> consequence is that the user must terminate the application from the
>> command line, which is an exceedingly ugly thing to ask a user to do.
>>
>> Is there any reason that there are no individual properties to
>> prohibit the display of the minimise and maximise boxes in Qt4? Is
>> there any way to prevent or permit the two buttons to be shown or not
>> shown on a Gambas3 window?
>>
>
> This is the "philosophy" of the X-Window system: if a window is under the
> control of the window manager (which is a process on its own), then *he*
> decides how the window are managed. Not the application.
>
> There is a way to ask the window manager not to use some of these buttons, but
> I'm not sure it is possible for all buttons. Moreover, the window manager may
> not follow your request.
>
> I fully agree with this philosophy, where the final user has always the full
> control on his windows. How many times, on Windows, I hated all these windows
> you couldn't minimize in the taskbar...
>
> So:
>
> 1) Either do not put you window under the control of the window manager
> (Border = False on Gambas). But then you won't have any window decoration at
> all.

Thanks for that.

> 2) Always use plain normal windows.
>
> Why do you use a modal dialog with SkipTaskbar set? Is there any good reason
> to prevent the user from doing what he wants with that dialog?

Yes, there is. Customer specification. "Modal dialog boxes: 1) will
not display titles in any taskbar. 2) Will not have either a maximise
or a minimise button."

It makes absolutely no sense whatsoever to have a minimise button on a
fixed size modal dialog box. None. It is illogical, and the fact that
the maximise button goes when fixed size is set supports that
argument. It makes even less sense when, say,  Message.Question() has
no minimise button yet I am prevented from choosing to have my own
windows look like that displayed by Message.Question().

So, how did you convince the window manager to not display the
minimise button for Message.Question()?




More information about the Devel mailing list