[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-6660":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":19,"stars90d":16,"forks30d":16,"starsTrendScore":20,"compositeScore":21,"rankGlobal":10,"rankLanguage":10,"license":22,"archived":23,"fork":23,"defaultBranch":24,"hasWiki":25,"hasPages":23,"topics":26,"createdAt":10,"pushedAt":10,"updatedAt":27,"readmeContent":28,"aiSummary":29,"trendingCount":16,"starSnapshotCount":16,"syncStatus":30,"lastSyncTime":31,"discoverSource":32},6660,"Rectangle","rxhanson\u002FRectangle","rxhanson","Move and resize windows on macOS with keyboard shortcuts and snap areas","https:\u002F\u002Frectangleapp.com",null,"Swift",29219,944,95,108,0,9,47,187,36,43.93,"Other",false,"main",true,[],"2026-06-12 02:01:28","# Rectangle\n\n[![Build](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FRectangle\u002Factions\u002Fworkflows\u002Fbuild.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FRectangle\u002Factions\u002Fworkflows\u002Fbuild.yml)\n\nRectangle is a window management app based on Spectacle, written in Swift.\n\n\u003Cimg width=\"962\" height=\"886\" alt=\"image\" src=\"https:\u002F\u002Fgithub.com\u002Fuser-attachments\u002Fassets\u002Fe8d88e5f-7d4f-43bc-a82e-146c42f92d68\" \u002F>\n\n## System Requirements\n\nRectangle supports macOS v10.15+. The last version that is supported for macOS 10.13 and 10.14 is https:\u002F\u002Fgithub.com\u002Frxhanson\u002FRectangle\u002Freleases\u002Ftag\u002Fv0.73.\n\n## Installation\n\nYou can download the latest dmg from \u003Chttps:\u002F\u002Frectangleapp.com> or the [Releases page](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FRectangle\u002Freleases).\n\nOr install with brew cask:\n\n```bash\nbrew install --cask rectangle\n```\n\n## How to use it\n\nThe [keyboard shortcuts](https:\u002F\u002Fsupport.apple.com\u002Fguide\u002Fmac-help\u002Fwhat-are-those-symbols-shown-in-menus-cpmh0011\u002Fmac) are self explanatory, but the snap areas can use some explanation if you've never used them on Windows or other window management apps.\n\nDrag a window to the edge of the screen. When the mouse cursor reaches the edge of the screen, you'll see a footprint that Rectangle will attempt to resize and move the window to when the click is released.\n\n| Snap Area                                              | Resulting Action                       |\n|--------------------------------------------------------|----------------------------------------|\n| Left or right edge                                     | Left or right half                     |\n| Top                                                    | Maximize                               |\n| Corners                                                | Quarter in respective corner           |\n| Left or right edge, just above or below a corner       | Top or bottom half                     |\n| Bottom left, center, or right third                    | Respective third                       |\n| Bottom left or right third, then drag to bottom center | First or last two thirds, respectively |\n\n### Ignore an app\n\nIgnoring an app means that when the app is frontmost, keyboard shortcuts are un-registered from macOS. When the app is no longer frontmost, keyboard shortcuts are re-registered with macOS. This is useful for apps that have the same shortcuts like Rectangle and you do not want to change them.\n\n1. Focus the app that you want to ignore (make a window from that app frontmost).\n1. Open the Rectangle menu and select \"Ignore app\"\n\nTo un-ignore an app that you have selected to ignore, simply bring that app frontmost again, open the Rectangle menu, and deselect \"Ignore\".\n\n## Execute an action by URL\n\nOpen the URL `rectangle:\u002F\u002Fexecute-action?name=[name]`. Do not activate Rectangle if possible.\n\nAvailable values for `[name]`: `left-half`, `right-half`, `center-half`, `top-half`, `bottom-half`, `top-left`, `top-right`, `bottom-left`, `bottom-right`, `first-third`, `center-third`, `last-third`, `first-two-thirds`, `last-two-thirds`, `maximize`, `almost-maximize`, `maximize-height`, `smaller`, `larger`, `center`, `center-prominently`, `restore`, `next-display`, `previous-display`, `move-left`, `move-right`, `move-up`, `move-down`, `first-fourth`, `second-fourth`, `third-fourth`, `last-fourth`, `first-three-fourths`, `last-three-fourths`, `top-left-sixth`, `top-center-sixth`, `top-right-sixth`, `bottom-left-sixth`, `bottom-center-sixth`, `bottom-right-sixth`, `specified`, `reverse-all`, `top-left-ninth`, `top-center-ninth`, `top-right-ninth`, `middle-left-ninth`, `middle-center-ninth`, `middle-right-ninth`, `bottom-left-ninth`, `bottom-center-ninth`, `bottom-right-ninth`, `top-left-third`, `top-right-third`, `bottom-left-third`, `bottom-right-third`, `top-left-eighth`, `top-center-left-eighth`, `top-center-right-eighth`, `top-right-eighth`, `bottom-left-eighth`, `bottom-center-left-eighth`, `bottom-center-right-eighth`, `bottom-right-eighth`, `tile-all`, `cascade-all`, `cascade-active-app`\n\nExample, from a shell: `open -g \"rectangle:\u002F\u002Fexecute-action?name=left-half\"`\n\nURLs can also be used to ignore\u002Funignore apps. \n\n```\nrectangle:\u002F\u002Fexecute-task?name=ignore-app\nrectangle:\u002F\u002Fexecute-task?name=unignore-app\n```\nA bundle identifier can also be specified, for example:\n```\nrectangle:\u002F\u002Fexecute-task?name=ignore-app&app-bundle-id=com.apple.Safari\n```\n\n## Terminal Commands for Hidden Preferences\n\nSee [TerminalCommands.md](TerminalCommands.md)\n\n## Differences with Spectacle\n\n* Rectangle uses [MASShortcut](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FMASShortcut) for keyboard shortcut recording. Spectacle used its own shortcut recorder.\n* Rectangle has additional window actions: move windows to each edge without resizing, maximize only the height of a window, almost maximizing a window.\n* Next\u002Fprev screen thirds is replaced with explicitly first third, first two thirds, center third, last two thirds, and last third. Screen orientation is taken into account, as in first third will be left third on landscape and top third on portrait.\n  * You can however emulate Spectacle's third cycling using first and last third actions. So, if you repeatedly execute first third, it will cycle through thirds (first, center, last) and vice-versa with the last third.\n* There's an option to have windows traverse across displays on subsequent left or right executions.\n* Windows will snap when dragged to edges\u002Fcorners of the screen. This can be disabled.\n\n## Common Known Issues\n\n### Rectangle doesn't have the ability to move to other desktops\u002Fspaces\n\nApple never released a public API for doing this. Rectangle Pro has next\u002Fprev Space actions, but there are no plans to add those into Rectangle at this time.\n\n### Window resizing is off slightly for iTerm2\n\nBy default iTerm2 will only resize in increments of character widths. There might be a setting inside iTerm2 to disable this, but you can change it with the following command.\n\n```bash\ndefaults write com.googlecode.iterm2 DisableWindowSizeSnap -integer 1\n```\n\n### Rectangle appears to cause Notification Center to freeze\n\nThis appears to affect only a small amount of users. To prevent this from happening, uncheck the box for \"Snap windows by dragging\".\nSee issue [317](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FRectangle\u002Fissues\u002F317).\n\n### Troubleshooting\n\nIf windows aren't resizing or moving as you expect, here's some initial steps to get to the bottom of it. Most issues of this type have been caused by other apps.\n\n**Quick fixes (try these first):**\n\n1. **Lock and unlock your Mac** – This simple step resolves many issues, especially after system updates.\n1. Make sure macOS is up to date.\n1. Restart your Mac (this often fixes things right after a macOS update).\n\n**Diagnose the issue:**\n\n4. **Enable debug logging** (see instructions in the following section) – This helps identify whether Rectangle is working correctly.\n1. The logs are straightforward. If your calculated rect and your resulting rect are identical, chances are that there is another application causing issues.\n\n**Check for conflicts:**\n\n6. Make sure there are no other window manager applications running.\n1. Make sure that the app whose windows are not behaving properly does not have any conflicting keyboard shortcuts.\n1. Try using the menu items to execute a window action or changing the keyboard shortcut to something different so we can tell if it's a keyboard shortcut issue or not.\n\n**Advanced troubleshooting:**\n\n9. If you suspect there may be another application causing issues, try creating and logging in as a new macOS user.\n1. Save your logs to attach to an issue if you need to create one.\n\n#### Try resetting the macOS accessibility permissions for Rectangle:\n\n```bash\ntccutil reset All com.knollsoft.Rectangle\n```\n\nOr, this can be done with the following steps instead of the tccutil terminal command.\n1. Close Rectangle if it's running\n2. In System Settings -> Privacy & Security -> Accessibility, first disable Rectangle, then remove it with the minus button. (it's important to do both of those steps in that order)\n3. Restart your mac.\n4. Launch Rectangle and enable settings for it as prompted.\n\n## View Debug Logging\n\n1. Hold down the alt (option) key with the Rectangle menu open.\n1. Select the \"View Logging...\" menu item, which is in place of the \"About\" menu item.\n1. Logging will appear in the window as you perform Rectangle commands.\n\n## Import & export JSON config\n\nThere are buttons for importing and exporting the config as a JSON file in the settings tab of the preferences window. \n\nUpon launch, Rectangle will load a config file at `~\u002FLibrary\u002FApplication Support\u002FRectangle\u002FRectangleConfig.json` if it is present and will rename that file with a time\u002Fdate stamp so that it isn't read on subsequent launches.\n\n## Preferences Storage\n\nThe configuration for Rectangle is stored using NSUserDefaults, meaning it is stored in the following location:\n`~\u002FLibrary\u002FPreferences\u002Fcom.knollsoft.Rectangle.plist`\nNote that shortcuts in v0.41+ are stored in a different format and will not load in prior versions.\n\nThat file can be backed up or transferred to other machines.\n\nIf you are using Rectangle v0.44+, you can also use the import\u002Fexport button in the Preferences pane to share to your preferences and keyboard shortcuts across machines using a JSON file.\n\n> [!NOTE]  \n> If you are having issues with configuration options persisting after an application restart and you've installed using Homebrew, you will need to uninstall and reinstall with the `--zap` flag.\n\n```\nbrew uninstall --zap rectangle\nbrew install rectangle\n```\n\n## Uninstallation\n\nRectangle can be uninstalled by quitting the app and moving it to the trash. You can remove the Rectangle defaults from your machine with the following terminal command:\n\n```bash\ndefaults delete com.knollsoft.Rectangle\n```\n\n> [!TIP]  \n> If you are uninstalling after installing with Homebrew, you should include the `--zap` flag to ensure it removes the plist entries too. \n\n```\nbrew uninstall --zap rectangle\n```\n\n---\n\n## Contributing\n\nLogic from Rectangle is used in the [Multitouch](https:\u002F\u002Fmultitouch.app) app. The [Rectangle Pro](https:\u002F\u002Frectangleapp.com\u002Fpro) app is entirely built on top of Rectangle. If you contribute significant code or localizations that get merged into Rectangle, send me an email for a free license of Multitouch or Rectangle Pro. Contributors to Sparkle, MASShortcut, or Spectacle can also receive free Multitouch or Rectangle Pro licenses.\n\n### Contributing additional sizes and positions\n\nRectangle's UI is intentionally simple. If you want to add a size and position that's not in the Shortcuts tab, then you can now add them into the \"Extra Shortcuts\" section accessed via the ellipsis button at the bottom of the General tab.\n\n### Localization\n\nIf you would like to contribute to localization, all of the translations are held in the Main.strings.\n\nPull requests for new localizations or improvements on existing localizations are welcome.\n\n### Running the app in Xcode (for developers)\n\nRectangle uses [Swift Package Manager](https:\u002F\u002Fwww.swift.org\u002Fpackage-manager\u002F) to install Sparkle and MASShortcut.\n\nThe original repository for MASShortcut was archived, so Rectangle uses my [fork](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FMASShortcut). If you want to make any changes that involve MASShortcut, please make a pull request on my fork. \n\nDue to the addition of the Liquid Glass icon with a fallback for older versions of macOS, there will be a build failure on macOS versions \u003C 26. You can delete the \"Asset Catalog Other Flags\" to build locally on versions \u003C 26 (but don't check that change in if you create a pull request).\n\n## Credits\n\nAs mentioned above, Rectangle uses a forked version of [MASShortcut](https:\u002F\u002Fgithub.com\u002Frxhanson\u002FMASShortcut), which still works great, and it uses [Sparkle](https:\u002F\u002Fsparkle-project.org) for updates. \n\nThe Big Sur variant of the Rectangle app icon was created by Giovanni Maria Cusaro (@gmcusaro). The Liquid Glass variant of the app icon was created by [Alexander Käßner](https:\u002F\u002Fwww.alexkaessner.de) (@alexkaessner).\n\nAnd of course, there's been a lot of community contributions over the years :)\n","Rectangle 是一款基于 macOS 的窗口管理应用，允许用户通过键盘快捷键和拖拽操作来移动和调整窗口大小。它使用 Swift 语言编写，支持自定义快捷键和屏幕边缘的快速布局功能，如将窗口置于屏幕的一半、三分之一或四分之一等位置。此外，Rectangle 还提供了一个忽略特定应用程序的功能，以防止与已有快捷键冲突。这款工具非常适合需要高效利用多任务处理能力的 macOS 用户，特别是在进行多窗口工作时希望提高生产力的场景下。",2,"2026-06-11 03:08:10","top_language"]