Archive

Archive for the ‘OSX’ Category

Mac Text Editors

February 16th, 2009 Ant 11 comments

I need a text editor that will print syntax highlighted Java code with line numbers.

  • Smultron doesn’t print line numbers.
  • TextWrangler doesn’t syntax highlight Java code.
  • BBEdit doesn’t syntax highlight Java code.
  • XCode doesn’t print line numbers.
  • Editra doesn’t print (it just prints the filename and the right-hand margin, leaving the actual text out).
  • TextMate doesn’t print line numbers.
  • NetBeans prints both line numbers and highlighted text, in a terrible way; printing to HTML results in print output surrounded by an inexplicable black box.
  • Aquamacs Emacs - an astonishing 115MB for a text editor even though it hasn’t got a real UI; view line numbers option doesn’t appear to work.

Why isn’t there a Mac text editor that will print properly?

Categories: OSX Tags: , ,

Mac Utilities; Versions in Beta

June 6th, 2008 Ant No comments

I’ve got a list of programs to buy at the moment. One of the main programs I miss from Windows is Sound Forge - Logic and Garageband are no substitute for a dedicated sample editor. Yeah, they have built-in editors, but they’re too clunky, cramped, counter-intuitive and limited. Audacity’s OK, though still clunky, but I’m looking for something with a more Mac-like interface.

I’ve found two main contenders for the role of Sound Forge Replacement. First up is Wave Editor from Audiofile Engineering. Not bad, but at $250 (or £125 in real money) it’s well out of my budget. That’s the same price as Logic Express.

I’ve settled instead on Sound Studio from Felt Tip Software. Great interface, fast, has all of the features I want and more, and only costs $80 (£40 in real money).

Whilst I’m on the topic of audio software, I discovered Soundflower the other day. It’s a tiny GPL program that creates a virtual sound device in OSX. You can set it as the output for one program and the input for another and, for example, rip audio streams as easily as recording from the microphone.

Anyhoo, the second program I’m thinking of buying at the moment is Pixelmator. It’s yet another Photoshop copy with all of the features you’d expect, but with two big differences. It uses the GPU for its effects processing (and so does neat things like rotating images in realtime) and only costs $59 (roughly £30). Photoshop is another application I’ve been missing since migrating away from Windows, and this looks like it’ll fill the gap.

The reason for mentioning this is that my SynchroSVN trial has expired. I’ve taken to storing all of my important files - source code, images, documents, serial numbers, etc - in a set of Subversion repositories. That means I have a working copy on my MacBook, the repositories on my MacMini, backups in their Time Machine databases, and a copy of the repositories in a SuperDuper image on a NAS. Unless the house explodes I’m pretty sure I’ll never lose anything important. I don’t want to buy any more serial numbers if I can’t add them to SVN and get them backed up automatically, so I need to buy Synchro first.

Except!

Versions, an OSX SVN client that seems like it’s been in development for nearly as long as Duke Nukem Forever, has finally gone into public beta. I tried it out today and it really is a massive step beyond all of the other clients available on the Mac. Forget Synchro, I’m going to wait for this to have a proper release. No mention of price yet, but as long as it’s not ridiculous I’m definitely getting it.

If you’re interested in trying it out, note that it currently has a stupid bug when trying to access SourceForge repos. When you try to bookmark a SourceForge repo, Versions runs into problems with the SSL certificate and opens an error dialogue with a “PROPFIND” message. There’s no way to accept the unknown certificate via Versions, so you can’t add the bookmark. The workaround is to open a shell and perform the initial checkout with the commandline client - this will prompt you to accept the certificate. If you choose to accept the certificate permanently, you’ll be able to work with the repo via Versions from then on.

I’ve notified the programmers, so hopefully they’ll fix the problem before it gets a proper release.

Categories: OSX Tags: , , ,

OSX 10.5.3

June 1st, 2008 Ant No comments

Since upgrading:

Strangely, these were all problems purported to be fixed by the new update, not introduced by it. Bah.

Here’s a quote from the first link:

I’m using Macs for 12 years now and I never experienced anything like this…

What is going on with 10.5? It’s a massive bugfest.

Categories: OSX Tags:

ListBox Take 2 and SVN Again

April 28th, 2008 Ant 6 comments

The rewritten version of the ListBox class is now in the SVN repository. Instead of farming out the drawing routines to an array of ListBoxItem child gadgets, the ListBox now draws its own list items. It’s made a massive difference to the scroll speed. Just need to make a wrapper gadget for it that includes a scrollbar and I can knock another item off the SourceForge to-do list.

As part of that rewrite, I had to fix a bug in the double click code. Nothing major, just a magic number that had slipped past somehow.

Given up for today because SourceForge’s SVN server is abysmally slow at the moment. I’ve come to rely on SVN heavily, and not being able to rely on it makes me uncomfortable…

Related to that, I’ve been tinkering with alternative OSX SVN clients again. I’ve gone back to ZigVersion, which I’ve discovered is free for non-commercial use; you just have to register for a free licence key. It’s got a much, much better interface than SmartSVN. It has several big problems, though. First of all, its ignore list functionality is lacklustre. There’s no way to change it unless you right-click on a file that can be ignored, as far as I can see.

