aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornyamatongwe <devnull@localhost>2011-06-04 21:22:30 +1000
committernyamatongwe <devnull@localhost>2011-06-04 21:22:30 +1000
commit070fcf5b39c7abd211ce399478e9da6050c703eb (patch)
tree0a55f2a16d09c838a1386132565673c047662539
parent40eb38b93c00093a4abe034f7f902ef432c88a4f (diff)
downloadscintilla-mirror-070fcf5b39c7abd211ce399478e9da6050c703eb.tar.gz
Fixed compilation failure retrieving NSFont* from Font.
-rw-r--r--cocoa/PlatCocoa.mm3
1 files changed, 2 insertions, 1 deletions
diff --git a/cocoa/PlatCocoa.mm b/cocoa/PlatCocoa.mm
index a9ac95461..83ef691e5 100644
--- a/cocoa/PlatCocoa.mm
+++ b/cocoa/PlatCocoa.mm
@@ -1456,7 +1456,8 @@ void ListBoxImpl::SetFont(Font& font_)
font.SetID(font_.GetID());
// NSCell setFont takes an NSFont* rather than a CTFontRef but they
// are the same thing toll-free bridged.
- NSFont* pfont = (NSFont*)FontRef(font_);
+ QuartzTextStyle* style = reinterpret_cast<QuartzTextStyle*>(font_.GetID());
+ NSFont *pfont = (NSFont *)style->getFontRef();
[[colText dataCell] setFont: pfont];
CGFloat itemHeight = lround([pfont ascender] - [pfont descender]);
[table setRowHeight:itemHeight];