Contents
The setting
One key takes an action identifier. The stored value is the action's index plus one, which is a small piece of awkwardness worth knowing about before you conclude it is off by one for no reason — it is, deliberately, so that zero can mean disabled.
defaults write com.knollsoft.Rectangle doubleClickTitleBar -int 3
killall Rectangle && open -a Rectangle
# turn the feature off entirely
defaults write com.knollsoft.Rectangle doubleClickTitleBar -int 0
The authoritative list of action identifiers lives in the project's source, in the window action enumeration. Because indices can shift between versions, the reliable approach is to set a value, restart, double-click a title bar, and see what happens — rather than trusting a number copied from a forum post written against an older build.
Start at 1 and work upwards, restarting each time. It takes a couple of minutes and is immune to version drift. The commonly wanted actions — maximise, almost maximise, centre, maximise height — all sit low in the list.
The toggle-back behaviour
By default a second double-click restores the window to its previous geometry, which makes the gesture a toggle. Most people want this. If you would rather each double-click simply reapply the action:
defaults write com.knollsoft.Rectangle doubleClickTitleBarRestore -int 2
The case for turning it off is narrow but real: if you have bound the gesture to something like centring, toggling back is rarely what you meant, whereas re-centring a window you have nudged is exactly what you meant.
Excluding applications that break
Some applications use the title bar area for their own purposes, or respond badly to being resized by a gesture they did not expect. Outlook is the named example in the documentation, and the exclusion list takes bundle identifiers as an escaped JSON array:
defaults write com.knollsoft.Rectangle doubleClickTitleBarIgnoredApps -string "[\"com.microsoft.Outlook\"]"
# several apps
defaults write com.knollsoft.Rectangle doubleClickTitleBarIgnoredApps -string "[\"com.microsoft.Outlook\",\"com.apple.Terminal\"]"
Finding an application's bundle identifier:
osascript -e 'id of app "Outlook"'
# or
mdls -name kMDItemCFBundleIdentifier /Applications/Microsoft\ Outlook.app
Interaction with the system setting
macOS has its own preference in System Settings → Desktop & Dock for what a title bar double-click does — typically zoom or minimise. When the app's own handling is enabled it takes precedence, so if you are seeing the system behaviour instead, the feature is off or the value is zero.
Conversely, if you want the system behaviour back, disable the app's handling rather than fighting the two settings against each other.
Whether this is worth setting up
An honest assessment. For a keyboard-driven user, this is close to pointless — the shortcut is already faster than reaching for the mouse and hitting a title bar precisely.
It earns its place in two situations. First, on a trackpad-heavy workflow where your hand is already there: double-clicking a title bar to almost-maximise is the least effortful window operation available on macOS. Second, for shared or family machines, where a single obvious gesture is far more likely to be used than a shortcut nobody will remember.
Set it to almost maximise rather than maximise if you pick one. A window at 90% of the screen leaves a visible margin, which preserves the sense of what is behind it and makes the gesture feel less absolute.
Get the current build
Rectangle is free and open source. Everything documented here works in the standard build.
Download from rectangleapp.comQuestions
Where is the list of action numbers?
In the window action enumeration in the project source. Numbers can shift between versions, so testing empirically is more reliable.
Why is the value the action index plus one?
So that zero can mean disabled.
Can I exclude several apps?
Yes, as a JSON array of bundle identifiers passed as an escaped string.
Does this override the macOS setting?
Yes, while enabled. Disable it to get the system behaviour back.