PDA

View Full Version : How to let first letter keep lower in Xcode?




mikezang
Jul 13, 2010, 09:26 AM
I defined a class as below, when I typed code after "*s" in @property, Xcode gave me a prompt for "SwitchViewController", but I need "switchViewController", what can I let Xcode keep that first letter in lower case?

@interface MyAppDelegate: NSObject < UIApplicationDelegate> {
SwitchViewController *switchViewController;

@property (nonatomic, retain) IBOutlet SwitchViewController *
@end



dejo
Jul 13, 2010, 10:16 AM
Just keep typing and it'll switch to the lower-case version when you hit the V. Another approach to take to make sure it autocompletes quicker is to not give your instance variables the same name (other than case) as your class names, such as mySwitchViewController or aSwitchViewController or initialSwitchViewController or something like that.

mikezang
Jul 13, 2010, 11:53 PM
Thanks for your suggestion.

I used a alt way to do it, pressed ESC, so it switch to lower case.