aboutsummaryrefslogtreecommitdiff
path: root/src/layout.rs
AgeCommit message (Collapse)Author
2023-10-07Update bounds of toplevel windowsIvan Molodetskikh
2023-10-07Add gaps settingIvan Molodetskikh
The past few refactors have led up to this point, and now it's finally possible.
2023-10-07layout: Refactor view offset, padding, work area handlingIvan Molodetskikh
Fixes broken padding on fullscreen windows, especially with struts on the sides present. It is now view offset's job to include padding and struts.
2023-10-05layout: Add every_op test from starting stateIvan Molodetskikh
2023-10-05layout: Handle padding in ColumnWidth::resolve()Ivan Molodetskikh
2023-10-05Refactor layout for configurability, add preset-column-widths optionIvan Molodetskikh
layout.rs finally gets a struct actually named Layout.
2023-10-04layout: Store view size in ColumnsIvan Molodetskikh
2023-10-03Add set-column-width actionIvan Molodetskikh
2023-10-01Avoid sending frame callbacks to invisible surfacesIvan Molodetskikh
2023-10-01Make find_window_and_output() accept non-mut selfIvan Molodetskikh
2023-09-30Compute view offset relative to anim targetIvan Molodetskikh
This enables quickly tapping focus right-left to keep typing in the current window while showing the next window. Resolves https://github.com/YaLTeR/niri/issues/26
2023-09-30Refactor frame schedulingIvan Molodetskikh
Combine the redraw state variables into one enum, and refactor to get rid of the requirement that a VBlank must queue a subsequent redraw. Also fix the bug where ongoing animations that produced no damage could stall the redrawing.
2023-09-29Throttle frame callbacks to once per monitor refreshIvan Molodetskikh
Under some circumstances, the compositor can get into a commit-frame callback busy loop with a client. For example, if a client redraws on frame callbacks, but the resulting frame has empty damage (e.g. the damaged part of the client is outside the monitor). Or if the client simply commits with empty damage (looking at you, Firefox). This behavior is compliant with the Wayland specification and with the intended idea of frame callbacks, but causes a lot of unnecessary CPU usage in the client and the compositor. To solve this problem, this commit introduces frame callback throttling. Every surface may only receive a single frame callback in one monitor refresh cycle. If a surface commits resulting in no KMS frame submission, a timer is created, that will fire at the predicted would- be-VBlank time, and send the accumulated frame callbacks. This way, a surface that redraws on frame callbacks will not notice any change in frame callback delivery, if its commits suddenly stop producing KMS updates.
2023-09-28layout: Add communicate op to testsIvan Molodetskikh
2023-09-28layout: Refresh windows tooIvan Molodetskikh
This will send output enter/leave to new popups.
2023-09-27layout: Use actual working area on workspace creationIvan Molodetskikh
Fixes https://github.com/YaLTeR/niri/issues/19
2023-09-27layout: Add more ops for proptest to play withIvan Molodetskikh
2023-09-27layout: Add randomized testIvan Molodetskikh
2023-09-27Fix test nameIvan Molodetskikh
2023-09-26Fix panic when the last window on previous workspace is closedIvan Molodetskikh
2023-09-26Extract check_opsIvan Molodetskikh
2023-09-26Fix panic when adding previously-removed output sometimesIvan Molodetskikh
2023-09-26Fix verify_invariants() assertsIvan Molodetskikh
2023-09-26Add layer shell exclusive zone supportIvan Molodetskikh
2023-09-26Make focus ring configurableIvan Molodetskikh
2023-09-24Add focus ringsIvan Molodetskikh
2023-09-24layout: Focus prev column when removing just created columnIvan Molodetskikh
This works similar to tabs in Firefox: when you create a tab and then close it without focusing any other tabs, the focus returns to the previously-focused tab, rather than the usual next tab. The logic is that in this case, the new tab was likely transient, and the user wants to get right back to what they were doing. In niri's case, this also serves as a workaround for wl-clipboard spawning and destroying a window, messing up the focus.
2023-09-24layout: Preserve active column when column to the left is removedIvan Molodetskikh
2023-09-21Add output configuration & integer scaling supportIvan Molodetskikh
2023-09-21layout: Fix workspace output updatingIvan Molodetskikh
2023-09-16Add by-index workspace commands and bindsIvan Molodetskikh
2023-09-13layout: Correct view offset when swapping columnsIvan Molodetskikh
2023-09-13Implement minimizing view movement on changesIvan Molodetskikh
Before this commit, windows were always left-aligned. Now, when changing focus, if the window is fully visible, the view doesn't move. If the window is not fully visible, the view is moved the minimum amount.
2023-09-12layout: Add tests for various operationsIvan Molodetskikh
2023-09-12layout: Fix assertion in verify_invariants()Ivan Molodetskikh
2023-09-12layout: Replace add_window_to_output with add_windowIvan Molodetskikh
2023-09-05layout: Fix input to non-active window in columnIvan Molodetskikh
2023-09-03Send scanout feedbacks to surfacesIvan Molodetskikh
2023-08-27Extract different parts of rendering into functionsIvan Molodetskikh
2023-08-16Remove some commented out codeIvan Molodetskikh
2023-08-16Implement wp-presentationIvan Molodetskikh
2023-08-16Respect max window widthIvan Molodetskikh
2023-08-16Use the correct min_size stateIvan Molodetskikh
2023-08-16Put active window on topIvan Molodetskikh
2023-08-16Add basic fullscreen implIvan Molodetskikh
2023-08-16Add binds to move between monitorsIvan Molodetskikh
2023-08-15Add initial layer-shell implementationIvan Molodetskikh
Those surfaces never receive mouse focus and always keyboard focus, which may not be always good, but it'll do for now.
2023-08-14Add Mod+F to maximizeIvan Molodetskikh
2023-08-14Add Mod+R to toggle between preset widthsIvan Molodetskikh
2023-08-14Advance animations in process_input_eventIvan Molodetskikh