Easily create, save, and use desktop arrangements.
Positioning logic adapted from https://github.com/dploeger/hammerspoon-window-manager
Signature | ArrangeDesktop.arrangements |
---|---|
Type | Variable |
Description | Contains the configured desktop arrangements |
Source | Source/ArrangeDesktop.spoon/init.lua line 21 |
Signature | ArrangeDesktop.configFile |
---|---|
Type | Variable |
Description | Defines where the config file is stored. Defaults to hs.spoons.scriptPath()/config.json |
Source | Source/ArrangeDesktop.spoon/init.lua line 26 |
Signature | ArrangeDesktop.logger |
---|---|
Type | Variable |
Description | Logger object used within the Spoon. Can be accessed to set the default log level for the messages coming from the Spoon. |
Source | Source/ArrangeDesktop.spoon/init.lua line 16 |
Signature | ArrangeDesktop._buildArrangement() -> table |
---|---|
Type | Function |
Description | Builds the configuration for the current desktop arrangement. |
Parameters |
|
Returns |
|
Source | Source/ArrangeDesktop.spoon/init.lua line 72 |
Signature | ArrangeDesktop._loadConfiguration() -> table or nil |
---|---|
Type | Function |
Description | Loads the configuration file. |
Parameters |
|
Returns |
|
Source | Source/ArrangeDesktop.spoon/init.lua line 31 |
Signature | ArrangeDesktop._positionApp(app, appTitle, screen, frame) |
---|---|
Type | Function |
Description | Positions all windows for an application based on the given configuration. |
Parameters |
|
Returns | |
Source | Source/ArrangeDesktop.spoon/init.lua line 113 |
Signature | ArrangeDesktop._writeConfiguration(config) -> bool |
---|---|
Type | Function |
Description | Writes the configuration to a file. |
Parameters |
|
Returns |
|
Source | Source/ArrangeDesktop.spoon/init.lua line 59 |
Signature | ArrangeDesktop:addMenuItems(menuItems) -> table |
---|---|
Type | Method |
Description | Add menu items to a table for each configured desktop arrangement. |
Parameters |
|
Returns |
|
Source | Source/ArrangeDesktop.spoon/init.lua line 154 |
Signature | ArrangeDesktop:arrange(arrangement) |
---|---|
Type | Method |
Description | Arrange the desktop based on a given configuration |
Parameters |
|
Returns | |
Source | Source/ArrangeDesktop.spoon/init.lua line 135 |
Signature | ArrangeDesktop:createArrangement() |
---|---|
Type | Method |
Description | Creates the desktop arrangement and saves it to the configuration file. |
Parameters |
|
Returns | |
Source | Source/ArrangeDesktop.spoon/init.lua line 186 |