If you use API methods like hs.grid.pushWindowDown(), you will not face this This is done to make sure interactive grid cells do not run out of hints. Then Hammerspoon merges few cells such that interactive grid dimensions do not exceed HINTS dimensions. When displaying interactive grid, if gird dimensions ( hs.tGrid()) are greater than HINTS dimensions, hs.inspect(hs.grid.HINTS) from the console will show you how the table is built.Functions - API calls offered directly by the extensionĪPI Documentation Variables HINTS SignatureĪ bidimensional array (table of tables of strings) holding the keyboard hints (as per hs.keycodes.map) to be used for the interactive resizing interface.In this case, the grid will highlight the selected cells.Īfter highlighting enough cells, press enter to move/resize the window to the highlighted area. Once you selected a cell, you can use the arrow keys to navigate through the grid. You can also use the arrow keys to move the window onto adjacent screens, and the tab/shift-tab keys to cycle to the next/previous window. The selected cell will become the new upper-left of the window. To resize/move the window, you can select the corner cells of the desired position.įor a move-only, you can select a cell and confirm with 'return'. The grid will be overlaid on the focused or frontmost window's screen with keyboard hints. a cell '2,0 1x1' will be in the upper-right cornerĪdditionally, a modal keyboard driven interface for interactive resizing is provided via hs.grid.show().a cell '0,0 1x1' will be in the upper-left corner.h - The number of rows the window occupies.w - The number of columns the window occupies.y - The row of the top edge of the window.x - The column of the left edge of the window.Each cell is an hs.geometry rect with these fields: Windows that are aligned with the grid have their location and size described as a cell. You can specify different grid layouts for different screens and/or screen resolutions. The default layout of the grid is 3 columns by 3 rows. The grid partitions your screens for the purposes of window management.
0 Comments
Leave a Reply. |