[PATCH weston v4] toytoolkit: Don't draw shadows for maximized windows.
oreaus at gmail.com
Fri Sep 28 16:09:57 PDT 2012
On Fri, Sep 28, 2012 at 2:30 PM, Bill Spitzak <spitzak at gmail.com> wrote:
> Also need to handle maximized-vertically and maximized-horizontally.
> I know it isn't liked but I want to push my recommendation again:
> The shell knows how thick the "edges" are of a window. This is the shadows
> and *also* the part that you are removing for your "maximized decorations"
> (please look carefully at how most X window managers do "maximize" and you
> will see it is more than the "shadow"). The client would tell the shell
> this information the same way it says the opaque and input areas.
> When a window is maximized the shell tells the client to make it *larger*
> than the screen such that the area inside the "edges" fills the screen. It
> then clips this to the screen (ie the edges and shadows do not appear on an
> adjacent output).
> This will handle clients that force the size to be smaller than maximized,
> and allow maximize horizontally/vertically to work. It will also allow
> "snap to the inside edge" on output sides and windows to each other, which
> allows more efficient screen usage, and is supported by some X window
> managers. Also allows the 3-edge-removed display that Windows 7 does when
> you half-screen-maximize a window. And it will work with really stupid
> clients, as long as they report the edges.
> However the client should be able to know that the edges are clipped, for
> a few reasons:
> 1. So it does not waste time rendering them
> 2. So it can avoid using image buffer memory for them
> 3. So it does not draw any controls out there that it assumes the user
> can see.
> 4. It can produce better graphics than a simple clip. For instance if
> there is some shading in the corner to make it look round, this can be
> disabled if one edge is clipped.
> 5. It may want to disable resizing on the clipped edges, though I believe
> the way Wayland is being done this can be entirely decided by the shell.
> 6. This information, if provided even when not clipped, can be used to
> position pop-up menus so they do not go off-screen. This is necessary if
> you don't want an xy position of windows sent to clients.
> Therefore the shell can tell a client "I want you to act like you are this
> size but only this area is needed" in the resize request. Conversely in the
> resize notify, the client can say "act like the surface is this size, but
> this sub-rectangle is what the image buffer actually is.
> This is not compatible, but the shell can detect "old" clients because
> they do not specify the edges and alter the requests.
> My feeling is that fullscreen is such a special case that it should remain
> a flag like it is now. The alternative of the client saying what the
> "contents" area (ie without the titlebar) and the shell resizing it larger,
> would be consistent, but does not look necessary to me.
I don't really understand why you're trying to push this idea without any
code to demonstrate your concept. You can't say how you think it should be
and expect someone else to implement the features you're suggesting. What
you're talking about here is relatively minor details that don't really
matter much at this point. This patch is only a first step toward the goal
of trying to get 'normal' expected behaviour from weston. Snapping,
horizontal/vertical maximize, edge/content adjustments can be done by
anyone willing to write the code to do it. Since you sound interested and
seem to know what you want, I encourage you to submit a patch set.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the wayland-devel