emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

feature/pgtk 964dfcf 062/100: * src/pgtkgui.h: change coding style


From: Yuuki Harano
Subject: feature/pgtk 964dfcf 062/100: * src/pgtkgui.h: change coding style
Date: Tue, 24 Nov 2020 08:02:38 -0500 (EST)

branch: feature/pgtk
commit 964dfcf46222d9d834da936f5cef7aa3c3c29bd9
Author: Yuuki Harano <masm+github@masm11.me>
Commit: Jeff Walsh <jeff.walsh@drtusers-MacBook-Pro.local>

    * src/pgtkgui.h: change coding style
---
 src/pgtkgui.h | 72 ++++++++++++++++++++++++++++++-----------------------------
 1 file changed, 37 insertions(+), 35 deletions(-)

diff --git a/src/pgtkgui.h b/src/pgtkgui.h
index be9fb25..0855920 100644
--- a/src/pgtkgui.h
+++ b/src/pgtkgui.h
@@ -45,7 +45,7 @@ typedef unichar XChar2b;
 
 typedef struct _GdkCursor *Emacs_Cursor;
 
-typedef void * Color;
+typedef void *Color;
 typedef int Window;
 typedef struct _GdkDisplay Display;
 
@@ -55,31 +55,12 @@ typedef void *XrmDatabase;
 
 /* some sort of attempt to normalize rectangle handling.. seems a bit much
    for what is accomplished */
-typedef struct {
-      int x, y;
-      unsigned width, height;
+typedef struct
+{
+  int x, y;
+  unsigned width, height;
 } XRectangle;
 
-#define NativeRectangle XRectangle
-
-#define CONVERT_TO_EMACS_RECT(xr, nr)          \
-  ((xr).x     = (nr).origin.x,                 \
-   (xr).y     = (nr).origin.y,                 \
-   (xr).width = (nr).size.width,               \
-   (xr).height = (nr).size.height)
-
-#define CONVERT_FROM_EMACS_RECT(xr, nr)        \
-  ((nr).x    = (xr).x,                 \
-   (nr).y    = (xr).y,                 \
-   (nr).width  = (xr).width,           \
-   (nr).height = (xr).height)
-
-#define STORE_NATIVE_RECT(nr, px, py, pwidth, pheight) \
-  ((nr).x    = (px),                   \
-   (nr).y    = (py),                   \
-   (nr).width  = (pwidth),             \
-   (nr).height = (pheight))
-
 /* This stuff needed by frame.c. */
 #define ForgetGravity          0
 #define NorthWestGravity       1
@@ -102,16 +83,37 @@ typedef struct {
 #define XNegative      0x0010
 #define YNegative      0x0020
 
-#define USPosition     (1L << 0) /* user specified x, y */
-#define USSize         (1L << 1) /* user specified width, height */
+#define USPosition     (1L << 0)       /* user specified x, y */
+#define USSize         (1L << 1)       /* user specified width, height */
 
-#define PPosition      (1L << 2) /* program specified position */
-#define PSize          (1L << 3) /* program specified size */
-#define PMinSize       (1L << 4) /* program specified minimum size */
-#define PMaxSize       (1L << 5) /* program specified maximum size */
-#define PResizeInc     (1L << 6) /* program specified resize increments */
-#define PAspect                (1L << 7) /* program specified min, max aspect 
ratios */
-#define PBaseSize      (1L << 8) /* program specified base for incrementing */
-#define PWinGravity    (1L << 9) /* program specified window gravity */
+#define PPosition      (1L << 2)       /* program specified position */
+#define PSize          (1L << 3)       /* program specified size */
+#define PMinSize       (1L << 4)       /* program specified minimum size */
+#define PMaxSize       (1L << 5)       /* program specified maximum size */
+#define PResizeInc     (1L << 6)       /* program specified resize increments 
*/
+#define PAspect                (1L << 7)       /* program specified min, max 
aspect ratios */
+#define PBaseSize      (1L << 8)       /* program specified base for 
incrementing */
+#define PWinGravity    (1L << 9)       /* program specified window gravity */
+
+
+#define NativeRectangle XRectangle
+
+#define CONVERT_TO_EMACS_RECT(xr, nr)          \
+  ((xr).x     = (nr).x,                                \
+   (xr).y     = (nr).y,                                \
+   (xr).width = (nr).width,                    \
+   (xr).height = (nr).height)
+
+#define CONVERT_FROM_EMACS_RECT(xr, nr)                \
+  ((nr).x      = (xr).x,                       \
+   (nr).y      = (xr).y,                       \
+   (nr).width  = (xr).width,                   \
+   (nr).height = (xr).height)
+
+#define STORE_NATIVE_RECT(nr, px, py, pwidth, pheight) \
+  ((nr).x      = (px),                                 \
+   (nr).y      = (py),                                 \
+   (nr).width  = (pwidth),                             \
+   (nr).height = (pheight))
 
-#endif  /* __PGTKGUI_H__ */
+#endif /* __PGTKGUI_H__ */



reply via email to

[Prev in Thread] Current Thread [Next in Thread]