 |
 |
|
 |
05-14-2009, 10:40 PM
|
#1 (permalink)
|
|
New Member
Join Date: May 2009
Location: Beijing, CN
Posts: 23
|
How to convert word to lower or upper case in xcode?
In xcode editor, i want to change a piece of code to upper case, how can i do it quickly? such as change " my_tunner_charge" to "MY_TUNNER_CHARGE"?
There is any hotkeys? Or xcode never support this?
|
|
|
05-14-2009, 11:08 PM
|
#2 (permalink)
|
|
Registered Member
Join Date: Mar 2009
Posts: 82
|
Quote:
Originally Posted by iwind
In xcode editor, i want to change a piece of code to upper case, how can i do it quickly? such as change " my_tunner_charge" to "MY_TUNNER_CHARGE"?
There is any hotkeys? Or xcode never support this?
|
Same way you would in every program ~ use Find & Replace and turning off the ignore case option. Just hit command F to bring it up for one doc, command-shift F for multiple documents.
|
|
|
05-15-2009, 12:40 AM
|
#3 (permalink)
|
|
New Member
Join Date: May 2009
Location: Beijing, CN
Posts: 23
|
Quote:
Originally Posted by Lars
Same way you would in every program ~ use Find & Replace and turning off the ignore case option. Just hit command F to bring it up for one doc, command-shift F for multiple documents.
|
Thank you for replying! In fact, in some other IDEs(on Windows Operation System), i only need to press CTRL+L to make the selected words to lower case, and CTRL+U to make them to upper case.
Find & Replace maybe a choice, but i have to knock keys and input the word AGAIN!
Is there a shortcut to do this, just like CTRL+L and CTRL+U?
|
|
|
05-15-2009, 11:00 AM
|
#5 (permalink)
|
|
New Member
Join Date: May 2009
Location: Beijing, CN
Posts: 23
|
Quote:
Originally Posted by deansx
I'm not aware of a default key in Xcode to do this, but I've reprogrammed several keys to make my life easier.
...
|
After following the two links mentioned, I can use CTRL+SHIFT+U/L to change the words' case now!
Thanks you.
The last thing I need to point out is I MUST use Xcode Default Key Binding Sets, or It will do not work.
Last edited by iwind; 05-15-2009 at 11:12 AM.
|
|
|
05-15-2009, 09:33 PM
|
#6 (permalink)
|
|
Objective-C Code Monkey
Join Date: May 2009
Location: Mountain View, CA
Posts: 127
|
I'm glad that the technique worked for you. It's nice to have the key mappings that we love.
|
|
|
06-28-2009, 06:05 PM
|
#7 (permalink)
|
|
Registered Member
Join Date: Jun 2009
Posts: 25
|
Quote:
Originally Posted by iwind
In xcode editor, i want to change a piece of code to upper case, how can i do it quickly? such as change " my_tunner_charge" to "MY_TUNNER_CHARGE"?
There is any hotkeys? Or xcode never support this?
|
Go into xcode preferences -> KeyBindings ->Text Key Bindings -> Capitialize Word -> assign a key
now it'll uppercase when you select some text in the xcode editor and hit your assigned key
|
|
|
06-29-2009, 02:44 AM
|
#8 (permalink)
|
|
Registered Member
Join Date: Jun 2009
Posts: 15
|
Use "Lowercase and Uppercase" for all letters in word
Setting the Capitalize Word key will change the first letter of the word to capital. If you want to change all letters in a selection to capitals or lowers, then set a couple of keys for the Uppercase Word and Lowercase Word choices in Text Key Bindings.
i.e., Go into xcode preferences -> KeyBindings ->Text Key Bindings -> Uppercase Word -> assign a key
and
Go into xcode preferences -> KeyBindings ->Text Key Bindings -> Lowercase Word -> assign a different key
|
|
|
 |
| Thread Tools |
|
|
| Display Modes |
Linear Mode
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
» Advertisements |
» Online Users: 260 |
| 23 members and 237 guests |
| andrei_c, ataranlen, bensj, Bertrand21, bravetarget, carendt242, Chilibird, cye, harkonian, ihua, iTrackiGiveaway, jonahgabriel, LemonMeringue, ltgbau, maverick0, pjlocko, refreshe, RJaus, RobotWoods, SirGeraint, smrtital, warmi, zxl777 |
| Most users ever online was 779, 05-11-2009 at 09:55 AM. |
» Stats |
Members: 24,224
Threads: 39,002
Posts: 171,077
Top Poster: smasher (2,570)
|
| Welcome to our newest member, SpeJohn613 |
|