News Projects Publications Contact About

Archive for the ‘Apple’ Category

Opening specified path in Terminal’s new tab

Tuesday, March 24th, 2009

Updates

  1. It uses now click menu instead of keystroke “System Events” command, because in some cases when you had this script assigned to shortcut that used Ctrl or Shift modifiers, those modifiers were sent together with Cmd to “Terminal” producing invalid behavior.
  2. It waits 0.5 second when window is busy just in case Terminal.app was not running and it is just loading the shell which makes it busy for short while too. Fixes incorrect behavior of opening extra tab when Terminal.app was not running.

If you ever wondered how to open specified path in new tab of Terminal.app or reuse current one if it is not busy (running a command), here’s a script you may use:

tell application "Terminal"

    activate

    set windowCount to (count of the windows)

    -- Terminal may be just launched loading the shell, wait a bit
    if windowCount is greater than 0 and first window is busy then
        delay 0.5
    end

    -- Still busy / no windows? open new tab
    if windowCount is greater than 0 and first window is busy or windowCount is 0 then
        tell application "System Events" to tell process "Terminal"
            click first menu item of first menu of second menu item of first menu of third menu bar item of first menu bar
        end tell
    end if

    do script "cd #{e_as(e_sh(dir))}" in first window

end tell

Where #{e_as(e_sh(dir))} is your desired folder. This is modified chunk of TextMate’s command script found at Mark Eli Kalderon’s Blog. Thanks Mark!

Note: Mark’s TextMate command script does not open anything when Terminal.app has no windows or it is not running.

I use this!

Thursday, March 19th, 2009

NSSpellServer tearing my hair out no more! (fixed in 10.5.7)

Monday, October 13th, 2008

I just received confirmation mail from Apple’s technician regarding this bug and 10.5.7. Thank you! It took them a while to nail it down, but finally we can change spell checker language w/o restarting Mail or Safari.

A story with happy ending

Since a while I am a happy Mac OS X user, would be happiest one… if only I could write my mails easily…

Even I find myself often talk too much I am neither a perfect speaker nor writer. So something commonly called “spell checker” is an invaluable tool in my daily work, especially when sending bunch mails per day. Short after my transition to Mac I was very excited finding out that spell checking is built into the system. Unfortunately as a spelling mistake prone Pole speaking usually English at work and Polish privately I realized that having no Polish spell checker makes my doom.

Core of the hatred

(more…)

Leopard’s Java 10.5 Update 2 breaks Quartz pipeline font rendering

Tuesday, September 30th, 2008

If you experience missing text in some applications, like one using Batik and native Mac’s Quartz Java pipeline, seek no more for an answer this is a bug introduced in 10.5 Update.

Here goes a copy of my bugreport to Apple #6256562
(more…)

European ISO MacBook Pro return button, WTF is that!?

Monday, January 21st, 2008

Here is a story of a blot on the great MacBook Pro landscape, which is the european, so called ISO, keyboard.

The “Apple Extended Keyboard II – ISO layout” is a keyboard specially
designed for the (retarded!?) European market. The layout complies with ISO 1091 standard on the “Layout of printing and function keys.”

(more…)