summaryrefslogtreecommitdiff
path: root/src/layout/IHyprLayout.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* layout: set window size after toggling floatingVaxry2025-01-241-2/+1
|
* layout: damage window properly on float mode changesVaxry2025-01-231-0/+4
| | | | fixes #8849
* core: move all shared_ptrs from the STL to hyprutils (#9143)Vaxry2025-01-231-2/+2
|
* core: cleanup header includes (#9088)user1111111111111111111111111111111112025-01-171-0/+5
| | | Cleanup some unneeded includes to speed up compilation
* core: move parts of the animation system to hyprutils (#8868)Maximilian Seidler2025-01-071-50/+50
| | | | | | | | | | | | | * core: change animation manager to use Hyprutils::Animation * config: move animation config to hyprutils animation tree * use g_pAnimationManager->createAnimation and the new PHLANIMVAR template * core: use CGenericAnimatedVariabled::{enabled,setConfig,getStyle} and adapt callbacks * core: adapt animated variable usage (dereference the shared pointer) * misc: bump CMakeLists to hyprutils 0.3.3
* snap: don't snap to any windows if workspace has a fullscreen window (#8870)Mike Will2025-01-061-3/+5
|
* snap: give edge snapping precedence over corner snapping (#8873)Mike Will2024-12-291-4/+4
|
* snap: revert #8659, use bounds checking instead of bit mask (#8872)Mike Will2024-12-271-2/+2
| | | | | They seem like the same check, but a snap bit might not be turned on as expected if we grab a different corner after an edge has already been snapped.
* groups: honor group lock window rule (#8782)Aqa-Ib2024-12-211-0/+2
|
* layout: apply group rules after window creation (#8779)Aqa-Ib2024-12-191-3/+3
| | | | | * apply group rules after window creation * clang-format
* core: Optimize window/layer rule application and scanning (#8735)Vaxry2024-12-161-18/+20
| | | Optimizes window and layer rule parsing and later usage.
* snap: bias reserved area when its size is greater than zero (#8694)Mike Will2024-12-131-8/+13
|
* core: Add clang-tidy (#8664)Vaxry2024-12-071-2/+2
| | | | | This adds a .clang-tidy file for us. It's not a strict requirement to be compliant, but I tuned it to be alright.
* snap: use the bit mask to check if snapping occurred (#8659)Mike Will2024-12-061-2/+2
|
* snap: check which corner is being grabbed for monitor snapping (#8637)Mike Will2024-12-041-4/+8
|
* snap: account for position of multiple monitors (#8543)Mike Will2024-11-231-2/+2
|
* core: workspace-related function cleanup / refactorVaxry2024-11-221-5/+5
| | | | CCompositor is massive, and has a lot of functions that could be better optimized if in CWorkspace
* windows/xdg: minor cleanup of min/max size calculationsVaxry2024-11-171-4/+4
| | | | fixes #8495
* groups: add merge_groups_on_groupbar (#8362)Aqa-Ib2024-11-061-7/+3
|
* snap: add option `border_overlap` and other improvements (#8289)Mike Will2024-10-311-80/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * snap: add option `border_overlap` and other improvements I really liked the way borders used to overlap when snapping and how only the window's main surface would snap to the monitor, so I would like to bring that behavior back, but in the form of a config option. Other improvements include: - reduced the number of snap functions from 4 down to 2, and only one ever gets called at any given time. - border size should not be added to gap size. It seemed like the right thing to do at the time, but it makes snapping feel way stronger than it actually should. - all const variables have been given the all-caps naming convention. - to avoid excessive casting, border size is declared as a double. - to avoid excessive x + w, y + h calculations. I'm using a struct called Range and working only with start and end values until the very end of the function. - check for both monitor snapping as well as reserved monitor space snapping in a relatively efficient way. * snap: always border-align for corners and reserved monitor space We probably don't want to treat reserved monitor space as if it were just a smaller monitor. Instead, it should be treated more like a borderless window, which means our window's border should never encroach upon it.
* internal: check size limit in layouts (#8298)MightyPlaza2024-10-301-12/+11
| | | | | | | | | | | modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/helpers/MiscFunctions.cpp modified: src/helpers/MiscFunctions.hpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/MasterLayout.cpp modified: src/macros.hpp
* group: fix moveWindowIntoGroup (#8297)Aqa-Ib2024-10-301-11/+8
|
* layout: slight adjustments to snapping logic (#8273)Mike Will2024-10-281-3/+3
| | | fixes some bugs with resizing and corner snapping
* layout: don't snap to self and allow same-pid snapsVaxry2024-10-271-2/+1
| | | | fixes #8255
* layout: window snapping cleanup + fixesVaxry2024-10-271-44/+50
| | | | | | way better now heh fixes #8259 fixes #8267
* core: move internal structures to monitor pointers (#8266)Vaxry2024-10-271-9/+9
|
* groups: fix swallowing (#8223)Aqa-Ib2024-10-271-18/+13
| | | | | | | | | | | | | * fix swallowing for groups * remove unnecessary check * clang-format * clarify comment * make variables consistent * make aditional variables consistent
* groups: add group_on_movetoworkspace (#8159)Aqa-Ib2024-10-231-2/+3
|
* input: add snapping to floating windows (#8088)Mike Will2024-10-211-4/+151
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add snapping to floating windows Works for both moving and resizing of windows. It comes with 3 options: `general:snap:enabled` - whether it's enabled, off by default `general:snap:window_gap` - minimum gap in pixels between windows before snapping. Setting to 0 effectively turns off this method of snapping. `general:snap:monitor_gap` - minimum gap in pixels between window and monitor edges before snapping. Again, setting it to 0 effectively turns it off. * snap: add more ignore criteria and change if clause into a guard * snap: refactor code * snap: new refactoring approach and account for border size * snap: do corner snapping after all edge snapping is done The approach of performing corner snaps after each individual edge snap results in far fewer scenarios where snapping can occur. After trying it out for a while, I found that I prefer an approach that's more prone to snapping. * snap: combine snapWindows and snapMonitor into a single function * snap: add forced aspect ratio functionality * snap: avoid directly referring to border_size config value * snap: address vaxerski feedback - add new line between functions - use std::function typedef for SnapFn and make snap functions static - avoid uninitialized variable declarations. - change ignore condition m_bIsX11 to isX11OverrideRedirect() - use braces for CBox and Vector2D declarations. - add SNAP_INVALID to eSnapEdge enum - use bitshift notation for eSnapEdge and eRectCorner - make performSnap a non-member function. * snap: add corner-snapping to forced aspect ratio mode
* layout: move applyGroupRules() to onWindowCreated() (#8139)Aqa-Ib2024-10-161-3/+4
|
* layout: enable group rules for new floating windows (#8122)Aqa-Ib2024-10-161-1/+3
| | | | | | | | | | * layout: enable group rules for new floating windows * fix comment * do not apply group rules to a new floating window if it shouldBeFloated. fixes child windows * comment
* layout: simplify the conditions to autogroup (#8120)Aqa-Ib2024-10-141-5/+3
|
* layout: deny auto-grouping a new floating window into a tiled group (#8108)Aqa-Ib2024-10-141-6/+11
|
* layout: remove unnecessary check after 45e8219 (#8037)Aqa-Ib2024-10-081-6/+6
|
* layout: add drag_into_group to control merging dragging windows (#8004)Aqa-Ib2024-10-081-21/+44
|
* layout: fix auto group when opening a new window in a non-focused workspace ↵Aqa-Ib2024-10-071-14/+15
| | | | using window rules (#8006)
* layout: fix dragging a window into a group after e242694 (#7976)Aqa-Ib2024-10-021-2/+2
|
* layout: add auto_group to control default grouping (#7883)Aqa-Ib2024-10-021-13/+56
|
* window/xwayland: minor property cleanupVaxry2024-08-301-7/+7
| | | | fixes #6921
* misc: constify the remaining for loops (#7534)Tom Englund2024-08-261-3/+3
| | | now we roll loops at blazing constified speed.
* core: make most for loops use const references (#7527)Tom Englund2024-08-261-1/+1
| | | | why not let the compiler optimise things for us at hyprspeeds when we can.
* internal: refactor fullscreen states (#7104)MightyPlaza2024-07-311-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * refactor fullscreen modified: src/Compositor.cpp modified: src/Compositor.hpp modified: src/config/ConfigManager.cpp modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/LayerSurface.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/desktop/Workspace.cpp modified: src/desktop/Workspace.hpp modified: src/events/Windows.cpp modified: src/helpers/Monitor.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/DwindleLayout.hpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp modified: src/layout/MasterLayout.hpp modified: src/managers/KeybindManager.cpp modified: src/managers/KeybindManager.hpp modified: src/managers/input/IdleInhibitor.cpp modified: src/managers/input/InputManager.cpp modified: src/managers/input/Swipe.cpp modified: src/protocols/ForeignToplevelWlr.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * clean up modified: src/config/ConfigManager.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.hpp modified: src/desktop/Workspace.cpp modified: src/events/Windows.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/input/Swipe.cpp * fix mapWindow fullscreen modified: src/events/Windows.cpp * fix typo modified: src/desktop/Workspace.cpp * add fullscreenstate modified: src/config/ConfigManager.cpp modified: src/events/Windows.cpp * change syncFullscreen to lower modified: src/config/ConfigManager.hpp * initialize fs state modified: src/desktop/Window.hpp
* input: unify removing currentlyDraggedWindow (#7071)MightyPlaza2024-07-271-6/+7
| | | | | | | | modified: src/desktop/Window.cpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/KeybindManager.hpp modified: src/managers/input/InputManager.cpp
* layout: update workspace rules on layout change (#6878)MightyPlaza2024-07-151-0/+1
| | | | | modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/MasterLayout.cpp
* core: Improve handling of window properties (#6776)MightyPlaza2024-07-111-6/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * add mWindowProperties modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp * support int values modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp * create m_sWindowData modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/MasterLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * simplify some properties modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/managers/KeybindManager.cpp * store multiple values in CWindowOverridableVar modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * clean up modified: src/Compositor.cpp modified: src/Compositor.hpp modified: src/config/ConfigManager.cpp modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp modified: src/managers/KeybindManager.cpp * use SET_PROP priority for exec rules modified: src/config/ConfigManager.hpp modified: src/desktop/Window.cpp * add default value modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp * add setprop toggle modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp * add setprop toggle modified: src/debug/HyprCtl.cpp * make window rules functional modified: src/config/ConfigManager.cpp modified: src/desktop/Window.cpp * minor fixes modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.hpp * properly clean layout data modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/DwindleLayout.cpp modified: src/layout/IHyprLayout.cpp modified: src/layout/IHyprLayout.hpp modified: src/layout/MasterLayout.cpp * remove newline modified: src/events/Windows.cpp * fixes modified: src/config/ConfigManager.hpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp * use CamelCase modified: src/Compositor.cpp modified: src/debug/HyprCtl.cpp modified: src/desktop/Window.cpp modified: src/desktop/Window.hpp modified: src/events/Windows.cpp modified: src/layout/IHyprLayout.cpp modified: src/managers/AnimationManager.cpp modified: src/managers/KeybindManager.cpp modified: src/managers/XWaylandManager.cpp modified: src/render/OpenGL.cpp modified: src/render/Renderer.cpp modified: src/render/decorations/CHyprBorderDecoration.cpp modified: src/render/decorations/CHyprDropShadowDecoration.cpp modified: src/render/decorations/CHyprGroupBarDecoration.cpp
* core: Move to hyprutils for MathVaxry2024-06-191-2/+2
| | | | | | Moves CRegion, CBox and Vector2D over to hyprutils. Requires hyprutils>=0.1.4
* wayland/core: move to new impl (#6268)Vaxry2024-06-081-2/+3
| | | | | * wayland/core/dmabuf: move to new impl it's the final countdown
* layout: fix centering of new floating windowsvaxerski2024-06-031-1/+1
| | | | ref #6154
* xwayland: move to hyprland impl (#6086)Vaxry2024-05-251-4/+5
|
* layout: Fix shrinking pseudotile windows. (#6143)Gabriel Ford2024-05-181-1/+1
|