Commit Graph

403 Commits

Author SHA1 Message Date
thejch d0229d6e1e
layout: limit updates when mouse animate drag is enabled (#5838) 2024-05-02 14:28:51 +01:00
Vaxry bca7804bb6
internal: Window storage rework - part 1 (#5762)
* Window storage rework - part 1

* format

* remove useless include

* fix pch

* format

* fix crash in dwindle

* fix vram leak

* prefer .expired() for bool checks
2024-04-27 12:43:12 +01:00
Maarten de Vries e57a2d7ec8
keybindmgr: add optional `silent` suffix to `movewindow`. (#5597)
With the `silent` suffix, the focus remains on the current position in
the layout or the current monitor, instead of following the moved
window. When combined with `movewindow mon:X`, this this allows you to
get the same behavior as xmonad's `windowToScreen` command.
2024-04-17 12:04:16 +01:00
thejch 34396f55a2
master: change the mfact dispatcher to use splitratio (#4766)
* master layout: change the mfact dispatcher to use splitratio

* add space for concat
2024-04-13 01:54:18 +01:00
Jan-Peter Dhallé e0a7cf5c30
master: fix full height when all windows master (#5549) 2024-04-12 00:05:30 +01:00
thejch 89f775aec2
master: fix crash (#5472) 2024-04-07 15:21:12 +01:00
thejch e80bccad51
master: fix workspace orientation not being restored after workspace rule no longer applies (#5463) 2024-04-06 23:49:38 +01:00
thejch 1e8f57c734
workspacerules: fix workspace rule loops (#5433) 2024-04-05 16:54:30 +01:00
Vaxry 9cf563065a layouts: add missing include 2024-04-04 01:10:46 +01:00
thejch fbdaf74a82
master: fix swapped workspaces (#5397) 2024-04-03 01:22:59 +01:00
thejch 3965faafac
master: fix center resizing (#5394) 2024-04-03 01:22:27 +01:00
Vaxry ef23ef60c5
Workspace/core: Refactor workspace storage (#5380)
* refactor workspaces to use ptrs

* clang-format
2024-04-02 20:32:39 +01:00
Vaxry 05eb2d4af2 master: guard window in moveWindowTo
fixes #5374
2024-04-02 12:46:15 +01:00
thejch ef7ac53e99
master: Make master workspace orientation rule dynamic (#5339)
* make master workspace orientation rule dynamic

* fix rebase

* fix special ws resizing

* style
2024-04-01 03:02:47 +01:00
thejch 5e8c25d498
core: match all workspace rules instead of the first one only (#5340) 2024-03-31 00:49:53 +00:00
Vaxry fcd9d77b64 layout: improve initial size prediction for floating 2024-03-29 00:43:50 +00:00
Brett Alcox 214ec82ba7
build: fix builds without pch (#5198) 2024-03-21 01:54:10 +00:00
Vaxry 8593c45be3 refactor: move window.hpp to desktop/ 2024-03-20 01:44:51 +00:00
phonetic112 bcba3951f4
input: Only limit drag resizes (#5164)
* only limit drag resizes

* change to not equals

* remove extra parentheses
2024-03-19 16:03:31 +00:00
thejch e6532ba024
animations: Fix incorrect animation when manually moving a window when its being created (#5141)
* fix incorrect rendering when manually moving a window when its being created

* add setAnimationsToMove
2024-03-19 02:52:52 +00:00
thejch 0387528c56
master: fix moving fullscreen workspace and remove duplicate code (#5131) 2024-03-17 00:15:12 +00:00
Vaxry c4f52d1979 master: fix invalid config usage 2024-03-15 19:31:33 +00:00
djvs 893c55217b
input: only override dragging corner on floating (#5092)
Co-authored-by: djvs <djvs@users.noreply.github.com>
2024-03-13 03:38:32 +00:00
djvs c58fcfbce2
input: add general:resize_corner for manual resizing (#5090)
* Resize corner config thing

* clang-format

---------

Co-authored-by: djvs <djvs@users.noreply.github.com>
2024-03-13 02:43:22 +00:00
thejch 7ea555da7f
master: Fix master layout window focus and scroll (#5074)
* fix master switch window scrolling

* fix some more dispatchers and remove some duplicate code

* refactor and remove duplicate code

* fix focusmonitor: https://github.com/hyprwm/Hyprland/issues/5006#issuecomment-1986977255

* change check
2024-03-13 02:09:20 +00:00
Vaxry 220144276b layout: unfullscreen on toggle into tiled fullscreen
fixes a bug where the tiled window would be on top
2024-03-10 22:31:49 +00:00
Vaxry 0a1632a79f dwindle: preserve fs state on switchWindows
fixes #2842
2024-03-10 22:27:23 +00:00
Epilepsy Gatherings e52d3fa852
windowrules: Make min/maxsize rules dynamic (#4775)
* rebase

* simplify and remove prop

* Stuff

- add back win prop
- change minsize defaults
- change request formatting for setprop

* style fix

* remove empty line

* change defaults

* redo string to vec

* remove redundant parsing

* change to vec

* support commas

* remove static rules

* take out garbage

* format

* don't allow commas and resize on setprop

* use isNumber
2024-03-08 02:24:44 +00:00
thejch 6c4e2489a0
layout: Fix toggling fullscreen special workspace on different monitor (#5000)
* fix toggling fullscreen special ws on different monitor

* add for dwindle

* fix change regular workspace when special fullscreen
2024-03-07 13:27:58 +00:00
thejch bf71026b8d
master: change active monitor when moving windows around (#5001) 2024-03-07 13:23:22 +00:00
bvr-yr fb87e332c5
input: fix window move stutter by introducing additional checks for low-hz monitors (#4553)
* resize-limiter: add additional check for low-hz monitors

* simplify checker

* add comment

* rename variable
2024-03-06 00:15:44 +00:00
Junxuan Liao f8a081b56d
layout: warp the cursor when focusing windows (#4982)
Similar to the `focuswindow` dispatcher, when focusing a window with
wlr-foreign-toplevel-management, the cursor should be warped. Otherwise, the
focus is lost immediately after the cursor moves.
2024-03-05 17:56:06 +00:00
thejch 9c48c322d4
keybinds: Allow fullscreen/maximize in special workspace (#4921)
* allow fullscreen/maximize in special workspace

* remove duplicate code

* hide top layer

* fix special fullscreen deco

* edit

* fix fade top layer when toggle special

* remove double render
2024-03-04 23:29:45 +00:00
Vaxry 063708df26 config: improve config value infrastructure 2024-03-03 18:41:38 +00:00
thejch 28272d2d74
master: Fix animate resize (#4942)
* fix master animate resize

* fix some other pointers
2024-03-03 17:03:23 +00:00
Vaxry d2289d8327 xdg: minor improvements to initial size reporting
fixes #4918
2024-03-02 18:53:17 +00:00
Vaxry 8811f4b69a drag: check min size for reisze drags
fixes #4920
2024-03-02 15:25:32 +00:00
GartoxFR b2c3440477
animations: Refactor AnimatedVariable (#4911)
* animation: Refactor AnimatedVariable

This commit decomposes the AnimatedVariable class into a base class
with the common attribute to all variable types and a templated derived
type containing strongly typed info on the type being animated.

Access to the typed version is perfomed using the visitor pattern. A
utility is provided to build a visitor on the fly using lambdas.

Adding a new type to be animated should just be a matter of adding the
typed in the list defined by the ANIMABLE_TYPES macro

The size of the commit is justified by the API change in the
AnimatedVariable class. No more vec(), fl() or col() method but a unified
value() method.

* animation: Remove visitor pattern

* animation: Fix coding style

* animation: Fix coding style
2024-03-02 00:35:17 +00:00
Vaxry f4f3aa2e50 layout: add size prediction for initial xdg commits
fixes #4022
2024-02-28 11:45:43 +00:00
Dashie ddf022d61c
feat: Add css style gaps (#4723) 2024-02-21 11:07:39 +00:00
Vaxry 13f6f0b923
Migrate the config to hyprlang (#4656)
* Migrate to hyprlang

* pop up errors

* fix swapped args

* Meson & Nix: build with hyprlang

* CI: add hyprlang to setup action

* add infra for plugin stuff

* fix hyprctl getoption

* fix hyprctl getoption with json

* format

* fix post parse logic

* fix autogen config

* oops missed exec-once

* fmt

* fix ws rules

* require 0.3.0 for hyprlang

* nix: flaek

* minor type fixes

* fix cfg usages in swipe

* use cvarlist for ws rules

* fix throw in addPluginConfigVar

* Nix: update hyprlang

* minor fixes

* fix disableLogs

* mention hyprlang docs

* bump hyprlang dep in cmake

* Meson: bump min hyprlang version

Nix: update hyprlang

* minor fix

* Nix: update meson patch

---------

Co-authored-by: Mihai Fufezan <fufexan@protonmail.com>
2024-02-18 15:00:34 +00:00
Niklas Haas d5950f7719
dwindle: add swapsplit dispatcher (#4702)
This is distinct from `swapwindow` in that it allows swapping the entire
tree node with its neighbour.

Fixes: https://github.com/hyprwm/Hyprland/issues/4701
2024-02-14 17:58:28 +00:00
Vaxry 0608791480 dwindle: round wbox before setting 2024-02-14 11:44:47 +00:00
Epilepsy Gatherings 2a3429d4cf
internal: add `forcenofocus` prop (#4672)
* add forcenofocus

* change nofocus to overridable var
2024-02-13 18:07:19 +00:00
MightyPlaza cbadf3e3f3
input: focus window on mouse down on decoration (#4514)
Also unifies vectorToWindow funcs
2024-02-04 15:40:20 +00:00
Vaxry 341e04a36c dwindle: avoid sending negative sizes to wlr
fixes #4591
2024-02-02 15:04:04 +00:00
rszyma 12d79d6342
dwindle: fix windows being created at incorrect position when cursor is over reserved area (#4520)
* fix: smart_split not working correctly when creating a window with cursor over reserved area

* use getClosestNodeOnWorkspace instead of getFirstNodeOnWorkspace when hovering over reserved area

* optimize `getClosestNodeOnWorkspace`

* remove unused methods
2024-01-26 22:30:36 +00:00
bvr-yr 08e3519747
layout: save float props before setting fs state (#4537)
fixes #4388
2024-01-26 17:24:00 +00:00
Epilepsy Gatherings 9f20a15955
input: remove animate checks on resize limiter (#4480) 2024-01-19 15:45:51 +01:00
Clyybber 8d31c84483
layout: Round window pos and size on togglefloating (#4407)
Also restore the behaviour introduced in bc4a51dbbb
2024-01-10 18:08:58 +01:00