aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2014-09-30 10:55:23 +0000
committerDimitri Sokolyuk <demon@dim13.org>2014-09-30 10:55:23 +0000
commit51114157d83ef3d4a2347de58a97e62d4e8cd065 (patch)
treecf132ce89147a25ee4551daa0c94907c243c18db
parentdc278e9146df0f93d2eced744fc48bf3023cb153 (diff)
drop space resource, at it is covered by border
-rw-r--r--Display.c20
-rw-r--r--DisplayP.h1
2 files changed, 7 insertions, 14 deletions
diff --git a/Display.c b/Display.c
index 1212950..7b0aea1 100644
--- a/Display.c
+++ b/Display.c
@@ -18,8 +18,6 @@ static Boolean SetValues(Widget, Widget, Widget, ArgList, Cardinal *);
#define Offset(field) XtOffsetOf(DisplayRec, display.field)
static XtResource resources[] = {
- { XtNspace, XtCSpace, XtRDimension, sizeof(Dimension),
- Offset(space), XtRImmediate, (XtPointer)2 },
{ XtNdata, XtCData, XtRPointer, sizeof(int **),
Offset(data), XtRPointer, NULL },
};
@@ -121,13 +119,11 @@ ChangeManaged(Widget w)
XtSetArg(arg, XtNdata, &dw->display.data[i]);
XtGetValues(child, &arg, 1);
XtMoveWidget(child,
- width + dw->display.space, dw->display.space);
+ width, 0);
width += child->core.width
- + 2 * child->core.border_width
- + 2 * dw->display.space;
+ + 2 * child->core.border_width;
height = child->core.height
- + 2 * child->core.border_width
- + 2 * dw->display.space;
+ + 2 * child->core.border_width;
}
}
w->core.width = width;
@@ -145,16 +141,14 @@ Resize(Widget w)
Trace(w);
- width = w->core.width / n - 2 * dw->display.space;
- height = w->core.height - 2 * dw->display.space;
+ width = w->core.width / n;
+ height = w->core.height;
for (i = 0; i < dw->composite.num_children; i++) {
child = dw->composite.children[i];
if (XtIsManaged(child)) {
- x = i * (width + dw->display.space
- + child->core.border_width)
- + dw->display.space;
- y = dw->display.space;
+ x = i * (width + child->core.border_width);
+ y = 0;
XtConfigureWidget(child, x, y,
width - 2 * child->core.border_width,
height - 2 * child->core.border_width,
diff --git a/DisplayP.h b/DisplayP.h
index f58ffca..668843e 100644
--- a/DisplayP.h
+++ b/DisplayP.h
@@ -6,7 +6,6 @@
#include "Display.h"
typedef struct {
- Dimension space;
int **data;
} DisplayPart;