Archive for the ‘Tips’ Category

Sorting in Open and Save dialogs – what IS up with that?

Tuesday, September 17th, 2013

“How the heck do I change the sort order of my files in Open and Save dialogs?” We get this question a lot, and I can’t blame you for being confused. The controls for sorting the list of files in Open and Save dialogs are a bit of a mess. They’re the result of new features being layered on top of older user interface controls, leaving you with some odd and confusing combinations.

In the beginning – well, OK, not The Beginning beginning, but quite a few years ago – you could only sort in file dialogs by clicking on the top of the columns in list view.

If you want to sort by date, you click on the “Date Modified” column header. The little triangle at the right side of the header shows you whether you’re sorting in ascending or descending order. Clicking the header again toggles between ascending and descending. To sort by name, click on the “Name” header. Pretty simple, right?

Wait, what column headers?That original method still works today, but only in List View, because there aren’t any column headers in Column View or Icon View. I know, you may not even be aware that there are different views in file dialogs. This is column view:

Click on those little buttons I’ve marked in red to change views. Note that they’re on the bottom of the file dialog in some applications, but at the top of the dialog in others. Don’t ask – that’s just the way it is.

So.. Method #1 for sorting your files: Click on the List View button and then on the column header you want to sort by.

But that doesn’t always work. Yeah, I just told you how to do what you want, but now I’ll screw it all up by showing you the new sorting controls, which completely disable method #1. In Mac OS 10.7 and later, there’s this nifty little sorting button at the top of the file dialog:

