Mercurial > emacs
diff mac/src/macfns.c @ 35660:b9366f467430
* alloc.c (allocate_string) [macintosh]: Call check_string_bytes
only if current_sblock has been initialized.
* frame.c (Fdelete_frame) [macintosh]: Allow deletion of initial
terminal frame even if it is the only visible frame.
* src/macfns.c (QCconversion): Replaces QCalgorithm.
* src/macfns.c (image_ascent, lookup_image): Adapt to change of
image margins.
* src/macterm.c (x_produce_image_glyph, x_draw_image_foreground)
(x_draw_image_relief, x_draw_image_foreground_1)
(x_draw_image_glyph_string): Adapt to change of image margins.
* src/macterm.c (mac_to_x_fontname): Change charset name of
Simplify Chinese fonts from gb2312 to gb2312.1980 and Korean fonts
from ksc5601 to ksc5601.1989.
author | Andrew Choi <akochoi@shaw.ca> |
---|---|
date | Sun, 28 Jan 2001 11:23:07 +0000 |
parents | 94435b0ce7fd |
children | 350e6092a4c4 |
line wrap: on
line diff
--- a/mac/src/macfns.c Sun Jan 28 03:43:35 2001 +0000 +++ b/mac/src/macfns.c Sun Jan 28 11:23:07 2001 +0000 @@ -4365,7 +4365,7 @@ extern Lisp_Object QCwidth, QCheight, QCforeground, QCbackground, QCfile; extern Lisp_Object QCdata; Lisp_Object QCtype, QCascent, QCmargin, QCrelief; -Lisp_Object QCalgorithm, QCcolor_symbols, QCheuristic_mask; +Lisp_Object QCconversion, QCcolor_symbols, QCheuristic_mask; Lisp_Object QCindex; /* Other symbols. */ @@ -4756,7 +4756,7 @@ struct image *img; struct face *face; { - int height = img->height + img->margin; + int height = img->height + img->vmargin; int ascent; if (img->ascent == CENTERED_IMAGE_ASCENT) @@ -5044,8 +5044,7 @@ { /* Handle image type independent image attributes `:ascent PERCENT', `:margin MARGIN', `:relief RELIEF'. */ - Lisp_Object ascent, margin, relief, algorithm, heuristic_mask; - Lisp_Object file; + Lisp_Object ascent, margin, relief; ascent = image_spec_value (spec, QCascent, NULL); if (INTEGERP (ascent)) @@ -5055,24 +5054,23 @@ margin = image_spec_value (spec, QCmargin, NULL); if (INTEGERP (margin) && XINT (margin) >= 0) - img->margin = XFASTINT (margin); + img->vmargin = img->hmargin = XFASTINT (margin); + else if (CONSP (margin) && INTEGERP (XCAR (margin)) + && INTEGERP (XCDR (margin))) + { + if (XINT (XCAR (margin)) > 0) + img->hmargin = XFASTINT (XCAR (margin)); + if (XINT (XCDR (margin)) > 0) + img->vmargin = XFASTINT (XCDR (margin)); + } relief = image_spec_value (spec, QCrelief, NULL); if (INTEGERP (relief)) { img->relief = XINT (relief); - img->margin += abs (img->relief); + img->hmargin += abs (img->relief); + img->vmargin += abs (img->relief); } - - /* Should we apply a Laplace edge-detection algorithm? */ - algorithm = image_spec_value (spec, QCalgorithm, NULL); - if (img->pixmap && EQ (algorithm, Qlaplace)) - x_laplace (f, img); - - /* Should we built a mask heuristically? */ - heuristic_mask = image_spec_value (spec, QCheuristic_mask, NULL); - if (img->pixmap && !img->mask && !NILP (heuristic_mask)) - x_build_heuristic_mask (f, img, heuristic_mask); } } @@ -9785,8 +9783,8 @@ staticpro (&Qxbm); QCtype = intern (":type"); staticpro (&QCtype); - QCalgorithm = intern (":algorithm"); - staticpro (&QCalgorithm); + QCconversion = intern (":conversion"); + staticpro (&QCconversion); QCheuristic_mask = intern (":heuristic-mask"); staticpro (&QCheuristic_mask); QCcolor_symbols = intern (":color-symbols");