systray.area.posx = panel->area.width - panel->area.paddingxlr - panel->area.pix.border.width - systray.area.width;
if (panel->clock.area.on_screen)
systray.area.posx -= (panel->clock.area.width + panel->area.paddingx);
+ if (panel->battery.area.on_screen)
+ systray.area.posx -= (panel->battery.area.width + panel->area.paddingx);
systray.area.redraw = 1;
}
GSList *l;
int icon_size;
- printf("draw_systray %d %d\n", systray.area.posx, systray.area.width);
+ //printf("draw_systray %d %d\n", systray.area.posx, systray.area.width);
icon_size = sysbar->area.height - (2 * sysbar->area.pix.border.width) - (2 * sysbar->area.paddingy);
for (l = systray.list_icons; l ; l = l->next) {
traywin = (TrayWindow*)l->data;
// watch for the icon trying to resize itself!
- XSelectInput(server.dsp, traywin->id, StructureNotifyMask);
+ XSelectInput(server.dsp, traywin->id, StructureNotifyMask|ResizeRedirectMask);
// position and size the icon window
XMoveResizeWindow(server.dsp, traywin->id, traywin->x, traywin->y, icon_size, icon_size);
+ // ceci intervertie les fonds : le premier icone prend le fond du dernier
+ // le dernier prend le fond de l'avant dernier, ...
+ XSetWindowBackgroundPixmap (server.dsp, panel->main_win, systray.area.pix.pmap);
// resize our window so that the new window can fit in it
//fix_geometry();
systray.area.posx = panel->area.width - panel->area.pix.border.width - panel->area.paddingxlr - systray.area.width;
if (panel->clock.area.on_screen)
systray.area.posx -= (panel->clock.area.width + panel->area.paddingx);
+ if (panel->battery.area.on_screen)
+ systray.area.posx -= (panel->battery.area.width + panel->area.paddingx);
systray.area.redraw = 1;