The texinfo format provides a command '@table' which is useful to provide
a list of object (function, variables, options, ...) with their associated
description.
As this will be very handy for the Installation Manual, this patch
implements the command in the script.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The texinfo format provides a command to generate list of item which are
prefixed by an auto-incremented number or letter.
This command was not implemented but as it will be used by the Installation
Manual of Window Maker, this patch implements it, reusing much of the code
that was handling the unordered lists.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
There are some cases where it can be useful to embed a list of item into
another list; the script was almost ready to handle this case, this patch
brings the missing stuff to get it to work properly.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Because the man page references some stuff that are dependant on the
configure options, it is a good idea to update the man page accordingly, so
the user will not be puzzled later.
There is now a script which takes care of replacing '@var@' in the same way
autoconf does, but also which can handle conditional '@def@' removal (for
the case of feature dependant command line options).
The man page for Window Maker is now processed this way so user will always
see accurate information.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
In order to ease the job of keeping the documentations up to date, there is
a new script 'check-cmdline-options' that checks a program's options (with
the '--help' option) and compare them with its documentation (the manual
page) to make sure everything is aligned.
This is triggered with "make check" for wmaker.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This 'switch' control statement is actually a GNU extension, so it is not
portable to other awk implementations.
This patch replace them with the traditional 'if...else' sequence which
will work everywhere.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
As reported by Doug Torrance, the 3rd argument to the 'match' function is
actually a GNU extension, so it breaks compatibility when run with another
version of awk, for instance mawk.
This script changes the code to stuck to the 2 arguments version which is
posix.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
With the new target, it is now easy to update all translations in the
project for a language against latest code with the simple command, run
from the top directory:
make update-lang PO=<lang>
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The support for variables in the text-from-texi script is used to
automatically insert the current version of Window Maker, inherited from
the definition in the AC_INIT command, so it will be always correctly
updated without the need for hand work.
Having this version information is recommended by GNU texinfo because if
the document happens to get distributed outside a package it can help user
avoid problems.
The second use is to define a variable 'emailsupport' which contains the
email address of the development team, so we can also inherit it from the
AC_INIT setting.
The third use is for a special variable 'cctexi2txt' to differentiate
between texi2any and our script, because when using texi2any the title
page is not generated, so we need to duplicate some information in the
source, but we do not want it to appear twice in our generated doc.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
The source of the documentation is in Texinfo format to have the
possibility someday to distribute in more format that just plain text;
There is a new Makefile to generate automatically the plain text file to be
distributed from the source; this doc is also generated by 'autogen.sh'
because a user would expect to find it before compiling the program, so
even before the 'configure' script have been generated, in the case he is
compiling from a git checkout;
There is a new script to generate the documentation, because from the way
we generate it we cannot assume that 'texi2any' is available and working
on the user's computer; it is also the opportunity to generate a better
looking document (see the description at the beginning of the script);
In this commit, the documentation only contains the base skeleton, it does
not contain yet any useful content because it is worth it's own commit.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Because the source file is redefined in the 'po/' directories, there is a
possibility that they get misaligned.
There is now a script that will check everything is in line; it is
triggered by "make check".
The case of the "util/" stuff is excluded at current time because the way
they are defined makes it hard to properly deduce the correct list of
sources, and it is not worth, the core need being on wmaker and WPrefs.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
Instead of having to maintain manually the map file for LD with the list of
symbols that we want to keep in the WRaster library (the purpose is to hide
internal symbols), this patch implements a script that parses the public
API header and extracts automatically the list of names that are supposed
to be visible to the user.
The goal is to reduce possible human errors, like for example the function
RCombineAlpha that was forgotten from the list, yet still keep the map file
feature which is considered a good practice (it reduces the risk for name
clash and the risk of mis-use of internal stuff from the library).
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
There are a few cases in which nested functions are an helpful way to write
code, as this is explained in 'script/nested-func-to-macro.sh'. However,
some compiler do not support them (like clang), so this patch proposes an
elegant solution, where developers can get the benefit of them, but for
users they are automatically converted to C macro if needed.
The advantage of this solution is that we keep the code simple, there is no
hack in the source (like #ifdef and code duplication), yet still having the
full advantages.
The translation is done according to what have been detected by configure
(see the WM_PROG_CC_NESTEDFUNC macro) so that user has nothing to do.
Signed-off-by: Christophe CURIS <christophe.curis@free.fr>