diff options
author | Geoff Voelker <voelker@cs.washington.edu> | 1999-01-22 19:58:23 +0000 |
---|---|---|
committer | Geoff Voelker <voelker@cs.washington.edu> | 1999-01-22 19:58:23 +0000 |
commit | 25d9ec8cc45ab2b1c0359859d4dc9bfbcb8ffa12 (patch) | |
tree | b01c917fa1dd443182cf76347e1dc21193af932b /src/w32term.h | |
parent | 640ea3c512d35ac0b8533b2c127976426cfd9971 (diff) | |
download | emacs-25d9ec8cc45ab2b1c0359859d4dc9bfbcb8ffa12.tar.gz |
(FONT_WIDTH, FONT_HEIGHT, FONT_BASE, FONT_MAX_WIDTH):
Support BDF fonts.
Diffstat (limited to 'src/w32term.h')
-rw-r--r-- | src/w32term.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/src/w32term.h b/src/w32term.h index 869c1df1847..aa4c8140451 100644 --- a/src/w32term.h +++ b/src/w32term.h @@ -28,10 +28,15 @@ Boston, MA 02111-1307, USA. */ #define BLACK_PIX_DEFAULT(f) PALETTERGB(0,0,0) #define WHITE_PIX_DEFAULT(f) PALETTERGB(255,255,255) -#define FONT_WIDTH(f) ((f)->tm.tmAveCharWidth) -#define FONT_HEIGHT(f) ((f)->tm.tmHeight) -#define FONT_BASE(f) ((f)->tm.tmAscent) -#define FONT_MAX_WIDTH(f) ((f)->tm.tmMaxCharWidth) +#define FONT_WIDTH(f) \ + ((f)->bdf ? (f)->bdf->width : (f)->tm.tmAveCharWidth) +#define FONT_HEIGHT(f) \ + ((f)->bdf ? (f)->bdf->height : (f)->tm.tmHeight) +/* No idea why 5 seems to work in here, but it does */ +#define FONT_BASE(f) \ + ((f)->bdf ? (f)->bdf->ury : (f)->tm.tmAscent) +#define FONT_MAX_WIDTH(f) \ + ((f)->bdf ? (f)->bdf->width : (f)->tm.tmMaxCharWidth) #define CHECK_W32_FRAME(f, frame) \ if (NILP (frame)) \ |