System76 COSMIC updates

System76 COSMIC updates

It's been four entire months since my last COSMIC video, and a lot has happened. Let me repeat: this is an incredibly cool project, that's building everything from the ground up - something I hardly thought possible - in a new programming language, rust, and a new graphical toolkit, iced.

Firstly, Pop!_OS is really known for its tiling functionalities. In the past, these were built on top of the GNOME window manager, and could be seen as a - really well done - plugin. In fact, even though they did not follow up on it yet, System76 even said thay wanted to bring Pop!_OS tiling to other desktops.

Either way, tiling has to be built from scratch yet again due to COSMIC, and the team has taken this as a great occasion to change how it works. Firstly, there used to be an "adjustment mode", toggled by Super + Enter, to arrange or resize tiled windows. The COSMIC team did not like this extra step required to adjust the layout, and they decided to get rid of it entirely.

They instead introduced a - rather intuitive - set of shortucts: Super + Arrows will move the focus around, and Shit + Super + Arrows will move the focused window around. When you start using these shortcuts, the windows will become slightly smaller and the background will fade out to show that you are currently adjust windows; this is subtle, but really easy to miss, so well done System76.

In this mode, all windows will get an outline: gray for normal windows, and light blue for the selected one. Now, here's a very cool thing: you will be able to group windows together; when you do, the entire group will act as a single window, meaning that you can select it and move the whole thing together, without changing its layout. You can also resize the group, and all of the windows within it will resize. Of course, you will still be able to adjust the tiling within a group, and take applications inside or outside the group as well.

Creating a group does not have any shortcut; the idea is that, if you want a certain layout, you can achieve it just by moving your window around. So, if you want to create a group, you just move one window towards another, and they'll join together. If you didn't want that, you just keep moving the window in the same direction, and the window will exit the group. Everything is extremely intuitive.

The other way to combine windows together is stacking. Which, by the way, was called window tabbing in in KDE, until it got removed and we just ... lost the feature. So, yeah, pretty cool that Pop!_OS is just making fun of KDE Plasma from this point of view. The idea is to join different windows together, and tabs will appear on the titlebar. You can see here the design for COSMIC: the current tab is indicated by an accent color to stand out, and if there are too many tabs then you'll be able to just click an arrow in the header area.

Another thing that was worked on in regards to tiling is mouse-driven tiling, so that you can drag and drop windows around to change the layout. If you do that, an indicator appears to show which windows are grouped together, whilst a transparent background indicates how that window will be arranged in its new position. If you drag and drop on the top of another window, as an example, the window will tile vertically; but, this is cool, if you drag and drop a window at the center of another, they will get grouped together. Finally, if you drag and drop a window in the space between two other windows, it will be tiled there. Pretty cool stuff.

In fact, being able to use the same code between keyboard and mouse tiling simplyfies the interface so much that Victoria, the engineer that worked on the implementation, said: "tiling is one of the most complex parts of our shell, so that [as in: making the tiling code more readable] was a personal highlight for me".

Next topic: we finally have a good idea on the customization options that COSMIC will have. This was an explicit goas early on in the design, and there are some quite unique idea that you won't find in other desktops. Now, of course you get all the usual stuff: there's a light and dark theme, and you also get to pick between a selected range of accent colors, or you can pick your own. In KDE Plasma, you have the concept of "Color Schemes", which can set all of the colors of the system; sometimes, you can do some pretty big damage by choosing the incorrect colors; also, you have to find a colorscheme that you like, as doing one from scratch is too much work for most users. COSMIC instead tried to find a solution that's also really flexible, but that doesn't allow for unusable setups and that any user can customize.

The solution: you are displayed with four colors: the background color, primary container background color, interface text palette tint, and neutral palette tint. The first two colors are pretty obvious, but the entire colorscheme is generated using these four indications (and the accent color) as a starting point. It won't be as powerful as manually picking each color in each context, but you can get pretty far just with these tools. I think this is a pretty cool concept.

Another couple of options that you don't usually see are: firstly, corner radius. There are three possible styles and you can go from super-roundness to, uh, less rounded. Then, you have a density setting; I don't think I've seen this elsewhere. Density will change the margins between components to make the whole interface more or less compact. This is something that was actually brought up in KDE development chats, but doing the step of actually implementing it... isn't easy, quite the opposite.

Another area of improvement is handling notifications. In most desktop, that's easy enough: you get a notification, you show the notification to the user. But it's not always that easy. In KDE Plasma, as an example, notifications are displayed by the notification applet; and you might have more than one applet, in different monitors, the applets might be in different parts of the screen, and so on; now that COSMIC is also intruding the concept of "modular applet that you can place in panels", they kind-of have the same issue; what they're doing, then, is a notification daemon that reads the notifications and throw those to the notification applets. If I understood this correctly, you can choose whether the notification is displayed - by the applet - on all the screens, or just one.

Oh, by the way, yes; this means that notifications are getting their own applet and won't be in the calendar applet as they used to be. Interestingly enough, even GNOME is currently thinking of moving notifications in the system tray. It seems like in just a few years time nobody will be putting notifications in calendars anymore, that's a dying concept. On top of that, in COSMIC multiple notifications of the same application will be stacked together to reduce clutter.

Next up, COSMIC introduced the ability to resize a window with your keyboard. Again, we're really really not talking about anything extraordinary or unseen here, but that's because this video is all about people building a desktop from scratch, so I'll take it. The shortcuts are Super+R+Arrows and Shift+Super+R=Arrows; when you press them, a hint will appear helping you remember the shortcuts, and you'lle get arrows at the borders indicating the movement. Of course, all other tiled windows will also adjust accordingly.

Wallpapers. The wallpaper system settings section has been written. You can - you guessed it - select a wallpaper, but also solid color or a simple gradient. KDE Plasma has that, by the way. You'lle be able to choose whether to show the same background on all monitors or not, whether to stretch or scale the wallpaper, and you can even have a slideshow. I would say, we've got all the important stuff for sure.

Next up is fractional scaling, and this is a new feature compared to what Pop!_OS has now; hower, I'm slighly confused by it. So: GNOME, which Pop!_OS currently relies on, does not support fractional scaling. They do give you the option to use fractional scaling, but that will actually render your window always twice the size, and then scale down to what you asked for; it's actually fractional scaling, it's ... fake. If you're interested, I have an entire video all about fractional scaling. So, COSMIC now has an option in Display settings called Fractional Scaling, and you can set it ... though, it has only three options between 100 and 200: 125%, 150%, 175% (KDE Plasma has many more steps). The text says: "this month, fractional scaling functionality was implemneted into COMISMIC desktop as well". I think this means that you do get actual fractional scaling, and not the fake one; however, I would have to ask the developers that. I'll keep you updated.

Another core functionality that COSMIC just got is user permissions through a Polkit agent; this means that whenever, as an example, an application requires a password or requires any other special permission, a dialog will pop up explaining who wants what permission and why. Again, nothing groudbreaking, but all these components are being developed by scratch.