dictionaryWithObjectsAndKeys
dictionaryWithObjectsAndKeys
- Subject: dictionaryWithObjectsAndKeys
- From: email@hidden
- Date: Sat, 9 Oct 2010 13:05:22 -0600
I want to make a NSDictionary of text attributes to apply to text
being drawn in a NSTextFieldCell.
This
m_textAttributes = [NSDictionary dictionaryWithObjectsAndKeys: [NSFont
systemFontOfSize:12.0], NSFontAttributeName, NSRightTextAlignment,
NSTextAlignment, nil];
gives this error:
error: syntax error before 'NSTextAlignment'
I want to use m_textAttributes to draw text right aligned eith the
specified font.
[m_obstacleName drawInRect:cellFrame withAttributes:m_textAttributes];
So two questions:
1. What is the syntax error, as the docs show a similar example
2. is there a better way to right align text
-koko
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden