<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<?xml-stylesheet type="text/xsl" href="/rss.xsl"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Andrey Listopadov</title>
    <link>https://andreyor.st/tags/ui/</link>
    <image>
      <title>Andrey Listopadov</title>
      <link>https://andreyor.st/tags/ui/</link>
      <url>https://andreyor.st/tags/ui/favicon-64.png</url>
    </image>
    <description>Posts tagged 'ui' by Andrey Listopadov</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en-us</language>
    <copyright>Andrey Listopadov 2020-2026 - This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License</copyright>
    <lastBuildDate>Tue, 11 Jul 2023 01:01:00 +0300</lastBuildDate>
    <atom:link href="https://andreyor.st/tags/ui/feed.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Emacs GUI library</title>
      <link>https://andreyor.st/posts/2023-07-11-emacs-gui-library/</link>
      <guid>https://andreyor.st/posts/2023-07-11-emacs-gui-library/</guid>
      <description>&lt;p&gt;Lately, my Magit buffer broke once again because of something weird going on with major mode, and I couldn&amp;rsquo;t stash or commit hunks unless the point was at the beginning of the line.
That once again reminded me that Emacs UI is not really a UI, all of it is mere text with a bunch of properties slapped on top.
It&amp;rsquo;s easy to forget about it, and use such things like Treemacs, Customize, heck, even Org Mode, thinking that you&amp;rsquo;re interacting with UI elements (file nodes in Treemacs, text-boxes in Customize, Org Modes sub-trees and drawers).
However, it is an illusion, though neatly crafted.
It&amp;rsquo;s still text.&lt;/p&gt;
&lt;p&gt;Well, what&amp;rsquo;s bad about it you might ask?
We love to manipulate text, Emacs even makes it actually comfortable to do, with a lot of functions dedicated to it.
And buffers are also a very fast way to manipulate even moderate amounts of text.
But ask yourself, do you really want to do the same kind of thing in a different UI system, outside of Emacs?
Maybe if it came with the same amount of useful functions?
Well, maybe you&amp;rsquo;d want to, but I sure don&amp;rsquo;t.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve made my own custom UI elements in Kakoune, making a file tree, and tag list plugins.
That was before I actually started using Emacs as my main environment, and Kakoune text properties are much less sophisticated than ones of Emacs, but&amp;hellip;
It&amp;rsquo;s the same thing, really.&lt;/p&gt;
&lt;p&gt;You programmatically spit some text into the buffer, then you parse it, find elements, walk on them, change them, and so on.
Yes, text properties, markers, overlays, all of it makes it more robust in Emacs, but even though, things still break.
Because Emacs still tries to interpret stiff in your buffer as text.&lt;/p&gt;
&lt;p&gt;Because that&amp;rsquo;s what it does, it expects text!
If you call &lt;code&gt;forward-sexp&lt;/code&gt; on some Magit UI element it will try to do the right thing, even if there&amp;rsquo;s no right thing - there are no sexps in the Magit buffer.
Well, maybe there are if you&amp;rsquo;re viewing diffs of your lisp code, and then yeah, the benefit of everything being text you can move on becomes obvious.
Except when we&amp;rsquo;re talking about UI it&amp;rsquo;s not working more of the times than it is useful in an occasional context of that UI element.&lt;/p&gt;
&lt;p&gt;I think you probably get where I&amp;rsquo;m going with this.
And you probably don&amp;rsquo;t like it, but bear with me.
And it&amp;rsquo;s an angry bear, so don&amp;rsquo;t threaten me more than he does, please.&lt;/p&gt;
&lt;p&gt;What I&amp;rsquo;m trying to say is that Emacs, as a GUI application isn&amp;rsquo;t something that I&amp;rsquo;d be advertising to other people.
You can make Emacs look beautiful, no doubt about that, &lt;a href=&#34;https://github.com/rougier/nano-emacs&#34; target=&#34;_blank&#34;&gt;Nano&lt;/a&gt; Emacs, &lt;a href=&#34;https://github.com/doomemacs/doomemacs&#34; target=&#34;_blank&#34;&gt;DOOM&lt;/a&gt;, and others try very hard to make Emacs visually appealing.
But it&amp;rsquo;s all too janky IMO.
Nano Emacs looks great on the pictures, but resize a window and the illusion of a coherent interface breaks fast.
So let&amp;rsquo;s look at different systems for inspiration:&lt;/p&gt;
&lt;h2 id=&#34;smalltalk&#34;&gt;Smalltalk&lt;/h2&gt;
&lt;p&gt;I&amp;rsquo;ve already mentioned Smalltalk in the past regarding comparison with Emacs in the GUI field.
And I think it is a fair thing to do - both are dynamic systems that you can program with their respective language.
Except, one is GUI oriented pretty much from the start, and the other one is Emacs.&lt;/p&gt;
&lt;p&gt;Look at how Smalltalk looks when you fire up Pharo:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/pharo.gif&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;It&amp;rsquo;s a GUI &lt;em&gt;system&lt;/em&gt;.
Complete with windows, containing text editors, browsers, context-aware menus, and so on.
Maybe it doesn&amp;rsquo;t look as pretty as your preferred GUI toolkit, but it&amp;rsquo;s not the main point.&lt;/p&gt;
&lt;p&gt;Although, here&amp;rsquo;s how Smalltalk looks when you fire up GToolkit, which is written in Pharo:&lt;/p&gt;
&lt;div class=&#34;horizontal-gallery&#34;&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/gtoolkit-1.png&#34;
         alt=&#34;Figure 1: Visualizing the current knowledge base through a Pharo snippet. Clicking on nodes opens the page to the right.&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 1: &lt;/span&gt;Visualizing the current knowledge base through a Pharo snippet. Clicking on nodes opens the page to the right.&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/gtoolkit-2.png&#34;
         alt=&#34;Figure 2: A page with a JavaScript snippet that is combined with a Pharo snippet to produce a visualization of dependencies defined in a Yarn file.&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 2: &lt;/span&gt;A page with a JavaScript snippet that is combined with a Pharo snippet to produce a visualization of dependencies defined in a Yarn file.&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/gtoolkit-3.png&#34;
         alt=&#34;Figure 3: Explaining a domain object through examples and custom views.&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 3: &lt;/span&gt;Explaining a domain object through examples and custom views.&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;/div&gt;
