don’t use reversed identifiers for include guards (Thanks Markus)

Done with:

    sed -in 's/\(ifndef\|define\) _\([0-9A-Z_]*\)$/\1 I3_\2/' include/**/*.h

fixes #804
This commit is contained in:
Michael Stapelberg 2012-09-21 15:36:25 +02:00
parent f9c903ba62
commit d638e3029a
43 changed files with 86 additions and 86 deletions

View File

@ -10,8 +10,8 @@
* compile-time. * compile-time.
* *
*/ */
#ifndef _ALL_H #ifndef I3_ALL_H
#define _ALL_H #define I3_ALL_H
#include <assert.h> #include <assert.h>
#include <stdbool.h> #include <stdbool.h>

View File

@ -7,8 +7,8 @@
* assignments.c: Assignments for specific windows (for_window). * assignments.c: Assignments for specific windows (for_window).
* *
*/ */
#ifndef _ASSIGNMENTS_H #ifndef I3_ASSIGNMENTS_H
#define _ASSIGNMENTS_H #define I3_ASSIGNMENTS_H
/** /**
* Checks the list of assignments for the given window and runs all matching * Checks the list of assignments for the given window and runs all matching

View File

@ -7,8 +7,8 @@
* click.c: Button press (mouse click) events. * click.c: Button press (mouse click) events.
* *
*/ */
#ifndef _CLICK_H #ifndef I3_CLICK_H
#define _CLICK_H #define I3_CLICK_H
/** /**
* The button press X callback. This function determines whether the floating * The button press X callback. This function determines whether the floating

View File

@ -7,8 +7,8 @@
* cmdparse.y: the parser for commands you send to i3 (or bind on keys) * cmdparse.y: the parser for commands you send to i3 (or bind on keys)
* *
*/ */
#ifndef _CMDPARSE_H #ifndef I3_CMDPARSE_H
#define _CMDPARSE_H #define I3_CMDPARSE_H
char *parse_cmd(const char *new); char *parse_cmd(const char *new);

View File

@ -7,8 +7,8 @@
* commands.c: all command functions (see commands_parser.c) * commands.c: all command functions (see commands_parser.c)
* *
*/ */
#ifndef _COMMANDS_H #ifndef I3_COMMANDS_H
#define _COMMANDS_H #define I3_COMMANDS_H
#include "commands_parser.h" #include "commands_parser.h"

View File

@ -7,8 +7,8 @@
* commands.c: all command functions (see commands_parser.c) * commands.c: all command functions (see commands_parser.c)
* *
*/ */
#ifndef _COMMANDS_PARSER_H #ifndef I3_COMMANDS_PARSER_H
#define _COMMANDS_PARSER_H #define I3_COMMANDS_PARSER_H
#include <yajl/yajl_gen.h> #include <yajl/yajl_gen.h>

View File

@ -9,8 +9,8 @@
* ). * ).
* *
*/ */
#ifndef _CON_H #ifndef I3_CON_H
#define _CON_H #define I3_CON_H
/** /**
* Create a new container (and attach it to the given parent, if not NULL). * Create a new container (and attach it to the given parent, if not NULL).

View File

@ -10,8 +10,8 @@
* mode). * mode).
* *
*/ */
#ifndef _CONFIG_H #ifndef I3_CONFIG_H
#define _CONFIG_H #define I3_CONFIG_H
#include <stdbool.h> #include <stdbool.h>
#include "queue.h" #include "queue.h"

View File

@ -7,8 +7,8 @@
* include/data.h: This file defines all data structures used by i3 * include/data.h: This file defines all data structures used by i3
* *
*/ */
#ifndef _DATA_H #ifndef I3_DATA_H
#define _DATA_H #define I3_DATA_H
#define SN_API_NOT_YET_FROZEN 1 #define SN_API_NOT_YET_FROZEN 1
#include <libsn/sn-launcher.h> #include <libsn/sn-launcher.h>

View File

@ -8,8 +8,8 @@
* events. This code is from xcb-util. * events. This code is from xcb-util.
* *
*/ */
#ifndef _DEBUG_H #ifndef I3_DEBUG_H
#define _DEBUG_H #define I3_DEBUG_H
int handle_event(void *ignored, xcb_connection_t *c, xcb_generic_event_t *e); int handle_event(void *ignored, xcb_connection_t *c, xcb_generic_event_t *e);

View File

