ESC/P: Use the new dot matrix font

Also remove the fallback to Courier as it's no longer needed
This commit is contained in:
Alexander Babikov
2023-12-25 07:05:02 +05:00
parent ce05674b7d
commit e812b3c3b1
2 changed files with 1 additions and 12 deletions

View File

@@ -46,7 +46,7 @@
#ifndef PRINTER_H
#define PRINTER_H
#define FONT_FILE_DOTMATRIX "dotmatrix.ttf"
#define FONT_FILE_DOTMATRIX "dotmatrix.otf"
#define FONT_FILE_ROMAN "roman.ttf"
#define FONT_FILE_SANSSERIF "sansserif.ttf"

View File

@@ -545,17 +545,6 @@ update_font(escp_t *dev)
if (FT_New_Face(ft_lib, path, 0, &dev->fontface)) {
escp_log("ESC/P: unable to load font '%s'\n", path);
dev->fontface = NULL;
/* Try to fall back to Courier in case the dot matrix font is absent. */
if (!strcmp(fn, FONT_FILE_DOTMATRIX)) {
strcpy(path, dev->fontpath);
path_slash(path);
strcat(path, FONT_FILE_COURIER);
if (FT_New_Face(ft_lib, path, 0, &dev->fontface)) {
escp_log("ESC/P: unable to load font '%s'\n", path);
dev->fontface = NULL;
}
}
}
if (!dev->multipoint_mode) {