Files
lotherkandClaude Opus 5.5 ac0952a29b mcde: anti-aliased Hack everywhere; dtterm draws through Xft with UTF-8 and glyph fallback
Fonts:
- fonts/hack: Hack 3.003 (Expat + Bitstream Vera, from Debian fonts-hack),
  installed to dt/fonts; config/fonts.conf (the system's fontconfig plus
  that directory) exported by Xsession.d/0070.dtfonts and
  Dtlogin*environment.
- sys.resources and dtlogin Xresources: Xft render tables in Hack 10 for
  renderTable, textRenderTable, labelRenderTable, buttonRenderTable (a
  render table wins over sys.font's *FontList; dtterm and text fields read
  the text table).
dtterm (ported from MakroDE -- setlocale and the Xft renderer -- then fixed):
- configure: Xft on by default, --disable-xft for machines without it.
- TermPrimRenderXft.c: reads wchar_t in multibyte locales (it read the
  buffer as UTF-8 bytes: three boxes after every character), places every
  character in its cell on the baseline, fills the background, draws
  underline/overstrike/secure, wcwidth for wide and combining characters,
  borrows glyphs from fontconfig fallbacks (check mark, CJK), and makes its
  XftDraw at the first drawing (made in Initialize it was window 0, and the
  first string a BadDrawable that ended dtterm).
- TermPrim.c AdjustWindowUnits: the cell from the renderer's extents when
  there is no XFontStruct (crashed with Xft); _DtTermPrimRenderFontExtents.
- TermPrimRenderFont.c: with setlocale the buffer is wchar_t in UTF-8, the
  single-font renderer draws it as XChar2b (it drew boxes too).
Screenshots: build/mcde-shots/dtterm-utf8b-crop.png, dtterm-classic-crop.png.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-09 23:55:41 +00:00

51 lines
1.5 KiB
Makefile

MAINTAINERCLEANFILES = Makefile.in
noinst_LTLIBRARIES = libTermPrim.la
AM_CPPFLAGS = $(DT_INCDIR)
libTermPrim_la_SOURCES = TermPrim.c \
TermPrimAction.c \
TermPrimBuffer.c \
TermPrimBufferWc.c \
TermPrimCursor.c \
TermPrimDebug.c \
TermPrimFunction.c \
TermPrimLineDraw.c \
TermPrimParse.c \
TermPrimParseTable.c \
TermPrimParser.c \
TermPrimPendingText.c \
TermPrimRender.c \
TermPrimRenderMb.c \
TermPrimRenderFont.c \
TermPrimRenderFontSet.c \
TermPrimRenderXft.c \
TermPrimRenderLineDraw.c \
TermPrimRepType.c \
TermPrimScroll.c \
TermPrimSelect.c \
TermPrimSetPty.c \
TermPrimSetUtmp.c \
TermPrimSubproc.c \
TermPrimUtil.c \
TermPrimVersion.c \
TermPrimWMProtocols.c
# JET there may be some more missing here...
if SOLARIS
libTermPrim_la_SOURCES += TermPrimGetPty-svr4.c
else
libTermPrim_la_SOURCES += TermPrimGetPty-pts.c
endif
# MakroDE addition (13b): dtterm draws through Xft for entries that are Xft fonts. configure.ac
# checks for it; debian/control carries the Build-Depends. The classic fontset path does not
# need any of this, so a machine that lacks Xft still builds -- it just has one way fewer.
libTermPrim_la_LIBADD = $(XFTLIB)
# Only set when --enable-xft was given: Xft.h includes <ft2build.h>, which lives in
# /usr/include/freetype2 on this system, and pkg-config is what knows that.
AM_CPPFLAGS += $(XFT_CFLAGS)