diff options
author | Richard Hughes <richard@hughsie.com> | 2008-05-02 14:42:51 +0100 |
---|---|---|
committer | Richard Hughes <richard@hughsie.com> | 2008-05-02 14:42:51 +0100 |
commit | f65d83cac58c109b13f0a603c6abe680c207df83 (patch) | |
tree | c508c3f1695575752789e89f836b04476c55d182 /CodingStyle | |
parent | 1007f7bcef9a9a19a81f83f5a990e085d7d35b2f (diff) |
don't winge about coding style without justification; justify it.
Diffstat (limited to 'CodingStyle')
-rw-r--r-- | CodingStyle | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/CodingStyle b/CodingStyle new file mode 100644 index 00000000..edfee010 --- /dev/null +++ b/CodingStyle @@ -0,0 +1,31 @@ +== Indent == + +Use "indent -kr -i8 -pcs -lps -psl *.c" to convert to "mostly correct" indenting levels. + +== Tabs == + +Tabs are the size of 8 spaces, and should be used in preference to spaces. + +== Overlong lines == + +Functions that are two long for one line are intented with tabs and then +spaces to the start of the bracket: + +libnotify_event ("HAL does not have PowerManagement capability", + LIBNOTIFY_URGENCY_CRITICAL, NULL); + +== Braces == + +Functions have curly brace on same line: + +if (icon == NULL) { + g_warning ("Cannot find icon"); + return FALSE; +} + +Braces not-ommitted for single line: + +if (!false) { + g_warning ("Cannot find icon"); +} + |