Show version info in serveral files including README, FAQ and manual
pages when building the distribution package, to ensure consistency.
Output is like:
Infocode: 20204
Version: 2.2.4, date: 26 January 2011
README: release 2.2.4, 26 January 2011
FAQ: The latest version of FIGlet is 2.2.4
.TH CHKFONT 6 "26 January 2011" "v2.2.4"
.TH FIGLET 6 "26 January 2011" "v2.2.4"
.TH FIGLIST 6 "26 January 2011" "v2.2.4"
.TH SHOWFIGFONTS 6 "26 January 2011" "v2.2.4"
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
The following tests have been added:
test 017: tlf2 kerning flush-right mode
test 018: tlf2 overlap centered mode
test 019: tlf2 full-width flush-left right-to-left mode
test 020: specify font directory
test 021: paragraph mode long line output
test 022: short line output
test 023: kerning paragraph centered mode (small)
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Use outchr as the ouput character type (instead of char) when computing
kerning, to prevent corruption with tlf2 fonts
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Add test target to the Makefile, and also automatically run tests
in the dist target. Current test results:
Run tests in /home/claudio/figlet/figlet
_____ _ _ _
|_ _|__ __| |_ _ _ ___ ____ _| | |_ ___
| |/ -_|_-< _| | '_/ -_|_-< || | | _(_-<
|_|\___/__/\__| |_| \___/__/\_,_|_|\__/__/
Run test 001: showfigfonts output... pass
Run test 002: text rendering in all fonts... pass
Run test 003: long text rendering... pass
Run test 004: left-to-right text... pass
Run test 005: right-to-left text... pass
Run test 006: flush-left justification... pass
Run test 007: flush-right justification... pass
Run test 008: center justification... pass
Run test 009: kerning mode... pass
Run test 010: full width mode... pass
Run test 011: overlap mode... pass
Run test 012: TLF font rendering... pass
Run test 013: kerning flush-left right-to-left mode... pass
Run test 014: kerning centered right-to-left mode (slant)... pass
Run test 015: full-width flush-right right-to-left mode... pass
Run test 016: overlap flush-right mode (big)... pass
All tests passed.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Do not hardcode '/usr/local' but allow it to be overriden from the
outside. Also disable the second DEFAULTFONTDIR by default. While here,
remove some whitespace characters.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Linefeed characters are printed differently depending of the shell
used as /bin/sh. Use an extra echo to prevent output problems.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Show version info in serveral files including README, FAQ and manual
pages when building the distribution package, to ensure consistency.
Output is like:
Infocode: 20204
Version: 2.2.4, date: 26 January 2011
README: release 2.2.4, 26 January 2011
FAQ: The latest version of FIGlet is 2.2.4
.TH CHKFONT 6 "26 January 2011" "v2.2.4"
.TH FIGLET 6 "26 January 2011" "v2.2.4"
.TH FIGLIST 6 "26 January 2011" "v2.2.4"
.TH SHOWFIGFONTS 6 "26 January 2011" "v2.2.4"
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
The following tests have been added:
test 017: tlf2 kerning flush-right mode
test 018: tlf2 overlap centered mode
test 019: tlf2 full-width flush-left right-to-left mode
test 020: specify font directory
test 021: paragraph mode long line output
test 022: short line output
test 023: kerning paragraph centered mode (small)
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Use outchr as the ouput character type (instead of char) when computing
kerning, to prevent corruption with tlf2 fonts
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Add test target to the Makefile, and also automatically run tests
in the dist target. Current test results:
Run tests in /home/claudio/figlet/figlet
_____ _ _ _
|_ _|__ __| |_ _ _ ___ ____ _| | |_ ___
| |/ -_|_-< _| | '_/ -_|_-< || | | _(_-<
|_|\___/__/\__| |_| \___/__/\_,_|_|\__/__/
Run test 001: showfigfonts output... pass
Run test 002: text rendering in all fonts... pass
Run test 003: long text rendering... pass
Run test 004: left-to-right text... pass
Run test 005: right-to-left text... pass
Run test 006: flush-left justification... pass
Run test 007: flush-right justification... pass
Run test 008: center justification... pass
Run test 009: kerning mode... pass
Run test 010: full width mode... pass
Run test 011: overlap mode... pass
Run test 012: TLF font rendering... pass
Run test 013: kerning flush-left right-to-left mode... pass
Run test 014: kerning centered right-to-left mode (slant)... pass
Run test 015: full-width flush-right right-to-left mode... pass
Run test 016: overlap flush-right mode (big)... pass
All tests passed.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Fix output corruption on line breaks caused by a previous attempt to
fix invalid memory accesses when smushing at the start of the line.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Changed showfigfont to use local figlet first. This is important for
our regression tests because we want to test the local figlet and
not the previously installed one from the system directories.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Reduce duplicate code by moving file opening code to the FIGopen()
function. This function is used to open font and control files, and
will be used to open multiple font files in ransom mode.
For code simplicity, DEFAULTFONTFILE is now defined without suffix.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Option -I5 lists supported file formats. If FIGlet is compiler with
TLF_FONTS defined, it will show tlf2 besides the always present flf2.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Recent history notes by Claudio Matsuoka and Ian Chai from
http://www.figlet.org/figlet_history.html added to figfonts.txt
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
This save us unnecessary conversions and attempts to convert
unitialized values, as reported by Valgrind.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
If a bad font file name is specified, display only the font name
without suffix, otherwise only the .tlf suffix is displayed (if
TLF_FONTS is defined)
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Found by inspection, the absence of function prototypes cause the compiler
to not issue a warning about this problem.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
The TLF font format is used by TOIlet and is very similar to the FLF
font format, the only difference being the presence of UTF-8 encoded
Unicode characters. This patch adds TLF support to FIGlet if TLF_FONTS
is defined in Makefile.
When TLF_FONTS is defined, the internal character format is changed
to UCS-4 wide characters. System requirements are support to UTF-8
multibyte encoding, a font capable of displaying Unicode glyphs and an
implementation of C99 wchar.h.
Warning: UTF-8 characters are allowed as endmarks and sub-characters, but
not as a hardblank symbol.
Example:
$ fortune | ./figlet -fpagga
░█▀█░▀█▀░█▀█░█▀▀░▀█▀░█░█░░░█▀█░█▀▀░█▀▄░█▀▀░█▀▀░█▀█░▀█▀░░░█▀█░█▀▀
░█░█░░█░░█░█░█▀▀░░█░░░█░░░░█▀▀░█▀▀░█▀▄░█░░░█▀▀░█░█░░█░░░░█░█░█▀▀
░▀░▀░▀▀▀░▀░▀░▀▀▀░░▀░░░▀░░░░▀░░░▀▀▀░▀░▀░▀▀▀░▀▀▀░▀░▀░░▀░░░░▀▀▀░▀░░
░█▀▀░█░█░█▀▀░█▀▄░█░█░▀█▀░█░█░▀█▀░█▀█░█▀▀░░░▀█▀░█▀▀░░░█▀▀░█▀▄░█▀█░█▀█░░░
░█▀▀░▀▄▀░█▀▀░█▀▄░░█░░░█░░█▀█░░█░░█░█░█░█░░░░█░░▀▀█░░░█░░░█▀▄░█▀█░█▀▀░░░
░▀▀▀░░▀░░▀▀▀░▀░▀░░▀░░░▀░░▀░▀░▀▀▀░▀░▀░▀▀▀░░░▀▀▀░▀▀▀░░░▀▀▀░▀░▀░▀░▀░▀░░░▀░
░░░░░░░░░░░░░░░▀█▀░█░█░█▀▀░█▀█░█▀▄░█▀█░█▀▄░█▀▀
░░░░░▄▄▄░▄▄▄░░░░█░░█▀█░█▀▀░█░█░█░█░█░█░█▀▄░█▀▀
░░░░░░░░░░░░░░░░▀░░▀░▀░▀▀▀░▀▀▀░▀▀░░▀▀▀░▀░▀░▀▀▀
░█▀▀░▀█▀░█░█░█▀▄░█▀▀░█▀▀░█▀█░█▀█
░▀▀█░░█░░█░█░█▀▄░█░█░█▀▀░█░█░█░█
░▀▀▀░░▀░░▀▀▀░▀░▀░▀▀▀░▀▀▀░▀▀▀░▀░▀
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
License change was discussed in the mailing list and authors agreed
to use a non-restrictive license as the AFL mandated redistribution
of source code with each copy of the binary, and could also conflict
with the GPL license.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Updated to version 2.2.3, release date 12 January 2011, and also add self
to author list with current year in Copyright notice.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
List current changes to the CHANGES file and call this version 2.3.
The version and date must be updated in several places before the
final release, including the FAQ and all man pages.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Add chkfont(6), figlist(6) and showfigfonts(6) manual pages contributed
by Jonathon Abbott to the Debian Project.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
This should make distribution package generation easier. Also removed
clang-specific entries since C flags are the same used in gcc.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
This makefile allows FIGlet to be built out-of-the-box using Turbo C++ 3.0
running maker -f Makefile.tc. To build with Turbo C++ 1.0, rename the file
to Makefile and run make.exe.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Also move man6 out of MANDIR to keep compatibility with modern canonical
usage of installation variables in Linux.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Explicitly initialize chkfont variables to prevent compiler warning,
and remove GCC-specific pragmas that don't work in all GCC versions
anyway -- warnings were still issued on the MinGW cross-compiler and
in the FreeBSD 8.0 gcc.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Not all non-GNU make(1) utility recognize $* in Makefile rule dependencies,
changed to a more compatible format to work e.g. with BSD make.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>
Actually verify return values of fgets() and fscanf() in chkfont instead
of disabling the warning.
Signed-off-by: Claudio Matsuoka <cmatsuoka@gmail.com>