olikraus / u8g2

U8glib library for monochrome displays, version 2
Other
5.13k stars 1.05k forks source link

convert Arabic fonts( Unicode UTF-8 ) not work !! #2527

Open X960xx opened 3 days ago

X960xx commented 3 days ago

hello olikraus

I tried many times to convert Arabic fonts to work in my project, but I did not succeed. I do not know what the reason is ?

from ttf to BDF otf2bdf -r 72 -p 24 segoeui.ttf -o segoeui.bdf

from BDF to C file bdfconv -f 1 -m '32-255' -n segoeui-o segoeui.c segoeui.bdf bdfconv -v 0 -f 1 -m'32-128,$600-$06FF,$FB50-$FBB1,$FE70-$FEFF' -n u8g2_font_segoeui -o u8g2_font_segoeui.c segoeui.bdf bdfconv -b 0 -f 1 -m map/gb2312.map -n u8g2_font_segoeui -o u8g2_font_segoeui.c segoeui.bdf

Any help ?

thank you

olikraus commented 14 hours ago

Which command doesn't work? Basically you need a blank between the option and its arguments. Also the map file requires an uppercase -M

bdfconv [options] filename -h Display this help -v Print log messages -b Font build mode, 0: proportional, 1: common height, 2: monospace, 3: multiple of 8, 4: 5x7 mode -f Font format, 0: ucglib font, 1: u8g2 font, 2: u8g2 uncompressed 8x8 font (enforces -b 3) -m 'map' Unicode ASCII mapping -M 'mapfile' Read Unicode ASCII mapping from file 'mapname' -o C output font file -k C output file with kerning information -p <%> Minimum distance for kerning in percent of the global char width (lower values: Smaller gaps, more data) -x X-Offset for 8x8 font sub-glyph extraction (requires -f 2, default 0) -y Y-Offset for 8x8 font sub-glyph extraction (requires -f 2, default 0) -th Horizontal size of the 8x8 glyphs (requires -f 2, default 1) -tv Vertical size of the 8x8 glyphs (requires -f 2, default 1) -n C indentifier (font name) -d Overview picture: Enable generation of bdf.tga and assign BDF font for description -l Overview picture: Set left margin -g Overview picture: Set glyphs per line (default: 16) -a Overview picture: Additional font information (background, orange&blue dot) -t Overview picture: Test string (Woven silk pyjamas exchanged for blue quartz.) -r Runtime test