PORT: GTK2 to GTK3
I've undertaken a task of porting alsa-tools programs from GTK2 to GTK3. These patches start with a base of 5eaadd15bda4cf0424ee2470a6d304a0c2ce10cb (master) Date: Mon Jan 27 (latest pull)
Results: Compilation completes successfully, Linked to GTK3, but I do not have the hardware cards to test run them.
All work has been done by me, and I request a code review on the GDK 2 Pixmap to GDK 3 Pixbuf + Cairo surfaces. Like it needs new logic and new plan. not simply change statement A to B (whatever I did to get it to compile)
I tried to comply with the existing style, and There was also a fair bit of inconsequential whitespace removed like (\n\t\n) or trailing space chars as I discovered them.
Looking forward to upstreaming these changes somehow if you would like to work on this.
- genBTC @ gentoo
Hi! I have tried your port of envy24control, and actually also made one myself (I started doing it before I found yours).
The level meters are not quite correct in your version (as you maybe already suspected). The signal expose_event is no longer valid, instead you should use "draw". Also, I don't think there's any point in using the pixbufs and surfaces anymore, as the drawing area is already double-buffered and the draw callback provides a cairo drawing context you can use directly. You can see my version here.
Other differences between your port and mine are:
- Your radio buttons don't quite work, they show all options as chosen.
- You don't set the data pointer for the control_input_callback, which causes a crash if some settings are changed outside the application.
- I changed all vbox and hbox to box, to get rid of deprecation warnings.
- Same thing with hseparator: I changed it to separator. I also fixed the pack options here, as the separator wasn't shown as a line anymore with the old options.
- I didn't do any whitespace cleanup.
Other than that our versions are very similar. I didn't create a pull request, as I wasn't sure if I should make it to your repo or this one.
I updated my version a bit: I removed the create_blank workaround, as it wasn't needed anymore.
I wasn't happy with the performance of my version, so I made some optimizations. After that, I decided to create a new pull request for it: #35. I hope that wasn't rude of me, I'm not trying to take credit for your work.
The new pull request only includes envy24control, not the other two applications included here.