Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse

NodeBB

  1. Home
  2. uncategorized
  3. Decided to try writing a Wayland compositor for fun.

Decided to try writing a Wayland compositor for fun.

Scheduled Pinned Locked Moved uncategorized
158 Posts 1 Posters 1 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • ? Guest

    Over the past 2 weeks I've been slowly but surely working on the interactive move niri PR [1] by @pajn. It's already got me to fix quite a bit of tech debt in the layout code, which is cool.

    The PR is still rough around the edges, but mostly works, and I switched to running the branch on my own systems to give it thorough testing.

    (also no, this is not the Floating Layer yet, though it's a good step towards that)

    Attaching a video of what it looks like rn

    [1]: https://github.com/YaLTeR/niri/pull/547

    #niri

    ? Offline
    ? Offline
    Guest
    wrote on last edited by
    #84

    Made interactive move work on touch (and resize too while I was at it), didn't need that many changes actually

    #niri

    ? 1 Reply Last reply
    0
    • ? Guest

      Made interactive move work on touch (and resize too while I was at it), didn't need that many changes actually

      #niri

      ? Offline
      ? Offline
      Guest
      wrote on last edited by
      #85

      Added a bit of rubberbanding before the window is "dragged out" of the layout. Should help avoid unintended layout changes.

      Along with a few more fixes I did, I think interactive move should be good to merge? It's not 100% perfect and jank free, but I'm fairly sure I got all the important things done. Will give it some more testing.

      #niri

      ? 1 Reply Last reply
      0
      • ? Guest

        Added a bit of rubberbanding before the window is "dragged out" of the layout. Should help avoid unintended layout changes.

        Along with a few more fixes I did, I think interactive move should be good to merge? It's not 100% perfect and jank free, but I'm fairly sure I got all the important things done. Will give it some more testing.

        #niri

        ? Offline
        ? Offline
        Guest
        wrote on last edited by
        #86

        Suddenly, @drakulix showcasing the Cosmic session running on, among other compositors, niri! On the big screen at the Ubuntu Summit 😄

        https://github.com/Drakulix/cosmic-ext-extra-sessions

        #niri

        ? 1 Reply Last reply
        0
        • ? Guest

          Suddenly, @drakulix showcasing the Cosmic session running on, among other compositors, niri! On the big screen at the Ubuntu Summit 😄

          https://github.com/Drakulix/cosmic-ext-extra-sessions

          #niri

          ? Offline
          ? Offline
          Guest
          wrote on last edited by
          #87

          somehow this touch moving under stationary pointer works better than i expected

          (yes trying to do a precise left click with an elbow was difficult)

          ? 1 Reply Last reply
          0
          • ? Guest

            somehow this touch moving under stationary pointer works better than i expected

            (yes trying to do a precise left click with an elbow was difficult)

            ? Offline
            ? Offline
            Guest
            wrote on last edited by
            #88

            By the way! I'll be giving a talk at RustCon in Moscow on December, 6!

            https://rustcon.ru/

            Wherein I will briefly describe what a Wayland compositor is, and then show several testing and profiling workflows that I've been using to keep niri stable, robust and performant.

            (The invitation to submit a talk was completely unexpected, guess niri found its way into the right eyes. 😅)

            There will be a recording, though in Russian.

            #rust #niri

            ? 1 Reply Last reply
            0
            • ? Guest

              By the way! I'll be giving a talk at RustCon in Moscow on December, 6!

              https://rustcon.ru/

              Wherein I will briefly describe what a Wayland compositor is, and then show several testing and profiling workflows that I've been using to keep niri stable, robust and performant.

              (The invitation to submit a talk was completely unexpected, guess niri found its way into the right eyes. 😅)

              There will be a recording, though in Russian.

              #rust #niri

              ? Offline
              ? Offline
              Guest
              wrote on last edited by
              #89

              Interactive window moving, laptop lid and tablet mode switch binds, mouse and touchpad scroll speed setting in today's niri v0.1.10 release!

              https://github.com/YaLTeR/niri/releases/tag/v0.1.10

              Also, niri-ipc is now on crates.io, but keep in mind that it will not be Rust-semver-stable: https://crates.io/crates/niri-ipc

              #wayland #smithay #rust #niri

              ? 1 Reply Last reply
              0
              • ? Guest

                Interactive window moving, laptop lid and tablet mode switch binds, mouse and touchpad scroll speed setting in today's niri v0.1.10 release!

                https://github.com/YaLTeR/niri/releases/tag/v0.1.10

                Also, niri-ipc is now on crates.io, but keep in mind that it will not be Rust-semver-stable: https://crates.io/crates/niri-ipc

                #wayland #smithay #rust #niri

                ? Offline
                ? Offline
                Guest
                wrote on last edited by
                #90

                Added scaffolding for layer rules, along with a block-out-from rule. Now you can finally block notifications from screencasts!

                Though, layer-shell surfaces don't have a "geometry" so if they have shadows or transparent padding, all of that becomes solid black, since niri has no way to know where the "actual content" of the layer surface is (that's what geometry is for windows).

                #niri

                ? 1 Reply Last reply
                0
                • ? Guest

                  Added scaffolding for layer rules, along with a block-out-from rule. Now you can finally block notifications from screencasts!

                  Though, layer-shell surfaces don't have a "geometry" so if they have shadows or transparent padding, all of that becomes solid black, since niri has no way to know where the "actual content" of the layer surface is (that's what geometry is for windows).

                  #niri

                  ? Offline
                  ? Offline
                  Guest
                  wrote on last edited by
                  #91

                  We hit 4000 stars today on the niri repo!!

                  #niri

                  ? 1 Reply Last reply
                  0
                  • ? Guest

                    We hit 4000 stars today on the niri repo!!

                    #niri

                    ? Offline
                    ? Offline
                    Guest
                    wrote on last edited by
                    #92

                    Thanks to Christian Meissl's fix in Smithay, the git version of niri correctly shows nested pop-up menus in lxqt-panel. They also submitted a fix for invalid pop-up spawning to ironbar, which makes it work on Smithay compositors.

                    #niri #lxqt

                    ? 1 Reply Last reply
                    0
                    • ? Guest

                      Thanks to Christian Meissl's fix in Smithay, the git version of niri correctly shows nested pop-up menus in lxqt-panel. They also submitted a fix for invalid pop-up spawning to ironbar, which makes it work on Smithay compositors.

                      #niri #lxqt

                      ? Offline
                      ? Offline
                      Guest
                      wrote on last edited by
                      #93

                      Somehow, a small change for tests escalated into trying to completely refactor how animation timing works in niri. And right now I find myself at the exact opposite of this picture. Unfortunately, time has not stopped and is causing problems

                      ? 1 Reply Last reply
                      0
                      • ? Guest

                        Somehow, a small change for tests escalated into trying to completely refactor how animation timing works in niri. And right now I find myself at the exact opposite of this picture. Unfortunately, time has not stopped and is causing problems

                        ? Offline
                        ? Offline
                        Guest
                        wrote on last edited by
                        #94

                        Like three complete refactors later, I think it's... working? For real this time? No weird issue is gonna sneak up that undermines the whole design?

                        ? 1 Reply Last reply
                        0
                        • ? Guest

                          Like three complete refactors later, I think it's... working? For real this time? No weird issue is gonna sneak up that undermines the whole design?

                          ? Offline
                          ? Offline
                          Guest
                          wrote on last edited by
                          #95

                          Nothing seems to have caught on fire after one more day of personal testing and one more day in main. So here's a technical page I wrote about the the new niri animation timing design and its motivations: https://github.com/YaLTeR/niri/wiki/Animation-Timing

                          ? 1 Reply Last reply
                          0
                          • ? Guest

                            Nothing seems to have caught on fire after one more day of personal testing and one more day in main. So here's a technical page I wrote about the the new niri animation timing design and its motivations: https://github.com/YaLTeR/niri/wiki/Animation-Timing

                            ? Offline
                            ? Offline
                            Guest
                            wrote on last edited by
                            #96

                            Today I merged a PR by FluxTape which adds "always empty workspace before first" to niri. At the surface this is just a simple config flag with obvious behavior, but it's actually full of edge cases! Things like which workspace to focus at startup. The code refers to workspaces by index in many places, and those all shift when you suddenly insert an empty workspace at index 0.

                            Took several days to catch them all even with our randomized tests, but I think it should be good now.

                            #niri

                            ? 1 Reply Last reply
                            0
                            • ? Guest

                              Today I merged a PR by FluxTape which adds "always empty workspace before first" to niri. At the surface this is just a simple config flag with obvious behavior, but it's actually full of edge cases! Things like which workspace to focus at startup. The code refers to workspaces by index in many places, and those all shift when you suddenly insert an empty workspace at index 0.

                              Took several days to catch them all even with our randomized tests, but I think it should be good now.

                              #niri

                              ? Offline
                              ? Offline
                              Guest
                              wrote on last edited by
                              #97

                              >did a +4,657 −4,237 refactor in the layout code
                              >while testing, already found two uncaught regressions introduced in previous niri releases, and no issues with the refactor

                              ? 1 Reply Last reply
                              0
                              • ? Guest

                                >did a +4,657 −4,237 refactor in the layout code
                                >while testing, already found two uncaught regressions introduced in previous niri releases, and no issues with the refactor

                                ? Offline
                                ? Offline
                                Guest
                                wrote on last edited by
                                #98

                                This morning was my niri (-adjacent) talk! Went really well, got many interesting questions!

                                They promised us video recordings in a few days, so I'll post a link when I get it. Though of course the talk is in Russian.

                                ? 1 Reply Last reply
                                0
                                • ? Guest

                                  This morning was my niri (-adjacent) talk! Went really well, got many interesting questions!

                                  They promised us video recordings in a few days, so I'll post a link when I get it. Though of course the talk is in Russian.

                                  ? Offline
                                  ? Offline
                                  Guest
                                  wrote on last edited by
                                  #99

                                  hmm

                                  #niri

                                  ? 1 Reply Last reply
                                  0
                                  • ? Guest

                                    hmm

                                    #niri

                                    ? Offline
                                    ? Offline
                                    Guest
                                    wrote on last edited by
                                    #100

                                    unusual sights

                                    #niri

                                    ? 1 Reply Last reply
                                    0
                                    • ? Guest

                                      unusual sights

                                      #niri

                                      ? Offline
                                      ? Offline
                                      Guest
                                      wrote on last edited by
                                      #101

                                      Turns out, there's a lot of details to get right when implementing a floating window space. For example, dialog windows should always show above their parent window. Otherwise, it's easy to lose them under the (usually much bigger) parent.

                                      The WIP floating branch in niri now handles this properly, even for xdg-desktop-portal dialogs (like file chooser) as long as the app correctly parents them via xdg-foreign.

                                      #niri

                                      ? 1 Reply Last reply
                                      0
                                      • ? Guest

                                        Turns out, there's a lot of details to get right when implementing a floating window space. For example, dialog windows should always show above their parent window. Otherwise, it's easy to lose them under the (usually much bigger) parent.

                                        The WIP floating branch in niri now handles this properly, even for xdg-desktop-portal dialogs (like file chooser) as long as the app correctly parents them via xdg-foreign.

                                        #niri

                                        ? Offline
                                        ? Offline
                                        Guest
                                        wrote on last edited by
                                        #102

                                        Another piece of the floating puzzle: keeping windows on screen. When you change your monitor scale or resolution, you don't want your floating windows to suddenly go unreachable behind the monitor's new borders.

                                        Here I'm resizing a nested niri with three windows, simulating resolution changes. No matter what I do, they always remain partially visible and reachable. Even for more unusual cases like trying to resize a window into out of bounds.

                                        #niri

                                        ? 1 Reply Last reply
                                        0
                                        • ? Guest

                                          Another piece of the floating puzzle: keeping windows on screen. When you change your monitor scale or resolution, you don't want your floating windows to suddenly go unreachable behind the monitor's new borders.

                                          Here I'm resizing a nested niri with three windows, simulating resolution changes. No matter what I do, they always remain partially visible and reachable. Even for more unusual cases like trying to resize a window into out of bounds.

                                          #niri

                                          ? Offline
                                          ? Offline
                                          Guest
                                          wrote on last edited by
                                          #103

                                          In the tiling layout, niri is constantly asking windows to assume their expected size. In contrast, floating windows should be able to freely change size as they see fit.

                                          The logic turns out to be quite tricky. On the one hand we want a window to keep its latest size, but on the other we still want to be able to resize the window, which means asking it for a different size. The window can take a second to respond, or respond with a yet another size, and nothing must break.

                                          #niri

                                          ? 1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Login or register to search.
                                          Powered by NodeBB Contributors
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups