I’m running Xubuntu 14.04, but the Thunar file manager has the annoying habit of
executing executable text files (i.e., scripts), instead of opening them in a text editor, when I double-click them. Since there seems to be no way to change this behaviour
(at least not without patching Thunar), I went looking for another file manager that will let me
open text files in an editor, whether or not they are executable.
Since the Ubuntu 14.04 repositories provide the
Nemo file manager (from the Cinnamon environment), I decided to try that one first.
Nemo works fine, except for one little detail: When I select an icon, and then press the
F2 key to rename the file, then the background of the file name field turns black, and I can no longer read what I’m typing (since the file name is now displayed with black text on a black background).
Since Nemo is a GTK3+ application, I decided to delete the
“gtk-3.0” subdirectory under the theme (or, rather, to move the subdirectory out of the way), and see if that changes anything. Under root, I do:
Code:
mkdir /root/Greybird
mv /usr/share/themes/Greybird/gtk-3.0 /root/Greybird
The problem then disappears.
For further experimentation, I moved the subdirectory back into place:
Code:
mv /root/Greybird/gtk-3.0 /usr/share/themes/Greybird
rmdir /root/Greybird
Then, under my own user account, I copied the theme files to my personal configuration directory:
Code:
cp -r /usr/share/themes/Greybird/gtk-3.0 ~/.config
(NOTE: I initially left the global theme settings in place at this point, but I soon realised that I had to move them out of the way again, to prevent any settings to be taken from the global files when I removed them from my local settings.)
I subsequently tried to delete as much as possible from my personal
“gtk-3.0” configuration directory, and after all my testing, I found that the problem sits in the
“gtk-widgets.css” file—specifically in the
“.entry” declaration in the file:
Code:
/*********
* entry *
*********/
.entry {
padding: 3px;
border-width: 1px;
border-style: solid;
border-top-color: shade(@theme_bg_color, 0.6);
border-right-color: shade(@theme_bg_color, 0.7);
border-left-color: shade(@theme_bg_color, 0.7);
border-bottom-color: shade(@theme_bg_color, 0.72);
border-radius: 3px;
background-color: @theme_base_color;
background-image: linear-gradient(to bottom,
shade(@theme_base_color, 0.99),
@theme_base_color
);
color: @theme_text_color;
}
To solve the colouring issue, I must apparently change the
“border-radius” value
(highlighted in the code above) to
“0px”. I have no idea whatsoever how a
“border-radius” setting can cause such an issue, but in any case, the minimal files that I need in my personal GTK3+ configuration directory (i.e.,
“${HOME}/.config/gtk-3.0”) in order to solve the issue, are as follows:
- File “gtk-widgets.css”:
Code:
.entry {
border-radius: 0px;
}
- File “gtk.css”:
Code:
@import url("gtk-widgets.css");
QUESTION: Does anybody have any idea why the “border-radius” setting causes this issue?
While I did find a way to fix the issue, I’m curious about why it happens in the first place.
P.S.: If you would rather stick with a GTK2+ file manager (in line with the XCFE 4.10 desktop environment that comes with Xubuntu 14.04), then you may want to try the
Caja file manager (from MATE) instead. However, MATE isn’t present in the default Ubuntu 14.04 repositories, and you will need to add the following PPAs to your system: