Re: change & bug on Infinite desktop

Teika Kazura <teika lavabit com> writes:
> Hi.
> On Sun, 11 Oct 2009 20:45:05 -0500, Jeremy Hankins wrote: 
>> a minor tweak to infinite-desktop (stop-at-workspace-borders is no 
>> longer a settable option, instead it depends on whether 
>> viewport-boundary-mode is dynamic).
> Oh, this is not minor. Previously, the default behavior of ID was to
> ignore the VP size. But now, it is confined, and explicitly needs
> dynamic VP to go far endlessly.

This is true -- for some reason I thought the previous default was to
stop, but apparently it was not.  So the default behavior will change,
since the default is not to have dynamic viewports.  I've added a note
in man/news.texi to that effect.

> This is a good change. Smooth scroll of the virtual desktop by mouse
> has nothing to do with VP infiniteness.
> Thus the name 'infinite-desktop' does not make sense any more. But if
> the name is to be changed, it should be done carefully.

This should probably be part of the general rationalization of module
names that Chris talked about.  Frankly I don't see any way of doing it
that doesn't cause problems, so better that all changes happen at the
same time so that users can be warned.

> And Jeremy, it's a bit buggy. Some users put in ~/.sawfishrc,
> (define-special-variable infinite-desktop.stop-at-workspace-borders
> nil) because it was a variable. (nil can be t) But now, it is a
> function, so (infinite-desktop.stop-at-workspace-borders) returns an
> error, as Invalid function: ()

This I don't think is a problem.  I get scope issues wrong from time to
time with rep, but my understanding is that since
infinite-desktop.stop-at-workspace-borders is a define (not a defun) and
not included in the export statement it should override any other
definition of the same symbol while in infinite-desktop.  When I tested
it just now, by opening up sawfish-client and running:

(define-special-variable infinite-desktop.stop-at-workspace-borders nil)
(require 'sawfish.wm.ext.infinite-desktop)

I got the expected behavior -- that smooth scroll didn't stop at
workspace borders, since I have dynamic viewports on.  Turning dynamic
viewports off changed the behavior, as I expected.  If you know of a way
to trigger a bug I'd be interested -- to improve my understanding of rep
scope... ;)

> I propose to rename 'infinite-desktop.stop-at-workspace-borders' to
> 'stop-at-workspace-borders' (prefix is dropped), and move it into
> viewport.jl.  So, if user sets a value to
> 'infinite-desktop.stop-at-workspace-borders', then it has no effect.

Making the name change is probably a good idea even if I'm right about
the scope, for reasons of readability.  And I think you're right, it
should be in viewports, so that anything else that might need that
information can use it.

So in my local branch I've changed it viewport-honor-workspace-edges (to
make it clear it's a viewport function).  It'll be included in my next
push to the viewport branch, once I get the current bugs figured out.

> If you put an unused custom-var in wm/util/compat.jl, then the var is
> deleted from ~/.sawfish/custom, and the value is not upon reading, as
> it seems. So let's do it. What I said above is explicit setq blah,
> and it can't be prevented with compat.jl, though.

I'll make this change as well.

Jeremy Hankins <nowan nowan org>

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