Selecting a sorting method from this menu gives you the new Finder-style sorting with interspersed headers saying “Today”, “Yesterday”, “Previous 30 Days”, “Earlier” etc – you can see them in the screenshot above. The confusing thing is that this will also sort List View windows that way, and will completely disable your ability to click on the column headers to sort the Old Way (what I called method #1).

So… Method #2 for sorting your files: Click on the Sort Menu button and select a sorting method.

And now the inevitable question: What if I don’t want those “Today, Yesterday, Previous 30 days” things in the way? I’m glad you asked – mostly because I don’t like them myself 🙂 If you want to go back to the Old Way of sorting in list views, start with the Sort menu and choose “None”. Then click on the List View button and click the column headers to select your sort method.

Using the keyboard in Open and Save dialogs

Sunday, April 21st, 2013

Someone asked about this today – it’s useful stuff that’s not obvious, so I figured I’d share it here. If there are navigation keys or shortcuts that I’ve missed, please comment.

There are a number of keyboard navigation keys that are standard in all Open and Save dialogs, but they vary a bit depending on the view mode you’ve got selected.

In List View:

  • Up and down arrows move up and down the file listing
  • +Right-Arrow displays the contents of a folder without opening it (it turns the little twisty-arrow next to the folder)
  • +Up-Arrow goes up to the parent folder
  • +Down-Arrow opens the selected item

In Column View:

  • Up and down arrows move up and down the file listing
  • Left and right arrows traverse left and right in the column listing
  • +Up-Arrow goes up to the parent folder (when you’ve gotten all the way to the leftmost column)
  • +Down-Arrow opens the selected item

In Icon View:

  • Up, down, left and right arrows traverse among files
  • +Up-Arrow goes up to the parent folder
  • +Down-Arrow opens the selected item

And of course, when keyboard focus is on the file list, typing the first few letters of a file or folder’s name selects it. Note that in Save dialogs, this requires tabbing 3 times (usually) to get the keyboard focus from the filename edit box to the file list.

There are also some command key shortcuts, I’ve borrowed this list from http://www.productivityorchard.com/keyboard-shortcuts-for-mac-os-x-open-save-dialog

  • Spacebar – View the selected item in Quick Look
  • +D – changes focus to your Desktop
  • +Shift+A – Changes focus to your Applications directory
  • +Shift+H – changes focus to your Home directory
  • +Shift+N – Creates a new folder.
  • +Shift+Period (.) – Toggle hidden files & folders on and off.
  • +Shift+G – Brings up Go To Folder window
  • Tab – Tab key auto-completes paths and file names from the aforementioned Go To window
  • +R – Reveals the file in Finder
  • +F – Move the cursor to the Find field
  • +Period (.) – Close the Open/Save dialog window

Tip: Automatically adding the date to filenames

Sunday, January 13th, 2013

From time to time I get requests to make Default Folder X automatically type the date or some other information into new filenames in Save dialogs. While this may be a good idea for a handful of people, the complexity and number of variations I’d have to support would result in a lot of additional settings in Default Folder X’s already crowded preferences.

Not only would it add complexity to Default Folder X, but there is already an easy solution to this – text macro utilities. I personally add the date to some filenames using Typinator, a “text expander” application from Ergonis Software. I just type “dt” and it automatically expands to the current date – and not just when I’m typing a name for a file in a Save As dialog – it’ll expand that shortcut wherever I type it on my Mac.

If you need this sort of shortcut when you’re saving files – or writing emails, filling in web forms, taking notes, etc – check out one of these tools (there are others – these are just a few of the major ones):

Typinator
TypeIt4Me
Keyboard Maestro
TextExpander

If you’ve got others you think should be added here, don’t hesitate to post a comment or give me a shout @stclairsoft

– Jon

Popping up Default Folder X’s menus with a hotkey

Tuesday, March 20th, 2012

I’ve had requests from a number of people asking for a hotkey to pop up Default Folder X’s menus under the mouse. That way you don’t have to go all the way up to the menubar to get to your Favorite and Recent folders. Default Folder X doesn’t currently have a keyboard shortcut for this, but you can make one easily with any macro utility that supports AppleScript. Keyboard Maestro is one example.

Just configure your macro program to run this AppleScript:

    with timeout of 0 seconds
        ignoring application responses
            tell application "Default Folder X"
                ShowMenu
            end tell
        end ignoring
    end timeout

That’s all there is to it!  Thanks to Scott Mintzer for jogging my memory on this.

Update – Andrew Gara wrote to remind me: If you’re running Default Folder X with its “Show icons and menus in the Dock” setting turned off, the application target in the AppleScript should be “Default Folder X Helper” instead of “Default Folder X”. Thanks Andrew!

Default Folder X 4.4.9 – Add Favorites using Finder contextual menus

Friday, February 17th, 2012

Default Folder X 4.4.9 is available, providing a couple of new features and an important bug-fix as well.

First the unpleasant stuff: A bug in previous versions of Default Folder X could cause crashes in other applications if they asked OS X to open an http URL using particular APIs. This caused Karelia’s Sandvox to crash, among others. This is fixed in version 4.4.9, so get the update – really.

On to lighter things: A nice little feature that numerous people have requested. Until now, there’s been no easy way to add a folder to your Default Folder X Favorites directly from the Finder. Now there is – a contextual menu in the Finder:

Here’s how you get it:

  1. Install version Default Folder X 4.4.9.
  2. Run  System Preferences and click on Keyboard.
  3. Select the Keyboard Shortcuts tab in your Keyboard preferences, then click on Services in the left hand list.
  4. In the right hand list, locate the Files and Folders section and find Add to Default Folder X Favorites.  Turn on the checkbox next to it.
  5. Quit  System Preferences
  6. Now, whenever you select a folder in the Finder, you can right-click (or control click) on a folder and add it to your  Default Folder X favorites.

Get your permissions right!

Wednesday, March 30th, 2011

Thought I’d post about this little developer experience because it was incredibly frustrating and not at all obvious. Maybe this will save someone else the headache that I’ve been through.

Background: When preparing an application for release on the Mac App Store, you code sign your application, then bundle it into an installer pkg which is also code signed (using either Xcode organizer or the productbuild command line tool). When the application is installed, it gets extracted from that .pkg file, the user runs it, and it checks for a Mac App Store receipt. If there’s no receipt, OS X checks to make sure that the application is signed correctly, then contacts the Mac App Store to get your receipt.

Problem: This would all work for me as advertised except that when the receipt check failed, OS X would complain that my application wasn’t code signed, and therefore wouldn’t contact the App Store to get the receipt. From a user’s perspective, the app would just fail to launch.

I’d followed all the instructions. I double- and triple-checked to make sure the application was signed before I built the .pkg file. I tried building the .pkg using both the Xcode organizer and productbuild – they both worked with no problems or error messages. Yet when the application came out of the .pkg file on the other end, it was always unsigned! I deleted all of my certificates, regenerated them, and redownloaded them from Apple’s developer site (several times). I checked every step along the way in my build process – they were all working. It was incredibly frustrating because the signed app went into the ‘black box’ of the .pkg file just fine, but came out on the other end without its code signature.

Solution: After tearing my hear out for a while, googling for answers, and checking the developer forums, I finally tracked down the solution. I had a single image file in my application’s resources that had its permissions set to 640 instead of 644, meaning that it was not readable by everyone. That threw the entire game off – apparently when the installer unpacked the .pkg file, it ran into this problem file and either stopped short of installing the code signature, or invalidated the signature.  Either way, the application it installed was useless.  Simply changing the permissions on that one tiff file fixed the problem I’d been fighting with for days.

Soooo….  If your app builds and runs fine UNTIL you package it, and then comes out unsigned on the other end, check the permissions on the resources in your application.  And Apple, please emit some kind of warning when hapless developers feed productbuild a file with the wrong permissions that’s gonna screw up the whole process.

Tip: There’s a really cool developer utility called Cong, written by Stephane Sudre.  It checks your application for all kinds of minor errors, from localization goofs in .strings files to incorrect Info.plist entries to missing files in your package.  I’ve contacted Stephane and checking file permissions is now on his To-Do list for Cong.  If you’re a developer, get a copy of Cong – a simple drag-and-drop could save you a lot of time and trouble!

App Tamer 1.0.2 Tips and Tricks

Monday, December 20th, 2010

A couple of App Tamer’s extra preference settings aren’t actually documented in the released version. They were added during development and were described in the beta notes, but never made it into the documentation. So, until that gets resolved in the docs for version 1.0.3, here’s a quick run-down:

  1. App Tamer can hide applications when they are stopped rather than dimming their windows. To turn this on, quit App Tamer and then use this command in Terminal:

    defaults write com.stclairsoft.AppTamer hideWhenStopped 1

    To turn the feature back off, use:

    defaults write com.stclairsoft.AppTamer hideWhenStopped 0

  2. When window dimming is turned on, the brightness of the dimmed windows can be modified with a defaults setting. Run this command in Terminal (the default value is 65% – lower percentages are darker, higher percentages are brighter):

    defaults write com.stclairsoft.AppTamer dimPercentage 65

Renaming Favorites in Default Folder X

Monday, April 12th, 2010

Default Folder X lets you mark folders as favorites so you can get to them quickly.  Unfortunately, it displays those folders in its menus using their names – if you’ve got two identically named folders named “Images,” for instance, they both show up in Default Folder X’s menus as “Images” and it’s hard to tell them apart.

Because of this, I’ve gotten a few requests for the ability to change the names of Favorites without changing the name of the actual folders that they point to.  This feature is on my To-Do list, but in the meantime here’s a workaround to do it with the current version of Default Folder X:

  1. Open Default Folder X in System Preferences.
  2. Click on the Settings button.
  3. Click on the Advanced tab and turn on “Create aliases for Recent Folders and Favorites in your Library folder”.
  4. In the Finder, navigate to this folder: HOME/Library/Favorites.  Locate the aliases of the folders you want to rename.
  5. Rename the alias files using the Finder.  Default Folder X will then read those names and substitute them for the original folder names in its menus.

Getting to Recent Folders with the Keyboard in DFX

Monday, March 29th, 2010

Many people are familiar with the Option-down-arrow keyboard shortcut in Default Folder X. When you’re using an Open or Save dialog, it takes you straight to the last folder you used. (If you haven’t been using this, try it – it saves a TON of time).

What most people don’t know is that there’s a hidden setting in your Default Folder X preferences that will let you use the same keyboard combination in the Finder. Press Option-down-arrow and the most recent folder in your DFX Recent Folders menu will open up in a new window.

To enable this, open System Preferences and select Default Folder X. Hold down the Option key while you press the “Settings…” button and you’ll get this sheet of options:

Turn on the checkbox marked “HotkeysForRecentFolders” and click OK.  That’s all there is to it.

If you’re curious about all of the other “secret settings”, have a look at this blog post.

Accessing Your Recent and Favorite Folders in LaunchBar

Friday, March 26th, 2010

LaunchBar is a great ‘mouse-free’ utility for instantly getting to files, folders, URLs, music, addresses, and just about anything else on your Mac.  Hit command-spacebar and start typing the first few letters of whatever you want – LaunchBar lists the choices that match and you just hit the return key to open or go to that item.  I use it all the time and recommend it to everyone I know.

There’s a really handy way of including your recent and favorite folders from Default Folder X in LaunchBar’s index. After doing this, you can instantly access those folders from the keyboard using LaunchBar.

To make Default Folder X favorites and recent folders available in LaunchBar do the following:

  1. In your Default Folder X preferences, click on the Advanced tab and turn on “Create aliases of Recent Folders and Favorites in your Library folder”.
  2. In LaunchBar, choose Show Index from the Index menu.  Click on the “Folder+” button in the toolbar to add a folder.
  3. Select the HOME/Library/Favorites/ folder.
  4. Once the folder is added, click on the Options tab for that folder and set Search Scope to “Search 1 Subfolder Level” and Search for “Folders”.
  5. Click on the Schedule tab and turn on the “Update automatically” checkbox.
  6. Repeat steps 2-5 for the folder HOME/Library/Recent Folders/
  7. Once you tell LaunchBar to reindex, you’ll have access to all of your Default Folder X favorite and recent folders.

Thanks to Gary Schelling for asking about this and jogging my brain 🙂