@ -7,8 +7,8 @@
* display_version.c: displays the running i3 version, runs as part of * display_version.c: displays the running i3 version, runs as part of
* i3 --moreversion. * i3 --moreversion.
*/ */
#ifndef _DISPLAY_VERSION_H #ifndef I3_DISPLAY_VERSION_H
#define _DISPLAY_VERSION_H #define I3_DISPLAY_VERSION_H
/** /**
* Connects to i3 to find out the currently running version. Useful since it * Connects to i3 to find out the currently running version. Useful since it

View File

@ -7,8 +7,8 @@
* ewmh.c: Get/set certain EWMH properties easily. * ewmh.c: Get/set certain EWMH properties easily.
* *
*/ */
#ifndef _EWMH_C #ifndef I3_EWMH_C
#define _EWMH_C #define I3_EWMH_C
/** /**
* Updates _NET_CURRENT_DESKTOP with the current desktop number. * Updates _NET_CURRENT_DESKTOP with the current desktop number.

View File

@ -8,8 +8,8 @@
* which dont support multi-monitor in a useful way) and for our testsuite. * which dont support multi-monitor in a useful way) and for our testsuite.
* *
*/ */
#ifndef _FAKE_OUTPUTS_H #ifndef I3_FAKE_OUTPUTS_H
#define _FAKE_OUTPUTS_H #define I3_FAKE_OUTPUTS_H
/** /**
* Creates outputs according to the given specification. * Creates outputs according to the given specification.

View File

@ -7,8 +7,8 @@
* floating.c: Floating windows. * floating.c: Floating windows.
* *
*/ */
#ifndef _FLOATING_H #ifndef I3_FLOATING_H
#define _FLOATING_H #define I3_FLOATING_H
#include "tree.h" #include "tree.h"

View File

@ -8,8 +8,8 @@
* ). * ).
* *
*/ */
#ifndef _HANDLERS_H #ifndef I3_HANDLERS_H
#define _HANDLERS_H #define I3_HANDLERS_H
#include <xcb/randr.h> #include <xcb/randr.h>

View File

@ -7,8 +7,8 @@
* i3.h: global variables that are used all over i3. * i3.h: global variables that are used all over i3.
* *
*/ */
#ifndef _I3_H #ifndef I3_I3_H
#define _I3_H #define I3_I3_H
#include <sys/time.h> #include <sys/time.h>
#include <sys/resource.h> #include <sys/resource.h>

View File

@ -8,8 +8,8 @@
* for the IPC interface to i3 (see docs/ipc for more information). * for the IPC interface to i3 (see docs/ipc for more information).
* *
*/ */
#ifndef _I3_IPC_H #ifndef I3_I3_IPC_H
#define _I3_IPC_H #define I3_I3_IPC_H
/* /*
* Messages from clients to i3 * Messages from clients to i3

View File

@ -7,8 +7,8 @@
* ipc.c: UNIX domain socket IPC (initialization, client handling, protocol). * ipc.c: UNIX domain socket IPC (initialization, client handling, protocol).
* *
*/ */
#ifndef _IPC_H #ifndef I3_IPC_H
#define _IPC_H #define I3_IPC_H
#include <ev.h> #include <ev.h>
#include <stdbool.h> #include <stdbool.h>

View File

@ -7,8 +7,8 @@
* key_press.c: key press handler * key_press.c: key press handler
* *
*/ */
#ifndef _KEY_PRESS_H #ifndef I3_KEY_PRESS_H
#define _KEY_PRESS_H #define I3_KEY_PRESS_H
/** /**
* There was a key press. We compare this key code with our bindings table and pass * There was a key press. We compare this key code with our bindings table and pass

View File

@ -8,8 +8,8 @@
* as i3-msg, i3-config-wizard, * as i3-msg, i3-config-wizard,
* *
*/ */
#ifndef _LIBI3_H #ifndef I3_LIBI3_H
#define _LIBI3_H #define I3_LIBI3_H
#include <stdbool.h> #include <stdbool.h>
#include <stdarg.h> #include <stdarg.h>

View File

@ -8,8 +8,8 @@
* restart. * restart.
* *
*/ */
#ifndef _LOAD_LAYOUT_H #ifndef I3_LOAD_LAYOUT_H
#define _LOAD_LAYOUT_H #define I3_LOAD_LAYOUT_H
void tree_append_json(const char *filename); void tree_append_json(const char *filename);

View File

@ -7,8 +7,8 @@
* log.c: Logging functions. * log.c: Logging functions.
* *
*/ */
#ifndef _LOG_H #ifndef I3_LOG_H
#define _LOG_H #define I3_LOG_H
#include <stdarg.h> #include <stdarg.h>
#include <stdbool.h> #include <stdbool.h>

