[gtk+/gtk-2-90: 141/158] [gdk] Remove deprecated GdkRGB stuff
- From: Javier Jardón <jjardon src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/gtk-2-90: 141/158] [gdk] Remove deprecated GdkRGB stuff
- Date: Thu, 11 Mar 2010 02:55:24 +0000 (UTC)
commit 5dbea74f67beb6f2e8eafcb2bd8343658a4631c6
Author: Javier Jardón <jjardon gnome org>
Date: Thu Nov 26 05:48:52 2009 +0100
[gdk] Remove deprecated GdkRGB stuff
.../gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml | 8 ----
docs/reference/gdk/gdk-sections.txt | 4 --
docs/reference/gdk/tmpl/rgb.sgml | 39 -----------------
gdk/gdk.symbols | 6 ---
gdk/gdkrgb.c | 45 --------------------
gdk/gdkrgb.h | 11 -----
6 files changed, 0 insertions(+), 113 deletions(-)
---
diff --git a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
index 128ca4a..a9891e0 100644
--- a/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
+++ b/docs/reference/gdk-pixbuf/tmpl/gdk-pixbuf-unused.sgml
@@ -215,14 +215,6 @@ GnomeCanvasPixbuf
and use that to draw the image onto a drawable.
</para>
- <important>
- <para>
- Since these functions use GdkRGB for rendering, you must
- initialize GdkRGB before using any of them. You can do this by
- calling gdk_rgb_init() near the beginning of your program.
- </para>
- </important>
-
<!-- ##### SECTION ./tmpl/rendering.sgml:See_Also ##### -->
<para>
diff --git a/docs/reference/gdk/gdk-sections.txt b/docs/reference/gdk/gdk-sections.txt
index a4c99e6..98d32ba 100644
--- a/docs/reference/gdk/gdk-sections.txt
+++ b/docs/reference/gdk/gdk-sections.txt
@@ -305,7 +305,6 @@ gdk_image_get_type
<SECTION>
<TITLE>GdkRGB</TITLE>
<FILE>rgb</FILE>
-gdk_rgb_init
<SUBSECTION>
gdk_draw_rgb_image
@@ -322,9 +321,6 @@ gdk_rgb_cmap_free
GdkRgbCmap
<SUBSECTION>
-gdk_rgb_gc_set_foreground
-gdk_rgb_gc_set_background
-gdk_rgb_xpixel_from_rgb
gdk_rgb_find_color
<SUBSECTION>
diff --git a/docs/reference/gdk/tmpl/rgb.sgml b/docs/reference/gdk/tmpl/rgb.sgml
index 000f2ce..857558d 100644
--- a/docs/reference/gdk/tmpl/rgb.sgml
+++ b/docs/reference/gdk/tmpl/rgb.sgml
@@ -125,14 +125,6 @@ colors.</para></listitem>
<!-- ##### SECTION Stability_Level ##### -->
-<!-- ##### FUNCTION gdk_rgb_init ##### -->
-<para>
-This function no longer does anything at all. It's completely useless
-(and harmless).
-</para>
-
-
-
<!-- ##### FUNCTION gdk_draw_rgb_image ##### -->
<para>
Draws an RGB image in the drawable. This is the core GdkRGB
@@ -328,37 +320,6 @@ colors. This is used only for gdk_draw_indexed_image().
@colors: The colors, represented as 0xRRGGBB integer values.
@n_colors: The number of colors in the cmap.
-<!-- ##### FUNCTION gdk_rgb_gc_set_foreground ##### -->
-<para>
-Sets the foreground color in @gc to the specified color (or the
-closest approximation, in the case of limited visuals).
-</para>
-
- gc: The #GdkGC to modify.
- rgb: The color, represented as a 0xRRGGBB integer value.
-
-
-<!-- ##### FUNCTION gdk_rgb_gc_set_background ##### -->
-<para>
-Sets the background color in @gc to the specified color (or the
-closest approximation, in the case of limited visuals).
-</para>
-
- gc: The #GdkGC to modify.
- rgb: The color, represented as a 0xRRGGBB integer value.
-
-
-<!-- ##### FUNCTION gdk_rgb_xpixel_from_rgb ##### -->
-<para>
-Finds the X pixel closest in color to the @rgb color specified. This
-value may be used to set the <structfield>pixel</structfield> field of
-a #GdkColor struct.
-</para>
-
- rgb: The color, represented as a 0xRRGGBB integer value.
- Returns: The X pixel value.
-
-
<!-- ##### FUNCTION gdk_rgb_find_color ##### -->
<para>
diff --git a/gdk/gdk.symbols b/gdk/gdk.symbols
index 4e71d18..226f712 100644
--- a/gdk/gdk.symbols
+++ b/gdk/gdk.symbols
@@ -978,12 +978,6 @@ gdk_rgb_ditherable
gdk_rgb_find_color
gdk_rgb_get_colormap
gdk_rgb_get_visual
-#ifndef GDK_DISABLE_DEPRECATED
-gdk_rgb_init
-gdk_rgb_xpixel_from_rgb G_GNUC_CONST
-gdk_rgb_gc_set_background
-gdk_rgb_gc_set_foreground
-#endif
gdk_rgb_set_install
gdk_rgb_set_min_colors
gdk_rgb_set_verbose
diff --git a/gdk/gdkrgb.c b/gdk/gdkrgb.c
index 347ff59..6b0ad9b 100644
--- a/gdk/gdkrgb.c
+++ b/gdk/gdkrgb.c
@@ -672,21 +672,6 @@ gdk_rgb_create_info (GdkVisual *visual, GdkColormap *colormap)
return image_info;
}
-void
-gdk_rgb_init (void)
-{
- static const gint byte_order[1] = { 1 };
-
- /* check endian sanity */
-#if G_BYTE_ORDER == G_BIG_ENDIAN
- if (((char *)byte_order)[0] == 1)
- g_error ("gdk_rgb_init: compiled for big endian, but this is a little endian machine.\n\n");
-#else
- if (((char *)byte_order)[0] != 1)
- g_error ("gdk_rgb_init: compiled for little endian, but this is a big endian machine.\n\n");
-#endif
-}
-
static GdkRgbInfo *
gdk_rgb_get_info_from_colormap (GdkColormap *cmap)
{
@@ -779,36 +764,6 @@ gdk_rgb_xpixel_from_rgb_internal (GdkColormap *colormap,
return pixel;
}
-/* convert an rgb value into an X pixel code */
-gulong
-gdk_rgb_xpixel_from_rgb (guint32 rgb)
-{
- guint32 r = rgb & 0xff0000;
- guint32 g = rgb & 0xff00;
- guint32 b = rgb & 0xff;
-
- return gdk_rgb_xpixel_from_rgb_internal (gdk_screen_get_rgb_colormap (gdk_screen_get_default ()),
- (r >> 8) + (r >> 16), g + (g >> 8), b + (b << 8));
-}
-
-void
-gdk_rgb_gc_set_foreground (GdkGC *gc, guint32 rgb)
-{
- GdkColor color;
-
- color.pixel = gdk_rgb_xpixel_from_rgb (rgb);
- gdk_gc_set_foreground (gc, &color);
-}
-
-void
-gdk_rgb_gc_set_background (GdkGC *gc, guint32 rgb)
-{
- GdkColor color;
-
- color.pixel = gdk_rgb_xpixel_from_rgb (rgb);
- gdk_gc_set_background (gc, &color);
-}
-
/**
* gdk_rgb_find_color:
* @colormap: a #GdkColormap
diff --git a/gdk/gdkrgb.h b/gdk/gdkrgb.h
index 3136e9a..919ac35 100644
--- a/gdk/gdkrgb.h
+++ b/gdk/gdkrgb.h
@@ -45,17 +45,6 @@ struct _GdkRgbCmap {
GSList *info_list;
};
-#ifndef GDK_DISABLE_DEPRECATED
-void gdk_rgb_init (void);
-
-gulong gdk_rgb_xpixel_from_rgb (guint32 rgb) G_GNUC_CONST;
-void gdk_rgb_gc_set_foreground (GdkGC *gc,
- guint32 rgb);
-void gdk_rgb_gc_set_background (GdkGC *gc,
- guint32 rgb);
-#define gdk_rgb_get_cmap gdk_rgb_get_colormap
-#endif /* GDK_DISABLE_DEPRECATED */
-
void gdk_rgb_find_color (GdkColormap *colormap,
GdkColor *color);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]