Skip to content

Commit

Permalink
hiding: unmap instead of rezise
Browse files Browse the repository at this point in the history
otherwise a 1px border will stay visible.
This is especially annoying in bottom-placement.
  • Loading branch information
Christopher Zimmermann committed Feb 4, 2022
1 parent 488ab66 commit d9785c6
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions action.c
Original file line number Diff line number Diff line change
Expand Up @@ -390,9 +390,9 @@ a_hide(char * opt[]) {
printf("n:%d\n", n);
if(!dzen.title_win.ishidden) {
if(!dzen.slave_win.ishmenu)
XResizeWindow(dzen.dpy, dzen.title_win.win, dzen.title_win.width, 1);
XUnmapWindow(dzen.dpy, dzen.title_win.win);
else
XResizeWindow(dzen.dpy, dzen.slave_win.win, dzen.title_win.width, 1);
XUnmapWindow(dzen.dpy, dzen.slave_win.win);

dzen.title_win.ishidden = True;
}
Expand All @@ -404,9 +404,9 @@ a_unhide(char * opt[]) {
(void)opt;
if(dzen.title_win.ishidden) {
if(!dzen.slave_win.ishmenu)
XResizeWindow(dzen.dpy, dzen.title_win.win, dzen.title_win.width, dzen.line_height);
XMapWindow(dzen.dpy, dzen.title_win.win);
else
XResizeWindow(dzen.dpy, dzen.slave_win.win, dzen.title_win.width, dzen.line_height);
XMapWindow(dzen.dpy, dzen.slave_win.win);

dzen.title_win.ishidden = False;
}
Expand Down

0 comments on commit d9785c6

Please # to comment.