Secondly, it seems to work directly off the server all of the time instead of from a cache. TortoiseSVN uses a cache, and is generally better for it, or it is until it starts sucking up 95% of the processor time and most of the computer’s RAM. Firefox 2’s memory leaks have nothing on TortoiseSVN.

Lastly, it keeps crashing on me. For all of its weird interface problems, SmartSVN is at least stable.

I gave svnX another go, but the interface for that really makes no sense.

Honestly, are there no good SVN clients for OSX? I’m seriously considering installing Eclipse just so that I can give Subclipse a try. Either that or I turn my back on 30 years of progress and join the guys who still think that the command line is an amazingly good idea.

Categories: OSX, Woopsi Tags: ,

A Great Idea, Ruined by Apple and Microsoft

December 23rd, 2007 Ant 14 comments

I was reading the GBADev forum yesterday and found an interesting thread about how people were getting around the problem of debugging when coding for the DS. It was such an interesting thread that I didn’t notice I’d missed both of the stops I could have got off at, and had to ride the train into the city centre and get a train back. Curses.

The idea goes something like this: If you can abstract away enough of the DS’ hardware, there’s nothing to stop you from writing a simple layer that will allow your DS project to run on the PC as a native application. Woopsi is itself basically a hardware abstraction layer, and all of its DS-hitting code is contained within Steven’s woopsifuncs files.

I decided that it would be easy to create a new “nds.h” file (containing all of the data type shortcuts from libnds) and create a new set of Woopsi functions targeted at another hardware platform. Obvious choice: SDL. If I can get Woopsi’s standard HAL pointing at SDL, Woopsi and any apps that use it will immediately run in Windows, on the Mac, on the Amiga, the GP2X, Linux…

Except, of course, both Microsoft and Apple have conspired against me to stop this happening. Getting SDL set up in Visual Studio looks to be needlessly complicated, so I went for Xcode instead. Easy to set up - just involves dragging the runtime library into the Frameworks folder, and copying over the templates.

However, Apple have played another hilarious trick with Leopard - if you upgrade Xcode from 2 to 3, you’ll find that trying to compile anything results in “duplicate symbol” errors. Nothing works.

That pretty much settles it. Leopard is a bloody nightmare if you perform an upgrade from Tiger - I’ve had endless problems with it - and I’ve got no choice but to wipe my laptop and reinstall the OS from scratch.

Categories: DS Coding, Development, GP2X, OSX, Woopsi Tags:

XCode PALib Template

October 19th, 2007 Ant No comments

Following on from the previous post about getting PALib and devkitARM set up in OSX, here’s some instructions for creating a PALib template project:

  • Download the PALib XCode Template
  • Unzip the archive
  • Drag the resultant folder to “/Library/Application Support/Apple/Developer Tools/Project Templates”

All done!

To create a project using the template:

  • Fire up XCode
  • Choose “File/New Project” from the top menu
  • Select “PAlib” from the template list
  • Click “Next”
  • Choose a project name and a location for the project
  • Click “Finish”

You’ve now created a basic PALib project that will compile (ROMs are put in the “release” folder) and run in an emulator.

Categories: DS Coding, OSX, PALib Tags:

OSX PALib

October 19th, 2007 Ant 9 comments

Quick guide to setting up PALib in OSX.

  • Download the correct version of devkitARM for your CPU architecture
  • Mount the DMG
  • Run the package and install to the default location
  • Download the latest stable version of PALib (make sure you get the zipped version)
  • Unzip the archive
  • Rename the resultant folder to “PAlib”
  • Open a Finder window and browse to /opt/local
  • Drag the “PAlib” folder into the Finder window - you will receive a prompt to authenticate yourself (click “Authenticate”), so type in your OSX password

That’s all of the files downloaded and installed. Next we need to start mucking about in the command line in order to replace devkitPro’s version of libnds with the version that ships with PALib.

  • Open a Terminal window
  • Type:cd /opt/local/devkitPro
  • Type:sudo mv libnds libnds_old
  • Enter your OSX password (the Terminal should prompt you with “Password:”)
  • Open a Finder window and browse to /opt/local/PAlib
  • Click on the “libnds” folder and press Command-C to copy it
  • Click on the desktop and press Command-V to paste a copy of the “libnds” folder
  • In the Finder, browse to /opt/local/devkitPro
  • Drag the copy of the “libnds” folder from the desktop to the Finder window (authenticate when prompted by entering your OSX password)

That’s all of the files set up. Now we need to add the PALib environment variable to OSX.

  • Load the file “~/.profile” into a text editor - if you have Smultron installed (and if not, you should do - it’s great) you can type this in the Terminal: /Applications/Smultron.app/Contents/MacOS/Smultron ~/.profile
  • Add the following line to the end of the file (you will have to type your OSX password in when saving):export PAPATH="/opt/local/PAlib/PAlib"

Nearly done now. The last thing we need to do is comment out a couple of bugs in the DS Motion card code - you probably don’t need to do this if you’re working in C, and you definitely shouldn’t do this if you need to use the motion functionality (you’ll need to wait for a proper fix in that case):

  • Open the file “/opt/local/PAlib/PAlib/include/nds/arm9/PA_Motion.h”
  • Comment out line 23
  • Change line 29 to:return 0;

That, I think, should be everything. Note that this is correct at the time of writing, using devkitPro r20 and PALib 070717.

Categories: DS Coding, OSX, PALib Tags: