Re: [Maybe OT]: Sawfish 'strange' behaviours



Havoc Pennington wrote:

If I don't set the WM_CLASS all windows of the app are created the same
size(which looks real ugly if the main window is maximised and you pop
up a one line dialog which also maximises itself), and they don't stack
properly on the panel.
and that's what is happening to my app under Sawfish, while all other WM I have tested
(enlightenment, windowmaker, aewm, amiwm ... ) work.

No, it's a legitimate issue. The problem is that what the ICCCM
specifies really isn't useful, so lots of window managers have this
"identify windows by class/role" feature that works best if apps do
something nonstandard. But not all window managers do that.
But, exactly, what is the problem in doing something not standard?

And so it's just a totally unspecified mess and you can't do anything
that will really work reliably.

so, conforming to the 'standard' really doesn't help that much. Right? ;-)

IMO the correct solution is to have the window manager ignore the
class/name for the most part.

maybe you are right, but I cannot expect that people will turn off some features just because they are not standard. I can have a preference option in my own app like "set WM_CLASS hints" or something to do dirty things, but I cannot expect that people change their own WM prefs just to
have my app working.

After all these readings, I have come out with this code (that, accidently, seems to work under Sawfish :-):

(main window)
gtk_window_set_wmclass ( GTK_WINDOW ( mb->win ), "MainWin", "MyAppClass" );

(my mebu window)
gtk_window_set_wmclass ( GTK_WINDOW ( mb->win ), "MenuWin", "MyAppClass" );

(child windows)
gtk_window_set_wmclass ( GTK_WINDOW ( mb->win ), "ChildWin", "MyAppClass" );

Now Sawfish does not mess things up when I maximize the main window and then add some child
windows.
Is this line of code something I should put under a prefs option? Is it so not standard?

Ciao,

 Fabio





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