I got two private messages saying it is good to speak about betas here.
On 08 Sep 2000 17:24:33 -0800, Czarina Caro L. Tablante 1995-24644 wrote:
>
> Hi! I'm having some trouble implementing this (pardon a newbie).
Implementing something non-standard or unknown always can be problematic.
I suggested two solutions (in 2.2.4 only an idea with cron job may work),
but you should choose yourself their implementations to match your needs.
> i added this to my .fvwm2rc :
>
> *NewWindowEventCmd
> *NewWindowPassId
> *NewWindow add_window FuncFocusWindow
>
> AddToFunc FuncFocusWindow
> + I PipeRead `windows "$w" "$n" "$r" "$c"
A missing backtick at the end of this line is a typo, right?
Also probably rename FuncFocusWindow to FuncVerifyWindow just to be clear.
This FvwmEvent implementation only works with fvwm betas, you know.
> FvwmEvent NewWindowEvent
Here you start an FvwmEvent's alias NewWindowEvent, but you define a
configuration for another alias NewWindow (*NewWindow lines above).
> (end)
>
> i'm really new with this stuff, and i've been reading everything i can
> find on the web, but i cant find what those variables "$w", "$n", etc
> are or where/how i can get them.
You can find an explanation about $w in the fvwm 2.2.4 man page.
Other variables are new and explained in the current beta man pages.
When you are viewing a man page, type: /\$w <Enter>
> this is my windows script:
>
> #!/bin/sh
>
> info=$(xwininfo -display :0 -tree -root | grep Navigator | wc -l)
> if [ "$info" -gt 3 ]; then
> FvwmCommand WindowId $w Delete
This line is incorrect. $w will be interpreted by sh as an empty string.
You can use $1 (window id), $2 (window name), $3, $4 in the shell script.
Also FvwmCommand(1) gets only one parameter. So the line could be:
FvwmCommand "WindowId $1 Delete"
But you should understand what happens. You call this script within
PipeRead, it usually only makes sence if the script outputs something.
My intend was (please reread that message) to call FvwmCommand from
a cron job and here to print a fvwm command.
Also 'windows' script and FvwmCommand should be in your unix path, or
you can specify their full paths. Errors can be found in X Server output.
> fi
>
> (end)
>
> i'm almost 100% sure what i did was incorrect. i dont get what u
> mean by printing "WindowId $w Delete" to standard output too.
Try in the script: echo "WindowId $1 Delete"
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 majordomo_at_fvwm.org.
To report problems, send mail to fvwm-owner_at_fvwm.org.
Received on Fri Sep 08 2000 - 15:03:28 BST