From d04b2d02cde69e686c53a9f98d34aede24d2ef5c Mon Sep 17 00:00:00 2001 From: deuce <> Date: Thu, 22 May 2003 22:12:02 +0000 Subject: [PATCH] Tested working final WIN_MID fixes. --- src/uifc/uifc32.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/uifc/uifc32.c b/src/uifc/uifc32.c index 05a47927aa..b78706c9d9 100644 --- a/src/uifc/uifc32.c +++ b/src/uifc/uifc32.c @@ -403,11 +403,11 @@ int ulist(int mode, int left, int top, int width, int *cur, int *bar } } if(mode&WIN_L2R) - left=(api->scrn_width-width)/2-s_left+1; + left=(api->scrn_width-width+1)/2-s_left; else if(mode&WIN_RHT) left=api->scrn_width-(width+4+left); if(mode&WIN_T2B) - top=(api->scrn_len/2)-(height/2)-2; + top=(api->scrn_len-height+1)/2-2; else if(mode&WIN_BOT) top=api->scrn_len-height-3-top; @@ -1141,9 +1141,9 @@ int uinput(int mode, int left, int top, char *prompt, char *str, slen=6; width=plen+slen+max; if(mode&WIN_T2B) - top=(api->scrn_len/2)-(height/2)-2; + top=(api->scrn_len-height+1)/2-2; if(mode&WIN_L2R) - left=(api->scrn_width-width)/2-SCRN_LEFT+1; + left=(api->scrn_width-width+1)/2-SCRN_LEFT; if(mode&WIN_SAV) gettext(SCRN_LEFT+left,SCRN_TOP+top,SCRN_LEFT+left+width+1 ,SCRN_TOP+top+height,save_buf); @@ -1668,11 +1668,11 @@ void showbuf(int mode, int left, int top, int width, int height, char *title, ch if(width>api->scrn_width) width=api->scrn_width; if(mode&WIN_L2R) - left=(api->scrn_width-width)/2+1; + left=(api->scrn_width-width+1)/2; else if(mode&WIN_RHT) left=api->scrn_width-(width+4+left); if(mode&WIN_T2B) - top=(api->scrn_len/2)-(height/2); + top=(api->scrn_len-height+1)/2; else if(mode&WIN_BOT) top=api->scrn_len-height-3-top; -- GitLab