View File

@ -7,8 +7,8 @@
* manage.c: Initially managing new windows (or existing ones on restart). * manage.c: Initially managing new windows (or existing ones on restart).
* *
*/ */
#ifndef _MANAGE_H #ifndef I3_MANAGE_H
#define _MANAGE_H #define I3_MANAGE_H
#include "data.h" #include "data.h"

View File

@ -11,8 +11,8 @@
* match_matches_window() to find the windows affected by this command. * match_matches_window() to find the windows affected by this command.
* *
*/ */
#ifndef _MATCH_H #ifndef I3_MATCH_H
#define _MATCH_H #define I3_MATCH_H
/* /*
* Initializes the Match data structure. This function is necessary because the * Initializes the Match data structure. This function is necessary because the

View File

@ -7,8 +7,8 @@
* move.c: Moving containers into some direction. * move.c: Moving containers into some direction.
* *
*/ */
#ifndef _MOVE_H #ifndef I3_MOVE_H
#define _MOVE_H #define I3_MOVE_H
/** /**
* Moves the current container in the given direction (TOK_LEFT, TOK_RIGHT, * Moves the current container in the given direction (TOK_LEFT, TOK_RIGHT,

View File

@ -7,8 +7,8 @@
* output.c: Output (monitor) related functions. * output.c: Output (monitor) related functions.
* *
*/ */
#ifndef _OUTPUT_H #ifndef I3_OUTPUT_H
#define _OUTPUT_H #define I3_OUTPUT_H
/** /**
* Returns the output container below the given output container. * Returns the output container below the given output container.

View File

@ -9,8 +9,8 @@
* (take your time to read it completely, it answers all questions). * (take your time to read it completely, it answers all questions).
* *
*/ */
#ifndef _RANDR_H #ifndef I3_RANDR_H
#define _RANDR_H #define I3_RANDR_H
#include "data.h" #include "data.h"
#include <xcb/randr.h> #include <xcb/randr.h>

View File

@ -7,8 +7,8 @@
* regex.c: Interface to libPCRE (perl compatible regular expressions). * regex.c: Interface to libPCRE (perl compatible regular expressions).
* *
*/ */
#ifndef _REGEX_H #ifndef I3_REGEX_H
#define _REGEX_H #define I3_REGEX_H
/** /**
* Creates a new 'regex' struct containing the given pattern and a PCRE * Creates a new 'regex' struct containing the given pattern and a PCRE

View File

@ -8,8 +8,8 @@
* various rects. Needs to be pushed to X11 (see x.c) to be visible. * various rects. Needs to be pushed to X11 (see x.c) to be visible.
* *
*/ */
#ifndef _RENDER_H #ifndef I3_RENDER_H
#define _RENDER_H #define I3_RENDER_H
/** /**
* "Renders" the given container (and its children), meaning that all rects are * "Renders" the given container (and its children), meaning that all rects are

View File

@ -7,8 +7,8 @@
* resize.c: Interactive resizing. * resize.c: Interactive resizing.
* *
*/ */
#ifndef _RESIZE_H #ifndef I3_RESIZE_H
#define _RESIZE_H #define I3_RESIZE_H
int resize_graphical_handler(Con *first, Con *second, orientation_t orientation, const xcb_button_press_event_t *event); int resize_graphical_handler(Con *first, Con *second, orientation_t orientation, const xcb_button_press_event_t *event);

View File

@ -7,8 +7,8 @@
* scratchpad.c: Scratchpad functions (TODO: more description) * scratchpad.c: Scratchpad functions (TODO: more description)
* *
*/ */
#ifndef _SCRATCHPAD_H #ifndef I3_SCRATCHPAD_H
#define _SCRATCHPAD_H #define I3_SCRATCHPAD_H
/** /**
* Moves the specified window to the __i3_scratch workspace, making it floating * Moves the specified window to the __i3_scratch workspace, making it floating

View File

@ -8,8 +8,8 @@
* default (ringbuffer for storing the debug log). * default (ringbuffer for storing the debug log).
* *
*/ */
#ifndef _I3_SHMLOG_H #ifndef I3_I3_SHMLOG_H
#define _I3_SHMLOG_H #define I3_I3_SHMLOG_H
#include <stdint.h> #include <stdint.h>
#include <pthread.h> #include <pthread.h>

View File

