diff options
author | nyamatongwe <nyamatongwe@gmail.com> | 2011-08-07 19:39:15 +1000 |
---|---|---|
committer | nyamatongwe <nyamatongwe@gmail.com> | 2011-08-07 19:39:15 +1000 |
commit | 0a1253d3507bec6a9dcab1006822aad3aacf5a58 (patch) | |
tree | 3509c11a6fe82cfb29b4acdfdd55b17cfac12901 /cocoa/QuartzTextStyleAttribute.h | |
parent | 59c0c0ebdffd339a2b1ae764358b1d2e2d708ae7 (diff) | |
download | scintilla-mirror-0a1253d3507bec6a9dcab1006822aad3aacf5a58.tar.gz |
Support a range of weights on Cocoa.
Diffstat (limited to 'cocoa/QuartzTextStyleAttribute.h')
-rw-r--r-- | cocoa/QuartzTextStyleAttribute.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/cocoa/QuartzTextStyleAttribute.h b/cocoa/QuartzTextStyleAttribute.h index 33c49281c..b9698645e 100644 --- a/cocoa/QuartzTextStyleAttribute.h +++ b/cocoa/QuartzTextStyleAttribute.h @@ -16,12 +16,13 @@ class QuartzFont { public: /** Create a font style from a name. */ - QuartzFont( const char* name, size_t length, float size, bool bold, bool italic ) + QuartzFont( const char* name, size_t length, float size, int weight, bool italic ) { assert( name != NULL && length > 0 && name[length] == '\0' ); CFStringRef fontName = CFStringCreateWithCString(kCFAllocatorDefault, name, kCFStringEncodingMacRoman); assert(fontName != NULL); + bool bold = weight > SC_WEIGHT_NORMAL; if (bold || italic) { |