diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/ChangeLog | 4 | ||||
| -rw-r--r-- | src/nsfont.m | 14 |
2 files changed, 17 insertions, 1 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index 412e67828a7..6fe7de51293 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,9 @@ | |||
| 1 | 2012-10-21 Jan Djärv <jan.h.d@swipnet.se> | 1 | 2012-10-21 Jan Djärv <jan.h.d@swipnet.se> |
| 2 | 2 | ||
| 3 | * nsfont.m (nsfont_open, ns_glyph_metrics): Force integer advancement | ||
| 4 | for screen font. | ||
| 5 | (nsfont_draw): Turn off LCD-smoothing (Bug#11484). | ||
| 6 | |||
| 3 | * xterm.c (x_focus_changed): Check if daemonp when sending focus in | 7 | * xterm.c (x_focus_changed): Check if daemonp when sending focus in |
| 4 | event (Bug#12681). | 8 | event (Bug#12681). |
| 5 | 9 | ||
diff --git a/src/nsfont.m b/src/nsfont.m index 7c9f05aa0bb..4f29d1d54a9 100644 --- a/src/nsfont.m +++ b/src/nsfont.m | |||
| @@ -797,7 +797,13 @@ nsfont_open (FRAME_PTR f, Lisp_Object font_entity, int pixel_size) | |||
| 797 | block_input (); | 797 | block_input (); |
| 798 | 798 | ||
| 799 | /* for metrics */ | 799 | /* for metrics */ |
| 800 | #ifdef NS_IMPL_COCOA | ||
| 801 | sfont = [nsfont screenFontWithRenderingMode: | ||
| 802 | NSFontAntialiasedIntegerAdvancementsRenderingMode]; | ||
| 803 | #else | ||
| 800 | sfont = [nsfont screenFont]; | 804 | sfont = [nsfont screenFont]; |
| 805 | #endif | ||
| 806 | |||
| 801 | if (sfont == nil) | 807 | if (sfont == nil) |
| 802 | sfont = nsfont; | 808 | sfont = nsfont; |
| 803 | 809 | ||
| @@ -1229,6 +1235,7 @@ nsfont_draw (struct glyph_string *s, int from, int to, int x, int y, | |||
| 1229 | else | 1235 | else |
| 1230 | CGContextSetShouldAntialias (gcontext, 1); | 1236 | CGContextSetShouldAntialias (gcontext, 1); |
| 1231 | 1237 | ||
| 1238 | CGContextSetShouldSmoothFonts (gcontext, NO); | ||
| 1232 | CGContextSetTextMatrix (gcontext, fliptf); | 1239 | CGContextSetTextMatrix (gcontext, fliptf); |
| 1233 | 1240 | ||
| 1234 | if (bgCol != nil) | 1241 | if (bgCol != nil) |
| @@ -1372,7 +1379,12 @@ ns_glyph_metrics (struct nsfont_info *font_info, unsigned char block) | |||
| 1372 | #endif | 1379 | #endif |
| 1373 | 1380 | ||
| 1374 | block_input (); | 1381 | block_input (); |
| 1375 | sfont = [font_info->nsfont screenFont]; | 1382 | #ifdef NS_IMPL_COCOA |
| 1383 | sfont = [font_info->nsfont screenFontWithRenderingMode: | ||
| 1384 | NSFontAntialiasedIntegerAdvancementsRenderingMode]; | ||
| 1385 | #else | ||
| 1386 | sfont = [font_info->nsfont screenFont]; | ||
| 1387 | #endif | ||
| 1376 | 1388 | ||
| 1377 | font_info->metrics[block] = xzalloc (0x100 * sizeof (struct font_metrics)); | 1389 | font_info->metrics[block] = xzalloc (0x100 * sizeof (struct font_metrics)); |
| 1378 | if (!(font_info->metrics[block])) | 1390 | if (!(font_info->metrics[block])) |