1303 files changed, 32187 insertions, 57138 deletions
diff --git a/console-tools/loadfont.c b/console-tools/loadfont.c index 032506d..52605ba 100644 --- a/console-tools/loadfont.c +++ b/console-tools/loadfont.c @@ -9,6 +9,57 @@ * * Licensed under GPLv2, see file LICENSE in this source tree. */ +//config:config LOADFONT +//config: bool "loadfont" +//config: default y +//config: select PLATFORM_LINUX +//config: help +//config: This program loads a console font from standard input. +//config: +//config:config SETFONT +//config: bool "setfont" +//config: default y +//config: select PLATFORM_LINUX +//config: help +//config: Allows to load console screen map. Useful for i18n. +//config: +//config:config FEATURE_SETFONT_TEXTUAL_MAP +//config: bool "Support reading textual screen maps" +//config: default y +//config: depends on SETFONT +//config: help +//config: Support reading textual screen maps. +//config: +//config:config DEFAULT_SETFONT_DIR +//config: string "Default directory for console-tools files" +//config: default "" +//config: depends on SETFONT +//config: help +//config: Directory to use if setfont's params are simple filenames +//config: (not /path/to/file or ./file). Default is "" (no default directory). +//config: +//config:comment "Common options for loadfont and setfont" +//config: depends on LOADFONT || SETFONT +//config: +//config:config FEATURE_LOADFONT_PSF2 +//config: bool "Support for PSF2 console fonts" +//config: default y +//config: depends on LOADFONT || SETFONT +//config: help +//config: Support PSF2 console fonts. +//config: +//config:config FEATURE_LOADFONT_RAW +//config: bool "Support for old (raw) console fonts" +//config: default y +//config: depends on LOADFONT || SETFONT +//config: help +//config: Support old (raw) console fonts. + +//applet:IF_LOADFONT(APPLET(loadfont, BB_DIR_USR_SBIN, BB_SUID_DROP)) +//applet:IF_SETFONT(APPLET(setfont, BB_DIR_USR_SBIN, BB_SUID_DROP)) + +//kbuild:lib-$(CONFIG_LOADFONT) += loadfont.o +//kbuild:lib-$(CONFIG_SETFONT) += loadfont.o //usage:#define loadfont_trivial_usage //usage: "< font" @@ -319,8 +370,10 @@ int loadfont_main(int argc UNUSED_PARAM, char **argv) * We used to look at the length of the input file * with stat(); now that we accept compressed files, * just read the entire file. + * Len was 32k, but latarcyrheb-sun32.psfu is 34377 bytes + * (it has largish Unicode map). */ - len = 32*1024; // can't be larger + len = 128*1024; buffer = xmalloc_read(STDIN_FILENO, &len); // xmalloc_open_zipped_read_close(filename, &len); if (!buffer) @@ -405,7 +458,7 @@ int setfont_main(int argc UNUSED_PARAM, char **argv) } } // load font - len = 32*1024; // can't be larger + len = 128*1024; buffer = xmalloc_open_zipped_read_close(*argv, &len); if (!buffer) bb_simple_perror_msg_and_die(*argv); |