/*
* ion/ioncore/infowin.h
*
- * Copyright (c) Tuomo Valkonen 1999-2007.
+ * Copyright (c) Tuomo Valkonen 1999-2009.
*
- * Ion is free software; you can redistribute it and/or modify it under
- * the terms of the GNU Lesser General Public License as published by
- * the Free Software Foundation; either version 2.1 of the License, or
- * (at your option) any later version.
+ * See the included file LICENSE for details.
*/
#include <string.h>
if(p->brush==NULL)
goto fail3;
- p->wwin.region.flags|=REGION_SKIP_FOCUS;
-
/* Enable save unders */
attr.save_under=True;
XChangeWindowAttributes(ioncore_g.dpy, p->wwin.win, CWSaveUnder, &attr);
{
bool set=FALSE;
- if(maxw>0 && p->brush!=NULL){
- char *tmp=grbrush_make_label(p->brush, str, maxw);
- if(tmp!=NULL){
- infowin_do_set_text(p, tmp);
- free(tmp);
- set=TRUE;
+ if(str==NULL){
+ INFOWIN_BUFFER(p)[0]='\0';
+ }else{
+ if(maxw>0 && p->brush!=NULL){
+ char *tmp=grbrush_make_label(p->brush, str, maxw);
+ if(tmp!=NULL){
+ infowin_do_set_text(p, tmp);
+ free(tmp);
+ set=TRUE;
+ }
}
+
+ if(!set)
+ infowin_do_set_text(p, str);
}
- if(!set)
- infowin_do_set_text(p, str);
-
infowin_resize(p);
/* sometimes unnecessary */