Subject: bug#38163: closed (Re: bug#38163: GDK does not return the monitor's refresh rate)

From: [email-masked] (GNU bug Tracking System)
Date: Wed, 27 May 2020 00:11:02 +0000

Your bug report

#38163: GDK does not return the monitor's refresh rate

which was filed against the guix package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
38163: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=38163
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#38163: GDK does not return the monitor's refresh rate
From: Alexandros Theodotou <[email-masked]>
To: [email-masked]
Date: Wed, 27 May 2020 01:10:35 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

This was fixed a long time ago.

Subject: GDK does not return the monitor's refresh rate
From: Alexandros Theodotou <[email-masked]>
To: [email-masked]
Date: Sun, 10 Nov 2019 16:44:23 +0000
List-Id: <debbugs-submit.debbugs.gnu.org>

I have been developing and testing my GTK app (Zrythm) on many distros
and Guix is the only case that the monitor's refresh rate is returned
as 0.

The API I am using is this:
https://developer.gnome.org/gdk3/stable/GdkMonitor.html#gdk-monitor-get-refresh-rate

I was developing/testing on Parabola GNU/Linux-libre before and it was
giving me a correct rate of 60 Hz.

Other distros I have tested this API before on:
Various ubuntu versions, debian 9 and 10, manjaro (arch), various
fedora versions, plus a few others that users tested on.

I suspect GDK is trying to access something that guix doesn't make
available to it, but I don't have much knowledge of the internals of
GDK or Guix to debug this myself.

I will post a package from my guix channel that you can test this on
soon.

To call the API, one basically calls the following, after including
<gtk/gtk.h>, so any GTK program will do.
```
GdkDisplay * display = gdk_display_get_default ();
GdkMonitor * monitor = gdk_display_get_primary_monitor (display);
int refresh_rate = gdk_monitor_get_refresh_rate (monitor);
```