Gtk4. Migration Label and tooltip from gtk3. Again

The problem here is: When application have a lot of labels there are separate threads which can change tooltips for any label. In UI for those unchanged Labels - tooltips are flickering or even disappeared
This topic continues Gtk4. Migration Label and tooltip from gtk3
Hi @gwillems , sorry for bothering you… did you have a time to check?
Last thing was:

#include <gtk/gtk.h>
#include <thread>
#include <iomanip>
#include <atomic>
//#include <spdlog/spdlog.h>

static GtkWidget *lLabel, *rLabel;
std::thread lT, rT;
std::atomic<bool> stop_thread = false;

void setTlpMarkup(GtkWidget *wg, const char* markUp) {
  if (wg) {
      auto t = std::time(nullptr);
      auto tm = *std::localtime(&t);
      std::ostringstream oss;
      oss << std::put_time(&tm, "%d-%m-%Y %H-%M-%S");
      auto str = std::string(markUp) + ' ' + oss.str();
      gtk_widget_set_tooltip_markup(wg, str.c_str());
    }
}

I have

terminated by signal SIGABRT (Abort)

in different distros

Hi @gwillems , finally I promoted local gtk to 4.17.0 and now it works well. Looks like 4.17.0 has got this issue fixed. Thank you for your effort.

1 Like

4.17.0 is the current development branch; you want 4.16 for a stable release.