@ -9,8 +9,8 @@
* to restart inplace). * to restart inplace).
* *
*/ */
#ifndef _SIGHANDLER_H #ifndef I3_SIGHANDLER_H
#define _SIGHANDLER_H #define I3_SIGHANDLER_H
/** /**
* Setup signal handlers to safely handle SIGSEGV and SIGFPE * Setup signal handlers to safely handle SIGSEGV and SIGFPE

View File

@ -10,8 +10,8 @@
* the appropriate workspace. * the appropriate workspace.
* *
*/ */
#ifndef _STARTUP_H #ifndef I3_STARTUP_H
#define _STARTUP_H #define I3_STARTUP_H
#define SN_API_NOT_YET_FROZEN 1 #define SN_API_NOT_YET_FROZEN 1
#include <libsn/sn-monitor.h> #include <libsn/sn-monitor.h>

View File

@ -7,8 +7,8 @@
* tree.c: Everything that primarily modifies the layout tree data structure. * tree.c: Everything that primarily modifies the layout tree data structure.
* *
*/ */
#ifndef _TREE_H #ifndef I3_TREE_H
#define _TREE_H #define I3_TREE_H
extern Con *croot; extern Con *croot;
/* TODO: i am not sure yet how much access to the focused container should /* TODO: i am not sure yet how much access to the focused container should

View File

@ -8,8 +8,8 @@
* also libi3). * also libi3).
* *
*/ */
#ifndef _UTIL_H #ifndef I3_UTIL_H
#define _UTIL_H #define I3_UTIL_H
#include <err.h> #include <err.h>

View File

@ -7,8 +7,8 @@
* window.c: Updates window attributes (X11 hints/properties). * window.c: Updates window attributes (X11 hints/properties).
* *
*/ */
#ifndef _WINDOW_H #ifndef I3_WINDOW_H
#define _WINDOW_H #define I3_WINDOW_H
/** /**
* Updates the WM_CLASS (consisting of the class and instance) for the * Updates the WM_CLASS (consisting of the class and instance) for the

View File

@ -8,8 +8,8 @@
* workspaces. * workspaces.
* *
*/ */
#ifndef _WORKSPACE_H #ifndef I3_WORKSPACE_H
#define _WORKSPACE_H #define I3_WORKSPACE_H
#include "data.h" #include "data.h"
#include "tree.h" #include "tree.h"

View File

@ -8,8 +8,8 @@
* render.c). Basically a big state machine. * render.c). Basically a big state machine.
* *
*/ */
#ifndef _X_H #ifndef I3_X_H
#define _X_H #define I3_X_H
/** Stores the X11 window ID of the currently focused window */ /** Stores the X11 window ID of the currently focused window */
extern xcb_window_t focused_id; extern xcb_window_t focused_id;

View File

@ -7,8 +7,8 @@
* xcb.c: Helper functions for easier usage of XCB * xcb.c: Helper functions for easier usage of XCB
* *
*/ */
#ifndef _XCB_H #ifndef I3_XCB_H
#define _XCB_H #define I3_XCB_H
#include "data.h" #include "data.h"
#include "xcursor.h" #include "xcursor.h"

View File

@ -9,8 +9,8 @@
* older versions. * older versions.
* *
*/ */
#ifndef _XCB_COMPAT_H #ifndef I3_XCB_COMPAT_H
#define _XCB_COMPAT_H #define I3_XCB_COMPAT_H
#define xcb_icccm_get_wm_protocols_reply_t xcb_get_wm_protocols_reply_t #define xcb_icccm_get_wm_protocols_reply_t xcb_get_wm_protocols_reply_t
#define xcb_icccm_get_wm_protocols xcb_get_wm_protocols #define xcb_icccm_get_wm_protocols xcb_get_wm_protocols

View File

@ -7,8 +7,8 @@
* xcursor.c: libXcursor support for themed cursors. * xcursor.c: libXcursor support for themed cursors.
* *
*/ */
#ifndef _XCURSOR_CURSOR_H #ifndef I3_XCURSOR_CURSOR_H
#define _XCURSOR_CURSOR_H #define I3_XCURSOR_CURSOR_H
#include <X11/Xlib.h> #include <X11/Xlib.h>

View File

@ -9,8 +9,8 @@
* driver which does not support RandR in 2011 *sigh*. * driver which does not support RandR in 2011 *sigh*.
* *
*/ */
#ifndef _XINERAMA_H #ifndef I3_XINERAMA_H
#define _XINERAMA_H #define I3_XINERAMA_H
#include "data.h" #include "data.h"