Milliways
Posts: 462
Joined: Fri Apr 25, 2014 12:18 am
Location: Sydney, Australia

An Introduction to C & GUI Programming

Sat Apr 27, 2019 6:36 am

I have been working through the GTK examples in An Introduction to C & GUI Programming, and while it is OK (if a bit short on explanation) I stumbled on the List stores example.

I can't figure out how to get the contents of a COMBO_BOX populated by a renderer.

Code: Select all

char *selected = gtk_combo_box_text_get_active_text(GTK_COMBO_BOX_TEXT (wid));
doesn't work.

Is there a ready reference to the GTK2 API?

A web search came up with https://developer.gnome.org/gtk2/stable/

User avatar
Joel_Mckay
Posts: 289
Joined: Mon Nov 12, 2012 10:22 pm
Contact: Website

Re: An Introduction to C & GUI Programming

Sat Apr 27, 2019 7:46 am

I usually prefer a native cross platform C++ lib like wxwidgets for GUI stuff:
https://wxwidgets.org/
(it has its own set of constraints, but works on most platforms)

If wxglade wasn't so unstable, the visual layout scaffold coding experience would be trivial:
http://wxglade.sourceforge.net/
https://wiki.wxwidgets.org/Tools

wxPython also works... but I don't like how it handles certain things... meh YMMV ;-)
https://www.wxpython.org/

Cheers,
J

Return to “Troubleshooting”