summaryrefslogtreecommitdiff
path: root/src/font.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2011-04-10 22:58:27 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2011-04-10 22:58:27 -0700
commit9247002884de0c64febb0807db428088800c39ff (patch)
treef96de259de91109b0999e3b4b3a31691346ada9a /src/font.c
parent244ed9077fe7ccebbc15c7157cb45832f46a46d3 (diff)
downloademacs-9247002884de0c64febb0807db428088800c39ff.tar.gz
font.c: Make copy_font_spec and merge_font_spec ordinary C functions.
* font.c (copy_font_spec): Rename from Fcopy_font_spec, since it was inaccessible from Lisp. (merge_font_spec): Likewise, renaming from Fmerge_font_spec. * font.c, font.h, fontset.c, xfaces.c, xfont.c: Change all uses.
Diffstat (limited to 'src/font.c')
-rw-r--r--src/font.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/font.c b/src/font.c
index 91cb0a2d52b..ace1b8442d4 100644
--- a/src/font.c
+++ b/src/font.c
@@ -2727,7 +2727,7 @@ font_list_entities (Lisp_Object frame, Lisp_Object spec)
val = null_vector;
else
val = Fvconcat (1, &val);
- copy = Fcopy_font_spec (scratch_font_spec);
+ copy = copy_font_spec (scratch_font_spec);
ASET (copy, FONT_TYPE_INDEX, driver_list->driver->type);
XSETCDR (cache, Fcons (Fcons (copy, val), XCDR (cache)));
}
@@ -2755,7 +2755,7 @@ font_matching_entity (FRAME_PTR f, Lisp_Object *attrs, Lisp_Object spec)
struct font_driver_list *driver_list = f->font_driver_list;
Lisp_Object ftype, size, entity;
Lisp_Object frame;
- Lisp_Object work = Fcopy_font_spec (spec);
+ Lisp_Object work = copy_font_spec (spec);
XSETFRAME (frame, f);
ftype = AREF (spec, FONT_TYPE_INDEX);
@@ -2782,7 +2782,7 @@ font_matching_entity (FRAME_PTR f, Lisp_Object *attrs, Lisp_Object spec)
else
{
entity = driver_list->driver->match (frame, work);
- copy = Fcopy_font_spec (work);
+ copy = copy_font_spec (work);
ASET (copy, FONT_TYPE_INDEX, driver_list->driver->type);
XSETCDR (cache, Fcons (Fcons (copy, entity), XCDR (cache)));
}
@@ -2976,7 +2976,7 @@ font_clear_prop (Lisp_Object *attrs, enum font_property_index prop)
if (! NILP (Ffont_get (font, QCname)))
{
- font = Fcopy_font_spec (font);
+ font = copy_font_spec (font);
font_put_extra (font, QCname, Qnil);
}
@@ -2987,7 +2987,7 @@ font_clear_prop (Lisp_Object *attrs, enum font_property_index prop)
&& prop != FONT_SIZE_INDEX)
return;
if (EQ (font, attrs[LFACE_FONT_INDEX]))
- font = Fcopy_font_spec (font);
+ font = copy_font_spec (font);
ASET (font, prop, Qnil);
if (prop == FONT_FAMILY_INDEX || prop == FONT_FOUNDRY_INDEX)
{
@@ -3098,7 +3098,7 @@ font_find_for_lface (FRAME_PTR f, Lisp_Object *attrs, Lisp_Object spec, int c)
return Qnil;
}
- work = Fcopy_font_spec (spec);
+ work = copy_font_spec (spec);
ASET (work, FONT_TYPE_INDEX, AREF (spec, FONT_TYPE_INDEX));
XSETFRAME (frame, f);
pixel_size = font_pixel_size (f, spec);
@@ -3868,9 +3868,9 @@ usage: (font-spec ARGS...) */)
return spec;
}
-DEFUE ("copy-font-spec", Fcopy_font_spec, Scopy_font_spec, 1, 1, 0,
- doc: /* Return a copy of FONT as a font-spec. */)
- (Lisp_Object font)
+/* Return a copy of FONT as a font-spec. */
+Lisp_Object
+copy_font_spec (Lisp_Object font)
{
Lisp_Object new_spec, tail, prev, extra;
int i;
@@ -3894,18 +3894,18 @@ DEFUE ("copy-font-spec", Fcopy_font_spec, Scopy_font_spec, 1, 1, 0,
return new_spec;
}
-DEFUE ("merge-font-spec", Fmerge_font_spec, Smerge_font_spec, 2, 2, 0,
- doc: /* Merge font-specs FROM and TO, and return a new font-spec.
-Every specified properties in FROM override the corresponding
-properties in TO. */)
- (Lisp_Object from, Lisp_Object to)
+/* Merge font-specs FROM and TO, and return a new font-spec.
+ Every specified property in FROM overrides the corresponding
+ property in TO. */
+Lisp_Object
+merge_font_spec (Lisp_Object from, Lisp_Object to)
{
Lisp_Object extra, tail;
int i;
CHECK_FONT (from);
CHECK_FONT (to);
- to = Fcopy_font_spec (to);
+ to = copy_font_spec (to);
for (i = 0; i < FONT_EXTRA_INDEX; i++)
ASET (to, i, AREF (from, i));
extra = AREF (to, FONT_EXTRA_INDEX);