DejaVuSansMono.ttf: added to repository for convenience.

mirc2png.py:main(): default fontFilePath to `DejaVuSansMono.ttf'.
This commit is contained in:
Lucio Andrés Illanes Albornoz 2018-01-02 16:58:15 +01:00
parent abaa92b53d
commit 734cc19333
2 changed files with 6 additions and 6 deletions

BIN
DejaVuSansMono.ttf Normal file

Binary file not shown.

View File

@ -194,15 +194,15 @@ class MiRCART:
# #
# Entry point # Entry point
def main(argv0, inFilePath, imgFilePath, fontFilePath, fontSize=11): def main(argv0, inFilePath, imgFilePath, fontFilePath="DejaVuSansMono.ttf", fontSize=11):
_MiRCART = MiRCART(inFilePath, imgFilePath, fontFilePath, fontSize) _MiRCART = MiRCART(inFilePath, imgFilePath, fontFilePath, fontSize)
if __name__ == "__main__": if __name__ == "__main__":
if ((len(sys.argv) - 1) < 3)\ if ((len(sys.argv) - 1) < 2)\
or ((len(sys.argv) - 1) > 4): or ((len(sys.argv) - 1) > 4):
print("usage: {} " \ print("usage: {} " \
"<MiRCART input file pathname> " \ "<MiRCART input file pathname> " \
"<PNG image output file pathname> " \ "<PNG image output file pathname> " \
"<Font file pathnane> " \ "[<Font file pathname; defaults to DejaVuSansMono.ttf>] " \
"[<Font size; defaults to 11>]".format(sys.argv[0]), file=sys.stderr) "[<Font size; defaults to 11>]".format(sys.argv[0]), file=sys.stderr)
else: else:
main(*sys.argv) main(*sys.argv)