I love that every new feature of Squeak is there… And, I love being able to turn them off!
When I’m working, I absolutely must, must, must have a blank canvas, so I don’t like backgrounds, icons, desktops, menus, or anything else to distract me.
To turn the Docking Bar on and off, there is a preference. Go to World menu -> Appearance -> Preferences, and type ‘dock’ in the search field and it will come up.
If you want to toggle the dock on and off a lot, you could save the following code and assign a keyboard shortcut to it:
TheWorldMainDockingBar showWorldMainDockingBar not.
I’m often jumping from file to file in Rails, so I really wanted Quicklook support for my template files. Unfortunately, the suggestions I found online were confusing and incomplete.
Here’s a really easy way to get it done – but no syntax highlighting
1. Show the contents of TextEdit’s package
2. Open Info.plist in a text editor… like TextEdit, perhaps… hmm…
3. Anyway, add the following snippet (find the code on github):
Put it just before the following section:
- UTTypeDescription - put in description of your choice (although you probably don’t need to)
- UTTypeIdentifier – apparently (and this is what was missing from other descriptions), you just make something up here
- public.filename-extension – add as many extensions as you want to map to this file type
Even though Preview doesn’t advertise scriptability, it at least responds to events needed by GUI applications in Mac OS X, including open…
From Mac Dev Center:
Apple Events Sent by the Mac OS
The Mac OS takes advantage of Apple events to communicate with applications, such as to notify an application that it has been launched or should open or print a list of documents. Applications that present a graphical user interface must be able to respond to whichever of these events make sense for the application. For example, all such applications can be launched and quit, but some may not be able to open or print documents.
So you can just say, for example:
tell application "Preview" to open POSIX file "/path/to/file.jpg"
I created an Applescript in response to the PersonalBrain Forums, which launches a VoodooPad page from the current active thought in PersonalBrain:
– Copy name of active thought
tell application “PersonalBrain” to activate
set old_clipboard to the clipboard
set the clipboard to “”
repeat while (the clipboard) is “”
tell application “System Events”
tell process “PersonalBrain”
perform action “AXPress” of menu item “Copy as Text” of menu 1 of menu bar item “Edit” of menu bar 1
– Strip trailing newline
set active_thought_name to (characters 1 thru -2 of (get the clipboard)) as string
– If page does not exist in VoodooPad, create it
– Open page in VoodooPad
tell application “VoodooPad”
tell document 1
open page with name active_thought_name
set the clipboard to old_clipboard