Install and create Gnome extensions
Let’s dive into Gnome extensions! Gnome is a big system, so it’s worth understanding which parts do what. The main pieces are Glib, GTK+ and Gnome-shell. Glib contains all the core libraries for developing Gnome applications. These libraries are divided further into I/O handling, text handling and even a webkit2 interface to handle web browsers and other similar jobs.
GTK+ is the graphical user interface toolkit. With it you design the user interface and connect to the Glib library. This toolkit has official bindings to Gnome for C++, Python, Vala and of course JavaScript, so if you plan to make full applications for Gnome, you’re already on your way. Gnome Shell is what is truly interesting to us. It is the part that provides functions to switch windows, launch applications and see notifications. It also creates the Top Bar, this is where you can see most extensions. Some just change the behaviour of Gnome, but the interesting ones are on the Top Bar.
Gnome-shell is written mainly in JavaScript using bindings to the underlying layers. This is why, as we’ll see later, all extensions are written in JavaScript accessing a number of classes. When you get serious about Gnome development, you will learn the details of Mutter, Clutter and OpenGL. These are lower in the stack and support all your code. However, when you create extensions you only need to know the JavaScript classes that are in the Gnome-shell code.
Most of this tutorial is about how to handle existing extensions, but you may want to follow along with the development example at the end. You just
You’re reading a preview, subscribe to read more.
Start your free 30 days