I want to migrate an application to gtk3

I want to migrate an application to gtk3

After I set make CFLAGS+=“-DGDK_DISABLE_DEPRECATED -DGTK_DISABLE_DEPRECATED”

I can’t any longer compile, because GtkOptionMenu is deprecated. OK

But how can I find any idea how to migrate this “GtkOptionMenu” to something different? What is the replacement for it if there is any? I also can not find any docs about gtk2 and its deprecated stuff. I feel totally lost!

The replacement for GtkOptionMenu is GtkComboBox; GtkOptionMenu was deprecated in GTK 2.4, released in March 2004.

For reasons that are too complex and too boring to explain, the GTK2 reference is available on the Wayback machine:

You’re catching up with nearly 20 years of development: it’s not going to be a case of mechanically porting things from a deprecated widget to a new one.

Now comes the hard truth: you should not migrate from GTK2 to GTK3; the migration guide was written when GTK2 and GTK3 were both maintained at the same time. GTK2 has been end-of-life’d 5 years ago, and GTK3 is feature and API frozen. If you want to port an application from GTK2 I recommend starting from GTK4, and re-implementing the application, instead of porting it.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.