&lt;p&gt;There are much more pictures on the &lt;a href=&#34;https://gtoolkit.com/&#34; target=&#34;_blank&#34;&gt;official web page&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The point of it is that you can build your own tools for your tasks in this toolkit, as shown in the pictures.
They call it building an inspector, and GToolkit comes with a lot of inspectors for various kinds of data.&lt;/p&gt;
&lt;p&gt;This is my favorite system so far, and it gets worse from here but I feel that we need to talk about other examples still.&lt;/p&gt;
&lt;h2 id=&#34;clojure&#34;&gt;&lt;del&gt;Java&lt;/del&gt; Clojure&lt;/h2&gt;
&lt;p&gt;Why not?
Clojure is another dynamic system, that you can change at runtime.
While Java isn&amp;rsquo;t what comes to mind when speaking about beautiful and functional GUI, making GUI apps in Clojure is far more fun than it is in Java.
Because again, you can update your UI elements on the fly.&lt;/p&gt;
&lt;p&gt;There are some examples of apps where the UI is done in Clojure, one example is the game engine called &lt;a href=&#34;https://defold.com/product/&#34; target=&#34;_blank&#34;&gt;Defold&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;It looks like this:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/defold.png&#34;
         alt=&#34;Figure 4: I couldn&amp;amp;rsquo;t find a non-skewed image on the official page.&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 4: &lt;/span&gt;I couldn&amp;rsquo;t find a non-skewed image on the official page.&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;As far as I understand, its Editor is made in Clojure, and UI is handled via the JavaFX toolkit.&lt;/p&gt;
&lt;p&gt;Intellij Idea is many another example of a decent-looking GUI in Java, although your opinion may vary.&lt;/p&gt;
&lt;p&gt;Still, JVM isn&amp;rsquo;t the greatest at UI, and somehow another language with a J in the name managed to do somewhat better.&lt;/p&gt;
&lt;h2 id=&#34;web&#34;&gt;Web&lt;/h2&gt;
&lt;p&gt;Lastly, the web is another way of building user interfaces, one that is quite popular today.
Because the web works the same across a majority of operating systems, as browsers are ported to them with a lot of care.
Browsers are also extremely capable of rendering all kinds of file formats, doing interactive stuff, and JavaScript frameworks are aimed at providing facilities for building UI that is highly responsive and interactive.&lt;/p&gt;
&lt;p&gt;The web is however associated with slow, often unresponsive UI, a lot of wasted screen space, and unnecessary high CPU and memory usage.
Mostly due to Electron packing lots of stuff.
I think Electron wasn&amp;rsquo;t a bad idea, the execution was just poor.
There are other projects that provide similar facilities like &lt;a href=&#34;https://ultralig.ht/&#34; target=&#34;_blank&#34;&gt;Ultralight&lt;/a&gt;, but I didn&amp;rsquo;t investigate further.
I&amp;rsquo;m OK with the idea of building UI on web technologies, as long as we&amp;rsquo;re making a robust system that works across multiple devices and actually benefits from using the browser.&lt;/p&gt;
&lt;p&gt;There&amp;rsquo;s also this project, which I find cool because it looks similar to GToolkit: &lt;a href=&#34;https://natto.dev/example/0a7aeb805e76412989946c5f270f84e5&#34; target=&#34;_blank&#34;&gt;natto.dev&lt;/a&gt;.
Basically, you get an infinite canvas, on which you can place text editing widgets, video widgets, and other stuff.
Keep this thing in mind, I find the idea of such UI interesting, and probably it will be explored more in the future.&lt;/p&gt;
&lt;p&gt;But, let&amp;rsquo;s get back to Emacs, and I&amp;rsquo;ll try to explain why I was bragging about all these other systems.&lt;/p&gt;
&lt;h2 id=&#34;emacs&#34;&gt;Emacs&lt;/h2&gt;
&lt;p&gt;Emacs has a windowing system.
Basically like a tiling window manager - you have a frame, you can divide it into windows, you can spawn other frames, you can divide them, and so on.
But, these windows can only display basic text, among some graphical elements, like SVG graphics, or bitmaps.
Needless to say, when compared to any of the systems I&amp;rsquo;ve talked about before the GUI capabilities of Emacs are quite limited.&lt;/p&gt;
&lt;p&gt;Basically, Emacs is a glorified terminal, with ability to draw different font sizes and decent image support.
Don&amp;rsquo;t make such a face, you know it&amp;rsquo;s not far from the truth.
Again, this may be a bit harsh, but I believe we need to admit things in order to move forward.&lt;/p&gt;
&lt;p&gt;Speaking of terminals, Emacs can actually run in a terminal!
You can start it with &lt;code&gt;emacs -nw&lt;/code&gt; and it will happily transform your terminal into Emacs.
I mean, you no longer have a terminal, it just acts as a rendering engine for Emacs.
So you basically get the same thing as GUI Emacs but worse, because now your terminal is responsible for rendering fonts, and you no longer have any image support.
Well, there are terminals that support images, but come on.&lt;/p&gt;
&lt;p&gt;And I think terminal support is one of the things that holds Emacs back.
Think about it - why do you even need a terminal if you&amp;rsquo;re already using Emacs?&lt;/p&gt;
&lt;p&gt;The common misconception is that you need a terminal version of Emacs to run it on headless environments, like servers, clouds, etc.
You don&amp;rsquo;t.
I work with remote servers constantly each day and I never open Emacs on the remote when I&amp;rsquo;m editing files there, I don&amp;rsquo;t even open a terminal for the SSH.
Here are some basic workflows involving remote servers or just terminal tasks:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Need to ssh somewhere to edit files or run some commands?
&lt;ul&gt;
&lt;li&gt;TRAMP got you covered.
&lt;ul&gt;
&lt;li&gt;You can even run &lt;code&gt;async-shell-command&lt;/code&gt; in a TRAMP buffer and it will be run on the remote.&lt;/li&gt;
&lt;li&gt;You even get to retain the entirety of your config without copying it onto the servers.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Need to run some commands in general?
&lt;ul&gt;
&lt;li&gt;Again, You can call &lt;code&gt;async-shell-command&lt;/code&gt;, it even will handle your input and password prompts in case there&amp;rsquo;s one;&lt;/li&gt;
&lt;li&gt;Or you can run &lt;code&gt;compile&lt;/code&gt;, which doesn&amp;rsquo;t handle prompts but still is much more interactive than the raw terminal output.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Want to run some complex commands with editing convenience, or maybe even some TUIs?
&lt;ul&gt;
&lt;li&gt;You can run &lt;code&gt;eshell&lt;/code&gt;, and go nuts on scripting in Emacs Lisp and calling sh scripts from the Emacs shell;&lt;/li&gt;
&lt;li&gt;Or you can run a proper terminal emulator from within Emacs:
&lt;ul&gt;
&lt;li&gt;&lt;a href=&#34;https://github.com/akermu/emacs-libvterm&#34; target=&#34;_blank&#34;&gt;Vterm&lt;/a&gt; - a terminal based on libvterm C library;&lt;/li&gt;
&lt;li&gt;&lt;a href=&#34;https://codeberg.org/akib/emacs-eat&#34; target=&#34;_blank&#34;&gt;EAT&lt;/a&gt; - a terminal emulator that can run in a region, in a buffer, and in Eshell, written in Emacs Lisp;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;ansi-term&lt;/code&gt;, &lt;code&gt;term&lt;/code&gt; - inbuilt terminal emulators in Emacs.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;I don&amp;rsquo;t know how many times I got into a situation, where there&amp;rsquo;s a PDF documentation in one buffer, TRAMP in another, and I&amp;rsquo;m editing a remote file while referring to that documentation and staying within the comfort of Emacs.
So no, with Emacs terminal itself isn&amp;rsquo;t needed in maybe 90% of situations, and terminal Emacs is just out of the question.&lt;/p&gt;
&lt;p&gt;But hey, I too previously was a terminal enjoyer before Emacs, and it was too hard to even imagine how to even approach work without a terminal.
As I&amp;rsquo;ve mentioned, I was using Kakoune, and prior to that, I was a Vim user.
Now, with Emacs, I rarely open the terminal at all.
There&amp;rsquo;s simply no need to, as there are more comfortable ways of interacting with the shell.
And damn, even things like VSCode, which isn&amp;rsquo;t a terminal app at all, still manage to run as a server in a headless/remote/container context and provide you with all of its GUI features by acting as a client.
So yeah, ditch the terminal version of Emacs, you&amp;rsquo;re ain&amp;rsquo;t gonna miss it.&lt;/p&gt;
&lt;p&gt;Except, don&amp;rsquo;t.
Use what you like, the solution I&amp;rsquo;m going to propose doesn&amp;rsquo;t require anything to be ditched at all.
But before that, let&amp;rsquo;s talk XWidgets&lt;/p&gt;
&lt;h3 id=&#34;xwidgets&#34;&gt;XWidgets&lt;/h3&gt;
&lt;p&gt;When I was talking about the web, I&amp;rsquo;m sure some of you thought about XWidgets and Webkit support in Emacs.
Like, here, I&amp;rsquo;m running the already mentioned natto.dev inside my Emacs right now:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/emacs-1.png&#34; width=&#34;580px&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;So what gives?
And at work, I occasionally use Portal to navigate through nested data structures while debugging Clojure code:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/emacs-2.png&#34;
         alt=&#34;Figure 5: (the code isn&amp;amp;rsquo;t from work, just a hobby project)&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 5: &lt;/span&gt;(the code isn&amp;rsquo;t from work, just a hobby project)&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;Again, what gives?
