Re: New 'viewport shifted hook' ?

On Tue, 03 Nov 2009 14:07:38 -0600, Jeremy Hankins wrote:
> Teika Kazura <teika lavabit com> writes:
>> # I think we need nomenclature refinement and better VP concept
>> # tutorial in future. E.g. VP can mean both 'the current VP' and 'the
>> # whole virtual desktop'. Not only distinction, but concise and
>> # self-descriptive names are wanted.
> Hm?  I'm not sure I understand.  My understanding:
>  - virtual workspace: a larger-than-screen-size working area where
>    windows can be placed.
>  - viewport: a screen-sized subsection of a virtual workspace

Now I've had a browse in ewmh-1.4, and it uses "large desktop" and
"viewport". OK. But the "virtual desktop" is used for Sawfish's
"workspace". Wow. I used to use "virtual desktop" for "large
desktop". (Sorry for bringing in another headache. Let's forget it
until 1.6 release. ;)

The current Sawfish's definition is wrong, as I pointed out. For
example, 'viewport-dimensions' is used, which should really be named
'virtual-desktop-dimension' or so. (For this example, both "large
desktop" and "virtual desktop" are acceptable.)

And it is better to let developers and users know which concepts are
confusing, and how mistakes are avoided. Good manuals should cover
such things, too. (We don't do it right now.)

>> I think the shift that I asked you about is inherent to each WS,
>> and that simply emitting shift signal, via hook or global variable
>> works. In another words, shift *is there* if it's done within WS.
>> On the other hand, shift accompanied when witching the WS has to be
>> hidden from users.
> If I understand what you were asking, the shift you were asking about
> doesn't happen at all.

You know, assume that (screen-viewport) returns '(0. 0). Now you go
left, and it remains '(0 . 0). (Sorry, from the beginning I
should have said this.) Perhaps both you and I are correct, and the
definition lacks consistency. But I haven't dug into VP codes, and I'm
not sure.

But on second thought, the solution I insisted may be a bad way; I
said "since the top-left is always (0, 0), shift is there." But the
correct way is to set it as (-1, 0), and there's no shift. Will this
way cause another difficulty?

>> Ah. (sigh) I've browsed VP-*-WS-handler functions in wm/viewport.jl.
>> You were careful enough not to break the conventional
>> definition. Thanks a lot for that. But my first impression is that
>> there must be a better definition, by being consistent - not affected
>> whether it is dynamic or not - so that it's clearer for coders. Of
>> course, definition changes annoy people and make existing scripts
>> unavailable, so you can't say it's unconditionally better.
> I don't know what you're referring to.

For example, virtual desktop size is unique if you don't use dynamic
viewport, but it is multi-valued in DVP (dynamic VP), per workspace,
so, 'viewport-dimensions' is the *size of the current WS*.  But I
think it's better to have a sole definition, not affected by whether
VP is dynamic or not. (So the obvious solution is that even without
DVP, each WS has its own size, and there's no global VP size. But
this will need another brain exercise, and I don't like to do it.)

It is a hidden spec change, so it must be described. (Well, but it has
been implicitly assumed that virtual desktop size is common to all
WS. One reason is that John Harper didn't like VP, and hid it from
users. It's recent that Chris resurrected it.)

> There are some somewhat complicated corner cases, from a user interface
> perspective, and unfortunately I'm not certain I've got them worked out
> properly.  For example, if you turn dynamic viewports on, create windows
> in multiple viewports in different workspaces, and then turn dynamic
> viewports off you can end up with differently sized virtual workspaces
> on different workspaces despite the fact that you have a set viewport
> size.  But such a scenario can't be all that common, and frankly I don't
> know what would be the proper thing to do to avoid it.

Let's forget it. Dynamic-or-not is "usually" a "slow" option which
users don't change so often. If you're perfectionist, you have to do
really many things. But let's not do this kind of things.

Now let me propose this: let's put in the news section, "dynamic
viewport is experimental. The specification and the implementation
may change. But outside of dynamic VP, nothing has changed. Please
let us know your opinions."

The dynamic, and plain VP is difficult enough for me, and doesn't seem
to be a piece of cake even for Jeremy, either, who understands best
the VP.

> No, I'm not doing much of anything lately -- personal stuff has
> intervened.

It may be obvious, but no one forces nothing. :)

Teika (Teika kazura)

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