Closed GoogleCodeExporter closed 9 years ago
Excellent! I'll take a look at this tonight!
Original comment by Michael....@gmail.com
on 27 Jul 2009 at 8:08
Man page still to be updated. I wonder if this should be made configurable so
that
the -F option is only put into the man page in the case that fontconfig is used?
Original comment by Michael....@gmail.com
on 28 Jul 2009 at 8:53
I do believe it is possible to detect fontconfig[1] and based on that modify the
contents of the man page. But I am wondering if it is the smart choice here.
Personally I think it would be better to always document the switch[2],
likewise that
mscgen always accept it. The reason for this is:
Imagine person A has mscgen with fontconfig and person B has without. Now
person A
makes a script/msc-file that uses the "-F" option and publishes it. When person
B now
look at this script, mscgen is given an option on his/her PC that is not
documented
in his man page and causes the script to break.
Instead if it is always documented and always accepted[3], person B will never
face
an undocumented option that is accepted on "any other PC than his/her own".
Alternatively you could go with a "fail if not supported"; it would require a
decent
error message. Nevertheless, I still feel the switch should be documented in
the man
page.
I believe that distros would prefer having the full man-page installed, even if
they
are forced to build without every feature enabled. It saves them some
bug-reports on
"missing information about -F argument."
Also, the documentation added for ADrawOpen() (about fontName) does not match
the
behavior for gd_out.c. The doc states that if fontName is NULL a default will be
used, where as gd_out.c calls abort() (via assert) or passes a NULL pointer to
the gd
functions (I do not know how they handle NULLs, so I cannot say if they do the
right
thing or not).
~Niels
[1] I assume you mean "libfontconfig" here.
[2] It would be good to mention that it may be "ignored" due to build
limitations.
[3] Though preferably with a warning that the font request could not be
fulfilled due
to build limitations.
Original comment by NThykier@gmail.com
on 28 Jul 2009 at 11:01
Okay, r80 adds docs, fixes the ADrawOpen() inline docs and enables -F with a
warning
message in the case it is used by USE_FREETYPE was not configured, something
like
what you suggest :)
NULL should never be passed down from ADrawOpen() - the code is pretty simple
at the
top level so that can't happen, and the assert() would have shown it in my
tests.
Original comment by Michael....@gmail.com
on 2 Aug 2009 at 5:40
Original issue reported on code.google.com by
NThykier@gmail.com
on 26 Jul 2009 at 5:01Attachments: