X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/572820e134463899af617cd65dd2f06f09db7032..88ea89339783ee587180b645981967f6cb8bcd20:/unix/gtkfont.h diff --git a/unix/gtkfont.h b/unix/gtkfont.h index 72f1f6bf..1ed202bf 100644 --- a/unix/gtkfont.h +++ b/unix/gtkfont.h @@ -28,6 +28,14 @@ typedef struct unifont { * Font dimensions needed by clients. */ int width, height, ascent, descent; + + /* + * Indicates whether this font is capable of handling all glyphs + * (Pango fonts can do this because Pango automatically supplies + * missing glyphs from other fonts), or whether it would like a + * fallback font to cope with missing glyphs. + */ + int want_fallback; } unifont; unifont *unifont_create(GtkWidget *widget, const char *name, @@ -39,6 +47,18 @@ void unifont_draw_text(GdkDrawable *target, GdkGC *gc, unifont *font, int wide, int bold, int cellwidth); /* + * This function behaves exactly like the low-level unifont_create, + * except that as well as the requested font it also allocates (if + * necessary) a fallback font for filling in replacement glyphs. + * + * Return value is usable with unifont_destroy and unifont_draw_text + * as if it were an ordinary unifont. + */ +unifont *multifont_create(GtkWidget *widget, const char *name, + int wide, int bold, + int shadowoffset, int shadowalways); + +/* * Unified font selector dialog. I can't be bothered to do a * proper GTK subclassing today, so this will just be an ordinary * data structure with some useful members.