Subject: FVWM CVS: fvwm hippo

From: CVS <[email-masked]>
Date: Tue, 30 Mar 1999 07:38:17 -0600 (CST)

CVSROOT:	/home/cvs/fvwm
Module name:	fvwm
Changes by:	hippo	99/03/30 07:38:17

Modified files:
	.              : ChangeLog 
	fvwm           : add_window.c builtins.c colors.c fvwm.c icons.c 
	                 menus.c screen.h 

Log message:
#define PICK_TRUECOLOR to get fvwm to use non-default visual, it doesn't
work.  Help!!

--
Visit the official FVWM web page at <URL:http://www.fvwm.org/>.
To unsubscribe from the list, send "unsubscribe fvwm-workers" in the
body of a message to [email-masked].
To report problems, send mail to [email-masked]

---

From: Tim Phipps <[email-masked]>
Date: Tue, 30 Mar 1999 14:48:17 +0100

> #define PICK_TRUECOLOR to get fvwm to use non-default visual, it doesn't

Here's the section of code that tries to pick a better visual

  /* grab a TrueColor visual */
  if (XMatchVisualInfo(dpy, Scr.screen, DefaultDepth(dpy, Scr.screen),
                       TrueColor, &vizinfo)) {
    Scr.viz = vizinfo.visual;
    Scr.depth = vizinfo.depth;
  }
  else
  {
    Scr.viz = DefaultVisual(dpy, Scr.screen);
    Scr.depth = DefaultDepth(dpy, Scr.screen);
  }

This works fine but the following call gives a BadMatch error

  attributes.event_mask = KeyPressMask|FocusChangeMask;
  attributes.override_redirect = True;
  Scr.NoFocusWin=XCreateWindow(dpy, Scr.Root, -10, -10, 10, 10, 0,
Scr.depth,
                               InputOutput, Scr.viz,
                               CWEventMask | CWOverrideRedirect,
&attributes);

Can anyone shed any light on this?

Cheers,
Tim.