feat(config): add aspect ratios for float toggling

This commit adds a new configuration option
"floating_window_aspect_ratio", which users can manipulate to set their
desired window size when using the toggle-float command.

resolve #1230
This commit is contained in:
LGUG2Z
2025-01-23 17:17:28 -08:00
parent 0a2dbed116
commit 473e7cd6a0
5 changed files with 273 additions and 118 deletions

View File

@@ -1,7 +1,7 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "StaticConfig",
"description": "The `komorebi.json` static configuration file reference for `v0.1.33`",
"description": "The `komorebi.json` static configuration file reference for `v0.1.34`",
"type": "object",
"properties": {
"animation": {
@@ -642,6 +642,39 @@
]
}
},
"floating_window_aspect_ratio": {
"description": "Aspect ratio to resize with when toggling floating mode for a window",
"anyOf": [
{
"description": "21:9",
"type": "null"
},
{
"description": "16:9",
"type": "null"
},
{
"description": "4:3",
"type": "null"
},
{
"description": "A custom W:H aspect ratio",
"type": "array",
"items": [
{
"type": "integer",
"format": "int32"
},
{
"type": "integer",
"format": "int32"
}
],
"maxItems": 2,
"minItems": 2
}
]
},
"focus_follows_mouse": {
"description": "END OF LIFE FEATURE: Use https://github.com/LGUG2Z/masir instead",
"oneOf": [