[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Whitespace fixes
- To: herbstluftwm _minus_ devel _at_ lists _dot_ sourceforge _dot_ net
- Subject: Re: [PATCH] Whitespace fixes
- From: Florian Bruhin <me _at_ the _minus_ compiler _dot_ org>
- Date: Wed, 31 Oct 2012 19:29:49 +0100
Hi Thorsten,
* Thorsten Wißmann <re06huxa _at_ cip _dot_ cs _dot_ fau _dot_ de> [2012-10-31 18:16:25 +0100]:
> I'd like to have a empty line at the end of files. E.g. It looks strange
> in the NEWS file if the file is ends directly after the last bullet
> point.
I attached the changed patch. I decided to add the blank lines
according to these "guidelines":
- One blank line at the end for every .c/.h file
- One blank line if the file ends with a "bullet point" or something
similiar
- No blank line at the end in any other case.
If you prefer something else, just let me know and I'll change it.
Florian
--
() ascii ribbon campaign - stop html mail www.asciiribbon.org
/\ www.the-compiler.org | I love long mails http://email.is-not-s.ms/
Man is a military animal, glories in gunpowder, and loves parade. -- P.J.
Bailey
>From 1dc7c6bcdb925c4e8b028bb159868f5581a89be2 Mon Sep 17 00:00:00 2001
From: Florian Bruhin <git _at_ the _minus_ compiler _dot_ org>
Date: Wed, 31 Oct 2012 19:13:29 +0100
Subject: [PATCH] Whitespace fixes
- Change tabs to four spaces in herbstcommander.sh
- Remove empty lines from beginning/end of files (unless it's a .c/.h file or
ends with a bullet point) respectively change multiple blank lines at the end
of a file to one
- Remove whitespace at the end of a line,
- Try to get whitespaces for #include/#define's consistent
- Try to get whitespace between functions consistent
(always 1 blank line instead of 0/1/2)
---
.gitignore | 1 -
Makefile | 1 -
README | 1 -
colors.mk | 3 --
config.mk | 1 -
doc/herbstluftwm-tutorial.txt | 3 --
ipc-client/ipc-client.h | 1 -
release.sh | 1 -
scripts/dmenu.sh | 1 -
scripts/dumpbeautify.sh | 3 --
scripts/exec_on_tag.sh | 2 -
scripts/execwith.sh | 1 -
scripts/herbstcommander.sh | 104 +++++++++++++++++++++---------------------
scripts/keychain.sh | 1 -
scripts/lasttag.sh | 3 --
scripts/layout.sh | 2 -
scripts/loadstate.sh | 2 -
scripts/savestate.sh | 2 -
scripts/wselect.sh | 1 -
share/_herbstclient | 1 -
share/autostart | 1 -
share/herbstclient-completion | 3 --
share/herbstluftwm.xpm | 1 -
share/panel.sh | 2 -
share/restartpanels.sh | 1 -
src/clientlist.c | 2 -
src/clientlist.h | 2 -
src/command.c | 2 -
src/command.h | 1 -
src/ewmh.c | 1 +
src/globals.h | 3 --
src/hook.c | 2 -
src/hook.h | 1 -
src/ipc-protocol.h | 2 -
src/ipc-server.h | 1 -
src/layout.c | 5 +-
src/layout.h | 2 +-
src/main.c | 22 +++++----
src/monitor.c | 3 +-
src/mouse.c | 2 -
src/mouse.h | 1 -
src/rules.c | 3 --
src/rules.h | 1 -
src/settings.c | 3 --
src/settings.h | 1 -
src/stack.c | 2 +-
src/stack.h | 3 --
src/tag.c | 1 -
src/utils.c | 5 +-
src/utils.h | 2 -
version.mk | 2 -
www/Makefile | 2 -
www/compose.sh | 1 -
www/faq.txt | 1 -
www/footer.txt | 1 -
www/header.txt | 2 -
www/index.txt | 10 ++--
www/install.sh | 5 --
www/main.css | 4 +-
59 files changed, 79 insertions(+), 165 deletions(-)
diff --git a/.gitignore b/.gitignore
index 3a11281..25f4a50 100644
--- a/.gitignore
+++ b/.gitignore
@@ -21,4 +21,3 @@ doc/herbstluftwm.html
# ignore build dirs
build/
etc/
-
diff --git a/Makefile b/Makefile
index e26e752..bd3be6c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,3 @@
-
include version.mk
include config.mk
include colors.mk
diff --git a/README b/README
index 1d3b549..ce0e5f5 100644
--- a/README
+++ b/README
@@ -91,4 +91,3 @@ add mod4 = Meta_L
clear mod1
add mod1 = Alt_L
--- snap ---
-
diff --git a/colors.mk b/colors.mk
index c0b9c10..824fbf0 100644
--- a/colors.mk
+++ b/colors.mk
@@ -1,4 +1,3 @@
-
# colors
ifeq ($(COLOR),1)
TPUT = tput
@@ -12,5 +11,3 @@ endif
define colorecho
@echo $(COLOR_BRACKET)" ["$(COLOR_ACTION)$1$(COLOR_BRACKET)"] " $(COLOR_FILE)$2$(COLOR_BRACKET)... $(COLOR_NORMAL)
endef
-
-
diff --git a/config.mk b/config.mk
index 7653ce3..2b18e15 100644
--- a/config.mk
+++ b/config.mk
@@ -1,4 +1,3 @@
-
# paths
X11INC = /usr/X11R6/include
X11LIB = /usr/X11R6/lib
diff --git a/doc/herbstluftwm-tutorial.txt b/doc/herbstluftwm-tutorial.txt
index 220fe83..fe32a49 100644
--- a/doc/herbstluftwm-tutorial.txt
+++ b/doc/herbstluftwm-tutorial.txt
@@ -182,7 +182,4 @@ configuration workflow:
autostart file from your shell to get the error messages if something went
wrong.
-
-
-
// vim: tw=80 ft=asciidoc
diff --git a/ipc-client/ipc-client.h b/ipc-client/ipc-client.h
index ed61230..dffea14 100644
--- a/ipc-client/ipc-client.h
+++ b/ipc-client/ipc-client.h
@@ -22,4 +22,3 @@ bool hc_send_command_once(int argc, char* argv[],
bool hc_hook_window_connect(HCConnection* con);
bool hc_next_hook(HCConnection* con, int* argc, char** argv[]);
-
diff --git a/release.sh b/release.sh
index 02a0e87..0dfe845 100755
--- a/release.sh
+++ b/release.sh
@@ -57,4 +57,3 @@ echo "1. Add the following line to the MD5SUMS file on the mirror:"
md5sum $tarball
echo "2. Make www files and install them on the remote"
echo "3. Push the changes to all public remotes (including --tags)"
-
diff --git a/scripts/dmenu.sh b/scripts/dmenu.sh
index e85e133..24bd556 100755
--- a/scripts/dmenu.sh
+++ b/scripts/dmenu.sh
@@ -13,4 +13,3 @@ simple_command() {
}
simple_command "$1"
-
diff --git a/scripts/dumpbeautify.sh b/scripts/dumpbeautify.sh
index 29a0175..3301306 100755
--- a/scripts/dumpbeautify.sh
+++ b/scripts/dumpbeautify.sh
@@ -58,6 +58,3 @@ clear=$(tput sgr0) || clear=$(echo -e '\e[0m')
sed 's/\([()]\)/\n\1/g' | # insert newlines before (
awk "$awkcode" |
sed 's#(#('"$clear"'#g'
-
-
-
diff --git a/scripts/exec_on_tag.sh b/scripts/exec_on_tag.sh
index 7510661..5c552db 100755
--- a/scripts/exec_on_tag.sh
+++ b/scripts/exec_on_tag.sh
@@ -1,6 +1,5 @@
#!/bin/bash
-
TAG="$1"
EXPIRE="120" # expiry time in seconds
shift
@@ -32,4 +31,3 @@ hc add "$TAG"
hc rule maxage="$EXPIRE" pid="$$" tag="$TAG" once
exec "$@"
-
diff --git a/scripts/execwith.sh b/scripts/execwith.sh
index ca6564c..775197d 100755
--- a/scripts/execwith.sh
+++ b/scripts/execwith.sh
@@ -7,4 +7,3 @@
source "$1"
shift
exec "$@"
-
diff --git a/scripts/herbstcommander.sh b/scripts/herbstcommander.sh
index f15deac..244d286 100755
--- a/scripts/herbstcommander.sh
+++ b/scripts/herbstcommander.sh
@@ -25,57 +25,57 @@ cmd=( "$@" )
forceexec=0
while :; do
- dmenu_args=""
- if [[ "$forceexec" != 1 ]]; then
- completion=$($herbstclient_cmd complete "${#cmd[ _at_ ]}" "${cmd[ _at_ ]}")
- if [[ "$?" = 7 ]] ; then
- forceexec=1
- fi
- fi
- if [[ "$forceexec" == 1 ]]; then
- echo "Executing ${cmd[ _at_ ]}"
- reply=$($herbstclient_cmd "${cmd[ _at_ ]}")
- status=$?
- if [[ "$display_reply" && "$reply" ]]; then
- $dmenu_cmd -p "${cmd[*]}" <<< "$reply" >/dev/null
- fi
- exit $status
- else
- case "${cmd[*]}" in
- raise|jumpto|bring)
- tags=( $($herbstclient_cmd tag_status) )
- i=1
- completion=$(
- wmctrl -l | while read line; do
- fields=( $line )
- id=${fields[0]}
- tag=${tags[ ${fields[1]} ]}
- class=$(xprop -notype -id $id WM_CLASS |
- sed 's/.*\?= *//; s/"\(.*\?\)", *"\(.*\?\)".*/\1,\2/')
- title=${fields[ _at_ ]:3}
- printf "%-3s %s %-3s [%s] %s\n" "$i)" "$id" "$tag" "$class" "$title"
- i=$((i+1))
- done
- )
+ dmenu_args=""
+ if [[ "$forceexec" != 1 ]]; then
+ completion=$($herbstclient_cmd complete "${#cmd[ _at_ ]}" "${cmd[ _at_ ]}")
+ if [[ "$?" = 7 ]] ; then
+ forceexec=1
+ fi
+ fi
+ if [[ "$forceexec" == 1 ]]; then
+ echo "Executing ${cmd[ _at_ ]}"
+ reply=$($herbstclient_cmd "${cmd[ _at_ ]}")
+ status=$?
+ if [[ "$display_reply" && "$reply" ]]; then
+ $dmenu_cmd -p "${cmd[*]}" <<< "$reply" >/dev/null
+ fi
+ exit $status
+ else
+ case "${cmd[*]}" in
+ raise|jumpto|bring)
+ tags=( $($herbstclient_cmd tag_status) )
+ i=1
+ completion=$(
+ wmctrl -l | while read line; do
+ fields=( $line )
+ id=${fields[0]}
+ tag=${tags[ ${fields[1]} ]}
+ class=$(xprop -notype -id $id WM_CLASS |
+ sed 's/.*\?= *//; s/"\(.*\?\)", *"\(.*\?\)".*/\1,\2/')
+ title=${fields[ _at_ ]:3}
+ printf "%-3s %s %-3s [%s] %s\n" "$i)" "$id" "$tag" "$class" "$title"
+ i=$((i+1))
+ done
+ )
- dmenu_args="-l 10"
- ;;
- esac
- next=$($dmenu_cmd $dmenu_args -p "${prompt}${cmd[*]}" <<< "$completion")
- (( $? != 0 )) && exit 125 # dmenu was killed
- if [[ -z "$next" ]]; then
- forceexec=1 # empty reply instead of completion
- else
- case "${cmd[*]}" in
- raise|jumpto|bring)
- # add the WINID only (second field)
- fields=( $next )
- cmd+=( ${fields[1]} )
- ;;
- *)
- cmd+=( $next )
- ;;
- esac
- fi
- fi
+ dmenu_args="-l 10"
+ ;;
+ esac
+ next=$($dmenu_cmd $dmenu_args -p "${prompt}${cmd[*]}" <<< "$completion")
+ (( $? != 0 )) && exit 125 # dmenu was killed
+ if [[ -z "$next" ]]; then
+ forceexec=1 # empty reply instead of completion
+ else
+ case "${cmd[*]}" in
+ raise|jumpto|bring)
+ # add the WINID only (second field)
+ fields=( $next )
+ cmd+=( ${fields[1]} )
+ ;;
+ *)
+ cmd+=( $next )
+ ;;
+ esac
+ fi
+ fi
done
diff --git a/scripts/keychain.sh b/scripts/keychain.sh
index 73d3801..54c6618 100755
--- a/scripts/keychain.sh
+++ b/scripts/keychain.sh
@@ -40,4 +40,3 @@ herbstclient keybind Mod4-i chain \
'->' keybind "${keys[8]}" chain "${unbind[ _at_ ]}" , use_index 8 \
'->' keybind "${keys[9]}" chain "${unbind[ _at_ ]}" , use_index 9 \
'->' keybind Escape chain "${unbind[ _at_ ]}"
-
diff --git a/scripts/lasttag.sh b/scripts/lasttag.sh
index 98c6879..c329227 100755
--- a/scripts/lasttag.sh
+++ b/scripts/lasttag.sh
@@ -22,6 +22,3 @@ herbstclient --idle '(tag_changed|goto_last_tag|reload)' \
;;
esac
done
-
-
-
diff --git a/scripts/layout.sh b/scripts/layout.sh
index b59e0ac..c631a84 100755
--- a/scripts/layout.sh
+++ b/scripts/layout.sh
@@ -14,5 +14,3 @@ while read tag ; do
| sed "2,\$ s/^/$indent/" \
| sed "s/\(0x[0-9a-f]\{1,\}\)/$(tput setaf 3)\1$(tput sgr0)/g"
done
-
-
diff --git a/scripts/loadstate.sh b/scripts/loadstate.sh
index 91583f3..42a7d37 100755
--- a/scripts/loadstate.sh
+++ b/scripts/loadstate.sh
@@ -16,5 +16,3 @@ while read line ; do
$hc add "$tag"
$hc load "$tag" "$tree"
done
-
-
diff --git a/scripts/savestate.sh b/scripts/savestate.sh
index 858ee33..b717f46 100755
--- a/scripts/savestate.sh
+++ b/scripts/savestate.sh
@@ -15,5 +15,3 @@ while read tag ; do
echo -n "$tag: "
$hc dump "$tag"
done
-
-
diff --git a/scripts/wselect.sh b/scripts/wselect.sh
index 63517f4..fee2847 100755
--- a/scripts/wselect.sh
+++ b/scripts/wselect.sh
@@ -25,4 +25,3 @@ esac
id=$(wmctrl -l |cat -n| sed 's/\t/) /g'| sed 's/^[ ]*//' \
| $dmenu_command -l $dmenu_lines -p "$name") \
&& action $(awk '{ print $2 ; }' <<< "$id")
-
diff --git a/share/_herbstclient b/share/_herbstclient
index 0741da6..8b45d07 100644
--- a/share/_herbstclient
+++ b/share/_herbstclient
@@ -10,4 +10,3 @@ _herbstclient() {
}
compdef _herbstclient herbstclient
-
diff --git a/share/autostart b/share/autostart
index 680f67e..627153e 100755
--- a/share/autostart
+++ b/share/autostart
@@ -125,4 +125,3 @@ for monitor in $(herbstclient list_monitors | cut -d: -f1) ; do
# start it on each monitor
$panel $monitor &
done
-
diff --git a/share/herbstclient-completion b/share/herbstclient-completion
index 3140c82..e20012c 100644
--- a/share/herbstclient-completion
+++ b/share/herbstclient-completion
@@ -1,6 +1,5 @@
# bash completion for herbstclient
-
_herbstclient_complete() {
COMPREPLY=(
# just call the herbstclient complete .. but without herbstclient as argument
@@ -8,6 +7,4 @@ _herbstclient_complete() {
)
}
-
complete -F _herbstclient_complete herbstclient
-
diff --git a/share/herbstluftwm.xpm b/share/herbstluftwm.xpm
index 6b06773..c6b571e 100644
--- a/share/herbstluftwm.xpm
+++ b/share/herbstluftwm.xpm
@@ -21,4 +21,3 @@ static char* HERBSTLUFTWM[] = {
" .llll. ",
" .lllll. ",
" ..... "};
-
diff --git a/share/panel.sh b/share/panel.sh
index dc323d1..e22a1ce 100755
--- a/share/panel.sh
+++ b/share/panel.sh
@@ -142,5 +142,3 @@ herbstclient pad $monitor $panel_height
done
} 2> /dev/null | dzen2 -w $panel_width -x $x -y $y -fn "$font" -h $panel_height \
-ta l -bg "$bgcolor" -fg '#efefef'
-
-
diff --git a/share/restartpanels.sh b/share/restartpanels.sh
index bd22694..320a3fe 100755
--- a/share/restartpanels.sh
+++ b/share/restartpanels.sh
@@ -14,4 +14,3 @@ herbstclient emit_hook quit_panel
for i in $(herbstclient list_monitors|cut -d':' -f1) ; do
$panelcmd $i &
done
-
diff --git a/src/clientlist.c b/src/clientlist.c
index b75662f..c69dbb0 100644
--- a/src/clientlist.c
+++ b/src/clientlist.c
@@ -43,7 +43,6 @@ unsigned long g_window_border_inner_color;
GHashTable* g_clients; // container of all clients
-
// atoms from dwm.c
// default atoms
enum { WMProtocols, WMDelete, WMState, WMTakeFocus, WMLast };
@@ -786,4 +785,3 @@ bool client_sendevent(HSClient *client, Atom proto) {
return exists;
}
-
diff --git a/src/clientlist.h b/src/clientlist.h
index 27c00b8..05faa2c 100644
--- a/src/clientlist.h
+++ b/src/clientlist.h
@@ -3,7 +3,6 @@
* This software is licensed under the "Simplified BSD License".
* See LICENSE for details */
-
#ifndef __CLIENTLIST_H_
#define __CLIENTLIST_H_
@@ -89,4 +88,3 @@ unsigned long get_window_border_color(HSClient* client);
#endif
-
diff --git a/src/command.c b/src/command.c
index 27bba8f..54296c9 100644
--- a/src/command.c
+++ b/src/command.c
@@ -221,7 +221,6 @@ int call_command_no_output(int argc, char** argv) {
return status;
}
-
int list_commands(int argc, char** argv, GString* output)
{
int i = 0;
@@ -290,7 +289,6 @@ void complete_against_winids(int argc, char** argv, int pos, GString* output) {
clientlist_foreach((GHFunc)add_winid_completion, &data);
}
-
void complete_merge_tag(int argc, char** argv, int pos, GString* output) {
char* first = (argc >= 1) ? argv[1] : "";
char* needle;
diff --git a/src/command.h b/src/command.h
index 91f92b7..200420a 100644
--- a/src/command.h
+++ b/src/command.h
@@ -22,7 +22,6 @@ typedef int (*HerbstCmdNoOutput)(int argc, // number of arguments
#define CMD_BIND_NO_OUTPUT(NAME, FUNC) \
{ .cmd = { .no_output = (FUNC) }, .name = (NAME), .has_output = 0 }
-
typedef struct CommandBinding {
union {
HerbstCmd standard;
diff --git a/src/ewmh.c b/src/ewmh.c
index f9df8b6..eb61634 100644
--- a/src/ewmh.c
+++ b/src/ewmh.c
@@ -417,3 +417,4 @@ void ewmh_set_window_opacity(Window win, double opacity) {
XChangeProperty(g_display, win, g_netatom[NetWmWindowOpacity], XA_CARDINAL,
32, PropModeReplace, (unsigned char*)&int_opacity, 1);
}
+
diff --git a/src/globals.h b/src/globals.h
index f1c7647..20bb4a1 100644
--- a/src/globals.h
+++ b/src/globals.h
@@ -42,7 +42,6 @@ int g_verbose;
// size for some normal string buffers
#define STRING_BUF_SIZE 1000
-
#define HSDebug(...) \
do { \
if (g_verbose) { \
@@ -53,5 +52,3 @@ int g_verbose;
#endif
-
-
diff --git a/src/hook.c b/src/hook.c
index b27fa3d..2d88427 100644
--- a/src/hook.c
+++ b/src/hook.c
@@ -19,7 +19,6 @@
#include <X11/Xutil.h>
#include <X11/Xatom.h>
-
static Window g_event_window;
void hook_init() {
@@ -43,7 +42,6 @@ void hook_destroy() {
XDestroyWindow(g_display, g_event_window);
}
-
void hook_emit(int argc, char** argv) {
static int last_property_number = 0;
if (argc <= 0) {
diff --git a/src/hook.h b/src/hook.h
index 6fbbe08..5dff716 100644
--- a/src/hook.h
+++ b/src/hook.h
@@ -3,7 +3,6 @@
* This software is licensed under the "Simplified BSD License".
* See LICENSE for details */
-
#ifndef __HERBSTLUFT_HOOK_H_
#define __HERBSTLUFT_HOOK_H_
diff --git a/src/ipc-protocol.h b/src/ipc-protocol.h
index 322f425..effa207 100644
--- a/src/ipc-protocol.h
+++ b/src/ipc-protocol.h
@@ -6,7 +6,6 @@
#ifndef __HERBST_IPC_PROTOCOL_H_
#define __HERBST_IPC_PROTOCOL_H_
-
#define HERBST_IPC_CLASS "HERBST_IPC_CLASS"
//#define HERBST_IPC_READY "HERBST_IPC_READY"
//#define HERBST_IPC_ATOM "_HERBST_IPC"
@@ -20,7 +19,6 @@
// maximum number of hooks to buffer
#define HERBST_HOOK_PROPERTY_COUNT 10
-
// function exit codes
enum {
HERBST_EXIT_SUCCESS = 0,
diff --git a/src/ipc-server.h b/src/ipc-server.h
index 2fe2b3e..db52352 100644
--- a/src/ipc-server.h
+++ b/src/ipc-server.h
@@ -9,7 +9,6 @@
#include <X11/Xlib.h>
#include <stdbool.h>
-
void ipc_init();
void ipc_destroy();
diff --git a/src/layout.c b/src/layout.c
index 40ced50..57ddcd5 100644
--- a/src/layout.c
+++ b/src/layout.c
@@ -3,7 +3,6 @@
* This software is licensed under the "Simplified BSD License".
* See LICENSE for details */
-
#include "clientlist.h"
#include "globals.h"
#include "utils.h"
@@ -13,12 +12,14 @@
#include "settings.h"
#include "layout.h"
#include "stack.h"
+
#include <glib.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <assert.h>
#include <stdint.h>
+
#include <X11/Xutil.h>
#include <X11/Xatom.h>
#include <X11/Xlib.h>
@@ -1725,7 +1726,6 @@ int frame_foreach_client(HSFrame* frame, ClientAction action, void* data) {
return 0;
}
-
void frame_update_border(Window window, unsigned long color) {
if (*g_frame_border_inner_width > 0 && *g_frame_border_inner_width < *g_frame_border_width) {
set_window_double_border(g_display, window, *g_frame_border_inner_width, g_frame_border_inner_color, color);
@@ -1733,3 +1733,4 @@ void frame_update_border(Window window, unsigned long color) {
XSetWindowBorder(g_display, window, color);
}
}
+
diff --git a/src/layout.h b/src/layout.h
index 3d086ce..997de78 100644
--- a/src/layout.h
+++ b/src/layout.h
@@ -20,6 +20,7 @@
#define TAG_SET_FLAG(tag, flag) \
((tag)->flags |= (flag))
+
enum {
TAG_FLAG_URGENT = 0x01, // is there a urgent window?
TAG_FLAG_USED = 0x02, // the oposit of empty
@@ -171,4 +172,3 @@ void frame_update_border(Window window, unsigned long color);
#endif
-
diff --git a/src/main.c b/src/main.c
index e6b0811..07be5e6 100644
--- a/src/main.c
+++ b/src/main.c
@@ -352,7 +352,6 @@ int jumpto_command(int argc, char** argv) {
return 0;
}
-
// handle x-events:
void event_on_configure(XEvent event) {
@@ -397,7 +396,6 @@ void event_on_configure(XEvent event) {
}
}
-
// from dwm.c
/* There's no way to check accesses to destroyed windows, thus those cases are
* ignored (especially on UnmapNotify's). Other types of errors call Xlibs
@@ -425,7 +423,6 @@ int xerror(Display *dpy, XErrorEvent *ee) {
return g_xerrorxlib(dpy, ee); /* may call exit */
}
-
int xerrordummy(Display *dpy, XErrorEvent *ee) {
return 0;
}
@@ -438,7 +435,6 @@ int xerrorstart(Display *dpy, XErrorEvent *ee) {
return -1;
}
-
// from dwm.c
void checkotherwm(void) {
g_otherwm = False;
@@ -452,7 +448,6 @@ void checkotherwm(void) {
XSync(g_display, False);
}
-
// scan for windows and add them to the list of managed clients
// from dwm.c
void scan(void) {
@@ -655,10 +650,12 @@ void createnotify(XEvent* event) {
ipc_add_connection(event->xcreatewindow.window);
}
}
+
void configurerequest(XEvent* event) {
HSDebug("name is: ConfigureRequest\n");
event_on_configure(*event);
}
+
void configurenotify(XEvent* event) {
if (event->xconfigure.window == g_root &&
settings_find("auto_detect_monitors")->value.i) {
@@ -667,10 +664,12 @@ void configurenotify(XEvent* event) {
}
// HSDebug("name is: ConfigureNotify\n");
}
+
void destroynotify(XEvent* event) {
// try to unmanage it
unmanage_client(event->xdestroywindow.window);
}
+
void enternotify(XEvent* event) {
XCrossingEvent *ce = &event->xcrossing;
HSDebug("name is: EnterNotify, focus = %d\n", event->xcrossing.focus);
@@ -681,16 +680,20 @@ void enternotify(XEvent* event) {
focus_window(ce->window, false, true);
}
}
+
void expose(XEvent* event) {
HSDebug("name is: Expose\n");
}
+
void focusin(XEvent* event) {
HSDebug("name is: FocusIn\n");
}
+
void keypress(XEvent* event) {
HSDebug("name is: KeyPress\n");
handle_key_press(event);
}
+
void mappingnotify(XEvent* event) {
{
// regrab when keyboard map changes
@@ -702,9 +705,11 @@ void mappingnotify(XEvent* event) {
}
}
}
+
void motionnotify(XEvent* event) {
handle_motion_event(event);
}
+
void mapnotify(XEvent* event) {
HSDebug("name is: MapNotify\n");
HSClient* c;
@@ -716,6 +721,7 @@ void mapnotify(XEvent* event) {
client_update_title(c);
}
}
+
void maprequest(XEvent* event) {
HSDebug("name is: MapRequest\n");
XMapRequestEvent* mapreq = &event->xmaprequest;
@@ -739,7 +745,7 @@ void maprequest(XEvent* event) {
}
void propertynotify(XEvent* event) {
- // printf("name is: PropertyNotify\n");
+ // printf("name is: PropertyNotify\n");
XPropertyEvent *ev = &event->xproperty;
HSClient* client;
if (ev->state == PropertyNewValue) {
@@ -759,12 +765,12 @@ void propertynotify(XEvent* event) {
}
}
}
+
void unmapnotify(XEvent* event) {
HSDebug("name is: UnmapNotify for %lx\n", event->xunmap.window);
unmanage_client(event->xunmap.window);
}
-
/* ---- */
/* main */
/* ---- */
@@ -846,5 +852,3 @@ int main(int argc, char* argv[]) {
return EXIT_SUCCESS;
}
-
-
diff --git a/src/monitor.c b/src/monitor.c
index d815329..105e701 100644
--- a/src/monitor.c
+++ b/src/monitor.c
@@ -2,6 +2,7 @@
*
* This software is licensed under the "Simplified BSD License".
* See LICENSE for details */
+
#include <assert.h>
#include <string.h>
#include <stdio.h>
@@ -57,7 +58,6 @@ void monitor_destroy() {
g_array_free(g_monitors, true);
}
-
void monitor_apply_layout(HSMonitor* monitor) {
if (monitor) {
if (*g_monitors_locked) {
@@ -843,7 +843,6 @@ int monitor_unlock_tag_command(int argc, char** argv) {
return 0;
}
-
// monitor detection using xinerama (if available)
#ifdef XINERAMA
// inspired by dwm's isuniquegeom()
diff --git a/src/mouse.c b/src/mouse.c
index d5cd91f..158eb35 100644
--- a/src/mouse.c
+++ b/src/mouse.c
@@ -12,7 +12,6 @@
#include "utils.h"
#include "settings.h"
-
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
@@ -25,7 +24,6 @@
#include <X11/Xatom.h>
#include <X11/cursorfont.h>
-
static XButtonPressedEvent g_button_drag_start;
static XRectangle g_win_drag_start;
static HSClient* g_win_drag_client = NULL;
diff --git a/src/mouse.h b/src/mouse.h
index 18426f4..e39aa3f 100644
--- a/src/mouse.h
+++ b/src/mouse.h
@@ -66,6 +66,5 @@ void mouse_function_move(XMotionEvent* me);
void mouse_function_resize(XMotionEvent* me);
void mouse_function_zoom(XMotionEvent* me);
-
#endif
diff --git a/src/rules.c b/src/rules.c
index a7b09cc..029d7a7 100644
--- a/src/rules.c
+++ b/src/rules.c
@@ -15,7 +15,6 @@
#include <stdio.h>
#include <sys/types.h>
-
/// TYPES ///
typedef struct {
@@ -501,7 +500,6 @@ bool condition_title(HSCondition* rule, HSClient* client) {
return condition_string(rule, client->title->str);
}
-
bool condition_pid(HSCondition* rule, HSClient* client) {
if (client->pid < 0) {
return false;
@@ -628,4 +626,3 @@ void consequence_ewmhrequests(HSConsequence* cons, HSClient* client,
client->ewmhrequests = string_to_bool(cons->value.str, client->ewmhrequests);
}
-
diff --git a/src/rules.h b/src/rules.h
index 5f4e35c..736040d 100644
--- a/src/rules.h
+++ b/src/rules.h
@@ -73,6 +73,5 @@ void rule_destroy(HSRule* rule);
int rule_add_command(int argc, char** argv);
int rule_remove_command(int argc, char** argv);
-
#endif
diff --git a/src/settings.c b/src/settings.c
index 9aad254..eba6414 100644
--- a/src/settings.c
+++ b/src/settings.c
@@ -3,7 +3,6 @@
* This software is licensed under the "Simplified BSD License".
* See LICENSE for details */
-
#include "globals.h"
#include "settings.h"
#include "clientlist.h"
@@ -111,7 +110,6 @@ void settings_destroy() {
}
}
-
SettingsPair* settings_find(char* name) {
return STATIC_TABLE_FIND_STR(SettingsPair, g_settings, name, name);
}
@@ -171,7 +169,6 @@ int settings_get(int argc, char** argv, GString* output) {
return 0;
}
-
// toggle integer-like values
int settings_toggle(int argc, char** argv) {
if (argc < 2) {
diff --git a/src/settings.h b/src/settings.h
index 5ef2660..7b28803 100644
--- a/src/settings.h
+++ b/src/settings.h
@@ -39,6 +39,5 @@ int settings_cycle_value(int argc, char** argv);
int settings_count();
int settings_get(int argc, char** argv, GString* output);
-
#endif
diff --git a/src/stack.c b/src/stack.c
index c7462f8..bd7f4a9 100644
--- a/src/stack.c
+++ b/src/stack.c
@@ -4,6 +4,7 @@
#include "ewmh.h"
#include "globals.h"
#include "utils.h"
+
#include <stdio.h>
#include <string.h>
#include <assert.h>
@@ -104,7 +105,6 @@ void stack_remove_slice(HSStack* s, HSSlice* elem) {
s->dirty = true;
}
-
static void slice_append_caption(HSTree root, GString* result) {
HSSlice* slice = (HSSlice*)root;
switch (slice->type) {
diff --git a/src/stack.h b/src/stack.h
index bc3e9c4..a4934b8 100644
--- a/src/stack.h
+++ b/src/stack.h
@@ -47,7 +47,6 @@ typedef struct HSStack {
bool dirty; /* stacking order changed but it wasn't restacked yet */
} HSStack;
-
void stacklist_init();
void stacklist_destroy();
@@ -78,7 +77,5 @@ Window stack_lowest_window(HSStack* stack);
HSStack* stack_create();
void stack_destroy(HSStack* s);
-
-
#endif
diff --git a/src/tag.c b/src/tag.c
index 2059683..1c2fd40 100644
--- a/src/tag.c
+++ b/src/tag.c
@@ -418,4 +418,3 @@ void tag_update_each_focus_layer() {
tag_foreach(tag_update_focus_layer);
}
-
diff --git a/src/utils.c b/src/utils.c
index c460966..793fe93 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -17,8 +17,6 @@
#include <X11/Xatom.h>
#include <glib.h>
-
-
#include <time.h>
#include <sys/time.h>
@@ -27,10 +25,8 @@
#include <mach/mach.h>
#endif
-
char* g_tree_style; /* the one from layout.c */
-
time_t get_monotonic_timestamp() {
struct timespec ts;
#if defined(__MACH__) && ! defined(CLOCK_REALTIME) // OS X does not have clock_gettime, use clock_get_time
@@ -440,3 +436,4 @@ int min(int a, int b) {
return a;
return b;
}
+
diff --git a/src/utils.h b/src/utils.h
index d79974e..3115b96 100644
--- a/src/utils.h
+++ b/src/utils.h
@@ -16,7 +16,6 @@
#define SHIFT(ARGC, ARGV) (--(ARGC) && ++(ARGV))
#define MOD(X, N) ((((X) % (signed)(N)) + (signed)(N)) % (signed)(N))
-
/// print a printf-like message to stderr and exit
void die(const char *errstr, ...);
@@ -110,4 +109,3 @@ void set_window_double_border(Display *dpy, Window win, int ibw,
#endif
-
diff --git a/version.mk b/version.mk
index a0bef2f..69110c3 100644
--- a/version.mk
+++ b/version.mk
@@ -1,4 +1,3 @@
-
# version is major.minor.patchlevel$suffix
VERSION_MAJOR = 0
@@ -7,4 +6,3 @@ VERSION_MINOR = 4
VERSION_PATCH = 1
VERSION_SUFFIX = ""
VERSION = $(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_PATCH)$(VERSION_SUFFIX)
-
diff --git a/www/Makefile b/www/Makefile
index 7e5d933..7b7c0b0 100644
--- a/www/Makefile
+++ b/www/Makefile
@@ -33,5 +33,3 @@ clean:
install:
@echo scp index.html main.css $(TARGET)
-
-
diff --git a/www/compose.sh b/www/compose.sh
index 084c12a..572be81 100755
--- a/www/compose.sh
+++ b/www/compose.sh
@@ -95,4 +95,3 @@ cat <<EOF
</body>
</html>
EOF
-
diff --git a/www/faq.txt b/www/faq.txt
index 79a8afb..c4afe74 100644
--- a/www/faq.txt
+++ b/www/faq.txt
@@ -191,4 +191,3 @@ Q: I set default_frame_layout to my favorite layout but it doesn't work with the
ones), so be sure to set it *before* creating any tags. A current
workaround is to put +hc split vertical 0.5; hc remove+ at the end in your
autostart file. You can also 'cycle_layout' in existing tags.
-
diff --git a/www/footer.txt b/www/footer.txt
index 4ca726c..f9a2a65 100644
--- a/www/footer.txt
+++ b/www/footer.txt
@@ -4,4 +4,3 @@ Imprint
Thorsten Wißmann,
+edu \_at_ thorsten \_minus_ wissmann \_dot_ de+,
November 2011-2012
-
diff --git a/www/header.txt b/www/header.txt
index 873f897..c9390cf 100644
--- a/www/header.txt
+++ b/www/header.txt
@@ -6,5 +6,3 @@ link:index.html[About]
link:news.html[NEWS]
link:faq.html[FAQ]
****
-
-
diff --git a/www/index.txt b/www/index.txt
index 6665f13..08a6b7d 100644
--- a/www/index.txt
+++ b/www/index.txt
@@ -92,10 +92,10 @@ Screenshots
-----------
// there screenshots are not in the git repo, so they must exist in the target
// directory
-image:irc-layout-tab-thumb.png["scr",link="irc-layout-tab.png"]
-image:herbstluftwm-autumncolors-thumb.png["scr",link="herbstluftwm-autumncolors.png"]
-image:../screenshots/hlwm-panelicons-0-thumb.png["scr",link="../screenshots/hlwm-panelicons-0.png"]
-image:../screenshots/hlwm-panelicons-1-thumb.png["scr",link="../screenshots/hlwm-panelicons-1.png"]
-image:../screenshots/hlwm-pseudotile-1-thumb.png["scr",link="../screenshots/hlwm-pseudotile-1.png"]
+image:irc-layout-tab-thumb.png["scr",link="irc-layout-tab.png"]
+image:herbstluftwm-autumncolors-thumb.png["scr",link="herbstluftwm-autumncolors.png"]
+image:../screenshots/hlwm-panelicons-0-thumb.png["scr",link="../screenshots/hlwm-panelicons-0.png"]
+image:../screenshots/hlwm-panelicons-1-thumb.png["scr",link="../screenshots/hlwm-panelicons-1.png"]
+image:../screenshots/hlwm-pseudotile-1-thumb.png["scr",link="../screenshots/hlwm-pseudotile-1.png"]
// vim: nowrap
diff --git a/www/install.sh b/www/install.sh
index 3aa9899..0e48265 100755
--- a/www/install.sh
+++ b/www/install.sh
@@ -12,8 +12,3 @@ files=(
)
rsync -v "${files[ _at_ ]}" "$target"
-
-
-
-
-
diff --git a/www/main.css b/www/main.css
index 7e4bc9d..f3ce14c 100644
--- a/www/main.css
+++ b/www/main.css
@@ -46,7 +46,7 @@ body {
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#000000', endColorstr='#303030'); /* for IE */
background: -webkit-gradient(linear, left top, left bottom, from(#000), to(#303030)); /* for webkit browsers */
- background: -moz-linear-gradient(top, #000, #303030); /* for firefox 3.6+ */
+ background: -moz-linear-gradient(top, #000, #303030); /* for firefox 3.6+ */
text-align: center;
padding-top: 0.2em;
}
@@ -317,5 +317,3 @@ table thead th {
margin-top: 0em;
margin-bottom: 0em;
}
-
-
--
1.8.0