diff options
| author | nyamatongwe <nyamatongwe@gmail.com> | 2013-05-02 09:46:17 +1000 |
|---|---|---|
| committer | nyamatongwe <nyamatongwe@gmail.com> | 2013-05-02 09:46:17 +1000 |
| commit | 689638d1e56d14d052fbb48048e03b8c361e5a67 (patch) | |
| tree | edd2cba36f3065aa7c45863f209f663ae31ef702 /cocoa/ScintillaCocoa.mm | |
| parent | feeb0152926363ab76b13d850b47528f879b864d (diff) | |
| download | scintilla-mirror-689638d1e56d14d052fbb48048e03b8c361e5a67.tar.gz | |
Feature: [feature-requests:#988]. Cocoa support for font quality.
From Mark Yen.
Diffstat (limited to 'cocoa/ScintillaCocoa.mm')
| -rw-r--r-- | cocoa/ScintillaCocoa.mm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/cocoa/ScintillaCocoa.mm b/cocoa/ScintillaCocoa.mm index 004a1dc46..f018aa351 100644 --- a/cocoa/ScintillaCocoa.mm +++ b/cocoa/ScintillaCocoa.mm @@ -1525,6 +1525,14 @@ bool ScintillaCocoa::SyncPaint(void* gc, PRectangle rc) Surface *sw = Surface::Allocate(SC_TECHNOLOGY_DEFAULT); if (sw) { + CGContextSetAllowsAntialiasing((CGContextRef)gc, + vs.extraFontFlag != SC_EFF_QUALITY_NON_ANTIALIASED); +#if MAC_OS_X_VERSION_MAX_ALLOWED > MAC_OS_X_VERSION_10_5 + if (CGContextSetAllowsFontSubpixelPositioning != NULL) + CGContextSetAllowsFontSubpixelPositioning((CGContextRef)gc, + vs.extraFontFlag == SC_EFF_QUALITY_DEFAULT || + vs.extraFontFlag == SC_EFF_QUALITY_LCD_OPTIMIZED); +#endif sw->Init(gc, wMain.GetID()); Paint(sw, rc); succeeded = paintState != paintAbandoned; |
