Prikazani su postovi s oznakom window manager. Prikaži sve postove
Prikazani su postovi s oznakom window manager. Prikaži sve postove

30. 05. 2013.

IceWM - Setting wallpaper

I saw that some people find it difficult to change wallpaper in IceWM. It is actually very simple. You can do that by:

1) Openin the desired photo in Feh, right-click and select File → Background → Set Tiled|Scaled|Centered|Filled. The problem with that is that after closing a session, wallpaper will be lost.

However, there are two more easy options (probably there are even some more):

2) Make Feh set a wallpaper on every session start. Read this post to see how to do that.

3) Copy a file /usr/share/icewm/preferences to ~/.icewm folder. Open it and at the very end (antepenultimate), you'll see:

#  Desktop background image
# DesktopBackgroundImage=""

Remove the crunch sign (#) and add a path to desired wallpaper image in quotes. Example:

#  Desktop background image
DesktopBackgroundImage="/home/hrvoje/.icewm/wallpaper.jpg"

After that restart the IceWM and it should work (it works for me).

25. 05. 2013.

IceWM - Toolbar launchers

To set up toolbar launchers, you have to edit (or create) toolbar file in ~/.icewm folder.

Syntax is this:
prog "tooltip name" /path/to/icon.ext command

Example:
prog "MOC Player" /home/hrvoje/.icons/AwOken/clear/128x128/apps/codeina.png xterm -e mocp ~
prog "PCManFM" /home/hrvoje/.icons/AwOken/clear/128x128/places/awoken/awokenclear/folder.png pcmanfm ~
prog "Leafpad" /home/hrvoje/.icons/AwOken/clear/128x128/apps/gedit.png leafpad
prog "LibreOffice Writer" /home/hrvoje/.icons/AwOken/clear/128x128/apps/libreoffice-writer.png libreoffice --writer
prog "Iceweasel" /home/hrvoje/.icons/AwOken/clear/128x128/apps/iceweasel.png iceweasel
prog "Skype" /home/hrvoje/.icons/AwOken/clear/128x128/apps/skype.png skype

24. 05. 2013.

IceWM - Startup commands

To tell your IceWM what commands should it run on startup, you have to edit (or create) startup file in ~/.icewm folder. On how to do that, see previous post.

It should actually be a BASH script, so in the first line, it has to have #!/bin/bash. Then you just put each command you want in the new line, followed by the & (except the last command).
I know it is not much understandable, but see this example:

#!/bin/bash
tilda &
sleep 1
numlockx &
sleep 1
xscreensaver &
sleep 2
checkgmail &
sleep 1
feh --bg-scale ~/.icewm/wallpaper.jpg &
sleep 1
setxkbmap -option grp:lwin_toggle hr,ru\(phonetic\) &
sleep 1
syndaemon -i 1 -d -t

This script tells IceWM to:
1. run Tilda (drop-down terminal)
2. wait one second
3. run NumLockX (turns on NumLock)
4. wait one second
5. run XScreenSaver (screen saver and power manager tool)
6. wait two second
7. run CheckGMail (GMail notifier)
8. wait one second
9. make Feh set a wallpaper.jpg image in ~/.icewm folder as a wallpaper (scaled)
10. wait one second
11. enable Croatian and Russian (phonetic) as a keyboard layouts and make left Win key switcher between them
12. wait one second
13. disable touchpad tapping and scrolling for one second after the last key is pressed via SynDaemon

For another example, if you wish only Skype and Dropbox to be started with the WM, your script should look like this:
#!/bin/bash
dropbox start -i &
skype

Now that you have your script, you have to make it executable in order to work. You can do that by entering in terminal:
chmod +x ~/.icewm/startup

IceWM - Keyboard shortcuts

You have to edit (or create) a file called keys in ~/.icewm folder.

You can do that by entering in terminal:
vim ~/.icewm/keys

You have to add a line for a keyboard shortcut in that file. Press key "i" on your keyboard to insert text.
Syntax is this: key "combination of keys" command.
For example:
key "Alt+F2" gmrun
key "Alt+w" leafpad
key "Alt+x" xterm
key "Alt+f" iceweasel
key "Alt+a" pcmanfm
key "Alt+c" chromium
key "Alt+s" skype
key "XF86AudioLowerVolume" amixer set Master 5%-
key "XF86AudioRaiseVolume" amixer set Master 5%+
key "XF86AudioMute" amixer set Master 0
key "XF86AudioPlay" mocp -G
key "XF86AudioStop" mocp -s
key "XF86AudioNext" mocp -f
key "XF86AudioPrev" mocp -r
key "Alt+Ctrl+l" xtrlock
key "Alt+Ctrl+p" xterm -e sudo pm-suspend
key "Alt+Ctrl+r" killall -SIGHUP icewm
key "Print" scrot

After adding all lines you want (you can, of course, change that file anytime later) press "esc" key on your keyboard and write :wq to save and exit from Vim editor.

Alternatively, you can create that file with any text editor (e.g. Leafpad), or write echo 'line with above syntax' >> ~/.icewm/keys, for example:

echo 'key "Alt+F2" gmrun' >>  ~/.icewm/keys

23. 05. 2013.

IceWM - Introduction

IceWM is very lightweight window manager and it looks very retro. However, it is highly customisable and you can make it look really nice. With a few tricks it also can be fully functional.

First you have to installing base things (which I wrote in previous post). Then you have to know something about IceWM. You can read about it here and here. To cut the long story short, he reads all configuration files from ~/.icewm (hidden - that's why the dot is in front of the name) directory in your home (represented by "~") folder. Those files contain the appearance of the IceWM, its menu, behavior, keyboard shortcuts and start applications or commands on startup.

I will write several posts about configuring those things in IceWM.

Here are some of my screenshots of IceWM:










MOC player on its own workspace

19. 05. 2013.

Choosing a DE/WM

It is not that easy to choose which DE you want to use, or, alternatively, whether you want to use just a WM. If you're a beginner and don't want to mess with configuration via text files, use a DE.

Here goes the story about my journey to find the right option (so you can skip this part). Out of all that WMs and DEs mentioned in previous post, I tried all (and some more) except Ion. Now I'm using Openbox, and if it wasn't the case, I'd be using IceWM again. It is not, that I don't like DEs, but they're slow and they give you bunch of things you don't actually need. They eat your computer's resources just to look nice and modern. If you need that than go for it. I like performance better than the look. Out of all DEs I liked KDE3.5 the most, but unfortunatelly it is thing of the past now. There is a team that is still (maybe not anymore) maintaining KDE3.5 packages, called Trinity DE. I tried that too. I was so happy, but it's hard to keep it from upgrading to KDE4. When KDE3.5 died, I started to like GNOME2. At first I didn't like the appearance of it and was still using KDE(4) (ok, I was fascinated by the new look), but then I realised it can be better, faster, with less fan activity and even more customisable. So I started to use GNOME2 until GNOME3 came up. Gnome Shell looks nice, but it's too heavy and slow for me, plus I don't like that dash thing and also its panel and notification/systray area. Then, out of curiosity, I tried different WMs. I was using twm some time, and also I had IceWM installed. I didn't like the look and behaviour of it, but when I find out how to configure it, I realised how great it is! And really! I was using it for a quite a long time. Then I bought myself a new laptop (I was happy that I don't have to buy expensive computer full of high-tech components) and again I wanted to try some DE on it. I installed XFCE (had some experience with it earlier). I was surprised by how it developed into a really good DE. I wasn using it for a short period of time and then I switched back to WM. This time it was Openbox, which I'm still using.

Now a couple of suggestions. If you have a computer with low skills and you want a full DE, consider using Xfce. If you have a better computer and you're into modern look of your OS, then take a look on GNOME Shell, KDE4, Cinnamon or MATE. I don't want to tell that Xfce can't look great. It can!
As I already wrote, Cinnamon and MATE were developed for Linux Mint distribution and they are both forges of GNOME.

The best way to choose between DE is to see it in action and decide which one you like the most. You can do that in few ways.

1. Install them all into your system and during each login you can easily choose which DE you want to use for that session. That option is really good for experiencing work with several different DEs, but there is something I really don't like about it. As I already mentioned, each DE will install you its default file manager, terminal emulator, DM, WM, control panel, internet browser, instant messanger, music player, burning tool, video player and so on and so on. With more than one DE installed, you'll have many unnecessary programs.

2. Install one, try it, uninstall it with all of its components, install the other one, try it, uninstall it.... I've never tried that, but it should work.

3. Maybe your friend has a DE you want to try. Ask him to show you and let you try it!

4. Find screenshots and videos of desired DE on the internet. The simpliest way is to type it in Google, or even better, YouTube.

5. If you have more than one computer, you can install different DE on each of them.


If you want to have just a WM, then the best option is to install all which you want to try and try them. They will just install some libraries, but won't install any programs.

WMs are really lightweight (especially tiling ones), but for someone who used to do things by clicking they are harder to configurate. Of course you can use them just as they are installed, but then you won't have many nice things.
For the cunfiguration of some WMs, you'll have to wait my another post.

Desktop environments and window managers

As I wrote in previous post, now I'm going to write about desktop environments (DEs) and window managers (WMs).
When you install a linux distribution, it usually comes with some DE or WM by default. Some distros offer you to choose between several DEs, either that you download different image (later burnt on a CD/DVD or copied to a USB flash drive) from which you install chosen distribution, or during the installation (if image contains all those DEs). If that is not the case, then you can install any of these DEs or WMs from repository or source found on their websites.

Wait! What is DE and what is WM?

The WM stands for the window manager and it is system that controls geometry of your windows on a desktop. In other words, when you open a program, it manages position and size of it, showing you its decoration (border and that thing on the top with maximise, minimise, close, info, etc. buttons) and allowing you to move and resize it.
There is not just one WM and they are of different types:

Floating or stacking: Openbox, IceWM, Twm, Fluxbox, Enlightment, etc.
What are they all about? The windows are rendered one-by-one and one window can overlap the other. That's the most used window manager type.

Tiling: Awesome, dwm, Ion, etc.
In this type you windows don't overlap one another, but they're all placed in tiles. However, sizes and position of the tiles can be changed.

Compositing: Metacity (part of GNOME2), Mutter (part of GNOME3), KWin (part of KDE), Xfwm (part of XFCE), Compiz, etc.
They are usually part of DE. First the window is rendered, and then it image is composed on the screen. With that, you can than apply various visual effects on windows (transparency, shadow, wobbly windows, cube, etc.).

VirtualFvwmFwvm-crystalvtwm, etc.
They are actually floating window managers that are using virtual screens, so windows can go out of the screen.


The DE stands for the desktop environment. That is more complex thing than WM, because it contains not only WM, but usually also file manager, display manager, terminal emulator, default programs, libraries, themes, configuration tools, default daemons lunched at start.
Some of the most popular DEs are GNOME, KDE, Xfce, LXDE, Razor-qt, MATE and Cinnamon.

GNOME used to be light DE, but as the years went by GNOME2 is no longer officially developed and we're introduced the GNOME3 (aka GNOME Shell), whis is not light at all.
Default window manager for GNOME2 is Metacity, for GNOME3 it is Mutter. Default file manager is Nautilus, display manager is GDM, and terminal emulator is Gnome-terminal. It is written in GTK+ (C).

KDE is also not very light DE. It's default window manager is KWin and file manager Dolphin. It is written in Qt (C++) and comes with KDM display manager and Konsole as a terminal emulator.

Xfce is, say, light DE, although it also becomes higher and higher. It is now what GNOME2 used to be few years ago.
Xfce is, as GNOME, written in GTK+ (C) and, unlike GNOME, comes with LightDM and has Thunar as default file manager and Xfce4-terminal as terminal emulator.

LXDE really is light DE, but is somehow poorly maintained. It was written in GTK+, but it is migrating to Qt. Its default WM is Openbox, display manager is LXDM, terminal emulator is LXterminal, and file manager is PCManFM.

Razor-qt is lightweight Qt desktop environment.

MATE and Cinnamon are actually a GNOME2 and GNOME3 (respectively) forges used by Linux Mint distribution.