Skip to content

Commit

Permalink
Hyper shift + (enter = fullscreen, space = center)
Browse files Browse the repository at this point in the history
  • Loading branch information
mafredri committed Dec 10, 2022
1 parent d144dbf commit 9ad410c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ The definition of `hyper` and `hyperShift` can be found in [src/config.ts](src/c
* `hyperShift + Right` (Move window to right edge of screen)
* `hyperShift + Up` (Move window to top edge of screen)
* `hyperShift + Down` (Move window to bottom edge of screen)
* `hyperShift + Return` (Move window to center of screen)
* `hyperShift + Return` (Toggle window fullscreen, i.e. separate space)
* `hyperShift + Space` (Move window to center of screen)
* `hyperShift + Tab` (Jump to next screen whilst maintaining current window size)

Use combos of the key bindings to further place the windows:
Expand Down
8 changes: 8 additions & 0 deletions src/phoenix.ts
Original file line number Diff line number Diff line change
Expand Up @@ -375,6 +375,14 @@ onKey('return', hyperShift, () => {
if (!win) {
return;
}
win.setFullScreen(!win.isFullScreen());
});

onKey('space', hyperShift, () => {
const win = Window.focused();
if (!win) {
return;
}

const {width, height} = win.frame();
const {
Expand Down

0 comments on commit 9ad410c

Please sign in to comment.