After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 157744 - free_colors (Color& colors, int ncolors) - ncolors seems to make no sence
free_colors (Color& colors, int ncolors) - ncolors seems to make no sence
Status: RESOLVED FIXED
Product: gtkmm
Classification: Bindings
Component: general
2.5
Other Linux
: Normal minor
: ---
Assigned To: gtkmm-forge
gtkmm-forge
Depends on:
Blocks:
 
 
Reported: 2004-11-09 12:14 UTC by noche.suapie
Modified: 2005-05-01 06:45 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description noche.suapie 2004-11-09 12:14:18 UTC
just look at
http://www.gtkmm.org/docs/gtkmm-2.4/docs/reference/html/classGdk_1_1Colormap.html#a6.
how can one Color& be ncolors Colors, if ncolors > 1 ?

indeed

some_colormap->alloc_colors(some_color);
....
some_colormap->free_colors(some_color, 1);

compiles and run's without errors, but the same is true for

some_colormap->alloc_color(some_color);
....
some_colormap->free_colors(some_color, 5);

so, what is ncolors all about ?

note that there isn't a free_color(Gdk::Color&) method ....
Comment 1 Murray Cumming 2005-05-01 06:45:48 UTC
In the HEAD branch, alloc_colors() has been deprecated in favour of
alloc_color(). free_colors() has been deprecated in favour of the a new
free_color() method.

In past, you had to call free_colors(color, 1), I think, though it it's not
important to call it.