• Uncategorized

About c++ : Detecting-when-a-window-is-resized-using-gtkmm

Question Detail

I am working with gtkmm 2.4 in Linux RHEL 6.

I have a class MyWindow that inherits from Gtk::Window.

I need to detect when MyWindow resizes.
The call back for this event resize the pixbufs and move the pixbuf/evenbox combination.
The pixbuf is the child of the eventbox. The call back is onresize_cb();

I am trying to use the signal_configure_event().

The code below will complie and run. When I try to resize the window, onresize_cb() is not excuting.
It does not display ” onresize_cb “.

What do I need to do to get onresize_cb() to excute?


#include <gtkmm.h>

class MyClass : public Gtk::Window

    static bool onresize_cb();



#include <iostream>

    // Set up window
    set_position(Gtk::WIN_POS_CENTER); // positions the Gtk::Window to the WIN_POS_CENTER position




bool MyClass::onresize_cb()
    std::cout << " onresize_cb " << std::endl;
    return true;

Question Answer

No answer for now.

You may also like...

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.