22

Power Toys is an open source toolbox that contains a lot of very useful tools for Windows 10+ and I use it on a daily basis at work. One of them though I really wish I could use in my personal system, which is an Ubuntu 20.04.4. That tool is called FancyZones.

You can follow the link for a detailed explanation of all features of it, but in abstract, FancyZones is a tool for zoning your screen area, so you can place windows in these zones. The way it works is, I drag the window with left mouse button down and while at that, I right click, so the zones will show up. When I let go of left mouse button, the window will fill the zone, or I can cancel that by right clicking again while still dragging.

The zones should be fully customizable and it should be possible to change between zoning layouts per monitor through a keyboard shortcut.

For example, I have the laptop monitor and an ultra-wide monitor. The laptop monitor has a layout with 4 zones one on each corner, while the ultra-wide monitor has 3 layouts, 1 is the same as the the laptop's, 2 is 4 zones side by side and 3 is a focused space on the left a little under what a normal monitor would have and the rest to the right is the unfocused content. This one also has another zone on top of it emulating a 720p size monitor for when I screen-share, so I can share just a window with the perfect proportion and size, which means people can enjoy full-screen without having to zoom to understand what I'm sharing

It's not a requirement, but if possible, I would like for it to be available within Ubuntu Software app

3
  • 3
    This would be a feature you'd see in a window manager or desktop environment. GNOME is the least customizable of the DEs, so I'd suggest that you create a bootable USB of a different flavour and "Try Ubuntu" by booting this USB without affecting your installed system. KDE (Kubuntu) probably has the ability to do what you are wanting.
    – Nmath
    Oct 30, 2022 at 18:09
  • Thanks Nmath, for the insignt. It doesn't have to be a native app, though and certainly I'm not willing to switch my OS installation to another one just because of that (the link you gave me is returning timeout for me, so I can't check what it's about right now, but will check it out when my network stabilizes). Oct 30, 2022 at 18:29
  • 3
    @Nmath Actually, KDE doesn’t really have much better native tiling support than GNOME does. Because dedicated tiling window managers are readily available on Linux, most of the big desktop environments don’t provide more than the basic four-corners layout natively (they assume people who want tiling support will just use a proper tiling WM), and require extensions to provide support for anything else (for reference, the good one in my experience for KDE is github.com/esjeon/krohnkite). Oct 31, 2022 at 13:30

3 Answers 3

31

There is the Tiling Assistant extension (see this post for how to install GNOME Shell extensions: How to install GNOME Shell extensions in Ubuntu 22.04 LTS?). It's an awesome extension that greatly expands the default GNOME tiling experience and is extremely customizable. The extension offers basic quarter tiling, as well as Windows-like tiling, both by dragging a window with the mouse and using customizable keyboard shortcuts. By default the options menu of the extension has only two tabs: General and Keybindings, shown in the following screenshots:

enter image description here

enter image description here

However, the real power of the extension and what is of more interest to you lies in a hidden tab. This tab can be found if you click the lamp icon on the top left of the extension window, select Advanced..., and toggle Advanced / Experimental Settings on:

enter image description here

Then you'll also have access to the Layouts tab:

enter image description here

The Layouts tab has a list of predefined custom layouts that you can use and also lets you add your own custom layouts. To tile a window to a custom layout, you drag the window with your mouse while holding the Alt key. Then a preview of the layout comes up and you drop the window where you want.

To change the layout you can use the Ctrl+Alt+O shortcut, which opens a pop-up window that lets you select another layout.

To add a custom layout:

You define a layout's rectangles by entering their x and y coordinate as well as their width and height into a text entry separated by --. They are floating point values and can range from 0 to 1. The point (0,0) represents the top-left of your workspace and (1,1) the bottom-right. A loopType is set by appending --h or --v to the text entry for a horizontal and a vertical loop respectively. You can attach an app by using the Add Button to the right of a text entry. It acts like a toggle. If you already attached an app to it, clicking it again, will remove the app.

