GTK Scale/Volume Buttons Show Muted Icon on Startup

Russel Winder russel at winder.org.uk
Fri Apr 26 09:36:04 UTC 2019


On Thu, 2019-04-25 at 11:36 +0000, Ron Tarrant via Digitalmars-d-learn wrote:
> I've scoured the docs, the wrapper code, the Internet, but can't 
> come up with an explanation...
> 
> When running this example of a VolumeButton, no matter what the 
> initial value of the slider, the icon showing is 
> audio-volume-muted.

Experience with Me TV in D/GtkD/GStreamerD and Rust/gtk-rs/gstreamer-rs
indicates that volume buttons and adjustments in GTK+ have issues, this is not
a GtkD or gtk-rs thing it seems to be a GTK+ thing.

If I remember correctly, you have to set up the volume button, set the initial
volume, then set up and add the adjustment, and then reset the initial value
via the adjustment to get the icon correct. Memory on this is hazy as it was a
while ago, I got it working and then left it alone, untouched.
 
-- 
Russel.
===========================================
Dr Russel Winder      t: +44 20 7585 2200
41 Buckmaster Road    m: +44 7770 465 077
London SW11 1EN, UK   w: www.russel.org.uk

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <http://lists.puremagic.com/pipermail/digitalmars-d-learn/attachments/20190426/5185a67b/attachment.sig>


More information about the Digitalmars-d-learn mailing list