diff --git a/ChangeLog b/ChangeLog index 6b20170..af5c093 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2682,3 +2682,11 @@ Thu Oct 28 16:17:21 PDT 1999 Michael Jennings theme files. ------------------------------------------------------------------------------- +Thu Oct 28 20:11:15 PDT 1999 Michael Jennings + + Fixed a couple problems pointed out by Joel Lesher + and Rahsheen Porter + regarding tinted/shaded transparency and a typo in the auto mode + theme file. Doh! + +------------------------------------------------------------------------------- diff --git a/src/Makefile.am b/src/Makefile.am index 217ee7a..0e0b34f 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -15,5 +15,5 @@ Eterm_LDFLAGS = -rpath $(libdir):$(pkglibdir) INCLUDES = -I. -I$(top_srcdir) -I$(top_srcdir)/libmej -I.. -I$(includedir) -I$(prefix)/include $(X_CFLAGS) LDADD = libEterm.la $(top_builddir)/libmej/libmej.la -L$(libdir) -L$(prefix)/lib $(LIBS) $(GRLIBS) $(X_LIBS) -EXTRA_DIST = actions.h command.h debug.h e.h eterm_utmp.h events.h feature.h font.h grkelot.h grx.h menus.h misc.h options.h \ +EXTRA_DIST = actions.h command.h debug.h e.h eterm_utmp.h events.h feature.h font.h grkelot.h menus.h misc.h options.h \ pixmap.h profile.h screen.h scrollbar.h startup.h system.h term.h timer.h windows.h Eterm.xpm diff --git a/src/pixmap.c b/src/pixmap.c index ca3a852..f7dbaf8 100644 --- a/src/pixmap.c +++ b/src/pixmap.c @@ -275,6 +275,8 @@ reset_simage(simage_t * simg, unsigned long mask) ASSERT(simg != NULL); + D_PIXMAP(("reset_simage(%8p, 0x%08x)\n", simg, mask)); + if ((mask & RESET_IMLIB_IM) && simg->iml->im) { Imlib_destroy_image(imlib_id, simg->iml->im); simg->iml->im = NULL; @@ -568,24 +570,6 @@ render_simage(simage_t * simg, Window win, unsigned short width, unsigned short if (desktop_pixmap == None) { get_desktop_pixmap(); last_x = last_y = -1; - if (desktop_pixmap != None && need_colormod()) { - pixmap = desktop_pixmap; - XGetGeometry(Xdisplay, desktop_pixmap, &w, &px, &py, &pw, &ph, &pb, &pd); - D_PIXMAP(("render_simage(): XGetGeometry() returned w = 0x%08x, pw == %u, ph == %u\n", w, pw, ph)); - if (pw < (unsigned int) scr->width || ph < (unsigned int) scr->height) { - desktop_pixmap = XCreatePixmap(Xdisplay, win, pw, ph, Xdepth); - XCopyArea(Xdisplay, pixmap, desktop_pixmap, gc, 0, 0, pw, ph, 0, 0); - colormod_trans(desktop_pixmap, gc, pw, ph); - } else { - desktop_pixmap = XCreatePixmap(Xdisplay, win, scr->width, scr->height, Xdepth); - XCopyArea(Xdisplay, pixmap, desktop_pixmap, gc, 0, 0, scr->width, scr->height, 0, 0); - colormod_trans(desktop_pixmap, gc, scr->width, scr->height); - } - desktop_pixmap_is_mine = 1; - pixmap = None; - } else { - desktop_pixmap_is_mine = 0; - } } if (desktop_pixmap != None) { XTranslateCoordinates(Xdisplay, win, desktop_window, 0, 0, &x, &y, &w); @@ -1235,7 +1219,34 @@ get_desktop_pixmap(void) } else { D_PIXMAP(("get_desktop_pixmap(): Desktop pixmap has changed. Updating desktop_pixmap\n")); free_desktop_pixmap(); - return (desktop_pixmap = p); + if (need_colormod()) { + int px, py; + unsigned int pw, ph, pb, pd; + Window w; + GC gc; + XGCValues gcvalue; + Screen *scr = ScreenOfDisplay(Xdisplay, Xscreen); + + gcvalue.foreground = gcvalue.background = PixColors[bgColor]; + gc = XCreateGC(Xdisplay, TermWin.vt, GCForeground | GCBackground, &gcvalue); + XGetGeometry(Xdisplay, p, &w, &px, &py, &pw, &ph, &pb, &pd); + D_PIXMAP(("get_desktop_pixmap(): XGetGeometry() returned w = 0x%08x, pw == %u, ph == %u\n", w, pw, ph)); + if (pw < (unsigned int) scr->width || ph < (unsigned int) scr->height) { + desktop_pixmap = XCreatePixmap(Xdisplay, TermWin.parent, pw, ph, Xdepth); + XCopyArea(Xdisplay, p, desktop_pixmap, gc, 0, 0, pw, ph, 0, 0); + colormod_trans(desktop_pixmap, gc, pw, ph); + } else { + desktop_pixmap = XCreatePixmap(Xdisplay, TermWin.vt, scr->width, scr->height, Xdepth); + XCopyArea(Xdisplay, p, desktop_pixmap, gc, 0, 0, scr->width, scr->height, 0, 0); + colormod_trans(desktop_pixmap, gc, scr->width, scr->height); + } + XFreeGC(Xdisplay, gc); + desktop_pixmap_is_mine = 1; + return (desktop_pixmap); + } else { + desktop_pixmap_is_mine = 0; + return (desktop_pixmap = p); + } } } } @@ -1258,6 +1269,7 @@ get_desktop_pixmap(void) color_pixmap = XCreatePixmap(Xdisplay, TermWin.vt, 16, 16, Xdepth); XFillRectangle(Xdisplay, color_pixmap, gc, 0, 0, 16, 16); D_PIXMAP(("get_desktop_pixmap(): Created solid color pixmap 0x%08x for desktop_pixmap.\n", color_pixmap)); + XFreeGC(Xdisplay, gc); return (desktop_pixmap = color_pixmap); } } diff --git a/themes/auto/theme.cfg.in b/themes/auto/theme.cfg.in index 26fb6fc..c7d94c8 100644 --- a/themes/auto/theme.cfg.in +++ b/themes/auto/theme.cfg.in @@ -217,7 +217,7 @@ begin main end image end -%include "Eterm-menu.cfg" +%include "auto-menu.cfg" # This section *must* come after the menu definitions if you want # menu actions to work. C'est la vie. :-)