From 9777b14fb73b0a8d60209c2e3d7acee76717112c Mon Sep 17 00:00:00 2001 From: "Carlos R. Mafra" Date: Sat, 13 Aug 2011 14:55:21 +0200 Subject: [PATCH] Increase height of 'Attributes' window With the addition of an extra button to the 'Advanced Options' window, the vertical space of the widget no longer suffices. Increase it from 350 to 360 and adjust other parameters accordingly. And let's write the button positions as 'PHEIGHT - 40' instead of using a hardcoded value, avoiding the need to change it everytime PHEIGHT is changed. Signed-off-by: Carlos R. Mafra --- src/winspector.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/winspector.c b/src/winspector.c index 23af4d2c..adaf8b73 100644 --- a/src/winspector.c +++ b/src/winspector.c @@ -160,7 +160,7 @@ static WMPropList *EmptyString; static WMPropList *Yes, *No; #define PWIDTH 290 -#define PHEIGHT 350 +#define PHEIGHT 360 static char *spec_text; static void applySettings(WMButton * button, InspectorPanel * panel); @@ -1143,7 +1143,7 @@ static InspectorPanel *createInspectorForWindow(WWindow * wwin, int xpos, int yp btn_width = (PWIDTH - (2 * 15) - (2 * 10)) / 3; panel->saveBtn = WMCreateCommandButton(panel->win); WMSetButtonAction(panel->saveBtn, (WMAction *) saveSettings, panel); - WMMoveWidget(panel->saveBtn, (2 * (btn_width + 10)) + 15, 310); + WMMoveWidget(panel->saveBtn, (2 * (btn_width + 10)) + 15, PHEIGHT - 40); WMSetButtonText(panel->saveBtn, _("Save")); WMResizeWidget(panel->saveBtn, btn_width, 28); if (wPreferences.flags.noupdates || !(wwin->wm_class || wwin->wm_instance)) @@ -1151,13 +1151,13 @@ static InspectorPanel *createInspectorForWindow(WWindow * wwin, int xpos, int yp panel->applyBtn = WMCreateCommandButton(panel->win); WMSetButtonAction(panel->applyBtn, (WMAction *) applySettings, panel); - WMMoveWidget(panel->applyBtn, btn_width + 10 + 15, 310); + WMMoveWidget(panel->applyBtn, btn_width + 10 + 15, PHEIGHT - 40); WMSetButtonText(panel->applyBtn, _("Apply")); WMResizeWidget(panel->applyBtn, btn_width, 28); panel->revertBtn = WMCreateCommandButton(panel->win); WMSetButtonAction(panel->revertBtn, (WMAction *) revertSettings, panel); - WMMoveWidget(panel->revertBtn, 15, 310); + WMMoveWidget(panel->revertBtn, 15, PHEIGHT - 40); WMSetButtonText(panel->revertBtn, _("Reload")); WMResizeWidget(panel->revertBtn, btn_width, 28); @@ -1334,7 +1334,7 @@ static InspectorPanel *createInspectorForWindow(WWindow * wwin, int xpos, int yp panel->moreFrm = WMCreateFrame(panel->win); WMSetFrameTitle(panel->moreFrm, _("Advanced")); WMMoveWidget(panel->moreFrm, 15, 45); - WMResizeWidget(panel->moreFrm, frame_width, 250); + WMResizeWidget(panel->moreFrm, frame_width, 265); for (i = 0; #ifdef XKB_BUTTON_HINT