]> Pileus Git - ~andy/gtk/commitdiff
Beginnings of support for 1 bpp depth in gdk. Very minor changes.
authorShawn Amundson <amundson@src.gnome.org>
Sat, 20 Dec 1997 08:39:21 +0000 (08:39 +0000)
committerShawn Amundson <amundson@src.gnome.org>
Sat, 20 Dec 1997 08:39:21 +0000 (08:39 +0000)
Most of testgtk runs on 1 bpp.  Nothing much else will work until
gdkcc is used for gtk_preview and other color-intensive things.

-Shawn

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gdk/gdkcolor.c
gdk/gdkvisual.c
gdk/x11/gdkcolor-x11.c
gdk/x11/gdkvisual-x11.c

index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index d0775959caa9cabdbab98ff7982ca6ec16e455a3..df2c30f4c1d14d51abbed0536a7e65b9e715840f 100644 (file)
@@ -1,4 +1,8 @@
 
+Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
+
+        * GDK support for 1 bpp depth screens.
+
 Thu Dec 18 23:46:11 CST 1997 Shawn T. Amundson <amundson@gimp.org>
 
        * Changes from Bolliet Jerome <bolliet@in2p3.fr> to gtktree.
index 3ad8df8d9d00122417c9af36e640578105a7c648..5da61f063c5456fd19380010f2b1d448dfca1f0b 100644 (file)
@@ -182,7 +182,8 @@ gdk_colormap_get_system (void)
          xpalette[i].blue = 0;
        }
 
-      XQueryColors (gdk_display, private->xcolormap, xpalette, 256);
+      XQueryColors (gdk_display, private->xcolormap, xpalette, 
+                    private->visual->colormap_size);
 
       for (i = 0; i < 256; i++)
        {
index 22acee6f13966bf1d7ac4864265384a32b7de59e..bb9388f208a71228757265fd6e1b74224ecf3c6e 100644 (file)
@@ -55,7 +55,7 @@ static GHashTable *visual_hash = NULL;
 void
 gdk_visual_init ()
 {
-  static gint possible_depths[5] = { 32, 24, 16, 15, 8 };
+  static gint possible_depths[6] = { 32, 24, 16, 15, 8, 1 };
   static GdkVisualType possible_types[6] =
     {
       GDK_VISUAL_DIRECT_COLOR,
@@ -66,7 +66,7 @@ gdk_visual_init ()
       GDK_VISUAL_STATIC_GRAY
     };
 
-  static gint npossible_depths = 5;
+  static gint npossible_depths = 6;
   static gint npossible_types = 6;
 
   XVisualInfo *visual_list;
@@ -85,7 +85,7 @@ gdk_visual_init ()
   nvisuals = 0;
   for (i = 0; i < nxvisuals; i++)
     {
-      if (visual_list[i].depth >= 8)
+      if (visual_list[i].depth >= 1)
        {
 #ifdef __cplusplus
          switch (visual_list[i].c_class)
index 3ad8df8d9d00122417c9af36e640578105a7c648..5da61f063c5456fd19380010f2b1d448dfca1f0b 100644 (file)
@@ -182,7 +182,8 @@ gdk_colormap_get_system (void)
          xpalette[i].blue = 0;
        }
 
-      XQueryColors (gdk_display, private->xcolormap, xpalette, 256);
+      XQueryColors (gdk_display, private->xcolormap, xpalette, 
+                    private->visual->colormap_size);
 
       for (i = 0; i < 256; i++)
        {
index 22acee6f13966bf1d7ac4864265384a32b7de59e..bb9388f208a71228757265fd6e1b74224ecf3c6e 100644 (file)
@@ -55,7 +55,7 @@ static GHashTable *visual_hash = NULL;
 void
 gdk_visual_init ()
 {
-  static gint possible_depths[5] = { 32, 24, 16, 15, 8 };
+  static gint possible_depths[6] = { 32, 24, 16, 15, 8, 1 };
   static GdkVisualType possible_types[6] =
     {
       GDK_VISUAL_DIRECT_COLOR,
@@ -66,7 +66,7 @@ gdk_visual_init ()
       GDK_VISUAL_STATIC_GRAY
     };
 
-  static gint npossible_depths = 5;
+  static gint npossible_depths = 6;
   static gint npossible_types = 6;
 
   XVisualInfo *visual_list;
@@ -85,7 +85,7 @@ gdk_visual_init ()
   nvisuals = 0;
   for (i = 0; i < nxvisuals; i++)
     {
-      if (visual_list[i].depth >= 8)
+      if (visual_list[i].depth >= 1)
        {
 #ifdef __cplusplus
          switch (visual_list[i].c_class)