osx

Opening a new terminal tab in OSX(Snow Leopard) with the opening terminal windows directory path

Hi all. I've been Googling for a while looking for a simple way to do this, and I can't find one. I have a custom terminal environment set up (zsh) with various aliases and functions to make things easier. One thing I keep running into is that I will quickly APPLE-t to create a new tab and then type a command relative to the path of th...

Is OS X Installer package postflight localization supported?

I've created an OS X installer package that includes localized resources (License.html, Readme.html, etc.) In particular, it includes a localized postflight script, since some of the post-install actions differ from language to language; opening a per-language file after the install completes, for example. The package is created as par...

QuickTime HTTP Basic Authentication on Safari 4

I am using Mac OS X Leopard 10.5.8, which is running Safari 4.0.3. My cross platform Java app has an embedded native web browser with its own internal web server. Whenever the browser tries to serve up a file that needs quicktime (mov, mp4, m4v, etc) i get a username/password credential dialog. I can see every request coming through and ...

Tracking downloads of your software + software CDN?

I'm primarily a web app developer/entrepreneur, so there's a lot I don't know about the desktop software distribution process. I've been thinking about making a Mac OS X app for fun, that I would distribute for free or a really small donation, but started thinking about distribution+download analytics: a) How do you host your software?...

Decoding Mac OS text in Python

I'm writing some code to parse RTF documents, and need to handle the various codepages they can use. Python comes with decoders for all the necessary Windows codepages, but I'm not sure how to handle the Mac ones: # 77: "10000", # Mac Roman # 78: "10001", # Mac Shift Jis # 79: "10003", # Mac Hangul # 80: "10008", # Mac GB2312 # 81: "100...

Applet lifecycle in Mac OS X

I have two applets A and B. They are embedded in separate pages. On destroy, A serializes objects to the local file system. On init, B deserializes these objects. This set-up works fine in Windows. Unfortunately, I have discovered that it doesn't work in Mac OS X. This is because B is initialized before A is destroyed. Does anyone...

Is Mono really cross-platform?

Official Mono project website says that Mono works successfully on Windows, Linux and Mac OS X. Is that true? I want to build applications which work at least on Windows and Linux. Is it possible with Mono? P.S. I know that similar topics already exist (e.g. http://stackoverflow.com/questions/56013/cross-platform-net), but they may be...

Building OSX App Bundle

Hi Suppose I have have made a an osX app without using Xcode. After compiling with GCC I get an executable which is linked to several other libraries. Some of those libraries might again be dynamically linked to other non-standard system libraries Is there any tool which exists which makes an OSX App bundle by first making the required ...

CGEventTimestamp to NSDate

I'm simply trying to convert a CGEventTimestamp (which is an unsigned 64-bit integer roughly representing nanoseconds since system startup) into an NSDate. I know there's a way to convert "time since system startup" into either an NSTimeInterval or a date relative to a reference date, but I'm not finding it. How do I convert a CGEventTi...

How can I invoke custom Scripting Additions using Python Appscript?

Assuming I have a new scripting addition, does appscript recognize them, and how do you invoke them using appscript? ...

How can you tell if a directory is writeable in Objective-C?

I want to use an open panel to let the user select a destination, but I want to alert them at that point that point that the directory is not-writable. I generally prefer to create it and handle the error, but that's not useful to me here, since I don't want to create the folder just yet. (I'll be sure to handle the error when I do creat...

Mono - OSX - ODBC

I've set up system DSNs, which I can use from other ODBC apps (e.g. iQueryODBC), but in mono, I get "Data source name not found and n" (sic). I am using "DSN=myodbc" for the connection string, via the connection string builder. OSX 10.4 Latest Mono packages - 2.4.2.3. Anyone ever got ODBC working on Mono/ OSX? (Oh - for what it is ...

What would you do instead of using NSViewController to be compatible with 10.4?

All I need to do is load and swap some nibs in a NSView of a window. I know how to do it with NSViewController and have it working perfectly with 10.5-10.6, but I don't know what to do for 10.4. Tutorial links very welcome, I have trouble finding legacy stuff. (Yes, I really do need to support 10.4.) ...

gem update sqlite3-ruby fails on Mac OS X 10.5.8

I was trying to get the latest ruby on rails for my Mac running OS X 10.5.8. All went well until I tried to update the sqlite3-ruby. I see that others have had similar problems, but they were on Windows. This is the error: sudo gem update sqlite3-ruby Updating installed gems Updating sqlite3-ruby Building native extensions. This could...

How do I embed data into a Mac OS X mach-o binary file's TEXT Section?

I have a Mac OS X command-line tool that would benefit from having some data embedded in the binary file itself. I know mach-o files support multiple segments, some of which can be used for storing arbitrary data. But I can't find a command-line tool to do that. While I know there are other, probably simpler ways (e.g. convert the data...

Mathematica in batch mode from the command line on Mac OS X

I'd like to start writing some unit tests for my Mathematica programs and control everything from the command line with some Makefiles. It seems like Mathematica can be run from the command line but I can't see any basic instructions on getting started with doing this on Mac OS X — has anyone done this before? Update: Creating a te...

Bluetooth Example Code for Cocoa (Objective-C)

I'm looking for example code for setting up a connection to a bluetooth device using the Bluetooth API in Cocoa. Apple used to include this type of example code in the XCode tools package under the /Developer/Examples/Bluetooth folder, but upon downloading the latest version of XCode (3.2.1), these bluetooth examples have been removed f...

Getting -bash: mvn: command not found

Hi. I tried setting the Maven PATH in .profile file as well using export commands in terminal(Mac OSX). But, on running mvn commands, getting -bash: mvn: command not found Please help. ...

Font used in Quicksilver - Large Text?

Hi, I want to use the font used in the Quicksilver large text display. Is it Monaco? But I see a difference between Monaco used in the application and in Quicksilver LargeText. Thanks. ...

office dde/macros with Mac

I have created some excel/word macros that use DDE and mailmerge, is it going to work at all with Office MACOSX version? ...