Commit 880b7166 authored by Jan Djärv's avatar Jan Djärv

* macfont.h (macfont_update_antialias_threshold): Declare.

* macfont.m (macfont_update_antialias_threshold): Remove static.

* nsterm.h (EmacsApp): Add antialiasThresholdDidChange.

* nsterm.m (applicationDidFinishLaunching:): Call
antialiasThresholdDidChange, register for antialias changes.
(antialiasThresholdDidChange:): New method for EmacsApp.

Fixes: debbugs:17534
parent eb8cb39e
2014-07-20 Jan Djärv <jan.h.d@swipnet.se>
* nsterm.m (applicationDidFinishLaunching:): Call
antialiasThresholdDidChange, register for antialias changes (Bug#17534).
(antialiasThresholdDidChange:): New method for EmacsApp.
* nsterm.h (EmacsApp): Add antialiasThresholdDidChange.
* macfont.m (macfont_update_antialias_threshold): Remove static.
* macfont.h (macfont_update_antialias_threshold): Declare.
2014-07-17 Eli Zaretskii <eliz@gnu.org>
* w32select.c (setup_windows_coding_system): Apply
......
......@@ -144,4 +144,5 @@ typedef const struct _EmacsScreenFont *ScreenFontRef; /* opaque */
extern void mac_register_font_driver (struct frame *f);
extern void *macfont_get_nsctfont (struct font *font);
extern void macfont_update_antialias_threshold (void);
......@@ -729,7 +729,7 @@ static void mac_font_get_glyphs_for_variants (CFDataRef, UTF32Char,
static CGFloat macfont_antialias_threshold;
static void
void
macfont_update_antialias_threshold (void)
{
int threshold;
......
......@@ -111,6 +111,7 @@ typedef float EmacsCGFloat;
#endif
}
- (void)logNotification: (NSNotification *)notification;
- (void)antialiasThresholdDidChange:(NSNotification *)notification;
- (void)sendEvent: (NSEvent *)theEvent;
- (void)showPreferencesWindow: (id)sender;
- (BOOL) openFile: (NSString *)fileName;
......
......@@ -4668,9 +4668,30 @@ - (void)applicationDidFinishLaunching: (NSNotification *)notification
((EmacsApp *)self)->applicationDidFinishLaunchingCalled = YES;
#endif
[NSApp setServicesProvider: NSApp];
[self antialiasThresholdDidChange:nil];
#ifdef NS_IMPL_COCOA
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
[[NSNotificationCenter defaultCenter]
addObserver:self
selector:@selector(antialiasThresholdDidChange:)
name:NSAntialiasThresholdChangedNotification
object:nil];
#endif
#endif
ns_send_appdefined (-2);
}
- (void)antialiasThresholdDidChange:(NSNotification *)notification
{
#ifdef NS_IMPL_COCOA
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
macfont_update_antialias_threshold ();
#endif
#endif
}
/* Termination sequences:
C-x C-c:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment