[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RP] [PATCH] centring the bar and 'defbargravity center'
From: |
Doug Kearns |
Subject: |
[RP] [PATCH] centring the bar and 'defbargravity center' |
Date: |
Sat Jul 19 19:34:50 2003 |
User-agent: |
Mutt/1.4i |
The bar was not quite centred when defbargravity was set to 'center'.
Regards,
Doug
Index: src/bar.c
===================================================================
RCS file: /cvsroot/ratpoison/ratpoison/src/bar.c,v
retrieving revision 1.43
diff -u -r1.43 bar.c
--- src/bar.c 2 Jun 2003 22:49:36 -0000 1.43
+++ src/bar.c 20 Jul 2003 02:09:28 -0000
@@ -377,7 +377,7 @@
XMoveResizeWindow (dpy, s->bar_window,
bar_x (s, width), bar_y (s, height),
width,
- height + defaults.bar_y_padding * 2);
+ height);
XRaiseWindow (dpy, s->bar_window);
XClearWindow (dpy, s->bar_window);
@@ -512,8 +512,8 @@
/* Calculate the width and height of the window. */
num_lines = count_lines (msg, strlen(msg));
- width = defaults.bar_x_padding * 2 + max_line_length(msg);
- height = FONT_HEIGHT (defaults.font) * num_lines;
+ width = max_line_length(msg) + defaults.bar_x_padding * 2;
+ height = FONT_HEIGHT (defaults.font) * num_lines + defaults.bar_y_padding *
2;
/* Display the string. */
prepare_bar (s, width, height);
Index: src/input.c
===================================================================
RCS file: /cvsroot/ratpoison/ratpoison/src/input.c,v
retrieving revision 1.35
diff -u -r1.35 input.c
--- src/input.c 27 May 2003 07:51:07 -0000 1.35
+++ src/input.c 20 Jul 2003 02:09:31 -0000
@@ -290,8 +290,8 @@
}
XMoveResizeWindow (dpy, s->input_window,
- bar_x (s, total_width), bar_y (s, height), total_width,
- (FONT_HEIGHT (defaults.font) + defaults.bar_y_padding *
2));
+ bar_x (s, total_width), bar_y (s, height),
+ total_width, height);
XClearWindow (dpy, s->input_window);
XSync (dpy, False);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [RP] [PATCH] centring the bar and 'defbargravity center',
Doug Kearns <=