Subject: Re: FVWM: question on positioning an FvmwButtons object

From: "Rouben Rostamian" <[email-masked]>
Date: Fri, 2 May 2003 18:59:14 -0400

Thanks, Mikhael, for your quick response to my query.  Your pointers
to the FAQ worked perfectly.  I implemented the positioning using
ReadPipe and FvwmEvent.

Regards,

Rouben

--- Forwarded mail from Mikhael Goikhman <[email-masked]>

>From [email-masked]  Fri May  2 15:23:12 2003
Date: Fri, 2 May 2003 19:21:43 +0000
From: Mikhael Goikhman <[email-masked]>
To: Rouben Rostamian <[email-masked]>
Cc: FVWM <[email-masked]>
Subject: Re: FVWM: question on positioning an FvmwButtons object

On 02 May 2003 14:48:01 -0400, Rouben Rostamian wrote:
> I wish to position a button bar, created using FvmwButtons,
> horizontally centered along the bottom edge of the screen.
> 
> Currently, I use m4 preprocessing to calculate the dimensions of the
> button bar by summing individual button sizes and paddings.  Based on
> that, I calculate the (x,y) coordinates needed to position the bar.
> This is too complex and error-prone.  For instance, button sizes can
> be affected by the length of a button's title and its font.
> 
> Is it possible that there is a straightforward method for doing such
> a placement?
> 
> Actually, for my purposes it would suffice if there is a hook
> which gives the total width of the button bar after it is created
> and before it is mapped to the screen.
> 
> I am using version 2.4.5, if that matters.

There is no currently a Center (you want CenterBottom) placement.
You may use the following technique if you find it suitable.

Start FvwmButtons using a function that Wait's for it and then moves
it, like described in FAQ #3.18. To center it, use FAQ #7.14.

Regards,
Mikhael.

--
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].