diff --git a/fvwm/builtins.c b/fvwm/builtins.c index 77c31c8eb..b55b0d542 100644 --- a/fvwm/builtins.c +++ b/fvwm/builtins.c @@ -23,8 +23,8 @@ #include #include #include -#include +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/fvwmsignal.h" #include "libs/setpgrp.h" @@ -271,7 +271,7 @@ static void obsolete_imagepaths( const char* pre_path ) * */ static char *ReadTitleButton( - char *s, TitleButton *tb, Boolean append, int button) + char *s, TitleButton *tb, Bool append, int button) { char *end = NULL; char *spec; diff --git a/fvwm/colorset.c b/fvwm/colorset.c index 2edaa0af4..48f59c8c6 100644 --- a/fvwm/colorset.c +++ b/fvwm/colorset.c @@ -26,9 +26,7 @@ #include "config.h" -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/Parse.h" #include "libs/PictureBase.h" diff --git a/fvwm/colorset.h b/fvwm/colorset.h index 31843aae7..53557b137 100644 --- a/fvwm/colorset.h +++ b/fvwm/colorset.h @@ -4,7 +4,7 @@ #define FVWM_COLORSET_H /* ---------------------------- included header files ---------------------- */ -#include +#include "libs/fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/fvwm/cursor.h b/fvwm/cursor.h index d99876dbe..b1a1e659b 100644 --- a/fvwm/cursor.h +++ b/fvwm/cursor.h @@ -4,7 +4,7 @@ #define FVWM_CURSOR_H /* ---------------------------- included header files ---------------------- */ -#include +#include "libs/fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/fvwm/decorations.c b/fvwm/decorations.c index fb5e36b71..20c502dee 100644 --- a/fvwm/decorations.c +++ b/fvwm/decorations.c @@ -18,9 +18,8 @@ #include "config.h" #include -#include -#include +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/FShape.h" #include "libs/Parse.h" diff --git a/fvwm/events.c b/fvwm/events.c index da98a5eb6..6fa7f3a51 100644 --- a/fvwm/events.c +++ b/fvwm/events.c @@ -54,8 +54,8 @@ #include #include #include -#include +#include "libs/fvwm_x11.h" #include "libs/ftime.h" #include "libs/fvwmlib.h" #include "libs/System.h" diff --git a/fvwm/ewmh.c b/fvwm/ewmh.c index 4aeacb491..17af0f412 100644 --- a/fvwm/ewmh.c +++ b/fvwm/ewmh.c @@ -53,8 +53,7 @@ #include "config.h" #include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "fvwm.h" #include "execcontext.h" diff --git a/fvwm/ewmh.h b/fvwm/ewmh.h index a31f381c6..df8a5e67a 100644 --- a/fvwm/ewmh.h +++ b/fvwm/ewmh.h @@ -24,7 +24,6 @@ Bool EWMH_CMD_Style(char *token, window_style *ptmpstyle, int on); /* Extended window manager hints support */ #include "libs/FScreen.h" -#include void EWMH_SetCurrentDesktop(struct monitor *); void EWMH_SetNumberOfDesktops(struct monitor *); diff --git a/fvwm/ewmh_conf.c b/fvwm/ewmh_conf.c index b712a4944..5c3f6c7dd 100644 --- a/fvwm/ewmh_conf.c +++ b/fvwm/ewmh_conf.c @@ -18,9 +18,7 @@ #include -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/Parse.h" #include "libs/Strings.h" diff --git a/fvwm/ewmh_events.c b/fvwm/ewmh_events.c index 505e027b2..fba4649ea 100644 --- a/fvwm/ewmh_events.c +++ b/fvwm/ewmh_events.c @@ -18,9 +18,7 @@ #include -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/Strings.h" #include "fvwm.h" diff --git a/fvwm/ewmh_names.c b/fvwm/ewmh_names.c index 0a90f160a..099cc3a86 100644 --- a/fvwm/ewmh_names.c +++ b/fvwm/ewmh_names.c @@ -17,9 +17,7 @@ #include "config.h" #include -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/Flocale.h" #include "libs/FlocaleCharset.h" diff --git a/fvwm/externs.h b/fvwm/externs.h index 348d68894..1fcb15971 100644 --- a/fvwm/externs.h +++ b/fvwm/externs.h @@ -29,8 +29,7 @@ #ifndef FVWM_EXTERNS_H #define FVWM_EXTERNS_H -#include -#include +#include "libs/fvwm_x11.h" void Done(int, char *) __attribute__((__noreturn__)); void set_init_function_name(int n, const char *name); diff --git a/fvwm/functions.c b/fvwm/functions.c index 7b7e3295e..6bcaa4912 100644 --- a/fvwm/functions.c +++ b/fvwm/functions.c @@ -23,8 +23,7 @@ #include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/charmap.h" #include "libs/wcontext.h" diff --git a/fvwm/fvwm.h b/fvwm/fvwm.h index 5eb1194b9..efa45be0d 100644 --- a/fvwm/fvwm.h +++ b/fvwm/fvwm.h @@ -33,10 +33,7 @@ /* ---------------------------- included header files ---------------------- */ -#include -#include -#include -#include +#include "libs/fvwm_x11.h" #include "libs/PictureBase.h" #include "libs/Fft.h" #include "libs/FRender.h" diff --git a/fvwm/fvwm3.c b/fvwm/fvwm3.c index 1539fd804..6fbd511dc 100644 --- a/fvwm/fvwm3.c +++ b/fvwm/fvwm3.c @@ -29,9 +29,7 @@ #include #endif -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/envvar.h" #include "libs/Strings.h" diff --git a/fvwm/icccm2.c b/fvwm/icccm2.c index 6d296b68e..047114739 100644 --- a/fvwm/icccm2.c +++ b/fvwm/icccm2.c @@ -19,8 +19,8 @@ #ifdef HAVE_FCNTL_H #include #endif -#include +#include "libs/fvwm_x11.h" #include "libs/FEvent.h" #include "fvwm.h" #include "externs.h" diff --git a/fvwm/icccm2.h b/fvwm/icccm2.h index fbed3142b..45dcd4dd1 100644 --- a/fvwm/icccm2.h +++ b/fvwm/icccm2.h @@ -2,7 +2,8 @@ #ifndef FVWM_ICCCM2_H #define FVWM_ICCCM2_H -#include + +#include "libs/fvwm_x11.h" extern void SetupICCCM2(Bool replace_wm); extern void CloseICCCM2(void); diff --git a/fvwm/icons.c b/fvwm/icons.c index 6e9f9ce09..b5c914d58 100644 --- a/fvwm/icons.c +++ b/fvwm/icons.c @@ -402,7 +402,7 @@ ICON_DBG((stderr,"ciw: iph%s used '%s'\n", { int newWidth = fw->icon_g.picture_w_g.width; int newHeight = fw->icon_g.picture_w_g.height; - Boolean resize = False; + Bool resize = False; if (newWidth < fw->min_icon_width) { diff --git a/fvwm/menubindings.c b/fvwm/menubindings.c index 605a25945..09dbef7a4 100644 --- a/fvwm/menubindings.c +++ b/fvwm/menubindings.c @@ -18,8 +18,8 @@ #include "config.h" #include -#include +#include "libs/fvwm_x11.h" #include "libs/Parse.h" #include "libs/Bindings.h" #include "libs/charmap.h" diff --git a/fvwm/menubindings.h b/fvwm/menubindings.h index ca50867e6..9c88f0874 100644 --- a/fvwm/menubindings.h +++ b/fvwm/menubindings.h @@ -2,7 +2,7 @@ #ifndef FVWM_MENU_BINDINGS_H #define FVWM_MENU_BINDINGS_H -#include + #include "libs/Bindings.h" /* ---------------------------- included header files ---------------------- */ diff --git a/fvwm/menugeometry.c b/fvwm/menugeometry.c index c4f378912..e578dc65d 100644 --- a/fvwm/menugeometry.c +++ b/fvwm/menugeometry.c @@ -19,7 +19,7 @@ #include -#include +#include "libs/fvwm_x11.h" #include "fvwm.h" #include "externs.h" diff --git a/fvwm/menugeometry.h b/fvwm/menugeometry.h index ebecf7a79..7056a06b8 100644 --- a/fvwm/menugeometry.h +++ b/fvwm/menugeometry.h @@ -4,7 +4,7 @@ #define FVWM_MENU_GEOMETRY_H /* ---------------------------- included header files ---------------------- */ -#include +#include "libs/fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/fvwm/menuparameters.h b/fvwm/menuparameters.h index ca5305eca..134d43d79 100644 --- a/fvwm/menuparameters.h +++ b/fvwm/menuparameters.h @@ -4,7 +4,7 @@ #define FVWM_MENU_PARAMETERS_H /* ---------------------------- included header files ---------------------- */ -#include +#include "libs/fvwm_x11.h" #include "execcontext.h" /* ---------------------------- forward declarations ----------------------- */ diff --git a/fvwm/menuroot.h b/fvwm/menuroot.h index 3ff052d94..d0babf75a 100644 --- a/fvwm/menuroot.h +++ b/fvwm/menuroot.h @@ -4,8 +4,7 @@ #define FVWM_MENU_ROOT_H /* ---------------------------- included header files ---------------------- */ -#include -#include +#include "libs/fvwm_x11.h" #include "menudim.h" #include "libs/PictureBase.h" /* ---------------------------- forward declarations ----------------------- */ diff --git a/fvwm/menus.c b/fvwm/menus.c index fa0a0f19b..731526631 100644 --- a/fvwm/menus.c +++ b/fvwm/menus.c @@ -22,7 +22,6 @@ #include #include -#include #include "libs/ftime.h" #include "libs/fvwmlib.h" diff --git a/fvwm/menustyle.c b/fvwm/menustyle.c index 9bb7a337f..00c2428a4 100644 --- a/fvwm/menustyle.c +++ b/fvwm/menustyle.c @@ -19,8 +19,7 @@ #include #include -#include - +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/Parse.h" #include "libs/ColorUtils.h" @@ -151,7 +150,7 @@ static void menustyle_copy_face(MenuFace *destmf, MenuFace *origmf) * Reads a menu face line into a structure (veliaa@rpi.edu) * */ -static Boolean menustyle_parse_face(char *s, MenuFace *mf, int verbose) +static Bool menustyle_parse_face(char *s, MenuFace *mf, int verbose) { char *style; char *token; diff --git a/fvwm/misc.c b/fvwm/misc.c index 0141f4a7b..613502d61 100644 --- a/fvwm/misc.c +++ b/fvwm/misc.c @@ -19,8 +19,8 @@ #include #include -#include +#include "libs/fvwm_x11.h" #include "libs/ftime.h" #include "libs/Parse.h" #include "libs/Target.h" diff --git a/fvwm/misc.h b/fvwm/misc.h index f5178a69c..5fb1aabbf 100644 --- a/fvwm/misc.h +++ b/fvwm/misc.h @@ -3,7 +3,6 @@ #ifndef FVWM_MISC_H #define FVWM_MISC_H -#include #include "fvwm.h" /* ---------------------------- included header files ---------------------- */ diff --git a/fvwm/move_resize.c b/fvwm/move_resize.c index 58f12fe1a..8ae5e7e26 100644 --- a/fvwm/move_resize.c +++ b/fvwm/move_resize.c @@ -23,7 +23,6 @@ #include #include -#include #include "libs/fvwmlib.h" #include "libs/Picture.h" diff --git a/fvwm/screen.h b/fvwm/screen.h index b14b6f8bc..b2ed4307d 100644 --- a/fvwm/screen.h +++ b/fvwm/screen.h @@ -33,8 +33,6 @@ #include "config.h" -#include - #include "update.h" #include "style.h" #include "fvwm.h" diff --git a/fvwm/session.c b/fvwm/session.c index 67fc679b9..9b38ee811 100644 --- a/fvwm/session.c +++ b/fvwm/session.c @@ -27,8 +27,8 @@ #endif #include #include -#include +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/FSMlib.h" #include "libs/Strings.h" diff --git a/fvwm/virtual.c b/fvwm/virtual.c index caf41a1f0..1b919be80 100644 --- a/fvwm/virtual.c +++ b/fvwm/virtual.c @@ -19,7 +19,6 @@ #include -#include #include "libs/fvwmlib.h" #include "libs/FGettext.h" #include "libs/Grab.h" diff --git a/libs/Bindings.h b/libs/Bindings.h index 05c3915f0..b99936e30 100644 --- a/libs/Bindings.h +++ b/libs/Bindings.h @@ -3,7 +3,7 @@ #ifndef FVWMLIB_BINDINGS_H_H #define FVWMLIB_BINDINGS_H_H -#include /* XClassHint */ +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/ClientMsg.h b/libs/ClientMsg.h index 57a8b9b78..88e7fbbfd 100644 --- a/libs/ClientMsg.h +++ b/libs/ClientMsg.h @@ -15,9 +15,7 @@ #ifndef FVWMLIB_CLIENTMSG_H #define FVWMLIB_CLIENTMSG_H -#include -#include -#include +#include "fvwm_x11.h" void send_clientmessage(Display *disp, Window w, Atom a, Time timestamp); diff --git a/libs/ColorUtils.h b/libs/ColorUtils.h index b5be34dcd..bee3db50f 100644 --- a/libs/ColorUtils.h +++ b/libs/ColorUtils.h @@ -1,9 +1,7 @@ #ifndef FVWMLIB_COLORUTILS_H #define FVWMLIB_COLORUTILS_H -#include -#include - +#include "fvwm_x11.h" /* * Stuff for dealing w/ bitmaps & pixmaps: */ diff --git a/libs/Colorset.h b/libs/Colorset.h index 40d71467c..577c1f5bd 100644 --- a/libs/Colorset.h +++ b/libs/Colorset.h @@ -7,8 +7,7 @@ #ifndef FVWMLIB_COLORSETS_H #define FVWMLIB_COLORSETS_H -#include -#include +#include "fvwm_x11.h" #include "PictureBase.h" typedef struct Colorset diff --git a/libs/CombineChars.h b/libs/CombineChars.h index 4c548ecf9..f2a400db0 100644 --- a/libs/CombineChars.h +++ b/libs/CombineChars.h @@ -10,7 +10,7 @@ #define FVWMLIB_COMBINECHARS_H #include "config.h" -#include +#include "fvwm_x11.h" typedef struct { diff --git a/libs/Event.h b/libs/Event.h index 4ab4ef6a4..5b6367dcc 100644 --- a/libs/Event.h +++ b/libs/Event.h @@ -1,7 +1,7 @@ #ifndef FVWMLIB_EVENT_H #define FVWMLIB_EVENT_H -#include +#include "fvwm_x11.h" /* * Return the subwindow member of an event if the event type has one. diff --git a/libs/FBidi.h b/libs/FBidi.h index cce038200..aa00ed935 100644 --- a/libs/FBidi.h +++ b/libs/FBidi.h @@ -66,7 +66,6 @@ #define FVWMLIB_FBIDI_H #include "config.h" -#include #include "CombineChars.h" #if HAVE_BIDI diff --git a/libs/FEvent.h b/libs/FEvent.h index ca12d4127..ecfb164ca 100644 --- a/libs/FEvent.h +++ b/libs/FEvent.h @@ -4,8 +4,7 @@ #define FVWMLIB_FEVENT_H /* ---------------------------- included header files ---------------------- */ -#include -#include +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/FRender.h b/libs/FRender.h index 5cc88b33f..45a7387f6 100644 --- a/libs/FRender.h +++ b/libs/FRender.h @@ -8,12 +8,7 @@ #include "config.h" #include "PictureBase.h" - -#if XRenderSupport -#define Picture XRenderPicture -#include -#undef Picture -#endif +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ @@ -26,11 +21,6 @@ typedef XRenderDirectFormat FRenderDirectFormat; typedef PictFormat FRPictFormat; typedef XRenderPictFormat FRenderPictFormat; typedef XRenderPicture FRenderPicture; -#if 0 /* this has disappeared */ -typedef XRenderVisual FRenderVisual; -typedef XRenderDepth FRenderDepth; -typedef XRenderInfo FRenderInfo; -#endif typedef XRenderPictureAttributes FRenderPictureAttributes; typedef XRenderColor FRenderColor; typedef XGlyphInfo FGlyphInfo; diff --git a/libs/FRenderInit.h b/libs/FRenderInit.h index 0d8a65eb6..886492cea 100644 --- a/libs/FRenderInit.h +++ b/libs/FRenderInit.h @@ -6,7 +6,7 @@ #ifndef FVWMLIB_FRENDER_INIT_H #define FVWMLIB_FRENDER_INIT_H -#include +#include "fvwm_x11.h" void FRenderInit(Display *dpy); int FRenderGetAlphaDepth(void); diff --git a/libs/FRenderInterface.h b/libs/FRenderInterface.h index a5944a258..a653ca498 100644 --- a/libs/FRenderInterface.h +++ b/libs/FRenderInterface.h @@ -3,8 +3,7 @@ #ifndef FVWMLIB_FRENDER_INTERFACE_H #define FVWMLIB_FRENDER_INTERFACE_H -#include -#include +#include "fvwm_x11.h" Bool FRenderTintRectangle( Display *dpy, Window win, Pixmap mask, Pixel tint, int shade_percent, diff --git a/libs/FSMlib.h b/libs/FSMlib.h index 1fb24738e..d7a526fc0 100644 --- a/libs/FSMlib.h +++ b/libs/FSMlib.h @@ -5,17 +5,7 @@ /* ---------------------------- included header files ---------------------- */ #include "config.h" - -#ifdef SESSION -#define SessionSupport 1 -#else -#define SessionSupport 0 -#endif - -#if SessionSupport -#include -#include -#endif +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/FScreen.h b/libs/FScreen.h index ad1729e4c..cf0374ac3 100644 --- a/libs/FScreen.h +++ b/libs/FScreen.h @@ -3,16 +3,7 @@ #define FVWMLIB_FSCRREN_H #include "config.h" - -#ifdef HAVE_XRANDR -#include -#endif - -/* For CARD32 */ -#include -#include -#include - +#include "fvwm_x11.h" #include "fvwmrect.h" typedef struct diff --git a/libs/FShape.h b/libs/FShape.h index 0dad696da..d97f01708 100644 --- a/libs/FShape.h +++ b/libs/FShape.h @@ -7,9 +7,9 @@ #define FVWMLIB_FSHAPE_H #include "config.h" +#include "fvwm_x11.h" #ifdef SHAPE -#include #define FShapeQueryExtension(dpy, evbase, errbase) \ XShapeQueryExtension(dpy, evbase, errbase) #define FShapeQueryVersion(dpy, vmajor, vminor) \ diff --git a/libs/FShm.h b/libs/FShm.h index 0aac9254f..b0ca36067 100644 --- a/libs/FShm.h +++ b/libs/FShm.h @@ -6,18 +6,7 @@ /* ---------------------------- included header files ---------------------- */ #include "config.h" - -#ifdef HAVE_XSHM -#define XShmSupport 1 -#else -#define XShmSupport 0 -#endif - -#if XShmSupport -#include -#include -#include -#endif +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/FTips.h b/libs/FTips.h index 6e499665e..575a0d61d 100644 --- a/libs/FTips.h +++ b/libs/FTips.h @@ -5,8 +5,7 @@ #define FVWMLIB_FTIPS_H /* ---------------------------- included header files ---------------------- */ -#include -#include +#include "fvwm_x11.h" #include "Flocale.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/Fcursor.h b/libs/Fcursor.h index 8cf97b460..55a4e7958 100644 --- a/libs/Fcursor.h +++ b/libs/Fcursor.h @@ -1,9 +1,9 @@ #ifndef FVWMLIB_FCURSOR_H #define FVWMLIB_FCURSOR_H -#ifdef HAVE_XCURSOR -# include +#include "fvwm_x11.h" +#ifdef HAVE_XCURSOR typedef XcursorImage FcursorImage; typedef XcursorImages FcursorImages; typedef XcursorPixel FcursorPixel; diff --git a/libs/Fft.h b/libs/Fft.h index c9c7d19a8..5a65e7374 100644 --- a/libs/Fft.h +++ b/libs/Fft.h @@ -14,16 +14,7 @@ #include "config.h" -/* no compat to avoid problems in the future */ -#define _XFT_NO_COMPAT_ 1 - -#ifdef HAVE_XFT -#define Picture XRenderPicture -#include -#include -#undef Picture -#endif - +#include "fvwm_x11.h" #include "FRender.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/Fsvg.h b/libs/Fsvg.h index 221561056..120d7e3e0 100644 --- a/libs/Fsvg.h +++ b/libs/Fsvg.h @@ -1,21 +1,22 @@ #ifndef FVWMLIB_FSVG_H #define FVWMLIB_FSVG_H +#include "fvwm_x11.h" +#include "PictureBase.h" + #ifdef HAVE_RSVG #define USE_SVG 1 +#include +#include #else #define USE_SVG 0 #endif -#include "PictureBase.h" - #ifndef M_PI #define M_PI 3.14159265358979323846 #endif #if USE_SVG -# include -# include typedef RsvgDimensionData FRsvgDimensionData; typedef RsvgHandle FRsvgHandle; typedef cairo_surface_t Fcairo_surface_t; diff --git a/libs/Fxpm.h b/libs/Fxpm.h index 4db0d0236..2ca5b7140 100644 --- a/libs/Fxpm.h +++ b/libs/Fxpm.h @@ -5,10 +5,7 @@ #define FVWMLIB_FXPM_H #include "PictureBase.h" - -#if XpmSupport -#include -#endif +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/Grab.h b/libs/Grab.h index 84d682559..94fa04431 100644 --- a/libs/Grab.h +++ b/libs/Grab.h @@ -7,7 +7,7 @@ #ifndef FVWMLIB_GRAB_H #define FVWMLIB_GRAB_H -#include +#include "fvwm_x11.h" void MyXGrabServer(Display *disp); void MyXUngrabServer(Display *disp); diff --git a/libs/Graphics.h b/libs/Graphics.h index 17a392681..7960d712b 100644 --- a/libs/Graphics.h +++ b/libs/Graphics.h @@ -1,8 +1,6 @@ #ifndef FVWMLIB_GRAPHICS_H #define FVWMLIB_GRAPHICS_H - -#include -#include +#include "fvwm_x11.h" void do_relieve_rectangle( Display *dpy, Drawable d, int x, int y, int w, int h, diff --git a/libs/Makefile.am b/libs/Makefile.am index ca20971c1..0f4514284 100644 --- a/libs/Makefile.am +++ b/libs/Makefile.am @@ -13,7 +13,7 @@ libfvwm3_a_SOURCES = \ PictureDitherMatrice.h PictureGraphics.h PictureImageLoader.h \ PictureUtils.h Rectangles.h Strings.h System.h Target.h WinMagic.h \ XError.h XResource.h charmap.h defaults.h envvar.h fio.h flist.h fqueue.h \ - fsm.h ftime.h fvwm_sys_stat.h fvwmlib.h fvwmrect.h fvwmsignal.h \ + fsm.h ftime.h fvwm_sys_stat.h fvwm_x11.h fvwmlib.h fvwmrect.h fvwmsignal.h \ gravity.c gravity.h getpwuid.h lang-strings.h log.h modifiers.h queue.h \ safemalloc.h setpgrp.h strlcpy.h timeout.h vpacket.h wcontext.h wild.h \ \ diff --git a/libs/Module.h b/libs/Module.h index 2129b4de0..e1acb0291 100644 --- a/libs/Module.h +++ b/libs/Module.h @@ -6,8 +6,8 @@ ** Module.c: code for modules to communicate with fvwm */ -#include -#include "libs/fvwmlib.h" +#include "fvwm_x11.h" +#include "fvwmlib.h" /** * fvwm sends packets of this type to modules. diff --git a/libs/PictureBase.h b/libs/PictureBase.h index 366efb85c..1ee6cdf5b 100644 --- a/libs/PictureBase.h +++ b/libs/PictureBase.h @@ -4,26 +4,7 @@ #define FVWMLIB_PICTURE_BASE_H #include "config.h" - -#include - -#ifdef HAVE_XRENDER -#define XRenderSupport 1 -#else -#define XRenderSupport 0 -#endif - -#ifdef XPM -#define XpmSupport 1 -#else -#define XpmSupport 0 -#endif - -#ifdef HAVE_PNG -#define PngSupport 1 -#else -#define PngSupport 0 -#endif +#include "fvwm_x11.h" extern Bool Pdefault; extern Visual *Pvisual; diff --git a/libs/PictureGraphics.h b/libs/PictureGraphics.h index fef604d68..d950c0d24 100644 --- a/libs/PictureGraphics.h +++ b/libs/PictureGraphics.h @@ -3,8 +3,8 @@ #ifndef FVWMLIB_PICTURE_GRAPHICS_H #define FVWMLIB_PICTURE_GRAPHICS_H -#include -#include "libs/PictureBase.h" +#include "fvwm_x11.h" +#include "PictureBase.h" /* * diff --git a/libs/PictureImageLoader.h b/libs/PictureImageLoader.h index 6fa654d56..4e49f55f0 100644 --- a/libs/PictureImageLoader.h +++ b/libs/PictureImageLoader.h @@ -6,9 +6,7 @@ /* ---------------------------- included header files ---------------------- */ -#include -#include -#include +#include "fvwm_x11.h" #include "PictureBase.h" /* ---------------------------- global macros ------------------------------ */ diff --git a/libs/PictureUtils.h b/libs/PictureUtils.h index 0a6048f44..3e10f3a64 100644 --- a/libs/PictureUtils.h +++ b/libs/PictureUtils.h @@ -3,7 +3,7 @@ #ifndef FVWMLIB_PICTURE_UTILS_H #define FVWMLIB_PICTURE_UTILS_H -#include +#include "fvwm_x11.h" #include "PictureBase.h" #define PICTURE_CALLED_BY_FVWM 0 diff --git a/libs/Rectangles.h b/libs/Rectangles.h index a9518392b..a66cd8ccd 100644 --- a/libs/Rectangles.h +++ b/libs/Rectangles.h @@ -8,7 +8,7 @@ #define FVWMLIB_RECTANGLES_H /* ---------------------------- included header files ---------------------- */ -#include +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/Target.h b/libs/Target.h index b10a887b3..3dbb2f3a1 100644 --- a/libs/Target.h +++ b/libs/Target.h @@ -1,7 +1,7 @@ #ifndef FVWMLIB_TARGET_H #define FVWMLIB_TARGET_H -#include +#include "fvwm_x11.h" void fvwmlib_keyboard_shortcuts( Display *dpy, int screen, XEvent *Event, int x_move_size, diff --git a/libs/WinMagic.h b/libs/WinMagic.h index c94516293..6b241c01d 100644 --- a/libs/WinMagic.h +++ b/libs/WinMagic.h @@ -1,7 +1,7 @@ #ifndef FVWMLIB_WINMAGIC #define FVWMLIB_WINMAGIC -#include +#include "fvwm_x11.h" void SlideWindow( Display *dpy, Window win, diff --git a/libs/XError.h b/libs/XError.h index e40acae99..744721111 100644 --- a/libs/XError.h +++ b/libs/XError.h @@ -1,6 +1,6 @@ #ifndef FVWMLIB_XERROR_H #define FVWMLIB_XERROR_H -#include +#include "fvwm_x11.h" void do_coredump(void); diff --git a/libs/XResource.h b/libs/XResource.h index 631fea711..857be51eb 100644 --- a/libs/XResource.h +++ b/libs/XResource.h @@ -1,7 +1,6 @@ #ifndef FVWMLIB_XRESOURCE_H #define FVWMLIB_XRESOURCE_H -#include -#include +#include "fvwm_x11.h" /* * Wrappers around Xrm routines (XResources.c) diff --git a/libs/fvwm_x11.h b/libs/fvwm_x11.h new file mode 100644 index 000000000..44b387970 --- /dev/null +++ b/libs/fvwm_x11.h @@ -0,0 +1,74 @@ +#ifndef FVWMLIB_X11_H +#define FVWMLIB_X11_H + +#include "config.h" + +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef XPM +#define XpmSupport 1 +#include +#else +#define XpmSupport 0 +#endif + +#if HAVE_PNG +#define PngSupport 1 +#include +#else +#define PngSupport 0 +#include +#endif + +#ifdef HAVE_XCURSOR +#include +#endif + +#ifdef HAVE_XRENDER +#define XRenderSupport 1 +#include +typedef Picture XRenderPicture; +#else +#define XRenderSupport 0 +#endif + +#ifdef HAVE_XFT +/* no compat to avoid problems in the future */ +#define _XFT_NO_COMPAT_ 1 +#include +#include +#endif + +#ifdef HAVE_XRANDR +#include +#endif + +#ifdef SHAPE +#include +#endif + +#ifdef HAVE_XSHM +#define XShmSupport 1 +#include +#include +#include +#else +#define XShmSupport 0 +#endif + +#ifdef SESSION +#define SessionSupport 1 +#include +#include +#else +#define SessionSupport 0 +#endif + +#endif /* FVWMLIB_X11_H */ diff --git a/libs/fvwmlib.h b/libs/fvwmlib.h index 97ff37042..7217c7a51 100644 --- a/libs/fvwmlib.h +++ b/libs/fvwmlib.h @@ -3,12 +3,9 @@ #ifndef FVWMLIB_H #define FVWMLIB_H -#include -#include -#include -#include /* needed for xpm.h and Pixel defn */ #include +#include "fvwm_x11.h" #include "fvwmrect.h" #include "safemalloc.h" diff --git a/libs/fvwmrect.h b/libs/fvwmrect.h index bf681614b..6545f5655 100644 --- a/libs/fvwmrect.h +++ b/libs/fvwmrect.h @@ -5,7 +5,7 @@ #define FVWMLIB_FVWMRECT_H /* ---------------------------- included header files ---------------------- */ -#include +#include "fvwm_x11.h" /* ---------------------------- global definitions ------------------------- */ diff --git a/libs/vpacket.h b/libs/vpacket.h index 00904e6a8..a239b0383 100644 --- a/libs/vpacket.h +++ b/libs/vpacket.h @@ -2,7 +2,7 @@ #ifndef FVWMLIB_VPACKET_H #define FVWMLIB_VPACKET_H -#include +#include "fvwm_x11.h" #include "fvwm/fvwm.h" /* diff --git a/modules/FvwmAnimate/FvwmAnimate.c b/modules/FvwmAnimate/FvwmAnimate.c index 7d7147ed0..0c17d5627 100644 --- a/modules/FvwmAnimate/FvwmAnimate.c +++ b/modules/FvwmAnimate/FvwmAnimate.c @@ -44,7 +44,6 @@ #include "config.h" #include -#include #include #include #include diff --git a/modules/FvwmBacker/FvwmBacker.c b/modules/FvwmBacker/FvwmBacker.c index 829a30fc1..272a57f97 100644 --- a/modules/FvwmBacker/FvwmBacker.c +++ b/modules/FvwmBacker/FvwmBacker.c @@ -32,10 +32,6 @@ #include /* Saul */ #endif /* Saul */ -#include -#include -#include - #include "libs/FShape.h" #include "libs/Module.h" #include "libs/Colorset.h" diff --git a/modules/FvwmBacker/root_bits.c b/modules/FvwmBacker/root_bits.c index 2a65a3a46..6dde22dbe 100644 --- a/modules/FvwmBacker/root_bits.c +++ b/modules/FvwmBacker/root_bits.c @@ -14,8 +14,7 @@ */ #include "config.h" - -#include +#include "libs/fvwm_x11.h" #include extern Display *dpy; diff --git a/modules/FvwmButtons/FvwmButtons.c b/modules/FvwmButtons/FvwmButtons.c index 739041698..ac9732241 100644 --- a/modules/FvwmButtons/FvwmButtons.c +++ b/modules/FvwmButtons/FvwmButtons.c @@ -35,13 +35,6 @@ #include "libs/ftime.h" #include -#include -#include -#include -#include -#include -#include - #include "libs/defaults.h" #include "libs/fvwmlib.h" #include "libs/FShape.h" diff --git a/modules/FvwmButtons/draw.c b/modules/FvwmButtons/draw.c index f4cd7d192..90d7397ac 100644 --- a/modules/FvwmButtons/draw.c +++ b/modules/FvwmButtons/draw.c @@ -33,12 +33,6 @@ #include #include -#include -#include -#include -#include -#include - #include "libs/Colorset.h" #include "libs/fvwmlib.h" #include "libs/Rectangles.h" diff --git a/modules/FvwmButtons/draw.h b/modules/FvwmButtons/draw.h index 62f952ec2..13a30714c 100644 --- a/modules/FvwmButtons/draw.h +++ b/modules/FvwmButtons/draw.h @@ -3,7 +3,7 @@ #ifndef FVWMBUTTONS_DRAW_H #define FVWMBUTTONS_DRAW_H -#include +#include "libs/fvwm_x11.h" #include "FvwmButtons.h" /* diff --git a/modules/FvwmButtons/dynamic.c b/modules/FvwmButtons/dynamic.c index b556fdf0b..016f03f13 100644 --- a/modules/FvwmButtons/dynamic.c +++ b/modules/FvwmButtons/dynamic.c @@ -19,13 +19,7 @@ #include #include -/* the following 5 are just to satisfy X11/extensions/shape.h on some systems */ -#include -#include -#include -#include -#include - +#include "libs/fvwm_x11.h" #include "libs/Module.h" #include "libs/Strings.h" #include "libs/Parse.h" diff --git a/modules/FvwmButtons/icons.c b/modules/FvwmButtons/icons.c index 59b98b2be..456715bd1 100644 --- a/modules/FvwmButtons/icons.c +++ b/modules/FvwmButtons/icons.c @@ -33,12 +33,6 @@ #include #include -#include -#include -#include -#include -#include - #ifdef HAVE_FCNTL_H #include #endif diff --git a/modules/FvwmButtons/misc.h b/modules/FvwmButtons/misc.h index 3508c0bfc..ad70c5fef 100644 --- a/modules/FvwmButtons/misc.h +++ b/modules/FvwmButtons/misc.h @@ -24,8 +24,7 @@ #ifndef FVWMBUTTONS_MISC_H #define FVWMBUTTONS_MISC_H -#include -#include +#include "libs/fvwm_x11.h" void ConstrainSize(XSizeHints *hints, int *widthp, int *heightp); diff --git a/modules/FvwmButtons/output.c b/modules/FvwmButtons/output.c index 5f7c6d56f..539b71647 100644 --- a/modules/FvwmButtons/output.c +++ b/modules/FvwmButtons/output.c @@ -26,7 +26,6 @@ #include #include #include -#include #include "FvwmButtons.h" /** diff --git a/modules/FvwmButtons/parse.c b/modules/FvwmButtons/parse.c index 6873ff9af..5ef48ff43 100644 --- a/modules/FvwmButtons/parse.c +++ b/modules/FvwmButtons/parse.c @@ -26,9 +26,6 @@ #include #include -#include -#include - #include "libs/fvwmlib.h" #include "libs/Module.h" #include "libs/Colorset.h" diff --git a/modules/FvwmForm/FvwmForm.c b/modules/FvwmForm/FvwmForm.c index ee7b27de6..79ddaa089 100644 --- a/modules/FvwmForm/FvwmForm.c +++ b/modules/FvwmForm/FvwmForm.c @@ -29,13 +29,7 @@ #include "libs/ftime.h" #include -#include -#include -#include -#include -#define XK_MISCELLANY -#include - +// #define XK_MISCELLANY #include "libs/Module.h" /* for headersize, etc. */ #include "libs/fvwmlib.h" #include "libs/fvwmsignal.h" diff --git a/modules/FvwmForm/ReadXServer.c b/modules/FvwmForm/ReadXServer.c index c68d0668e..43140c841 100644 --- a/modules/FvwmForm/ReadXServer.c +++ b/modules/FvwmForm/ReadXServer.c @@ -47,13 +47,7 @@ #include #include -#include -#include -#include -#include -#define XK_MISCELLANY -#include -#include /* for XA_CUT_BUFFER0 */ +// #define XK_MISCELLANY #include "FvwmForm.h" diff --git a/modules/FvwmIconMan/FvwmIconMan.h b/modules/FvwmIconMan/FvwmIconMan.h index cbca2f757..5a484aded 100644 --- a/modules/FvwmIconMan/FvwmIconMan.h +++ b/modules/FvwmIconMan/FvwmIconMan.h @@ -7,9 +7,6 @@ #include "libs/ftime.h" -#include -#include - #include "libs/fvwmlib.h" #include "libs/Flocale.h" #include "libs/Picture.h" @@ -317,7 +314,7 @@ typedef struct win_manager { char *tips_fontname; char *tips_formatstring; ftips_config *tips_conf; - + /* X11 state */ Window theWindow, theFrame; long sizehints_flags; diff --git a/modules/FvwmIconMan/x.h b/modules/FvwmIconMan/x.h index a9f31bbe0..72a7dfa8b 100644 --- a/modules/FvwmIconMan/x.h +++ b/modules/FvwmIconMan/x.h @@ -2,7 +2,6 @@ #ifndef FVWMICONMAN_X_H #define FVWMICONMAN_X_H -#include #include "FvwmIconMan.h" extern Display *theDisplay; diff --git a/modules/FvwmIconMan/xmanager.h b/modules/FvwmIconMan/xmanager.h index 49a2ad8e2..e5fcdff71 100644 --- a/modules/FvwmIconMan/xmanager.h +++ b/modules/FvwmIconMan/xmanager.h @@ -2,7 +2,6 @@ #ifndef FVWMICONMAN_XMANAGER_H #define FVWMICONMAN_XMANAGER_H -#include #include "FvwmIconMan.h" #define DEFAULT_BUTTON_WIDTH 200 diff --git a/modules/FvwmIdent/FvwmIdent.c b/modules/FvwmIdent/FvwmIdent.c index 4487275c4..059785470 100644 --- a/modules/FvwmIdent/FvwmIdent.c +++ b/modules/FvwmIdent/FvwmIdent.c @@ -38,14 +38,8 @@ #include #include -#include -#include -#include -#include -#include -#include -#include +#include "libs/fvwm_x11.h" #include "libs/fvwmlib.h" #include "libs/FShape.h" #include "libs/FEvent.h" diff --git a/modules/FvwmIdent/FvwmIdent.h b/modules/FvwmIdent/FvwmIdent.h index 1c3c025e5..d397f4e16 100644 --- a/modules/FvwmIdent/FvwmIdent.h +++ b/modules/FvwmIdent/FvwmIdent.h @@ -3,7 +3,6 @@ #ifndef FVWMIDENT_H #define FVWMIDENT_H -#include #include "libs/fvwmlib.h" #include "fvwm/fvwm.h" #include "libs/vpacket.h" diff --git a/modules/FvwmPager/FvwmPager.c b/modules/FvwmPager/FvwmPager.c index fb4e1b626..9d5d3eaff 100644 --- a/modules/FvwmPager/FvwmPager.c +++ b/modules/FvwmPager/FvwmPager.c @@ -31,13 +31,6 @@ #include /* Saul */ #endif /* Saul */ -#include -#include -#include -#include -#include -#include - #include "libs/Module.h" #include "libs/fvwmlib.h" #include "libs/FShape.h" diff --git a/modules/FvwmPager/x_pager.c b/modules/FvwmPager/x_pager.c index bd05d0a0d..fb9eef6f2 100644 --- a/modules/FvwmPager/x_pager.c +++ b/modules/FvwmPager/x_pager.c @@ -29,13 +29,6 @@ #include #include -#include -#include -#include -#include -#include -#include - #include "libs/fvwmlib.h" #include "libs/FShape.h" #include "libs/Module.h"