After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 109654 - Large desktop support
Large desktop support
Status: RESOLVED FIXED
Product: libwnck
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: libwnck maintainers
libwnck maintainers
Depends on:
Blocks:
 
 
Reported: 2003-03-31 23:52 UTC by Kim Woelders
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
revised patch (34.22 KB, patch)
2003-04-02 05:02 UTC, Havoc Pennington
none Details | Review
Patch on revised patch (4.14 KB, patch)
2003-04-02 23:45 UTC, Kim Woelders
none Details | Review

Description Kim Woelders 2003-03-31 23:52:22 UTC
Currently libwnck (and therefore the gnome-panel pager and
window list) doesn't support large desktops, i.e. handling
of the _NET_DESKTOP_GEOMETRY and _NET_DESKTOP_VIEWPORT hints.

Recently, Extended Window Manager Hint support (i.e. potential
GNOME2 compatibility) has been added to enlightenment, which
does support large desktops.

I really would like to see the GNOME desktop being able to
work with enlightenment, so please consider these patches,
which add support for large desktops to two libwnck versions:
http://www.woelders.dk/~kw/stuff/gnome/libwnck-0.18-large-desktop-kw2.patch
http://www.woelders.dk/~kw/stuff/gnome/libwnck-2.2.1-large-desktop-kw2.patch

The patches are not perfect, but I think they do a fairly
good job to begin with.
Comment 1 Havoc Pennington 2003-04-01 20:17:17 UTC
The patches look pretty close to right, thanks for doing this work.
                                                                     
                 
Here are some quick nitpicks:
                                                                     
                 
 - be sure to put a space before parens "foo (" not "foo("
                                                                     
                 
 - should not name things wnck_viewport_get_x() but rather
   wnck_workspace_get_viewport_x() or something like that,
   if they are methods on the workspace
                                                                     
                 
 - I wouldn't make wnck_screen_get_xyhint a public function,
   I'd keep it in xprops.h with an underscore prepended
                                                                     
                 
 - the values in the properties need to be sanity-checked,
   in case someone decides it would be funny to specify
   a -50x-150 viewport or something
                                                                     
                 
 - the viewport properties should be read in an idle handler
   when a PropertyNotify for them is received, like the other
   stuff in screen.c
                                                                     
                 
Comment 2 Kim Woelders 2003-04-02 00:12:58 UTC
OK, next version:
http://www.woelders.dk/~kw/stuff/gnome/libwnck-2.2.1-large-desktop-kw3.patch

Changes:
- Style changes as requested.
- Sanity checks on hint data. I assume that we only want to avoid
  applications to crash, not to attempt fixing general bad behavior.
- A rewrite of the viewport hint handling.

You asked me to "put the 2.2.1 one in bugzilla". Did you mean that I
should include the patch as an attachment?
Comment 3 Havoc Pennington 2003-04-02 03:19:04 UTC
A link to the patch is fine, as long as you don't take it down before
I apply it. ;-)

I'm looking at merging the patch now, but you'll have to test the 
result since I don't have a WM that supports _NET_WM viewports.

Comment 4 Havoc Pennington 2003-04-02 05:02:50 UTC
Created attachment 15378 [details] [review]
revised patch
Comment 5 Havoc Pennington 2003-04-02 05:05:07 UTC
Can you try this patch (and maybe debug it if it's hosed ;-) since 
I don't have a WM with viewports)

A remaining issue is that if the WM changes the viewport geometry 
first and number of workspaces second, I think libwnck will 
get confused. So on changing number of workspaces probably 
we need to reload all viewport stuff. I'll make a little tweak 
for that but won't upload a new patch yet.
Comment 6 Havoc Pennington 2003-04-02 05:07:34 UTC
The extra bit I added in do_update_now():

 /* if number of workspaces changes, we have to
   * update the per-workspace information as well
   * in case the WM changed the per-workspace info
   * first and number of spaces second.
   */
  if (screen->priv->need_update_workspace_list)
    {
      screen->priv->need_update_viewport_settings = TRUE;
      screen->priv->need_update_workspace_names = TRUE;
    }
Comment 7 Kim Woelders 2003-04-02 18:07:26 UTC
It looks as if the pager as well as the task list is broken.
I will dig into it.
A WM with large desktop support: E16 from CVS.
Comment 8 Kim Woelders 2003-04-02 23:45:31 UTC
Created attachment 15416 [details] [review]
Patch on revised patch
Comment 9 Havoc Pennington 2003-04-02 23:58:29 UTC
+	      /* Yes, but space is the active one by the time the viewport hint
+	       * hits the WM. It should be possible to change the desktop *and*
+	       * the viewport in one mouse click.

I don't think this can be implemented without fixing the EWMH, 
unfortunately.

I don't understand the change to wnck_window_is_in_viewport() - 
isn't window->priv->x the actual server-side window position?
I'm not looking at the code right this minute.
Comment 10 Kim Woelders 2003-04-03 00:09:16 UTC
Collision - OK, I'll commit this message before reading yours anyway.

I have been testing with patch above - things seem to work fine.
You corrected the _NET_DESKTOP_VIEWPORT decoding according to the
standard, and after doing that in E16 too things were fine with the pager.
Changes:
- pager.c: I think it should be possible to change the workspace *and*
the viewport in one mouse click. Otherwise it doesn't "feel" right.
- tasklist.c: Also needs the viewport change callback.
- window.c: No need to make things more complicated than they are.
Comment 11 Havoc Pennington 2003-04-03 00:14:19 UTC
Oh, the window.c thing is just saying "since they have the same offset
you can ignore the offset", I get it. This isn't actually needed to fix 
any bugs though, that's what I was confused about.

Thanks, I'll get this in CVS later tonight.
Comment 12 Kim Woelders 2003-04-03 00:20:09 UTC
Did it again...

+ I don't think this can be implemented without fixing the EWMH, 
+ unfortunately.
What do you mean - it works?

wnck_window_is_in_viewport: This is just a question about a common
origin - I think it is simplest to think of it in simple screen
coordinates.
Comment 13 Havoc Pennington 2003-04-04 06:51:20 UTC
OK, in CVS now, should be working with all so-far-mentioned issues
fixed. Thanks a lot for the patches, if there are any 
remaining details broken go ahead and file a new bug report
for those.
Comment 14 Kim Woelders 2003-05-14 14:36:37 UTC
Is there a chance of seeing a libwnck-2.3.1 release some time soon so
that this feature starts rippling into the distributions?
Comment 15 Havoc Pennington 2003-05-14 15:26:15 UTC
The next stable release of libwnck (that distributions should ship)
will be 2.4.0 - to come out with GNOME 2.4.
http://www.gnome.org/start/2.3/ has the schedule.
Comment 16 Kim Woelders 2003-05-14 16:23:43 UTC
I would be happy with an unstable libwnck-2.3.1 tarball going into
unstable releases.
From the release schedule it looks to me as if 2.3.1 tarballs are due
May 5?
Sorry to go on about this.