comparison src/objects-xlike-inc.c @ 5027:22179cd0fe15

merge
author Ben Wing <ben@xemacs.org>
date Wed, 10 Feb 2010 07:25:19 -0600
parents d95c102a96d3
children
comparison
equal deleted inserted replaced
5026:46cf825f6158 5027:22179cd0fe15
1 /* Common code between X and GTK -- fonts and colors. 1 /* Common code between X and GTK -- fonts and colors.
2 Copyright (C) 1991-5, 1997 Free Software Foundation, Inc. 2 Copyright (C) 1991-5, 1997 Free Software Foundation, Inc.
3 Copyright (C) 1995 Sun Microsystems, Inc. 3 Copyright (C) 1995 Sun Microsystems, Inc.
4 Copyright (C) 1996, 2001, 2002, 2003 Ben Wing. 4 Copyright (C) 1996, 2001, 2002, 2003, 2010 Ben Wing.
5 5
6 This file is part of XEmacs. 6 This file is part of XEmacs.
7 7
8 XEmacs is free software; you can redistribute it and/or modify it 8 XEmacs is free software; you can redistribute it and/or modify it
9 under the terms of the GNU General Public License as published by the 9 under the terms of the GNU General Public License as published by the
104 the_nonreloc = XSTRING_DATA (reloc); 104 the_nonreloc = XSTRING_DATA (reloc);
105 fixup_internal_substring (nonreloc, reloc, offset, &the_length); 105 fixup_internal_substring (nonreloc, reloc, offset, &the_length);
106 the_nonreloc += offset; 106 the_nonreloc += offset;
107 107
108 #ifdef USE_XFT 108 #ifdef USE_XFT
109 if (stage) 109 if (stage == STAGE_FINAL)
110 { 110 {
111 Display *dpy = DEVICE_X_DISPLAY (d); 111 Display *dpy = DEVICE_X_DISPLAY (d);
112 Extbyte *extname; 112 Extbyte *extname;
113 XftFont *rf; 113 XftFont *rf;
114 const Ibyte *the_nonreloc; 114 const Ibyte *the_nonreloc;
144 && (5 > (count_hyphens(the_nonreloc, the_length, NULL)))) 144 && (5 > (count_hyphens(the_nonreloc, the_length, NULL))))
145 { 145 {
146 return 1; 146 return 1;
147 } 147 }
148 148
149 if (final == stage) 149 if (STAGE_FINAL == stage)
150 { 150 {
151 registries = Qunicode_registries; 151 registries = Qunicode_registries;
152 } 152 }
153 else if (initial == stage) 153 else if (STAGE_INITIAL == stage)
154 { 154 {
155 registries = XCHARSET_REGISTRIES (charset); 155 registries = XCHARSET_REGISTRIES (charset);
156 if (NILP(registries)) 156 if (NILP(registries))
157 { 157 {
158 return 0; 158 return 0;
387 const Extbyte *patternext; 387 const Extbyte *patternext;
388 Lisp_Object result = Qnil; 388 Lisp_Object result = Qnil;
389 389
390 /* #### with Xft need to handle second stage here -- sjt 390 /* #### with Xft need to handle second stage here -- sjt
391 Hm. Or maybe not. That would be cool. :-) */ 391 Hm. Or maybe not. That would be cool. :-) */
392 if (stage) 392 if (stage == STAGE_FINAL)
393 return Qnil; 393 return Qnil;
394 394
395 /* Fontconfig converts all FreeType names to UTF-8 before passing them 395 /* Fontconfig converts all FreeType names to UTF-8 before passing them
396 back to callers---see fcfreetype.c (FcFreeTypeQuery). 396 back to callers---see fcfreetype.c (FcFreeTypeQuery).
397 I don't believe this is documented. */ 397 I don't believe this is documented. */
681 } 681 }
682 #endif 682 #endif
683 683
684 switch (stage) 684 switch (stage)
685 { 685 {
686 case initial: 686 case STAGE_INITIAL:
687 { 687 {
688 if (!(NILP(XCHARSET_REGISTRIES(charset))) 688 if (!(NILP(XCHARSET_REGISTRIES(charset)))
689 && VECTORP(XCHARSET_REGISTRIES(charset))) 689 && VECTORP(XCHARSET_REGISTRIES(charset)))
690 { 690 {
691 registries_len = XVECTOR_LENGTH(XCHARSET_REGISTRIES(charset)); 691 registries_len = XVECTOR_LENGTH(XCHARSET_REGISTRIES(charset));
692 registries = XCHARSET_REGISTRIES(charset); 692 registries = XCHARSET_REGISTRIES(charset);
693 } 693 }
694 break; 694 break;
695 } 695 }
696 case final: 696 case STAGE_FINAL:
697 { 697 {
698 registries_len = 1; 698 registries_len = 1;
699 registries = Qunicode_registries; 699 registries = Qunicode_registries;
700 break; 700 break;
701 } 701 }