1
0
mirror of synced 2026-01-12 00:42:56 +00:00

10 Commits

Author SHA1 Message Date
Matt Heffron
71894e9b54 Make CHARSETENCODING and FONTCHARENCODING values of CHARSETINFO and FONTDESCRIPTOR, respectively, explicitly be MCCS 2025-12-08 12:18:35 -08:00
Matt Heffron
27d4e7aab2 More bugs discovered and fixed.
(This needs regression tests. "Harmless" edits aren't!)
Documentation review changes.
2025-12-02 16:13:26 -08:00
Matt Heffron
b5ccfdc4e7 Fixed incomplete description in documentation.
Changed parameters for BUILD-COMPOSITE to simplify, and enable keyword :VERBOSE parameter.
Added some VERBOSE progress messages.
2025-12-01 23:39:59 -08:00
Matt Heffron
a8a427597f Significant restructuring:
Removed WRITE-BDF-TO-DISPLAYFONT-FILE (i.e., no STRIKE format files).
No multiple-values returned. Instead, use LIST when appropriate.
BDF-TO-CHARSETINFO is now IDEMPOTENT w.r.t. the GLYPHS.
Move resolution and defaulting of FAMILY, FACE, SIZE, ROTATION, DEVICE from WRITE-BDF-TO-MEDLEYDISPLAYFONT-FILE to BDF-TO-FONTDESCRIPTOR.
Keep the MCCS chars present BITMAP in the BDF-FONT structure, instead of needing to schlepping it around separately.
Abstracted testing/setting the MCCS chars present bits to CHAR-PRESENT-BIT (mimicking BITMAPBIT).
Added COUNT-MCHARS to know how many MCCS chars are marked in the BITMAP as present.
READ-BDF now handles when UTOMCODE? returns multiple mappings, and creates the appropriate duplicate GLYPHS with different MCCS char codes.
READ-GLYPH doesn't create an empty BITMAP for spacing glyphs.

Use font code changes:
Set (CHARSETINFO CHARSETNO).
Set (FONTDESCRIPTOR FONTSLUGWIDTH).
2025-11-30 17:46:12 -08:00
Matt Heffron
b10d90b42f More progress on composite files.
WRITE-BDF-TO-DISPLAYFONT-FILES is deprecated (but symbols imported from IL: only for use there are not yet removed from :IMPORT-FROM)
2025-11-19 22:07:50 -08:00
Matt Heffron
defd68a892
READ-BDF initial changes for XCCS to MCCS (#2360)
* Verbose mode (READ-BDF) was implemented incorrectly - fixed
* Cleanup DEFPACKAGE in source file using :IMPORT-FROM, and fewer imports.
* Various renaming for consistency with XCCS -> MCCS changes.
* Use IL:FONTSPEC record instead of using FIRST, SECOND, etc.
* Fix the parsing of IL:FONTSPEC to use COMPRESSED instead of incorrect CONDENSED.
* Zero-width "image" with zero-width "escapement" GLYPHS now get put into NOMAPPINGCHARSET.
* Add (FILES (SYSLOAD) SYSEDIT) under existing (DECLARE: EVAL@COMPILE DONTCOPY ...)
2025-11-17 10:44:23 -08:00
Matt Heffron
30872f62e7
READ-BDF Fix incorrect detection of Italic font slope from BDF font metadata. (#2132)
Fix incorrect detection of Italic font slope from BDF font metadata.
2025-05-01 06:45:29 -07:00
Matt Heffron
39ebd40da4
READ-BDF: Handle newly encountered cases in BDF files. (#2108)
* Better handling of a glyph with ENCODING of -1. 
I treat it as the _slug_ glyph, instead of the _default_ of a solid block.

* Handle scrambled bitmaps issue #2109.
Glyphs with zero width bitmap *and* zero advance (_escapement_) caused miscalculated glyph offsets into the CHARSETINFO bitmap.

* Allow and ignore COMMENT lines preceding the STARTFONT line.
Add error checking for extracting font FAMILY, SIZE, FACE, etc. from the BDF-FONT object.
Add recommendation to documentation to write the DISPLAYFONT files to a directory separate from the system's IL:DISPLAYFONTDIRECTORIES locations.

* Account for glyphs with a negative initial offset.

* Add VERBOSE optional parameter to READ-BDF to report font internal FAMILY, FACE, etc.
Change &OPTIONAL parameters of WRITE-BDF-TO-DISPLAYFONT-FILES to &KEY to simplify calling. (No need to remember the order.)
Add CHAR-SETS and WRITE-UNMAPPED parameters to WRITE-BDF-TO-DISPLAYFONT-FILES to allow some level of control of which DISPLAYFONT files are written.
Updated documentation, and added warning note about font's FAMILY containing any digits.
2025-04-28 11:40:08 -07:00
Matt Heffron
1491fa91cc
READ-BDF add ability to create FONTDESCRIPTOR and write DISPLAYFONT files (#2015)
* Now can create the FONTDESCRIPTOR with all non-empty charsets.
Can write DISPLAYFONTFILE format ("STRIKE") files for the charsets.
Add ability to use mapping of Unicode charcode to unknown XCCS charcode in the private space.

* Create 2nd FONTDESCRIPTOR for unmapped Unicode to XCCS charcodes, organized by charset-like (8-bit splitting of charcode) of Unicode encoding value.

* Added option to create and write files for RAW FONTDESCRIPTOR which does NO mapping from Unicode to XCCS.
All glyphs are at the Unicode encoding positions.
Any glyphs with Unicode encoding > xFFFF are not included in the FONTDESCRIPTOR or DISPLAYFONT files.

* Fix a bug where I assumed glyph names couldn't be parsed as a number; and a little cleanup.
The linux otf2bdf utility uses the hex of encoding value as the name, which can appear to be a FLOAT and overflow (i.e., 3D39). 
Similar parsing problem fixed and corrected an error message.

* Initial documentation file written.
2025-04-14 12:08:10 -07:00
Matt Heffron
e1989850f3
Added new module READ-BDF. (#1811)
* Added new module READ-BDF.
This will parse a bdf font file into a BDF::BDF-FONT structure.
It does NOT create (convert into) an IL:FONTDESCRIPTOR instance.
Minimal error checking!

* Remove work-around for bug in CL:READ-FROM-STRING that is fixed in PR #1833
2024-09-26 14:08:36 -07:00