Possible error in fvwm(1) manpage

2007-07-31 Thread Gustavo Rondina
Hello

Recently I've compiled and installed fvwm 2.5.21 and now I'm
learning how to use and configure it properly.  One of the resources
I'm relying on, besides the great documentation I have found on the
web, is the online manual page of fvwm(1).

While I was reading the manpage, though, I noticed what I judge to
be a minor mistake.  Under the INITIALIZATION section it reads:



If you want to start some applications or modules with fvwm, you
can simply put

Exec app

or

Module FvwmXxx

into your config, but it is not recommended; do this only if you
know what you are doing. It is usually critical to start
applications or modules *after* the entire config is read, because
it contains styles or module configurations which can affect window
appearance and functionality.

The standard way to start applications or modules on fvwm's start up
is to add them to an initialization function (usually StartFunction
or InitFunction). This way they are only started *after* fvwm
finishes to read and execute config file. 



Shouldn't that first after be replaced by before?  These two
paragraphs seems to be opposing each other.  The first says that it
is critical (i.e., dangerous, error prone) to start apps or modules
after the config file is entirely read and processed.  The second,
on the other hand, states that apps and modules which must be
launched on start up should be placed within an initialization
function, so they would only be started after the config file was
read and executed.  The latter assertion seems to go against the former.

Gustavo




Re: Possible error in fvwm(1) manpage

2007-07-31 Thread Thomas Adam
On 31/07/07, Gustavo Rondina [EMAIL PROTECTED] wrote:
 Shouldn't that first after be replaced by before?  These two
 paragraphs seems to be opposing each other.  The first says that it
 is critical (i.e., dangerous, error prone) to start apps or modules
 after the config file is entirely read and processed.  The second,
 on the other hand, states that apps and modules which must be
 launched on start up should be placed within an initialization
 function, so they would only be started after the config file was
 read and executed.  The latter assertion seems to go against the former.

Probably.  The whole point of that is in the way FVWM processes the
file it's reading.  It does this:

1.  Executes the entire file line-by-line.
2.  If it comes across function definitions such as
{Init,Start}Function, it executes those *AFTER* the entire file has
been processed.

So in that sense, what it's trying to convey is if you had this in your config:

Module FvwmButtons A
DestroyModuleConfig FvwmButtons A:*
*A: Columns 1
*A: Rows 20
*A: (1x1)

That there is every chance FvwmButtons might not start because of the
order you have specified things in.  Inverting that on its head:

DestroyModuleConfig FvwmButtons A:*
*A: Columns 1
*A: Rows 20
*A: (1x1)
Module FvwmButtons A

Makes all the more sense.  Although generally speaking you would leave
the module definitions in the file as-is, but move the module
invocation call into the function:

AddToFunc StartFunction I Module FvwmButtons A

This explains why you can have multiple:

AddToFunc StartFunction I Bar

lines in your config and have them all appear to run at the same time,
because StartFunction is read after the entire file has been
processed.

Kindly,

Thomas Adam



Re: Possible error in fvwm(1) manpage

2007-07-31 Thread Gustavo Rondina
Thomas Adam wrote:
 1.  Executes the entire file line-by-line.
 2.  If it comes across function definitions such as
 {Init,Start}Function, it executes those *AFTER* the entire file has
 been processed.

Thanks for the clarifications Thomas.  I had comprehended the role
of StartFunction in this context, but the manpage text was a bit
confusing for me (I am not a native English speaker, probably this
was the reason of my misunderstanding).

Gustavo