My thoughts on Slackware, life and everything

Tag: theme

I switched the blog’s theme

A blog  is something personal, and theming it just right is a challenge. You’ll surely have noticed that the theme of Alien Pastures has been changed overnight.

This blog started out with a theme by Andreas Viklund (wp-andreas01) but that did not scale well on mobile devices, also it did weird stuff with user comments. I liked its visual quality a lot but the usability challenges were not fixable even by rummaging around in its code.
Eventually I replaced that with a new theme by Rajeeb Banstola (techism) but during my recent WordPress blog-code update I realized that this techism theme had not been updated for years, the author’s website has disappeared and the Freemius SDK from which that theme is created has a XSS vulnerability. Real shame because I thought it was beautiful, light, responsive and it fixed the user comment issues I mentioned previously.

So I have used my December holiday to look for another theme, experimenting with several, but I wanted to end with one that at a minimum allows me to have two columns: one for the articles and one as a sidebar with widgets showing all kinds of permanent info. Three columns was what I had with wp-andreas01 and techism, but I could live without one of the two sidebars.

I finally found a theme collection created by Anders Norén. On his page teman he showcases several that I find appealing, but after some experimenting I chose his Lovecraft and Hemingway themes over Baskerville. I kept the visual style of the new theme as close as possible to the old one (header image, top menu, sidebar widgets etc).
A note about the header image – that one has changed a few times over the years. I always use a picture I have taken myself and I rotate them on occasion.

At the bottom I was able to add three widgets that otherwise would have gone into a left sidebar. I think it’s cleaner now. Plus, one of these bottom widgets shows posts that have been most popular during recent weeks. That’s always interesting information to you (visitors), previously I would be the only one with that overview – it shows in the blog’s admin dashboard.

I am still undecided whether Hemingway or Lovecraft will make it as my final choice. Hemingway theme shows the number of comments to each article and it’s visually somewhat more condensed. Lovecraft on the other hand is aesthetically more pleasing to my eye.

I hope you like and appreciate the change and the new interface does not pose any difficulty writing and posting your comments. Feel free to comment below of course!

Cheers, Eric

Running VLC in XFCE

As you may know I am using KDE for my daily work. However, I use XFCE from time to time – for example when I have to run a remote X session over XDMCP and want to keep a fluid feel to the desktop.

When I was working in XFCE yesterday I wanted to use VLC to check a video file on my computer, and I was in for a surprise when clicking “Media > Open file” made my VLC hang indefinitely!

I remembered a discussion about this phenomenon on LinuxQuestions.org and indeed the solution as pointed out in that thread works for me.

What happens here?

The core of the issue, is that Qt4 makes an incorrect assumption about which GTK+ theme engine to use. A GTK+ theme engine makes a Qt4 application blend in nicely with a GTK+ based desktop environment such as XFCE, by using GTK+ instead of Qt4 to render all graphical components.

There are a few GTK+ theme engines available – one of them is QGtkStyle which is part of Qt4 in Slackware. However, Qt4 libraries look at the environment variable “GTK2_RC_FILES” in order to find out how to configure the GTK theme engine.

If this environment variable is not (or incorrectly) set, then Qt4 assumes that GTK+ is using GTK-QT-Engine which is not part of Slackware (GTK-QT-Engine is used to give GTK appplications a Qt feel when they are running in KDE) and it will not correctly apply the QGtkStyle engine. It sets QGtkStyle to use the GTK style Clearlooks, and outputs an error message which you will sometimes be able to see if you started a Qt-based application from a terminal:

QGtkStyle cannot be used together with the GTK_Qt engine.

This can be solved by explicitly telling Qt4 where Slackware keeps its GTK+ configuration files, and then making sure a GTK+ theme is configured there.

  • Define the environment variable “GTK2_RC_FILES” in one of these files: ${HOME}/.xinitrc (applies to just you) or in /etc/profile.d/qt4.sh (applies system-wide) by adding the follwing two lines to that file (assuming you are using bash as your default shell):
    GTK2_RC_FILES="$HOME/.gtkrc-2.0:/etc/gtk-2.0/gtkrc"
    export GTK2_RC_FILES
  • Create a new file (or edit the existing) ${HOME}/.gtkrc-2.0 (so that the GTK theme applies to just you) or /etc/gtk-2.0/gtkrc (so that it applies system-wide) and add the following line to it:
    gtk-theme-name="GTK+"

That should fix VLC’s “Media > File Open” dialog which will now appear instantly.

Note: You can choose a GTK+ theme for all your QT4 based applications if you want by running “qtconfig” and in the tab “Appearance” set the “Select GUI Style” to “GTK+” instead of “Desktop Settings (default)“.

Eric

GTK2_RC_FILES

Icons disappear in XFCE 4.6.0

Ouch…

You just upgraded your Slackware computer to the latest slackware-current and you are using XFCE as a desktop manager. Perhaps you wondered why all of a sudden most of your panel icons are missing, and several of the icons that should display in menus and dialogs are gone as well.

The issue you are experiencing is caused by the removal of the Rodent icon theme from XFCE 4.6.0. This icon theme was the default in past versions, and your configuration in ~/.config/xfce4/ will have references to that Rodent theme especially if you selected custom icons in some places. Now you upgraded to 4.6.0 and the Rodent is gone, XFCE will not be able to display the associated icons.

The remedy is fairly simple (thanks Robby for informing me). Running (all of) the following three steps should work:

  1. Run the command “/usr/bin/gtk-update-icon-cache /usr/share/icons/hicolor”
  2. Use the XFCE Settings Manager to change the theme to Tango or Gnome
  3. Re-install the “hicolor-icon-theme” package

When that is done, you may still have icons for launchers on the panel that are missing. In that case there is no other solution than to edit that particular launcher’s properties and select a new icon for it. See our bug report about this issue at http://bugzilla.xfce.org/show_bug.cgi?id=5067 which was opened by Robby Workman.

Note that you will not experience this “missing icons” behaviour if you install XFCE 4.6.0 without ever having used older versions of XFCE before on that computer. It is purely upgrade-related.

Cheers, Eric

© 2024 Alien Pastures

Theme by Anders NorenUp ↑