This looks like we can have interactive GUIs in Emacs, much like in GToolkit and Pharo.
However, there&amp;rsquo;s a catch.
There&amp;rsquo;s always a catch, and in the case of Emacs, it&amp;rsquo;s that the XWidget UIs are &lt;em&gt;foreign&lt;/em&gt; to Emacs.&lt;/p&gt;
&lt;p&gt;Here, foreign means that inside that &lt;code&gt;*xwidget-webkit: portal...*&lt;/code&gt; buffer nothing you expect to work will actually work.
Remember how I mentioned that in Magit if you call &lt;code&gt;forward-sexp&lt;/code&gt; it will try to do the right thing?
Well, here it can&amp;rsquo;t do anything, because this isn&amp;rsquo;t a buffer really.
It is an embedded widget that only looks like a buffer in the Emacs window, but it&amp;rsquo;s not.&lt;/p&gt;
&lt;p&gt;There&amp;rsquo;s &lt;em&gt;no point&lt;/em&gt; in calling &lt;code&gt;forward-sexp&lt;/code&gt; because there&amp;rsquo;s literally no point in such a buffer.
You can&amp;rsquo;t use &lt;a href=&#34;https://github.com/abo-abo/avy&#34; target=&#34;_blank&#34;&gt;Avy&lt;/a&gt; to jump to an element in such a buffer because there are no textual elements that Avy can look at.&lt;/p&gt;
&lt;p&gt;Because of it, it is basically the same as if you&amp;rsquo;ve opened a separate web browser side by side with Emacs and used it to browse the web, or run Portal, and it would probably even work better.
Unfortunately, we can&amp;rsquo;t embed something like Webkit into Emacs and hope that it will solve our UI problems.
Or can we?&lt;/p&gt;
&lt;h2 id=&#34;emacs-gui-toolkit&#34;&gt;Emacs GUI Toolkit&lt;/h2&gt;
&lt;p&gt;So here&amp;rsquo;s my idea.
I&amp;rsquo;m pretty sure it&amp;rsquo;s not new, but that&amp;rsquo;s not the point of this blog - it is merely a container for my thoughts, original or not.&lt;/p&gt;
&lt;p&gt;What if, instead of embedding Webkit into Emacs, we turn this around?
Hear me out.&lt;/p&gt;
&lt;p&gt;When I was talking about opening a browser side by side with Emacs two seconds ago, I should have mentioned that window managers, or WMs for short, are quite good at placing windows.
If you&amp;rsquo;re using some kind of a tiling manager, you know what I mean - you can leave window management to your window manager.
Kakoune, for instance, does exactly that - instead of creating its own windowing system, like Vim or Emacs, it leaves it out for things like TMUX or i3 to solve.
This, of course, has some problems too, but works well enough in general.&lt;/p&gt;
&lt;p&gt;But I&amp;rsquo;m not saying that we should ditch windowing from Emacs and leave it to the WM, far from it.
I would rather ditch frames from Emacs if you ask me, but that&amp;rsquo;s another topic.&lt;/p&gt;
&lt;p&gt;Look at this as if Emacs was embedded into your window manager, which is basically how it works.
You start your WM of choice&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt;, you launch Emacs, and as long as the Emacs window is focused, you live in Emacs.
All of your shortcuts work, and all of your navigation habits are there.&lt;/p&gt;
&lt;p&gt;So what if we expand on this idea?
Instead of embedding Webkit, let&amp;rsquo;s embed Emacs in its current state as a UI widget.&lt;/p&gt;
&lt;h3 id=&#34;the-widget-library&#34;&gt;The Widget Library&lt;/h3&gt;
&lt;p&gt;What I&amp;rsquo;m thinking is, let&amp;rsquo;s take, say SDL2 (or maybe something like &lt;a href=&#34;https://github.com/ocornut/imgui&#34; target=&#34;_blank&#34;&gt;ImGui&lt;/a&gt;), and create a library of widgets for Emacs.
We&amp;rsquo;ll then integrate Emacs into it as the runtime system behind it, much like in the case of Smalltalk, JavaFX+Clojure, and Web+JS, and provide a set of functions to navigate through widgets in a meaningful way.
The widgets would include basic stuff, like buttons, text boxes, buffers, drawers, menus&amp;hellip; wait, buffers?&lt;/p&gt;
&lt;p&gt;Yes, why ditch something that works well?
Like when you focus Emacs in your WM and it just works, when the buffer widget is in focus it will just work too!
We can keep the redisplay code, it will just need to learn how to render into such widgets, which I&amp;rsquo;m sure is possible, as there&amp;rsquo;s a very similar feature in Emacs already, called child-frames.&lt;/p&gt;
&lt;p&gt;With enough widgets, one will be able to build GUI, much like in GToolkit, but with Emacs Lisp, and we&amp;rsquo;ll still have all the legacy textual interface working, e.g. things like Magit don&amp;rsquo;t have to throw everything out of the window and adapt - they can continue to work.
We just need to be sure to provide enough extensibility, and a way to implement custom widgets, much like Emacs allows right now with its text properties, overlays, and such.
Then new plugins for the GUI toolkit will arrive, making Emacs even more extensible than before.&lt;/p&gt;
&lt;p&gt;Now, imagine, you open Emacs and it creates a window that is basically like a desktop of your operating system.
You open a window, and it&amp;rsquo;s a real window, floating on that desktop.
Don&amp;rsquo;t like it?
Just maximize it, the window widget will work similarly to how windows are created in Emacs right now.
Except it doesn&amp;rsquo;t have to be a window displaying a buffer and nothing else - it can display other widgets, some of which are buffers.&lt;/p&gt;
&lt;p&gt;Frames become virtual desktops, which they really are, it&amp;rsquo;s just that they&amp;rsquo;re represented as WM windows because Emacs didn&amp;rsquo;t include ways of switching them virtually (it did in the terminal mode actually).
You can still open a separate &amp;ldquo;frame&amp;rdquo; with a given virtual desktop, so again, everything would work as you&amp;rsquo;d expect.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve made a quick prototype that implements this.
Here&amp;rsquo;s a live demo:&lt;/p&gt;
&lt;p&gt;&lt;video controls autoplay loop muted width=&#34;640px&#34;&gt;&lt;source src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/infinite.mp4&#34; type=&#34;video/mp4&#34;&gt;
Your browser does not support the video tag.&lt;/video&gt;&lt;/p&gt;
&lt;p&gt;And here&amp;rsquo;s Emacs running natto.dev and GToolkit pages in these child frames:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2023-07-11-emacs-gui-library/infinite.png&#34;
         alt=&#34;Figure 6: And there are some more windows below the screen that I can pan to&#34; width=&#34;640px&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 6: &lt;/span&gt;And there are some more windows below the screen that I can pan to&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;With this mode, I can create child frames, that act as small windows, and pan these around much like the natto.dev app I keep referring to.
Note that when the window tries to split itself, instead it creates a new window near it, and tries to keep windows from overlapping by finding empty space nearby.
Basically, this is almost like a different kind of window manager.&lt;/p&gt;
&lt;p&gt;Though this thing doesn&amp;rsquo;t work as well as you&amp;rsquo;d imagine, if you want to try it, you can get it &lt;a href=&#34;https://gitlab.com/andreyorst/infinite.el&#34; target=&#34;_blank&#34;&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;h2 id=&#34;the-future-of-emacs&#34;&gt;The future of Emacs&lt;/h2&gt;
&lt;p&gt;&amp;hellip;probably isn&amp;rsquo;t what I&amp;rsquo;m describing here.
I don&amp;rsquo;t know.
I&amp;rsquo;m just fantasizing, but the image of such a system I see behind my eyelids is great.&lt;/p&gt;
&lt;p&gt;I &lt;em&gt;depend&lt;/em&gt; on Emacs, it is my main tool for the job, this blog, my other hobbies, and other activities, so I want this system to evolve.
This is just a route I think it could take.
Again, maybe nothing of this makes any sense to you, but I encourage you to try out at least the GToolkit, I think it is the most interesting things I saw in the last years.
Pharo can be a bit less exciting but it laid the foundation for GT, and I think that&amp;rsquo;s says something.
If it wasn&amp;rsquo;t for Clojure, and maybe this blog which I do in Org-mode, and if I never used Emacs I would probably try GToolkit at some point, and maybe it would become my main tool, and I would probably look at Emacs as an inferior system.
Well, at least when it comes to GUI capabilities.
But I still love Emacs as it is, it fulfills my needs, and I can make it do what I want it to do, which is the main point.&lt;/p&gt;
&lt;p&gt;This post was mostly a collection of random thoughts, hence the category, but I genuinely think that if a system like this can be created in Smalltalk or in the current state of the web, it is definitively possible in Emacs, there&amp;rsquo;s just not that much of an interest in it.
Well, actually there is, as I&amp;rsquo;ve mentioned, people trying to make emacs more beautiful and appealing, but I think we should not forget about utility too, and thus if someone is to develop a GUI toolkit for Emacs they need to put a lot of thought into it:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;What widgets to include;&lt;/li&gt;
&lt;li&gt;How do you move from widget to widget in an efficient way;&lt;/li&gt;
&lt;li&gt;What is best done with a mouse, and what should not be done with it;&lt;/li&gt;
&lt;li&gt;What level of interactivity from Emacs Lisp we should get;&lt;/li&gt;
&lt;li&gt;Other questions like this.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;So yeah, it will take a lot of planning, prototyping, maybe some competing systems to progress on this - let&amp;rsquo;s see where Emacs will go in the upcoming 30 years.
Maybe another XEmacs will happen, or it will be forced to evolve by something like &lt;a href=&#34;https://project-mage.org/elevator&#34; target=&#34;_blank&#34;&gt;Project Mage&lt;/a&gt; or &lt;a href=&#34;https://nyxt.atlas.engineer/&#34; target=&#34;_blank&#34;&gt;Nyxt&lt;/a&gt;, or even another system, that would embrace GToolkit&amp;rsquo;s modal-less interface and infinite canvas.
The advent of virtual and/or augmented reality makes an interesting infinite-canvas type of interface candidate in my opinion, so maybe we&amp;rsquo;ll stop seeing flat screens in the future, who knows?&lt;/p&gt;
&lt;p&gt;Anyway, let me know what you think.
If you have any thoughts you like to share, you can find my contacts on the &lt;a href=&#34;https://andreyor.st/about&#34;&gt;About&lt;/a&gt; page.
Hope it was an interesting read!&lt;/p&gt;
&lt;div class=&#34;footnotes&#34; role=&#34;doc-endnotes&#34;&gt;
&lt;hr&gt;
&lt;ol&gt;
&lt;li id=&#34;fn:1&#34;&gt;
&lt;p&gt;I know that Emacs can be your WM of choice, no need to tell me that.&amp;#160;&lt;a href=&#34;#fnref:1&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
&lt;div class=&#34;comment-link&#34;&gt; &lt;a href=&#34;mailto:%61%6e%64%72%65%79%6f%72%73%74%2b%62%6c%6f%67%40%67%6d%61%69%6c%2e%63%6f%6d?subject=Comment: Emacs GUI library&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Comment via email&lt;/a&gt;&lt;/div&gt;</description>
      <pubDate>Tue, 11 Jul 2023 01:01:00 +0300</pubDate>
    </item><item>
      <title>GNOME doesn&#39;t need to be that huge</title>
      <link>https://andreyor.st/posts/2022-10-07-gnome-doesnt-need-to-be-that-huge/</link>
      <guid>https://andreyor.st/posts/2022-10-07-gnome-doesnt-need-to-be-that-huge/</guid>
      <description>&lt;p&gt;I&amp;rsquo;ve been a GNOME Shell user for many years now - I&amp;rsquo;ve started using it pretty much since its initial release in 2011.
I&amp;rsquo;m using GNU/Linux as my main operating system since 2008, and I started with Ubuntu, as many did back then, and what I liked about Ubuntu was its desktop environment, or DE for short.
Back then Ubuntu was using Gnome 2, a predecessor to GNOME Shell (or Gnome 3), and it was great - very well thought out, customizable, responsible, and lightweight.
However, with the release of Ubuntu 10.10, Canonical moved to their own DE, called &lt;a href=&#34;https://en.wikipedia.org/wiki/Unity_%28user_interface%29&#34; target=&#34;_blank&#34;&gt;Unity&lt;/a&gt;, and I found myself in a weird situation.&lt;/p&gt;
&lt;p&gt;The Gnome project just announced GNOME Shell, but Ubuntu moved to its own solution.
And both options were, well, how do I put it… buggy?&lt;/p&gt;
&lt;p&gt;In my opinion, Unity wasn&amp;rsquo;t good up until the release of Ubuntu 12.04, and it became really good in 14.04.
Well, at least that&amp;rsquo;s how I remember it.
I didn&amp;rsquo;t like Unity so I continued to use Gnome 2 for several years.&lt;/p&gt;
&lt;p&gt;GNOME Shell, on the other hand…
Let&amp;rsquo;s just say that it became really good just recently with the release of GNOME 40.
Up until the release of GNOME 3.28 it wasn&amp;rsquo;t really that good, there were performance issues, occasional crashes, and other problems.
Combined with the tendency of breaking extensions with every release, and the overall direction Gnome developers took, it wasn&amp;rsquo;t the best option, again, in my opinion, especially when Unity was making good progress.
But, Canonical decided that Unity isn&amp;rsquo;t that great, Unity8 wasn&amp;rsquo;t making good progress, and with the release of Ubuntu 17.10, they&amp;rsquo;ve moved to GNOME Shell too.
However, they&amp;rsquo;ve used gnome 3.26 and it wasn&amp;rsquo;t particularly great at the time, as I&amp;rsquo;ve mentioned it.&lt;/p&gt;
&lt;p&gt;Now, you may wonder - why I&amp;rsquo;m only talking about Ubuntu?
There were, of course, other distributions that used Gnome at the time, it&amp;rsquo;s just I used Ubuntu back then so that&amp;rsquo;s what I remember personally.
I&amp;rsquo;m no longer an Ubuntu user though, I&amp;rsquo;ve moved to Fedora, simply because it has a vanilla Gnome, without any stupid things put on top of it by the developers of the distribution, like extra extensions or themes.
Yes, I prefer Gnome as is - default Adwaita theme, no extensions that change the UI, like docks.&lt;/p&gt;
&lt;p&gt;But there&amp;rsquo;s still one problem that I think is somewhat serious, and it is a common problem with a lot of interfaces today.
And I noticed this problem when Ubuntu changed to Gnome in the 17.10 release.
You see, Unity was made to be something &lt;em&gt;in between&lt;/em&gt; - something more modern than Gnome 2, yet not &lt;em&gt;as modern&lt;/em&gt; as Gnome 3.
When Gnome 3 was released in 2011 it was looking rather different from Gnome 2.
Unity, on the other hand, kept the good things of Gnome 2, yet expanded on some usability features, like good support for the global menu and HUD.
The in-app menu search in Unity was amazing, but I&amp;rsquo;m going away from the topic.&lt;/p&gt;
&lt;p&gt;What&amp;rsquo;s common between most modern interfaces as of today?
They&amp;rsquo;re all &lt;em&gt;big&lt;/em&gt;.
And so was Gnome, already in the year 2011 going way ahead of its time.&lt;/p&gt;
&lt;h2 id=&#34;mobile-oriented-ui&#34;&gt;Mobile-oriented UI&lt;/h2&gt;
&lt;p&gt;With the increased popularity of mobile devices, there also was the rise of mobile-oriented designs.
Web pages now have a dedicated mobile-friendly mode, where all elements are bigger, so it is more comfortable to navigate with a bare finger, which provides far lower precision than a mouse pointer.
Mobile apps use similar designs to web pages, even to the extent that some mobile apps are made with web technologies, and some web pages can be installed as an app.&lt;/p&gt;
&lt;p&gt;A tablet is another quite popular device type, quite similar to a smartphone but bigger and more aimed at surfing the web.
However, even though it usually has a bigger screen, it is still used with fingers as the main input device, so the UI elements are still big so users could reliably navigate them.&lt;/p&gt;
&lt;p&gt;Desktops, however, don&amp;rsquo;t suffer from this, as they have a touchpad/trackpoint/trackball/mouse to control the pointer with great precision, and rarely have a touch screen, though the latter became more popular lately.
But the popularity of mobile devices impacted the desktop UI guidelines as well.
The first victims were desktop versions of the mobile-first web pages - they were either just stretched-up mobile versions or desktop variants that were stylized after their mobile versions.
And it started to creep into the desktop UI itself.
And Gnome and macOS are affected by it the most.&lt;/p&gt;
&lt;p&gt;If you&amp;rsquo;re a Mac user, you know that visually macOS gets closer and closer to the iPad OS with each release.
Perhaps that&amp;rsquo;s because they want to unify the operating systems, and make the iPad a fully featured portable computer at some point, similar to Microsoft Surface.
Maybe, it&amp;rsquo;s just my guess - I&amp;rsquo;m not an Apple user and won&amp;rsquo;t likely be one.
But what this means is that UI elements are getting bigger and more spaced out, in order to be usable on both desktop and portable devices with touch screens.
There&amp;rsquo;s a &lt;a href=&#34;https://www.andrewdenty.com/blog/2020/07/01/a-visual-comparison-of-macos-catalina-and-big-sur.html&#34; target=&#34;_blank&#34;&gt;great post by Andrew Denty&lt;/a&gt;, which has a lot of images, comparing Catalina and Big Sur versions of macOS.
Here&amp;rsquo;s one of the images from that post:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/4-notification-preferences-macos-catalina-big-sur-comparison.png&#34;
         alt=&#34;Figure 1: macOS Catalina on the left, Big Sur on the right&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 1: &lt;/span&gt;macOS Catalina on the left, Big Sur on the right&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;If you look at the window &lt;em&gt;headerbar&lt;/em&gt;, you&amp;rsquo;ll notice that it is almost twice as big, as it was before.
Well, not twice, but about ~1.4x bigger - the old one is 76px tall, and the new one is 106px:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/notifications-stacked.png&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;Yet the close, minimize and maximize buttons size remains the same.
Other elements also have bigger padding, making the UI more &lt;em&gt;spacy&lt;/em&gt;.
I guess it is considered beautiful, but I also think that this is a waste of screen space.
Macs are unlikely to get touch screens any time soon, and even if they are, the increased height of the headerbar won&amp;rsquo;t make a difference for the user, who&amp;rsquo;s trying to touch the minimize button right next to the close button.
So I don&amp;rsquo;t think it was a change needed to make macOS closer to having the touch-ready interface, but a pure stylistic one.&lt;/p&gt;
&lt;p&gt;But, well, the post title was about Gnome, and here we are, talking about macOS - why?
Well, because Gnome takes a lot of inspiration from macOS, as far as I can see, at least.
See for yourself:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/finder-and-nautilus.png&#34;
         alt=&#34;Figure 2: macOS Finder and Gnome File Manager&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 2: &lt;/span&gt;macOS Finder and Gnome File Manager&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;Yeah, yeah, I know, a Mac user will say that it&amp;rsquo;s not even close, but the inspiration is pretty clear to me.
Nikitonsky even used Gnome&amp;rsquo;s settings app screenshot as a joke after a &lt;a href=&#34;https://twitter.com/nikitonsky/status/1557357661171204098&#34; target=&#34;_blank&#34;&gt;long thread&lt;/a&gt; on the redesign of the settings window in the macOS Ventura beta version:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/nikitonsky-tweet.png&#34;
         alt=&#34;Figure 3: @nikitonsky tweet&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 3: &lt;/span&gt;&lt;a href=&#34;https://twitter.com/nikitonsky/status/1559538442412900352&#34; target=&#34;_blank&#34;&gt;@nikitonsky tweet&lt;/a&gt;&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;Well, enough with the comparison to macOS, let&amp;rsquo;s get back to the main topic.&lt;/p&gt;
&lt;h2 id=&#34;mobile-oriented-desktop-ui-dot-dot&#34;&gt;Mobile-oriented &lt;em&gt;desktop&lt;/em&gt; UI?..&lt;/h2&gt;
&lt;p&gt;Yeah, you&amp;rsquo;ve read that right - Gnome wants to be on mobile phones and on the desktop at the same time.
Their UI is designed with this idea in mind.
A lot of apps change layout when you resize the window to be more like a screen of the phone:&lt;/p&gt;
&lt;p&gt;&lt;video autoplay loop muted style=&#34;border-radius: 16px&#34;&gt;&lt;source src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/gnome-responsive-ui.mp4&#34; type=&#34;video/mp4&#34;&gt;
Your browser does not support the video tag.&lt;/video&gt;&lt;/p&gt;
&lt;p&gt;This is a nice &lt;em&gt;touch&lt;/em&gt; indeed, and I can appreciate the effort, especially since there are ways to run Gnome on mobile phones today.
Alternatives are always good and given the sad state of Android as an operating system, I&amp;rsquo;m all for full-blown Linux on mobile devices, with nice-looking native apps.
And while this is cool and all, here&amp;rsquo;s a big problem:&lt;/p&gt;
&lt;p&gt;Gnome interface elements are just way too big on the desktop.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s a screenshot of the Gnome desktop on a Full HD display:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/15%27%27full-hd.png&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;And here&amp;rsquo;s a similar screenshot but on a 2K display:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/13%27%272k.png&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;Just by visual comparison, you can see how much more space the file manager window is using on the first screenshot.
Note, however, that both screenshots have file manager windows of the very same size, e.g. there&amp;rsquo;s no interface scaling.
If you have a 1920×1080 display, try opening both screenshots in full screen, to see how the UI scale &lt;em&gt;changes&lt;/em&gt; with the resolution.
I, unfortunately, don&amp;rsquo;t have two displays with the same diagonal size but different resolutions, but here&amp;rsquo;s how it looks on my two laptops, from which I&amp;rsquo;ve taken the screenshots.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Edit&lt;/strong&gt;: After getting a few &lt;a href=&#34;https://www.reddit.com/r/gnome/comments/xy0uov/comment/iretitl/?utm_source=share&amp;amp;utm_medium=web2x&amp;amp;context=3&#34; target=&#34;_blank&#34;&gt;comments&lt;/a&gt; on the fact that comparison screenshots don&amp;rsquo;t show anything useful, as the file manager windows have the same pixel size, I understood that I was not quite exact on what I wanted people to see.
The problem in my explanation was with the fact that while windows do have the same size, the text size was supposed to be different but I forgot to enable it.
Sorry for the confusion, and thanks for pointing this out.
I&amp;rsquo;ve enabled font scaling and re-made the screenshots, so I hope that now this will illustrate my point a bit better.&lt;/p&gt;
&lt;p&gt;Here&amp;rsquo;s a screenshot of a display with a resolution of 1920×1200:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/regular1920x1200.png&#34;
         alt=&#34;Figure 4: UI scale: 100%, display resolution: 1920×1200, font scale: 1x&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 4: &lt;/span&gt;UI scale: 100%, display resolution: 1920×1200, font scale: 1x&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;This is how I see things on my work laptop, which has no UI or font scaling&lt;/p&gt;
&lt;p&gt;Now the same image, but I&amp;rsquo;ve downscaled 2560×1600 to 1920×1200 and upscaled fonts to 1.33x.
This way the images will have the same size, but you&amp;rsquo;ll see the difference in the UI element sizes:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/2k-downscalded-to-1920x1200-with-upscaled-fonts.png&#34;
         alt=&#34;Figure 5: UI scale: 75%, display resolution: 2560×1600, font scale: 1.33x&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 5: &lt;/span&gt;UI scale: 75%, display resolution: 2560×1600, font scale: 1.33x&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;You can toggle between these screenshots to see the difference in UI scale.
I, naturally, see it on screen, given that I use the latter setup on my smaller laptop, and the first screenshot represents the setup on my work laptop.
And I indeed had to adjust the size of the file manager window so their geometry matched, however, note that the text size is the same&lt;sup id=&#34;fnref:1&#34;&gt;&lt;a href=&#34;#fn:1&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;1&lt;/a&gt;&lt;/sup&gt; on both screenshots:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/text-size-same.png&#34;
         alt=&#34;Figure 6: UI elements are scaled down, yet the text is the same size&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 6: &lt;/span&gt;UI elements are scaled down, yet the text is the same size&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;I understand that this was not very obvious to see from the screenshots I provided earlier, that&amp;rsquo;s why I&amp;rsquo;ve included laptop photos that should have demonstrated this idea.
Hopefully, these screenshots better illustrate my point.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;The first one has a 15-inch Full HD display, the second one has a 13-inch 2K display:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/screen-sizes.jpg&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;Now, let&amp;rsquo;s set the screen scale on the 13-inch laptop to 125% and compare:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/screen-sizes-scaled.jpg&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;It may seem that apps don&amp;rsquo;t have the same size, but that&amp;rsquo;s due to the fact that the screens have different heights, and actually, 125% scaling matches how the screen would look if I had a 2k 15-inch display, instead of a 13-inch one.
Here&amp;rsquo;s a better illustration:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/screen-sizes-scaled-adjusted.jpg&#34;/&gt;
&lt;/figure&gt;

&lt;p&gt;I&amp;rsquo;ve used my GIMP skills to increase the height of the second display to match the height of the first display.
You can see that the file manager windows are indeed (almost) the same size.
Well, I guess I could just add a screenshot with the system scale set to 125% but the post already has way too many images, so if you want to compare them, see the footnotes section &lt;sup id=&#34;fnref:2&#34;&gt;&lt;a href=&#34;#fn:2&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;2&lt;/a&gt;&lt;/sup&gt;&lt;sup&gt;, &lt;/sup&gt;&lt;sup id=&#34;fnref:3&#34;&gt;&lt;a href=&#34;#fn:3&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;3&lt;/a&gt;&lt;/sup&gt;&lt;sup&gt;, &lt;/sup&gt;&lt;sup id=&#34;fnref:4&#34;&gt;&lt;a href=&#34;#fn:4&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;4&lt;/a&gt;&lt;/sup&gt;.&lt;/p&gt;
&lt;p&gt;So what do I want you to take away from all of this?&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m using the laptop on the left for 9 hours a day because it&amp;rsquo;s my work laptop.
And each day I do I feel that the interface could have been 25% smaller.
Notably, I felt this way even before I got myself a laptop with a higher resolution - and when I did I realized that Gnome works perfectly with this kind of pixel density.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;m using the right laptop right before and after work.
This is basically my hobby machine - I write this blog on it, and I code all my side projects on this very screen.
And every time I use Gnome apps on this screen they feel right at home.
I don&amp;rsquo;t have the best eyesight, mind you, so small elements should be problematic for me, but with this level of scale, they simply are not small - they&amp;rsquo;re &lt;strong&gt;normal&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;So my takeaway here is that Gnome can safely &lt;strong&gt;reduce all their UI element sizes by 25%&lt;/strong&gt; and it will still work great!
Like, seriously, I even used &lt;code&gt;~/.config/monitors.xml&lt;/code&gt; to set the UI scale to &lt;code&gt;0.75&lt;/code&gt; under the Wayland session, which looks amazing&lt;sup id=&#34;fnref:5&#34;&gt;&lt;a href=&#34;#fn:5&#34; class=&#34;footnote-ref&#34; role=&#34;doc-noteref&#34;&gt;5&lt;/a&gt;&lt;/sup&gt; on my 1920×1080 display UI-wise.
The text is a bit too small for my liking, but this can be fixed by scaling fonts up, the main thing I wanted from this is to make UI elements take less space.
All UI elements such as buttons, menus, headerbars, panels, e.t.c. are perfectly usable with this scale on a regular Full HD display.
The same can be done under XOrg with &lt;code&gt;xrandr --output &amp;lt;display&amp;gt; --scale1.25x1.25&lt;/code&gt;.&lt;/p&gt;
&lt;p&gt;On a side note, I once owned a &lt;a href=&#34;https://www.gpd.hk/gpdpocket/&#34; target=&#34;_blank&#34;&gt;GPD Pocket&lt;/a&gt;, the first revision, and it had a 7-inch screen with a 1920×1200 resolution.
I&amp;rsquo;ve used Gnome on it, and funnily enough, upon installation Gnome detected that the screen is small, and automatically set the interface scale to 200%.
Fractional scaling is still an experimental option, so I guess it was rounded to the next non-fractional scale available.
Using it like this was not possible at all, because nothing was able to fit on the screen.
I don&amp;rsquo;t have the device anymore, but I can set the scale to 200% on my work laptop and add it via GIMP to an old photo I&amp;rsquo;ve taken in 2018:&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/gpd-with-gnome.png&#34;
         alt=&#34;Figure 7: A mockup of how Gnome looked on GPD Pocket with scaling set to 200%&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 7: &lt;/span&gt;A mockup of how Gnome looked on GPD Pocket with scaling set to 200%&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;Setting the scaling to back 100% made the device usable but the text was too small.
So I&amp;rsquo;ve turned font scaling only, and could use Gnome on this tiny screen without any hiccups -  because all UI elements were perfectly usable in their unscaled form.
GPD Pocket also has a touch screen, and even the it wasn&amp;rsquo;t affected by scale change - all elements still could have been pressed reliably with ease.
I hope you can now trust me that the Gnome UI elements can be smaller without impacting usability because I&amp;rsquo;ve used Gnome on a large variety of screen sizes and resolutions.&lt;/p&gt;
&lt;h2 id=&#34;big-for-the-sake-of-being-big--or-just-different&#34;&gt;Big for the sake of being big (or just different?)&lt;/h2&gt;
&lt;p&gt;There&amp;rsquo;s another thing I&amp;rsquo;d like to mention.
Gnome is quite different from other desktop environments available for GNU/Linux.
There are a lot of different DEs, of course, but the most common ones to pop up are KDE Plasma, XFCE4, MATE, and Cinnamon.
All these DEs are not &amp;ldquo;big&amp;rdquo; in terms of their UI elements.
KDE is more Windows-like, and Xfce and Mate are more Gnome2-like (well, Mate &lt;strong&gt;is&lt;/strong&gt; a continuation of Gnome2).
While Xfce and Mate are more of an old-school type of DEs, which are still mostly using UI guidelines from that era of Gnome2 but build on top of modern GTK, KDE is not.
KDE aims at being modern UI, without being big, and somehow that&amp;rsquo;s possible too!&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve used KDE Plasma 5 for two whole years from 2017 to 2019 if I remember correctly.
Even though I always was a Gnome user before that, I enjoyed my time with KDE, after I got past the initial setup.
KDE, ships with a ton of settings, unlike Gnome, and for some reason, the KDE dev team decided to turn most of them on.
It was a major barrier for me because I want my desktop to be as simple as possible, not as noisy as possible.
So I had to turn off all these jumping cursor animations, loading circles, e.t.c. speed up window animations one step up, and so on.
After that KDE felt like a big improvement over what I&amp;rsquo;ve had in other Gnome2-like desktops.&lt;/p&gt;
&lt;figure&gt;&lt;img src=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/plasma.png&#34;
         alt=&#34;Figure 8: Official KDE Plasma 5.25 screenshot&#34;/&gt;&lt;figcaption&gt;
            &lt;p&gt;&lt;span class=&#34;figure-number&#34;&gt;Figure 8: &lt;/span&gt;Official KDE Plasma 5.25 screenshot&lt;/p&gt;
        &lt;/figcaption&gt;
&lt;/figure&gt;

&lt;p&gt;While I liked KDE, I&amp;rsquo;m just more familiar with Gnome, so I&amp;rsquo;ve returned to it after some time, but KDE was what made me start thinking about smaller interface elements again.
I also wanted Wayland, and KDE didn&amp;rsquo;t have great support for it back then, while Gnome kinda did.&lt;/p&gt;
&lt;p&gt;But what&amp;rsquo;s interesting, is that KDE Plasma also &lt;a href=&#34;https://plasma-mobile.org/&#34; target=&#34;_blank&#34;&gt;can be used on mobile phones&lt;/a&gt;, yet they don&amp;rsquo;t use mobile UI on desktop, unlike Gnome.
I&amp;rsquo;m not sure if Plasma mobile ships with completely different apps or reuses apps from the desktop, but as far as I can tell, all apps that are built with the &lt;a href=&#34;https://develop.kde.org/frameworks/kirigami/&#34; target=&#34;_blank&#34;&gt;Kirigami framework&lt;/a&gt; can work as both desktop and mobile apps, similarly to Gnome.
So it can be done, even without using a big UI on a desktop.
Gnome just didn&amp;rsquo;t want to do that, unfortunately.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ll admit, there are &lt;a href=&#34;https://www.deepin.org/en/dde/&#34; target=&#34;_blank&#34;&gt;other desktop environments&lt;/a&gt; with big UI elements, it&amp;rsquo;s just the fact that Gnome is one of the most used desktop environments in the Linux ecosystem.
Gnome is used by default by two major out-of-the-box distributions - Fedora and Ubuntu.
It is used by default in Pop_OS!, Tails, Debian, CentOS, and RHEL, and even Oracle&amp;rsquo;s Solaris &lt;a href=&#34;https://en.wikipedia.org/wiki/Oracle_Solaris#Version_history&#34; target=&#34;_blank&#34;&gt;switched to it in version 11.4&lt;/a&gt;.
This is why I think that there should be put a bit more thought on the UI guidelines, as all these distributions are not for the mobile market.&lt;/p&gt;
&lt;h2 id=&#34;it-s-getting-better&#34;&gt;It&amp;rsquo;s getting better&lt;/h2&gt;
&lt;p&gt;Though I don&amp;rsquo;t like decisions that were made in the past by the Gnome developers, I must admit - Gnome is getting better with every release.
Gnome 40 introduced a lot of tweaks to the UI, making workspaces horizontal by default for example, and changing the overview screen to better utilize space because of it.
The dark mode is another new addition, and it is made good, though it&amp;rsquo;s not automatic, you need to use an extension for that, but it&amp;rsquo;s &lt;em&gt;fine&lt;/em&gt;.
What I&amp;rsquo;m saying is that the project is lively and ever-changing - maybe we&amp;rsquo;ll get a more desktop-oriented design in the future.&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve mentioned that I prefer not to use extensions, but in actuality, I use two extensions - &lt;a href=&#34;https://github.com/kaiseracm/gnome-shell-extension-maximize-to-empty-workspace&#34; target=&#34;_blank&#34;&gt;maximize-to-empty-workspace&lt;/a&gt; and &lt;a href=&#34;https://nightthemeswitcher.romainvigier.fr/&#34; target=&#34;_blank&#34;&gt;Night Theme Switcher&lt;/a&gt;.
Because of the first one, I&amp;rsquo;ve adopted the workflow, that I think the Gnome team envisioned - one maximized window per workspace.
Thus the big UI elements are not that of a problem, for me, at least, given that most of the screen is used by the maximized app, and I usually don&amp;rsquo;t stack multiple windows on one workspace.&lt;/p&gt;
&lt;p&gt;Even though, I think Gnome shouldn&amp;rsquo;t use these huge UI elements, or at least should provide a variant of the default theme that has 20-25% smaller window-related elements.
If this were done, I could use fractional scaling on my 2k laptop display, making text slightly bigger, while still having more usable space on my other Full HD laptop.
But we&amp;rsquo;ll see, I guess.&lt;/p&gt;
&lt;p&gt;Thanks for reading, and let&amp;rsquo;s hope that Gnome will become even better in the future!&lt;/p&gt;
&lt;div class=&#34;footnotes&#34; role=&#34;doc-endnotes&#34;&gt;
&lt;hr&gt;
&lt;ol&gt;
&lt;li id=&#34;fn:1&#34;&gt;
&lt;p&gt;There is a small rounding error after upscaling fonts to 1.333333, so the text sizes are not exactly same, but very close.&amp;#160;&lt;a href=&#34;#fnref:1&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li id=&#34;fn:2&#34;&gt;
&lt;p&gt;Gnome file manager at &lt;a href=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/15%27%27full-hd.png&#34;&gt;1920×1080 with a scale of 100%&lt;/a&gt;&amp;#160;&lt;a href=&#34;#fnref:2&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li id=&#34;fn:3&#34;&gt;
&lt;p&gt;Gnome file manager at &lt;a href=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/13%27%272k.png&#34;&gt;2560×1600 with a scale of 100%&lt;/a&gt;&amp;#160;&lt;a href=&#34;#fnref:3&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li id=&#34;fn:4&#34;&gt;
&lt;p&gt;Gnome file manager at &lt;a href=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/13%27%272k-scaled.png&#34;&gt;2560×1600 with a scale of 125%&lt;/a&gt;&amp;#160;&lt;a href=&#34;#fnref:4&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li id=&#34;fn:5&#34;&gt;
&lt;p&gt;Gnome file manager at &lt;a href=&#34;https://andreyor.st/2022-10-07-gnome-doesnt-need-to-be-that-huge/15%27%27full-hd-downscaled.png&#34;&gt;1920×1080 with a scale of 75%&lt;/a&gt; (resolution was artificially increased by scale settings in &lt;code&gt;~/.config/monitors.xml&lt;/code&gt;)&amp;#160;&lt;a href=&#34;#fnref:5&#34; class=&#34;footnote-backref&#34; role=&#34;doc-backlink&#34;&gt;&amp;#x21a9;&amp;#xfe0e;&lt;/a&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;/ol&gt;
&lt;/div&gt;
&lt;div class=&#34;comment-link&#34;&gt; &lt;a href=&#34;mailto:%61%6e%64%72%65%79%6f%72%73%74%2b%62%6c%6f%67%40%67%6d%61%69%6c%2e%63%6f%6d?subject=Comment: GNOME doesn&#39;t need to be that huge&#34; target=&#34;_blank&#34; rel=&#34;noopener noreferrer&#34;&gt;Comment via email&lt;/a&gt;&lt;/div&gt;</description>
      <pubDate>Fri, 07 Oct 2022 02:45:00 +0300</pubDate>
    </item>
  </channel>
</rss>
