Safari 4 on Linux: tabs fix

Date: 28 Feb, 2009
Posted by: admin
In: linux, open source & software

Bookmark and Share

A slightly involved fix to partially enable tabs in the Safari 4 beta over WINE on Linux. Other options are exposed and can be altered too, eg turning off Google suggest.

See also posts on getting Safari 4 running on Linux and on fixing running with Safari 4 with WINE.

Fixing the tabs in Safari 4 on Linux

Working tabs on Safari 4 beta on Linux

Working tabs on Safari 4 beta on Linux

On a scale of 1-10 for putting off newbies this one is probably an 8. If you’ve used the command line at all then you’ll be more than fine. Here’s what we have to do:

  1. Find configuration plist file called an “apple binary property list” (according to the file command)
  2. Download a utility to read and write plist files
  3. Convert plist file to a UTF-8 XML (text) file and alter
  4. Convert plist text file back to binary and admire your crooked tabs …

It’s not going to be pretty but it does give you tabs (and they’re only slightly buggy).

Apple binary property list

1. Apple uses plist files to store configuration inforamtion, like an rc file (eg bashrc) or the MS Windows registry. For Safari 4 on windows XP the file we need is apparently stored at C:\Documents and Settings\<Your Username>\Application Data\Apple Computer\Preferences (thanks to justin for that one). In my wine installationn however the files are at ~/.wine/drive_c/windows/profiles/pandfi/Application Data/Apple Computer/Preferences. We’re looking for .

Read and write binary plist files

2, 3. The perl script from Starlight Computer Wizadry sorts us out here. Download it (you may have to run chmod u+x to enable it to be executed) and run it on that plist file we found:

$ perl ~/Applications/ ./

This gives us a new file calle, open that with your favourite text editor (I use kate) and simply add the required options (see section below), alterations are highlighted:

<?xml version=”1.0″ encoding=”UTF-8″?>
<!DOCTYPE plist PUBLIC “-//Apple Computer//DTD PLIST 1.0//EN” “”>
<plist version=”1.0″>


This change, not surprisingly will turn off the feature where the tab bar is on top. As it’s a debug feature I wouldn’t be surprised if this option doesn’t make it in to the final release. We’re certainly not guarranteed the final release will be as WINE friendly as this beta.

Debug options in Safari 4 beta

The following debug options were suggested by Caius by analysing strings found in the Mac Safari binaries, they can be added to the plist file in the same way a the above DebugSafari4TabBarIsOnTop option was.

$ strings /Applications/ | grep DebugSafari4

Convert plist text file to binary

4. Lastly we need to use the script to convert our text file back to a binary, then rename the resulting file.

$ perl ~/Applications/ ./

$mv perl ./ ./

Quick tip mv perl ./{.text,}.plist is equivalent to that last line, the curly braces {} simply say use the first string for the first option and replace it with the second string (empty string here) for the second option.

You’re done!

That’s it, you’re done, run Safari 4 beta with wine and see how it looks. Not pretty for me (see image at top of post), quite buggy but tabs nonetheless.

No Responses to "Safari 4 on Linux: tabs fix"

Comments are closed.


Flapjacktastic is just a random collection of musings, hints&tips, notes, information ... a collection of stuff really that's overflowed from the brain of this husband, father, potter, business-man, geek ...

past posts