Hacker News new | ask | show | jobs
by rgbrgb 5672 days ago
Agreed. I had the exact opposite reaction when I started doing some Android dev after coming from iPhone.

I find Xcode to be at least 80,000 times better than Eclipse (memory usage, UI, interface builder, speed, general bugginess).

I also REALLY like Apple's docs and the ease of integrating C code (no NDK!) when you need to do something like real-time audio.

My only really big complaint is the certificate signing process which can be a real pain.

I mean, I can totally see why Android might feel better or more familiar to a Java programmer though.

3 comments

I have a question. I asked this to a few mac users and haven't received a good answer.

How the hell do you get xcode (or other programs, but xcode is particularly bad) not to end up being a big piles of small windows you can't access effectively because they don't have a dock icon? The only way I found, was to long-click on the xcode dock icon which after a while splatters small versions of the windows everywhere, then scan these tiled windows until I find the right one and click on it. I have to do that atrociously long multi-step process every damn time I wan't to take a glance at another window! This, for example, makes the internal iOS documentation useless to me. At least I can use the web documentation to get the browser dock icon but when I don't have an internet connection I'm out of luck.

While I'm at it, is there any way, when using 'Spaces' to do a desktop change in one click? I'm mainly a Linux user and I'm used to having multiple desktops. OSX also has this functionality, and the 'Spaces' icon actually has four little square on it that represents the four desktops it's controlling. However when I click on one of the small squares, instead of going to the right desktop like it does in Gnome/Linux (and has been doing right since about 1995), it goes into an animation where the four desktop are displayed tiled full screen and I have to pick one. That is a two step process with an animation in between for something that should clearly be instantaneous. Is there an alternative to this. Both these things are driving me insane!

Like in the article, I bought a mac just to do iOS development and up to now my experience on osx felt like using a broken out of date gnome desktop with serious usability issues.

To use XCode in a single window, switch it to the All-in-One layout in the preferences:

http://iphonedevelopment.blogspot.com/2009/03/xcode-single-w...

Also, in any OS X application with multiple windows you can use Command-` (i.e. Command + backtick key) to switch between windows of the active application.

I'll add this because it has happened to me - sometimes you're in all in one mode and you still don't see your code, just the file name that you selected at the top of the window - this is because there is a horizontal divider that is pulled all the way to the bottom of the window. Look for 1 little dot at the bottom of the window in the center, if you drag that up you'll be able to see your code again.
All-in-One is kinda nice. It seems it should be the default. It still doesn't make the documentation window of any use though. I guess it has a little less chance of being hidden under a pile of other windows now. Command+backtick doesn't seem to do anything on my mac.
Strange that Cmd-backtick doesn't work for you. Try this: Open up System Preferences, select "Keyboard", change to the "Keyboard Shortcuts" tab, and highlight "Keyboard & Text Input" on the left. Is the "Move focus to next window in application" box checked? What's its shortcut?

Also, long-clicking on the dock icon just activates Expose for Application Windows. I have it set-up to activate upon mousing to the top right corner and really like it. You don't have to wait for the delay of clicking and holding on the dock, though you'll still have to scan for the correct window.

I wish I could vote you up more than once. Not using all-in-one layout in XCode is Considered Harmful. This is even more important than binding Open Quickly to CMD-O or some other quick key shortcut.
I've got a few tips that might make your experience a little better. Option 3 below will be particularly helpful for accessing the documentation more easily.

Option 1: Re-map your Expose´ keys. I mouse (tablet, actually) right handed, so I use the following shortcuts that I can access them quickly with non-mouse hand:

F1 - All Applications

F2 - All Windows

F3 - Desktop

F4 - Spaces

This allows me to use Expose´/Spaces via keyboard in tandem with the mouse. While technically two steps, it feels more like a single, coordinated step to me.

I use XCode in the Condensed (not All-in-One) layout, which results in lots of small windows. I hit F2 (or F1 if I've secluded XCode to a single Space), then either:

- mouse over the various windows and press the space bar to see a zoomed-in view of that window. Then, click the one you want to bring into focus.

- press an arrow key to highlight a window, press space to see a zoomed-in view, press arrow keys as necessary, and then either press F2 again (or click the left mouse button) to exit Expose´.

Option 2: Press Cmd + Shift + D. This will bring up the "Open Quickly" dialog box. Start typing the name of the file you need to open or bring into focus.

Option 3: Use shortcuts to go immediately to the definition of a class/method/protocol/etc., toggle between .h/.m files, or open the documentation to whatever's under the mouse.

- Press Cmd key then double click a class name (or method name or whatever). This immediately opens a window to the definition.

- Press Cmd + Option + Up Arrow to toggle between .h and .m files for a class

- Press Option then double click a class/method/etc. name to open the documentation in a floating window.

- Press Cmd + Option then double click a class/method/etc. name to open the documentation in the XCode documentation window.

Mac OS X is littered with these kinds of accelerated interface shortcuts. I wish I could point you to a good, consolidated guide; but I have yet to find one on the web. Several of them can be found in the opening chapters of Aaron Hillegass' Cocoa programming books.

Don't know on the first one, but you can use ctrl + cursor keys to move between spaces. Fairly sure that's the default, but if not, it can be setup in preferences for Spaces.
It doesn't seem to be the default but I guess I can find out how to set it up. I still think you should get a mouse based one click interface though.
Ctl+1 through 9 switches spaces directly. If you enable the spaces menu bar in system preferences, you can click on the icon and choose which space to switch to (in snow leopard at least).
Grab Xcode 4. It's still beta and buggy but it's all one window and is pretty good IMO.

There's keyboard shortcuts for spaces. And CMD` to switch between windows in apps.

OS X isn't perfect, I switched from KDE 5 years ago. Eventually you start noticing all the little touches that mean it is—really—light years ahead of Linux desktop options.

It does have a lot of little "Apple" touches though that you'll just have to take with a LOL.

Another tip: ctrl-shift-d brings up the "File > Open Quickly" dialog, where you can type the name of a file into a filtered list (eclipse also has something like this). So instead of finding the right window, just bring up whatever file you need via the keyboard. I find this faster than using the mouse or cmd-`.

Another shortcut I used frequently is cmd-shift-e. This toggles "View > Zoom Editor" so that I can see more code.

Well, there's Cmd + ~ hotkey for switching windows of active apps in 10.6, and it can be added using some small app in 10.5
It existed off the bat in 10.5 :).
Cmd+` has existed for almost as long as the MacOS itself - and I'm not just talking about MacOS X here. Interestingly, BeOS also used the same shortcut, maybe because a number of Be engineers initially worked at Apple and the original BeOS was Mac-only. You can also use Alt+` in GNOME with the same effect, though you might have to enable a setting in GConf first.
There is also an expose option to show all windows for an application. Set it to a keyboard hot key.
I'll make just one refutation to this: I am not a Java programmer :)

I had to learn Java specifically for this project. Python is my preferred hammer for most nails, but not an option on mobile. I've also been a professional C programmer before, wreaking havoc in the kernel. I've got opinions on Objective-C, but that's a subject that deserves a whole separate post.

Just a quick reminder: You don't have to use Eclipse to develop for Android. You can use any other Java IDE (I use the free version of IntelliJ IDEA) or no IDE at all. You can even use a combination of XCode and Maven to develop for Android.