Add centered layout support (#9754)
This PR implements the Centered Layout feature (#4685): - Added the `toggle centered layout` action. - The centered layout mode only takes effect when there's a single central pane. - The state of the centered layout toggle is saved / restored between Zed restarts. - The paddings are controlled by the `centered_layout` setting: ```json "centered_layout": { "left_padding": 0.2, "right_padding": 0.2 } ``` This allows us to support both the VSCode-style (equal paddings) and IntelliJ-style (only left padding in Zen mode). Release Notes: - Added support for Centered Layout ([#4685](https://github.com/zed-industries/zed/pull/9754)). https://github.com/zed-industries/zed/assets/2101250/2d5b2a16-c248-48b5-9e8c-6f1219619398 Related Issues: - Part of #4382
This commit is contained in:
@@ -47,11 +47,20 @@
|
||||
// The factor to grow the active pane by. Defaults to 1.0
|
||||
// which gives the same size as all other panes.
|
||||
"active_pane_magnification": 1.0,
|
||||
// Centered layout related settings.
|
||||
"centered_layout": {
|
||||
// The relative width of the left padding of the central pane from the
|
||||
// workspace when the centered layout is used.
|
||||
"left_padding": 0.2,
|
||||
// The relative width of the right padding of the central pane from the
|
||||
// workspace when the centered layout is used.
|
||||
"right_padding": 0.2
|
||||
},
|
||||
// The key to use for adding multiple cursors
|
||||
// Currently "alt" or "cmd_or_ctrl" (also aliased as
|
||||
// "cmd" and "ctrl") are supported.
|
||||
"multi_cursor_modifier": "alt",
|
||||
// Whether to enable vim modes and key bindings
|
||||
// Whether to enable vim modes and key bindings.
|
||||
"vim_mode": false,
|
||||
// Whether to show the informational hover box when moving the mouse
|
||||
// over symbols in the editor.
|
||||
|
||||
Reference in New Issue
Block a user