[Vala] Use alpha in GtkColorButton in GTK3 with Vala



I want to use an alpha value in the color buttons in my app -
https://github.com/satya164/elegance-colors

Currently I'm using colorbutton.set_use_alpha (true);, as documented in
http://www.valadoc.org/#!api=gtk+-3.0/Gtk.ColorButton

But, while compiling, I get warnings saying,

/home/satya/Workspace/elegance-colors/elegance-colors-prefs.vala.c:4706:2:
warning: ‘gtk_color_button_set_use_alpha’ is deprecated (declared at
/usr/include/gtk-3.0/gtk/gtkcolorbutton.h:95): Use
'gtk_color_chooser_set_use_alpha' instead [-Wdeprecated-declarations]

The code samples in the valadoc website are outdated and the sample on
gnome's website doesn't use alpha. Can anyone help me fix the warning
messages?

I'm using GTK 3.8 and Vala 0.20.1.
-- 
Satyajit Sahoo
Profile - Facebook <http://facebook.com/satya164>,
Google+<http://plus.google.com/u/0/114564489020097923600>
Artwork - DeviantArt <http://satya164.deviantart.com>


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