[PATCH] (Draft2) Make X11 server-side fonts and Mule suck less.
stephen at xemacs.org
stephen at xemacs.org
Wed Nov 1 02:34:13 EST 2006
Aidan Kehoe writes:
In the ChangeLog:
> Stop using the `registry' charset property; use `registries'
> instead. The difference is that registries is an ordered vector of
> X11 registries and encodings rather than a regexp; this means we
> can leave the matching to the X11 server, avoiding transferring
> huge amounts of data (perhaps across the network!) in order to do
> a regexp search on it.
Isn't this gratuitous difference with GNU?
There ought to be a way to get the best of both worlds. First, since
`charset-registry' already matches multiple charsets in the general
case, we don't need to change the name. Then
(1) Accept either a string (regexp) or vector of strings (explicit).
(2) If a regexp, use the old method, if a vector use yours.
(3) It's trivial to construct a regexp from a vector of strings, so
that's what `charset-registry' should return.
(4) `make-charset', `set-charset-registry', and friends (if they have
any! ;-) should warn on being handed a string.
(5) Bonus points for determining that a regexp is actually a
disjunction of fixed strings and turning it into a vector
internally. This is mostly a joke except for the presumably very
common and useful case of a single fixed string. (If I thought
GNU were going to stick with Mule indefinitely I'd consider it an
important compatibility feature, but I doubt they will.)
In the ChangeLog:
> * mule/mule-charset.el (charset-registries): New.
> * mule/mule-charset.el (set-charset-registry): New.
Isn't `set-charset-registry' in the above a typo?
> src/ChangeLog addition:
>
> 2006-10-31 Aidan Kehoe <kehoea at parhasard.net>
>
> * charset.h (XCHARSET_CCL_PROGRAM):
> * charset.h (XCHARSET_NAME):
> Make dummy versions of these available in non-Mule.
Other things being equal, I doubt this is a good idea. Why do you want it?
> * console-impl.h:
> * console-impl.h (struct console_methods):
> Rename the last parameter to a couple of methods; reformat their
> declarations.
The above will cause some annoyance to CHISE, Carbon XEmacs, and
possibly SXEmacs someday. Is it a good idea?
Can the rest of these be split out? I want them!
> 2006-10-31 Aidan Kehoe <kehoea at parhasard.net>
>
> * faces.el (face-property-matching-instance):
> Simplify.
> * faces.el (face-font-instance):
> Document CHARSET.
> * faces.el (set-face-font):
> Give more details on common values for font instantiators,
> LOCALEs.
> * unicode.el:
> Remove a few comments that were only relevant to GNU Emacs.
> * unicode.el (decode-char):
> * unicode.el (encode-char):
> src/ChangeLog addition:
>
> 2006-10-31 Aidan Kehoe <kehoea at parhasard.net>
>
>
> * faces.c:
> * faces.c (face_property_matching_instance):
> * faces.c (ensure_face_cachel_contains_charset):
> * faces.c (merge_face_cachel_data):
> * faces.c (reset_face_cachel):
> * faces.c (mark_face_cachels_as_not_updated):
> * faces.c (syms_of_faces):
> * faces.c (vars_of_faces):
> * faces.c (complex_vars_of_faces):
> Provide a DEBUG_FACES macro; use it to make debugging output
> available in debug builds.
> Implement multi-stage font lookup, assigning the stages names, not
> numbers.
> Re-implement the cachel->font_specified cache using the
> infrastructure for Lisp bit vectors.
>
> * faces.h:
> * faces.h (struct face_cachel):
> * faces.h (FACE_CACHEL_FONT_UPDATED):
> * faces.h (FACE_FONT):
> Re-implement the cachel->font_specified cache using the
> infrastructure for Lisp bit vectors.
>
> * font-mgr.h:
> Move some XFT debug macros here from objects-x.c.
>
> * general-slots.h:
> Provide a few new symbols for the multi-stage font resolution
> process.
>
> * intl.c (init_intl):
> Correct a comment.
>
> * objects-gtk.c:
> * objects-gtk.c (gtk_font_spec_matches_charset):
> * objects-gtk.c (gtk_find_charset_font):
> * objects-msw.c (mswindows_find_charset_font):
> * objects-tty.c (tty_find_charset_font):
> Redeclare various functions to work with the multi-stage lookup
> process.
>
> * objects-x.c (count_hyphens):
> New. How many ASCII minus characters in a string?
>
> * objects.c (print_font_instance):
> * objects.c (font_spec_matches_charset):
> * objects.c (font_validate_matchspec):
> * objects.c (font_instantiate):
> Redeclare some methods to take enums rather than numeric stages.
>
> * objects.h (EXFUN):
> Make Fregexp_quote available to mule-charset.c
>
> * redisplay-x.c:
> * redisplay-x.c (separate_textual_runs):
> Make this slightly faster, cleaner. Make it accept a face cachel
> pointer argument, and check it as to whether a given charset
> should be translated to UCS-2 before redisplay.
>
> * specifier.c:
> * specifier.c (charset_matches_specifier_tag_set_p):
> * specifier.c (define_specifier_tag):
> * specifier.c (Fdefine_specifier_tag):
> * specifier.c (setup_device_initial_specifier_tags):
> * specifier.c (setup_charset_initial_specifier_tags):
> * specifier.c (specifier_instance_from_inst_list):
> * specifier.c (syms_of_specifier):
> * specifier.c (vars_of_specifier):
> * specifier.h:
>
> Extend specifiers to allow limiting their applicability by using
> charset predicates. Document this.
>
> * unicode.c (unicode_to_ichar):
> * unicode.c (syms_of_unicode):
> * unicode.c (vars_of_unicode):
> Use unicode-registries, a dumped vector, as the charset-registries
> of the on-the-fly JIT charsets.
More information about the XEmacs-Patches
mailing list