Subject: FVWM: repositioning on Maximize and FvwmPager geometry specification

From: Guido Berhoerster <[email-masked]>
Date: Thu, 27 Feb 2003 12:17:20 +0100

Hello,

I'm currently using FVWM version 2.4.15 and when I use "Maximize
90 90" the window is not only maximized but also moved to the top
left corner (position 0,0) of the screen. I would like the window
to stay at its current position when it is maximized to 90% of
the width and height of the current screen. Is there a way to
circumvent this unwanted repositioning when maximizing?

The FvwmPager manpage states that "in order to maintain an
undistorted aspect ratio, you might want to leave out either the
width or height dimension of the geometry specification". I tried
something like "*FvwmPager: Geometry x64-0+0" in order to get a
pager with a height of 64 pixels but unfortunately it didn't
work. Any ideas?

Please CC me since I'm not subscribed. Thanks in advance.

-- 
Guido Berhoerster    [email-masked]
                     http://www.guido-berhoerster.org/
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Mikhael Goikhman <[email-masked]>
Date: Thu, 27 Feb 2003 13:15:24 +0000

> circumvent this unwanted repositioning when maximizing?

In 2.4.x or greater use:

  Resize bottomright 90 90

In 2.5.x you can do it even better by toggling the maximization flag too:

  ResizeMaximize bottomright 90 90

> pager with a height of 64 pixels but unfortunately it didn't

Without taking a look at the code, I see that without Geometry the pager
page (the smallest rectangle) is assumed to be the 1/32 size of the screen.
You may change this constant 32 using DeskTopScale. So when you leave out
one dimension it is taking as if you would not specify the geometry at all.

If my guess is right and you want to get a 4x3 <width>x<height> ratio and
specify only height, you may do the math yourself. With DesktopSize 2x2
and only one desk in a pager and a label font of 10 pixels, the page size
could be 36x27 (4x3 ratio) and the pager geometry would be 73x66-0+0
(73 = 36 * 2 + 1 separator; 66 = 27 * 2 + 1 separator + 11 label).

I don't know whether the current behaviour is what is originally intended.
But I think a good solution to this is to have a new option KeepAspect
that would force the page size to the same aspect ratio as the screen.
Patches to the cvs version are welcome.

Regards,
Mikhael.

---

From: Guido Berhoerster <[email-masked]>
Date: Thu, 27 Feb 2003 16:55:16 +0100

>   Resize bottomright 90 90

Unfortunately this is impractical for me since it doesn't toggle
the maximization flag. Furthermore the values "90 90" of the
Resize-command are interpreted as a position and not the width
and height of the resized/maximized window.

>   ResizeMaximize bottomright 90 90

I don't know about that since I don't use version 2.5.x but I
assume the values are interpreted the same way. Thus the window
is resized until the bottom right corner of the window is at a
position 90% from the left and 90% from the top of the screen.

I'd like to have something like the "growright/growdown"-option of
the "Maximize"-Function that doesn't stop when it runs into an
obstacle but keeps maximizing the window until the window has a
certain width and height, e.g. 90%, 90%.
But I gues that's not possible right now.

> Patches to the cvs version are welcome.

       *FvwmPager: Geometry geometry
              Completely or partially specifies the pager windows
              location and geometry, in  standard  X11  notation.
              In  order  to maintain an undistorted aspect ratio,
              you might want to leave out  either  the  width  or
              height dimension of the geometry specification

After reading this on the manpage of FvwmPager would say the
current behaviour is probably not the behaviour that was originally
intended. So a "KeepAspect"-option would be really nice.
-- 
Guido Berhoerster    [email-masked]
                     http://www.guido-berhoerster.org/
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Dominik Vogt <[email-masked]>
Date: Thu, 27 Feb 2003 17:01:42 +0100

> But I gues that's not possible right now.

You want

  ResizeMaximize 90 90

without the "bottomright" argument.

Bye

Dominik ^_^  ^_^

---

From: Guido Berhoerster <[email-masked]>
Date: Thu, 27 Feb 2003 18:52:53 +0100

> without the "bottomright" argument.

Yes, that is exactly what I was asking for, thanks.

Is there a way to get this effect when maximizing only
horizontally or vertically?
"ResizeMaximize 0 90" or "ResizeMaximize 90 0" will not work
because in contrast to Maximize ResizeMaximize does not interpret
0 as the current width or height but as width or height 0.
-- 
Guido Berhoerster    [email-masked]
                     http://www.guido-berhoerster.org/
--
Visit the official FVWM web page at <URL: http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm" in the body of a
message to [email-masked].
To report problems, send mail to [email-masked].

---

From: Mikhael Goikhman <[email-masked]>
Date: Thu, 27 Feb 2003 22:07:20 +0000

> 0 as the current width or height but as width or height 0.

In 2.5.x all these commands Move, Resize, Maximize and their numerous
combinations accept argument(s) "keep" to achieve this.

Regards,
Mikhael.