[gtk+] Deprecate gdk_visual_get_bits_per_rgb



commit aa4c5459b77b7afd6885290f5159d9828edbfcb1
Author: Matthias Clasen <mclasen redhat com>
Date:   Sat Mar 26 14:20:23 2016 -0400

    Deprecate gdk_visual_get_bits_per_rgb
    
    This function is pretty useless, since the Wayland backend returns
    0 for this, and the Windows backend 42 (!).

 gdk/gdkvisual.c |    3 +++
 gdk/gdkvisual.h |    2 +-
 2 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/gdk/gdkvisual.c b/gdk/gdkvisual.c
index 356ea19..e3c5b6f 100644
--- a/gdk/gdkvisual.c
+++ b/gdk/gdkvisual.c
@@ -338,10 +338,13 @@ gdk_visual_get_colormap_size (GdkVisual *visual)
  * @visual: a #GdkVisual
  *
  * Returns the number of significant bits per red, green and blue value.
+ * Not all GDK backend provide a meaningful value for this function.
  *
  * Returns: The number of significant bits per color value for @visual.
  *
  * Since: 2.22
+ *
+ * Deprecated: 3.22. Use gdk_visual_get_red_pixel_details() and its variants
  */
 gint
 gdk_visual_get_bits_per_rgb (GdkVisual *visual)
diff --git a/gdk/gdkvisual.h b/gdk/gdkvisual.h
index 3d0f76e..3f603a3 100644
--- a/gdk/gdkvisual.h
+++ b/gdk/gdkvisual.h
@@ -119,7 +119,7 @@ GDK_AVAILABLE_IN_ALL
 GdkByteOrder  gdk_visual_get_byte_order          (GdkVisual *visual);
 GDK_AVAILABLE_IN_ALL
 gint          gdk_visual_get_colormap_size       (GdkVisual *visual);
-GDK_AVAILABLE_IN_ALL
+GDK_DEPRECATED_IN_3_22
 gint          gdk_visual_get_bits_per_rgb        (GdkVisual *visual);
 GDK_AVAILABLE_IN_ALL
 void          gdk_visual_get_red_pixel_details   (GdkVisual *visual,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]