On Fri, 11 Apr 2008, Jesús Guerrero wrote:

> On Fri, 11 Apr 2008 13:12:02 -0400 (EDT)
> Eben King <[EMAIL PROTECTED]> wrote:
> 
> > On Fri, 11 Apr 2008, Jesús Guerrero wrote:
> > 
> > > I am using things like $[vp.width]/10 on my config (to calculeta the
> > > ButtonSize for one FvwmButtons), all is nice except when I use xinerama,
> > > because then the total width of the viewport is obtained -logically-
> > > summing the widths of the two monitors.
> > >
> > > Is there any way to get the dimensions of one monitor only? I am looking
> > > for a portable setup that can work with or without xinerama, and the 
> > > monitors
> > > might be of equal or different size. That's the main problem :P
> > 
> > How about if instead of width/10 you use height/7.5?  It's a pragmatic 
> > approach...
> > 
> As I said, it must work in many circumstances. The "pragmatic approach"
> would require the edition of the config file each time I switch monitors
> or the X layout, which is what I intend to avoid.

I've done that (but in an automated fashion) to change my keybindings to 
move my mouse, because if I said 
Key Left        A       CMS     CursorMove -1 +0
then depending on whether I had xinerama or not, the mouse would move 1 or 
2 percent of the physical screen size in the X direction, but always 1% in 
the y direction.

Depending on your needs, you way want to invoke FvwmCommand from an 
external script that calculates 1/10th of the physical screen, etc.

Mine calculates it in a script that is invoked by a keybinding, is read by 
PipeRead, that toggles the existance of a bunch of other keybindings 
including these cursormove bindings.  And in doing so, it calculates how 
many pixels to move:
Key Left        A       CMS     CursorMove -168p +0


-- 
Tim Connors

Reply via email to