aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKenichi Handa1997-06-21 00:44:42 +0000
committerKenichi Handa1997-06-21 00:44:42 +0000
commit7bca5cf2214f3ab2442bc3f1b5ef442ce1cc20b3 (patch)
tree496eeb5599965105bd50d5ee5a5c702c35b6c39c /src
parentbb8143d9b8db2e808ea6688b4567e07afaced72c (diff)
downloademacs-7bca5cf2214f3ab2442bc3f1b5ef442ce1cc20b3.tar.gz
emacs-7bca5cf2214f3ab2442bc3f1b5ef442ce1cc20b3.zip
(font_idx_temp): Extern it.
(FS_LOAD_FONT): New macro.
Diffstat (limited to 'src')
-rw-r--r--src/fontset.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/fontset.h b/src/fontset.h
index 7e999135d74..00aedb77c66 100644
--- a/src/fontset.h
+++ b/src/fontset.h
@@ -213,3 +213,21 @@ extern Lisp_Object Vhighlight_wrong_size_font;
213extern Lisp_Object Vclip_large_size_font; 213extern Lisp_Object Vclip_large_size_font;
214 214
215#endif /* _FONTSET_H */ 215#endif /* _FONTSET_H */
216extern int font_idx_temp;
217
218/* Load a font named FONTNAME for displaying CHARSET on frame F.
219 All fonts for frame F is stored in a table pointed by FONT_TABLE.
220 Return a pointer to the struct font_info of the loaded font.
221 If loading fails, return 0;
222 If FONTNAME is NULL, the name is taken from the information of FONTSET.
223 If FONTSET is given, try to load a font whose size matches that of
224 FONTSET, and, the font index is stored in the table for FONTSET. */
225
226#define FS_LOAD_FONT(f, font_table, charset, fontname, fontset) \
227 (fontset >= 0 && fontset < FRAME_FONTSET_DATA (f)->n_fontsets \
228 && (font_idx_temp = (FRAME_FONTSET_DATA (f) \
229 ->fontset_table[fontset]->font_indexes[charset]), \
230 font_idx_temp >= 0) \
231 ? font_table + font_idx_temp \
232 : fs_load_font (f, font_table, charset, fontname, fontset))
233