Difference between revisions of "WMFS"

From ArchWiki
Jump to: navigation, search
m (moved Wmfs to WMFS: proper casing)
(Major rewrite)
Line 1: Line 1:
[[Category:Tiling WMs (English)]]
+
[[Category:Dynamic WMs (English)]]
 
[[Category:HOWTOs (English)]]
 
[[Category:HOWTOs (English)]]
 +
{{i18n|WMFS}} {{DISPLAYTITLE:WMFS}}
 +
{{Article summary start|Summary}}
 +
{{Article summary text|Information on installing and configuring WMFS}}
 +
{{Article summary heading|Related}}
 +
{{Article summary wiki|dmenu}}
 +
{{Article summary end}}
  
 
{{stub}}
 
{{stub}}
Line 10: Line 16:
 
wmfs is available from the '''unsupported''' [AUR] . Due the high development rate its recommended to use the [http://aur.archlinux.org/packages.php?ID=26924 git] version.
 
wmfs is available from the '''unsupported''' [AUR] . Due the high development rate its recommended to use the [http://aur.archlinux.org/packages.php?ID=26924 git] version.
  
If yaourt is installed, just type the following in your console :
+
You can install it with an AUR helper, or build it yourself.
yaourt -S wmfs-git
+
  
The config folder is located in ~/.config/wmfs. If it doesn't exist, just create it.
+
To configure WMFS to your liking, you will need to create a config file {{filename|~/.config/wmfs/wmfsrc}}. If {{filename|~/.config/wmfs}} doesn't exist, create it:
 
  mkdir -p ~/.config/wmfs
 
  mkdir -p ~/.config/wmfs
  
A default file is located in your XDG directory, normally in /etc/xdg/wmfs, called wmfsrc. Copy&Paste it in the previous created folder and modify it to your desire.
+
A default file is located in your XDG directory, normally in /etc/xdg/wmfs, called wmfsrc. Copy it to your newly created {{filename|.config/wmfs}} folder and you can begin to modify it.
  cd /etc/xdg/wmfs
+
  cp /etc/xdg/wmfs/wmfsrc ~/.config/wmfs
cp wmfsrc ~/.config/wmfs
+
  
To use wmfs as windowmanager
+
To use wmfs as windowmanager, add it to your {{filename|.xinitrc}}:
  echo "exec wmfs" > ~/.xinitrc
+
  echo "exec wmfs" >> ~/.xinitrc
  
 
== Configuration ==
 
== Configuration ==
 
===Config file===
 
===Config file===
The config file is quite self-explanatory. More detailed information will follow soon.
+
The config file is well commented. Make small changes cumulatively and reload WMFS (default key to restart is {{Keypress|Alt}}+{{Keypress|Ctrl}}+{{Keypress|r}}.
  
By default two different mod keys are used for keybindings (Ctrl and Alt) which may cause problems with applications. These can be changed in the config file. For example if you want to use the win-key instead of Alt, replace "Alt" by "Super" or "Mod4" in the config file e.g
+
By default two different mod keys are used for keybindings ({{Keypress|Ctrl}} and {{Keypress|Alt}}) which may conflict with your pre-exisitng set-up. These can be changed in {{filename|wmfsrc}}. For example, if you want to use the win-key instead of Alt, replace "Alt" by "Super" or "Mod4" in the config file, e.g:
  
 
  [key] mod = { "Super" } key = "p" func = "launcher" cmd = "launcher_exec" [/key]
 
  [key] mod = { "Super" } key = "p" func = "launcher" cmd = "launcher_exec" [/key]
Line 36: Line 40:
  
 
===Statusbar configuration===
 
===Statusbar configuration===
The text shown in the status bars (or infobars) is set on a running wmfs instance using the "wmfs -s" command.  They can be different for each screen (tag). The infobars can also be positioned at the top, bottom or off differently for each screen in the configuration file. For example
+
The text shown in the status bars (or infobars) is set on a running wmfs instance using the "wmfs -s" command.  You can set a different bar for each tag. The bars can also be positioned at the top or bottom of each screen in the configuration file. For example
 
  wmfs -s "hello world, I am visible on all screens"
 
  wmfs -s "hello world, I am visible on all screens"
 
  wmfs -s 5 "hello world, I am visible on screen five only"  (not working, bug?)
 
  wmfs -s 5 "hello world, I am visible on screen five only"  (not working, bug?)
 +
 
Colors may be encoded like this:
 
Colors may be encoded like this:
 
  wmfs -s "This text is \#ff0000\red, \#00ff00\green and \#0000ff\blue"
 
  wmfs -s "This text is \#ff0000\red, \#00ff00\green and \#0000ff\blue"
 +
 
Rectangles may be drawn like this:
 
Rectangles may be drawn like this:
 
  wmfs -s "<--look rectangles \b[700;9;14;5;#00ff00]\ \b[715;4;14;10;#00ff00]\ \b[730;3;14;11;#ff0000]\ "
 
  wmfs -s "<--look rectangles \b[700;9;14;5;#00ff00]\ \b[715;4;14;10;#00ff00]\ \b[730;3;14;11;#ff0000]\ "
The format is \b[xx;yy;ww;hh;#cccccc]\ where xx and yy are absolute (not relative) x and y positions, ww and hh are width and height, and cccccc is a color. This feature could be used to create CPU barcharts, volume displays and the like. Note: if ''relative'' positioning were introduced it would be easier to interleave text and graphics.
 
  
So now one can simply write a bash script which will loop forever writing the correct strings to the infobars. Call it status.sh and wmfs will launch it if it is in ~/.config/wmfs. Note that the output in the status.sh is as explained before.
+
The format is \b[xx;yy;ww;hh;#cccccc]\ where xx and yy are absolute (not relative) x and y positions, ww and hh are width and height, and cccccc is a color. This feature could be used to create CPU barcharts, volume displays and the like. Note: the absolute positioning makes it difficult to accurately interleave text and graphics.
 +
 
 +
To pipe data to the bar, write a bash script with the relevant data you wish to display and source it in your {{filename|wmfsrc}}. WMFS will call it at the interval you specify:
 +
status_path = ".config/wmfs/wmfs-status"
 +
status_timing = 5
 +
 
 +
Note that the output in the status.sh is as explained before.
 
  wmfs -s "What ever you want to be displayed"
 
  wmfs -s "What ever you want to be displayed"
 +
 +
Some example status scripts are on the [http://wmfs.info/ WMFS] website.
  
 
===Conky===
 
===Conky===
  
You can pipe Conky's output to wmfs' statusbar with command:
+
You can use [[Conky]] to pipe output to wmfs' statusbar with the command:
  
 
  conky | while read -r; do wmfs -s -name "$REPLY"; done
 
  conky | while read -r; do wmfs -s -name "$REPLY"; done
Line 56: Line 69:
 
== Usage ==
 
== Usage ==
  
The keybinding Alt+p starts a launcher in the titlebar (similar to dmenu). It supports tab-completion and command-line parameters. Multiple presses of the tab key iterate through possible completions (but currently in the wrong order :( ).
+
The keybinding {{Keypress|Alt}}+{{Keypress|p}} starts a launcher in the titlebar (similar to [[dmenu]]). It supports tab-completion and command-line parameters. Multiple presses of the tab key iterate through possible completions.
  
Wmfs can be controlled from the command line with commands such as
+
WMFS can be controlled from the command line with commands such as
  
 
  wmfs -V :ln
 
  wmfs -V :ln
  
which selects the next layout. Equivalently press Alt+Escape followed by ":ln". Type "wmfs -V help" to see the full list.
+
which selects the next layout. Equivalently press {{Keypress|Alt}}+{{Keypress|Escape}} followed by ":ln". Type "wmfs -V help" to see the full list.

Revision as of 06:58, 29 December 2010

This template has only maintenance purposes. For linking to local translations please use interlanguage links, see Help:i18n#Interlanguage links.


Local languages: Català – Dansk – English – Español – Esperanto – Hrvatski – Indonesia – Italiano – Lietuviškai – Magyar – Nederlands – Norsk Bokmål – Polski – Português – Slovenský – Česky – Ελληνικά – Български – Русский – Српски – Українська – עברית – العربية – ไทย – 日本語 – 正體中文 – 简体中文 – 한국어


External languages (all articles in these languages should be moved to the external wiki): Deutsch – Français – Română – Suomi – Svenska – Tiếng Việt – Türkçe – فارسی

Template:Article summary start Template:Article summary text Template:Article summary heading Template:Article summary wiki Template:Article summary end

Tango-document-new.pngThis article is a stub.Tango-document-new.png

Notes: please use the first argument of the template to provide more detailed indications. (Discuss in Talk:WMFS#)

Introduction

WMFS (Window Manager From Scratch) is a lightweight and highly configurable tiling window manager for X. It can be configured with a configuration file, supports Xft (Freetype) fonts and is compliant with the Extended Window Manager Hints (EWMH) specifications. It's still under heavy development

Installation

wmfs is available from the unsupported [AUR] . Due the high development rate its recommended to use the git version.

You can install it with an AUR helper, or build it yourself.

To configure WMFS to your liking, you will need to create a config file Template:Filename. If Template:Filename doesn't exist, create it:

mkdir -p ~/.config/wmfs

A default file is located in your XDG directory, normally in /etc/xdg/wmfs, called wmfsrc. Copy it to your newly created Template:Filename folder and you can begin to modify it.

cp /etc/xdg/wmfs/wmfsrc ~/.config/wmfs

To use wmfs as windowmanager, add it to your Template:Filename:

echo "exec wmfs" >> ~/.xinitrc

Configuration

Config file

The config file is well commented. Make small changes cumulatively and reload WMFS (default key to restart is Template:Keypress+Template:Keypress+Template:Keypress.

By default two different mod keys are used for keybindings (Template:Keypress and Template:Keypress) which may conflict with your pre-exisitng set-up. These can be changed in Template:Filename. For example, if you want to use the win-key instead of Alt, replace "Alt" by "Super" or "Mod4" in the config file, e.g:

[key] mod = { "Super" } key = "p" func = "launcher" cmd = "launcher_exec" [/key]

Or in a single command

sed --in-place=.bak 's/"Alt"/"Mod4"/' wmfsrc

Statusbar configuration

The text shown in the status bars (or infobars) is set on a running wmfs instance using the "wmfs -s" command. You can set a different bar for each tag. The bars can also be positioned at the top or bottom of each screen in the configuration file. For example

wmfs -s "hello world, I am visible on all screens"
wmfs -s 5 "hello world, I am visible on screen five only"  (not working, bug?)

Colors may be encoded like this:

wmfs -s "This text is \#ff0000\red, \#00ff00\green and \#0000ff\blue"

Rectangles may be drawn like this:

wmfs -s "<--look rectangles \b[700;9;14;5;#00ff00]\ \b[715;4;14;10;#00ff00]\ \b[730;3;14;11;#ff0000]\ "

The format is \b[xx;yy;ww;hh;#cccccc]\ where xx and yy are absolute (not relative) x and y positions, ww and hh are width and height, and cccccc is a color. This feature could be used to create CPU barcharts, volume displays and the like. Note: the absolute positioning makes it difficult to accurately interleave text and graphics.

To pipe data to the bar, write a bash script with the relevant data you wish to display and source it in your Template:Filename. WMFS will call it at the interval you specify:

status_path = ".config/wmfs/wmfs-status"
status_timing = 5

Note that the output in the status.sh is as explained before.

wmfs -s "What ever you want to be displayed"

Some example status scripts are on the WMFS website.

Conky

You can use Conky to pipe output to wmfs' statusbar with the command:

conky | while read -r; do wmfs -s -name "$REPLY"; done

Usage

The keybinding Template:Keypress+Template:Keypress starts a launcher in the titlebar (similar to dmenu). It supports tab-completion and command-line parameters. Multiple presses of the tab key iterate through possible completions.

WMFS can be controlled from the command line with commands such as

wmfs -V :ln

which selects the next layout. Equivalently press Template:Keypress+Template:Keypress followed by ":ln". Type "wmfs -V help" to see the full list.