doc comment fixes.

This commit is contained in:
Matthias Clasen 2002-10-29 21:27:17 +00:00
parent ec84d8d14d
commit d00b2b0a4a
9 changed files with 69 additions and 23 deletions

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -1,5 +1,13 @@
2002-10-29 Matthias Clasen <maclas@gmx.de>
* gdk/x11/gdkcolor-x11.c (gdk_colors_free): Use the same parameter
names in header, docs and implementation.
* gdk/gdkcolor.c (gdk_colors_store): Doc comment fix.
* gdk/x11/gdkcursor-x11.c (gdk_cursor_new_from_pixmap): Fix
example in doc comment.
* gtk/gtkiconfactory.c (gtk_icon_size_lookup_for_settings):
* gtk/gtkfilesel.c (gtk_file_selection_get_selections): Doc
comment fixes. (#97136, #97125, Vitaly Tishkov)

View File

@ -82,8 +82,6 @@ gdk_colormap_get_visual (GdkColormap *colormap)
* Changes the value of the first @ncolors colors in
* a private colormap. This function is obsolete and
* should not be used. See gdk_color_change().
*
* Return value:
**/
void
gdk_colors_store (GdkColormap *colormap,

View File

@ -604,8 +604,8 @@ gdk_colors_alloc (GdkColormap *colormap,
/**
* gdk_colors_free:
* @colormap: a #GdkColormap.
* @in_pixels: the pixel values of the colors to free.
* @in_npixels: the number of values in @pixels.
* @pixels: the pixel values of the colors to free.
* @npixels: the number of values in @pixels.
* @planes: the plane masks for all planes to free, OR'd together.
*
* Frees colors allocated with gdk_colors_alloc(). This
@ -613,17 +613,17 @@ gdk_colors_alloc (GdkColormap *colormap,
**/
void
gdk_colors_free (GdkColormap *colormap,
gulong *in_pixels,
gint in_npixels,
gulong *pixels,
gint npixels,
gulong planes)
{
GdkColormapPrivateX11 *private;
gulong *pixels;
gint npixels = 0;
gulong *pixels_to_free;
gint npixels_to_free = 0;
gint i;
g_return_if_fail (GDK_IS_COLORMAP (colormap));
g_return_if_fail (in_pixels != NULL);
g_return_if_fail (pixels != NULL);
private = GDK_COLORMAP_PRIVATE_DATA (colormap);
@ -631,11 +631,11 @@ gdk_colors_free (GdkColormap *colormap,
(colormap->visual->type != GDK_VISUAL_GRAYSCALE))
return;
pixels = g_new (gulong, in_npixels);
pixels_to_free = g_new (gulong, npixels);
for (i=0; i<in_npixels; i++)
for (i=0; i<npixels; i++)
{
gulong pixel = in_pixels[i];
gulong pixel = pixels[i];
if (private->info[pixel].ref_count)
{
@ -643,7 +643,7 @@ gdk_colors_free (GdkColormap *colormap,
if (private->info[pixel].ref_count == 0)
{
pixels[npixels++] = pixel;
pixels_to_free[npixels_to_free++] = pixel;
if (!(private->info[pixel].flags & GDK_COLOR_WRITEABLE))
g_hash_table_remove (private->hash, &colormap->colors[pixel]);
private->info[pixel].flags = 0;
@ -651,10 +651,10 @@ gdk_colors_free (GdkColormap *colormap,
}
}
if (npixels && !private->screen->closed)
if (npixels_to_free && !private->screen->closed)
XFreeColors (GDK_SCREEN_XDISPLAY (private->screen), private->xcolormap,
pixels, npixels, planes);
g_free (pixels);
pixels_to_free, npixels_to_free, planes);
g_free (pixels_to_free);
}
/* This is almost identical to gdk_colors_free.

View File

@ -151,19 +151,19 @@ gdk_cursor_new_for_display (GdkDisplay *display,
* 0x80, 0x01, 0x40, 0x02, 0x20, 0x04, 0x10, 0x08, 0x08, 0x10, 0x04, 0x20,
* 0x82, 0x41, 0x41, 0x82, 0x41, 0x82, 0x82, 0x41, 0x04, 0x20, 0x08, 0x10,
* 0x10, 0x08, 0x20, 0x04, 0x40, 0x02, 0x80, 0x01};
*
*
* static unsigned char cursor1mask_bits[] = {
* 0x80, 0x01, 0xc0, 0x03, 0x60, 0x06, 0x30, 0x0c, 0x18, 0x18, 0x8c, 0x31,
* 0xc6, 0x63, 0x63, 0xc6, 0x63, 0xc6, 0xc6, 0x63, 0x8c, 0x31, 0x18, 0x18,
* 0x30, 0x0c, 0x60, 0x06, 0xc0, 0x03, 0x80, 0x01};
*
*
*
*
* GdkCursor *cursor;
* GdkPixmap *source, *mask;
* GdkColor fg = { 0, 65535, 0, 0 }; /<!-- -->* Red. *<!-- -->/
* GdkColor bg = { 0, 0, 0, 65535 }; /<!-- -->* Blue. *<!-- -->/
*
*
*
*
* source = gdk_bitmap_create_from_data (NULL, cursor1_bits,
* cursor1_width, cursor1_height);
* mask = gdk_bitmap_create_from_data (NULL, cursor1mask_bits,
@ -171,8 +171,8 @@ gdk_cursor_new_for_display (GdkDisplay *display,
* cursor = gdk_cursor_new_from_pixmap (source, mask, &amp;fg, &amp;bg, 8, 8);
* gdk_pixmap_unref (source);
* gdk_pixmap_unref (mask);
*
*
*
*
* gdk_window_set_cursor (widget->window, cursor);
* </programlisting>
* </example>