Re: FVWM: stick between screen

2009-03-16 Thread Dominik Vogt
On Mon, Mar 16, 2009 at 01:14:20AM +, Thomas Adam wrote:
> 2009/3/15 Jason Weber :
> > Start with one empty unified screen, two side by side monitors using
> > twinview (same card, different plugs).
> >
> > Instance a new window, say a xterm.
> >
> > Slide it left and right so that the left or right edge passes from
> > one monitor to the other.  I believe that the window edge is supposed to
> > snap with strong preference to keep the window on only one monitor.
> >
> > The only thing I know of that might be unusual is that my
> > monitors' horizontal resolutions are different.
> 
> Well as long as X reports things correctly then FVWM will honour that,
> so I think this a red-herring.  I'm not in a position to test this
> myself as I am sans Xinerama,

You can test Xinerama if you configure fvwm with
--enable-xinerame-emulation.


> but does the following patch do anything
> to help "fix" this?  I warn you it's complete theory on my part, so
> expect a quirk or fifty.  ;)
> 
> -- Thomas Adam
> 
> P.S.  Also Cc'ed fvwm-workers which is what you should have done from
> the outset.

> Index: fvwm/move_resize.c
> ===
> RCS file: /home/cvs/fvwm/fvwm/fvwm/move_resize.c,v
> retrieving revision 1.304
> diff -u -r1.304 move_resize.c
> --- fvwm/move_resize.c7 Dec 2007 18:52:21 -   1.304
> +++ fvwm/move_resize.c16 Mar 2009 01:11:21 -
> @@ -2076,8 +2076,23 @@
>   /* snap to screen egdes */
>   if ((fw->snap_mode & SNAP_SCREEN) && fw->snap_proximity > 0)
>   {
> + /* TA:  20090315:  Make sure windows being told to snap to a
> +  * screen; honour Xinerama screens separately -- and don't
> +  * treat the screen area as one huge screen.
> +  */
> + rectangle screen;
> + int screen_width;
> +
> + screen_width = Scr.MyDisplayWidth;
> +
> + /* Get the parameters for the screen */
> + FScreenGetScrRect(NULL, FSCREEN_CURRENT, &screen.x, &screen.y, 
> + &screen.width, &screen.height);
> + if (screen.width > 0)
> + screen_width = screen.width;
> +
>   /* horizontally */
> - if (!(Scr.MyDisplayWidth < (*px) ||
> + if (!(screen_width < (*px) ||
> (*px + self.width) < 0))
>   {
>   dist = abs(Scr.MyDisplayHeight - (*py + self.height));
> @@ -2119,23 +2134,23 @@
> (*py + self.height) < 0))
>   {
>   dist = abs(
> - Scr.MyDisplayWidth - (*px + self.width));
> + screen_width - (*px + self.width));
>   if (dist < closestRight)
>   {
>   closestRight = dist;
>  
> - if (*px + self.width >= Scr.MyDisplayWidth &&
> + if (*px + self.width >= screen_width &&
>   *px + self.width <
> - Scr.MyDisplayWidth + fw->snap_proximity)
> + screen_width + fw->snap_proximity)
>   {
> - nxl = Scr.MyDisplayWidth - self.width;
> + nxl = screen_width - self.width;
>   }
>  
>   if (*px + self.width >=
> - Scr.MyDisplayWidth - fw->snap_proximity &&
> - *px + self.width < Scr.MyDisplayWidth)
> + screen_width - fw->snap_proximity &&
> + *px + self.width < screen_width)
>   {
> - nxl = Scr.MyDisplayWidth - self.width;
> + nxl = screen_width - self.width;
>   }
>   }
>   dist = abs(*px);



Ciao

Dominik ^_^  ^_^

-- 

Dominik Vogt



Re: FVWM: Trouble with Sun Presenter Console

2009-03-16 Thread Dan Espen
Sven Geggus  writes:

> Dan Espen  wrote:
>
>> The horizontal lines indicate the window is "sticky"
>> (shown on all desktops).
>> 
>> This is probably done by the application with an emwh hint.
>
> True! I was already wondering why switching to a different desktop is
> impossible while in Presenter Mode. Is there a way to make all sticky 
> windows decorationless? This would be a workaround to make it work   
> for now.  

I believe you are actually switching to different desktops.
A sticky window is shown on all desktops.  That's what sticky means.

>> You could start by looking in the application preferences to
>> see if the hints can be controlled.
>
> Well, there is at least nothing which is accessible be configuration
> menu.
>
>> Otherwise the Fvwm documentation can be used to find out how
>> to override hints.
> 
> OK, I need to have a look.

There are emwh ignore hints commands if you just want to
ignore the hint that makes it sticky.

If you are more concerned with the decorations,
you'll want:

Style XXX NoTitle, BorderWidth 0, HandleWidth 0, NoHandles

Use FvwmIdent to get the value for XXX.
Use either the Name, Class, or Resource.



Re: FVWM: Trouble with Sun Presenter Console

2009-03-16 Thread Sven Geggus
Dan Espen  wrote:

> The horizontal lines indicate the window is "sticky"
> (shown on all desktops).
> 
> This is probably done by the application with an emwh hint.

True! I was already wondering why switching to a different desktop is
impossible while in Presenter Mode. Is there a way to make all sticky 
windows decorationless? This would be a workaround to make it work   
for now.  

> You could start by looking in the application preferences to
> see if the hints can be controlled.

Well, there is at least nothing which is accessible be configuration
menu.

> Otherwise the Fvwm documentation can be used to find out how
> to override hints.

OK, I need to have a look.

Sven

-- 
This APT has Super Cow Powers.
(apt-get --help on debian woody)

/me is gig...@ircnet, http://sven.gegg.us/ on the Web



Re: FVWM: Trouble with Sun Presenter Console

2009-03-16 Thread Dan Espen
Sven Geggus  writes:

> Hello,
>
> I try to use the Sun presenter Console on a dual-head screen (diffenrent
> content on beamer and TFT).
>
> Unfortunately the Windows are decorated :(
>
> Are there other types of Windows than Transient and normal ones? 
>
> I ask this Question, because the decoration looks somewhat unusual as the
> top window has 3 horizontal lines, which I don't have on my generic fvwm
> Windows.
>
> So how can I make the undecorated?
>
> I'm using fvwm 2.5.26 from Debian lenny.

The horizontal lines indicate the window is "sticky"
(shown on all desktops).

This is probably done by the application with an emwh hint.

You could start by looking in the application preferences to
see if the hints can be controlled.

Otherwise the Fvwm documentation can be used to find out how
to override hints.



FVWM: Trouble with Sun Presenter Console

2009-03-16 Thread Sven Geggus
Hello,

I try to use the Sun presenter Console on a dual-head screen (diffenrent
content on beamer and TFT).

Unfortunately the Windows are decorated :(

Are there other types of Windows than Transient and normal ones? 

I ask this Question, because the decoration looks somewhat unusual as the
top window has 3 horizontal lines, which I don't have on my generic fvwm
Windows.

So how can I make the undecorated?

I'm using fvwm 2.5.26 from Debian lenny.

Sven


-- 
"Those who do not understand Unix are condemned to reinvent it, poorly"
(Henry Spencer)

/me is gig...@ircnet, http://sven.gegg.us/ on the Web