📅 March 25, 2015
Gedit, as well as xed, is an excellent text editor. Not only does it sport a variety of features that facilitate typing, programming, and file organization, but gedit also supports…get ready…wait for it…THEMES!
Yes, themes. Are you dissatisfied with the plain black-on-white color scheme? Maybe you prefer a darker theme with bold neon colors for keywords while programming? Or perhaps you simply want to look at pretty, new colors?
Gedit supports theme files that change the colors of various parts of text. This is especially valuable for highlighting specific programming languages. You can create gedit theme files yourself, or you can download existing themes from others.
Theme files seem to be one of gedit’s best-kept secrets. A few web sites have lists of themes available, but few previews. What does a theme look like before downloading?
This article aims to provide screenshots for a number of gedit themes for preview purposes and to show what is possible with gedit.
Where To Download Gedit Themes
The following three sites will provide a starting point, and it is from these sites the themes were obtained:
Find a theme you like, and download it as an xml file. This often means right-clicking the RAW download link and choosing the Save Link As option from the browser’s context menu. Some themes can be downloaded all at once in a single ZIP file.
How to Install New Themes
There are two ways to do this.
One Theme At A Time Method
If you have a few themes, then this method is probably the best. Open gedit, and go to Edit > Preferences > Font & Colors tab. Next, click the small “+” button to add a theme. Navigate to the xml theme file and open it. The theme will be added to gedit, ready for immediate use.
Multiple Copy Method
Themes are stored in the $HOME/.local/share/gedit/styles directory. This is a hidden directory in your home. Simply copy all theme xml files to this directory. However, you must restart gedit in order to detect and use the themes.
To use a theme, select it from the Color Scheme list box. Gedit instantly changes.
Update, July 29, 2016: In Linux Mint 18, you can copy all theme .xml files to /usr/share/gtksourceview-3.0 instead of $HOME/.local/share/gedit/styles.
Assume you are in a gedit theme directory containing all downloaded theme .xml files:
sudo cp *.xml /usr/share/gtksourceview-3.0
Themes will work with both gedit and the xed text editor — included as the default text editor in Linux Mint 18. Both editors check the same location for themes.
So, what do the themes look like? Here are a number of gedit themes organized by web site. For the file example, I took screenshots of the /etc/init.d/acpid file in Linux Mint 17.1. Plain text does not reveal a theme’s potential, so I used a script file to show how colors change when different themes are applied.
Each theme is named according to its name as seen per web site. Go to the web sites to download themes.
What does gedit provide by default?
Not certain what to name this set, but these are the themes found at the web site https://github.com/mig/gedit-themes.
Here are many more themes compatible with gedit, though not advertised as such.
Is a particular theme close but not quite to your liking? Then, you can open the theme in a text editor and edit it. These previews should provide a glimpse into what is possible in the world of gedit themes and help inspire your creativity. Happy theming!