aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGerd Moellmann2000-03-19 17:00:51 +0000
committerGerd Moellmann2000-03-19 17:00:51 +0000
commit94ac875b4113108a02e2a2c15df16d77acadc557 (patch)
treeda36b6c38bb119911ba8087c42bb2baf6f26f1ab /src
parentb75c9917dfffa2da2f97c4e3f8ffa4753dfab06e (diff)
downloademacs-94ac875b4113108a02e2a2c15df16d77acadc557.tar.gz
emacs-94ac875b4113108a02e2a2c15df16d77acadc557.zip
* xfns.c (select_visual): Don't set dpyinfo->n_planes to the
number of bits per RGB because it's everywhere used as the depth of the visual.
Diffstat (limited to 'src')
-rw-r--r--src/xfns.c15
1 files changed, 1 insertions, 14 deletions
diff --git a/src/xfns.c b/src/xfns.c
index 8ed9b7d98d9..a08f74eccbf 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -4622,20 +4622,7 @@ select_visual (dpyinfo)
4622 if (n_visuals != 1) 4622 if (n_visuals != 1)
4623 fatal ("Can't get proper X visual info"); 4623 fatal ("Can't get proper X visual info");
4624 4624
4625 if ((1 << vinfo->depth) == vinfo->colormap_size) 4625 dpyinfo->n_planes = vinfo->depth;
4626 dpyinfo->n_planes = vinfo->depth;
4627 else
4628 {
4629 int i = 0;
4630 int n = vinfo->colormap_size - 1;
4631 while (n)
4632 {
4633 n = n >> 1;
4634 i++;
4635 }
4636 dpyinfo->n_planes = i;
4637 }
4638
4639 XFree ((char *) vinfo); 4626 XFree ((char *) vinfo);
4640 } 4627 }
4641} 4628}