For example, to add a 3 columns layout, you click the + button at the bottom of the Layouts tab and add the following (screenshot from the project's User Guide linked below):

enter image description here

You can find more in the extension's User Guide.

Here is how three windows look on my desktop using a customized 3-Columns layout with:

  • Rect 0: 0--0--0.25--1
  • Rect 1: 0.25--0--0.5--1
  • Rect 2: 0.75--0--0.25--1

final desktop with custom layout

3
  • 10
    That's a spectacular answer!! Oct 30, 2022 at 21:49
  • Absolutely gorgeous answer! Even though it seems I've got a different version of Tiling Assistant from your screenshots. I had the same issue that other person had from your link, but their solution didn't work (it was unable to locate the package gnome-shell-extension-manager), so Googling around, I found it on flathub, from where I installed the manager and then installed the extension from there. But although the options are similar, the layout is very different and had more tabs, which were on a sidenav instead of top tabs. I'll get back to it tomorrow, but I think this is it. Thanks! Nov 1, 2022 at 3:12
  • Just as a follow up, yes, I think I've got the correct app, but it seems it's not going to update to the one in your screenshots. After looking out for it, I guess it's because of the shell's version in 20.04. Interesting enough in this version, Layout isn't hidden. The available tabs are General, Keybindings, Layouts, Pie Menu and Help and Changelog. I don't know if the newer versions fixed this, but you can't just drag a window to a zone. You have to bring up the whole zone and choose what window will go to each zone every time. Sometimes I just want to use the second zone and not the first. Nov 2, 2022 at 14:37
4

gSnap

I tried a handful of Gnome extensions, and gSnap seems to be the one closest to FancyZones.

First a quick word on Tiling Assistant: I tried that as well, and mistakenly thought that multi-monitor support and snapping to a tile weren't working because there are some extra steps needed to get them set up. Overall I think it's probably a more powerful and customisable extension than gSnap but with a less intuitive UX. Also, layout support in Tiling Assistant is still labeled as "experimental."

gSnap, however, seemed to work much better out of the box:

  • It has a set of default layouts out of the box, and you can create your own
  • You can set separate layouts per monitor
  • It has keyboard shortcuts for moving windows, snapping windows to zones, and changing layouts
    • The keyboard shortcuts for changing layouts are listed in the extension settings and are customisable
  • Multiple windows can be in the same zone, optionally with tabs at the top to show the list of windows (some other tiling extensions force tiling of every window and don't allow overlapping windows)
  • Windows can snap to zone by default, or this can be enabled via a hotkey
  • Configurable margins between zones

I did make a couple changes to make it function more like FancyZones:

  1. Click the tray icon > Settings

  2. I unchecked Show tabs. FancyZones doesn't have them and I really didn't like how much space they took up or how they sometimes covered up parts of the screen I was trying to see. Plus there are plenty of other ways to change windows (from the app icon in the dock, Alt+Tab, etc).

  3. I checked Hold CTRL to snap windows. FancyZones doesn't snap windows to zones by default either. The default behaviour of gSnap is to snap every window to a zone, which I didn't like. Sometimes I don't want to move a window to a zone, especially smaller windows. And when a new window popped up (e.g. a password prompt) it would snap it to a zone, spreading the UI elements out to places where I wasn't expecting them to be.

You can also further imitate FancyZones by setting the margins in the gSnap settings, although I didn't do this.

Lastly, here are my notes for some of the other tiling extensions I tried: https://gist.github.com/bmaupin/5ebd4d7fd52f8911e14fa55cd58aee2d

3
  • One downside I see is that it hasn't received support for GNOME 44 yet, so one has to disable version validation in order to be able to install the extension. Other than that, a nice suggestion! May 12, 2023 at 19:51
  • 1
    " In Tiling Assistant, I think you're supposed to be able to hold Alt while dragging a window to snap to a zone, but this never worked. " -- that actually works, but you have to first choose a favorite layout. Simply set one of the layouts as favorite and the zone based snapping will work. May 18, 2023 at 20:25
  • @KaiSellgren Ah that worked, thanks! It still feels pretty unintuitive to me (I didn't even notice the star icon before) and could benefit from some improved UX. But thanks for the clarification.
    – bmaupin
    May 23, 2023 at 13:25
2

Pygrid has been my goto for years

2
  • A brief description of the basic settings and functionality of the extension would be nice! :) Aug 15, 2023 at 20:14
  • prettymuch per the others, set zone sizes and you can drag-snap to those and keyboard shortcut to make windows jump to them also. It's basic but it works. Check the issues (inc closed) for a few small gremlins esp conflict between default shortcuts and existing system shortcuts.
    – dez93_2000
    Aug 24, 2023 at 17:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .