Technical Stuff

83 posts

Assorted technical stuff of all kind.

Creating Mac OS X Icons (icns) on Linux

Time again for some new icons for an Eclipse RCP launcher. While The Gimp can easily create XPM and Windows ICO files, when it comes to Mac OS “icns” format, you won’t have any built in support.

There are some fine tools out there for Mac OS, but if you are running Linux and don’t want to buy a Mac just for creating some icon files, png2icns comes to the rescue. It is a small command line tool which simply creates an “icns” files from some “png” files.

Create your icon files as “png” in multiple resolutions. If you are creating an Eclipse RCP launcher, you will, most likely, have them anyway for creating your Windows “ico” file. Place them in any folder you like:

-rwxr-xr-x 0 jens jens   1427 Feb 24 10:49 icon_16px.png
-rwxr-xr-x 0 jens jens   2003 Feb 24 10:49 icon_32px.png
-rwxr-xr-x 0 jens jens   2560 Feb 24 10:48 icon_48px.png
-rwxr-xr-x 0 jens jens   5304 Feb 24 10:48 icon_128px.png
-rwxr-xr-x 0 jens jens   9883 Feb 24 10:47 icon_256px.png

Ensure that you have the “png2icns” application installed. On Ubuntu it comes with the package “icnsutils”, which can simply be installed by executing:

sudo apt-get install icnsutils

Now call “png2icns”. As the man page suggest you need to provide all PNG files, that you want to be part of the icon, as argument. The first argument is the output filename. Also you can let the shell find the correct PNG file by using the wildcard (*):

png2icns icon.icns icon_*px.png

Easy! ;-)

PS: If anything goes wrong, “png2icns” will complain at the command line (e.g. due to some wrong resolution).

Fixing the Mint-X theme for Eclipse/SWT

If you are running Mint, Eclipse and you like the Mint-X theme, you might be a bit frustrated every time you open up Eclipse. Especially with Eclipse 4.2 the design of the toolbars is pretty messed up. See the launchpad bug entry:


Gladly this is only a minor glitch which can be fixed easily. Hopefully the change of the github pull request will find its way into Mint.

Build your own SIP trunk with Asterisk and mISDN

The mission: “save some bucks by using a free PBX using a cheap isdn card”. Don’t try! Buy something working in the first place. But if you have to, here is one example how it can be done. There are, for sure, many others!

The idea was to replace trixbox using an AVM Fritz!PCI card with something more up to date and not that buggy. FreePBX Distro kicked itself out because of the issues with mISDN. Elastix brought in mISDN support but still failed in configuring it. Since the setup was for only 3 users for now and the idea was to later buy something more professional (I really hope it comes to this point), I used Starface free. It has 4 users and 10 extensions for free. Yet the free version only allows using SIP providers. Also it was not possible to buy a Patton SmartNode 4120 at the moment, which I still hope to get somewhere in the future. So I needed to build our own SIP trunk since the provider used (M-NET) does not provide SIP trunks as a product.

Continue reading