]> git.eshelyaron.com Git - emacs.git/commitdiff
Remedy bug#63395
authorPo Lu <luangruo@yahoo.com>
Thu, 7 Sep 2023 00:58:21 +0000 (08:58 +0800)
committerPo Lu <luangruo@yahoo.com>
Thu, 7 Sep 2023 00:58:21 +0000 (08:58 +0800)
* src/gtkutil.c (xg_update_frame_menubar): Avoid scaling the
requisiton height twice.  (bug#63395)

src/gtkutil.c

index 22b2a70f279aa20ffbdae57a1d819d791e4b38ec..f9d9a22a06be36e7850c8236ac767f78322b10ff 100644 (file)
@@ -4141,7 +4141,7 @@ xg_update_frame_menubar (struct frame *f)
   g_signal_connect (x->menubar_widget, "map", G_CALLBACK (menubar_map_cb), f);
   gtk_widget_show_all (x->menubar_widget);
   gtk_widget_get_preferred_size (x->menubar_widget, NULL, &req);
-  req.height *= xg_get_scale (f);
+  req.height *= scale;
 
 #if !defined HAVE_PGTK && defined HAVE_GTK3
   if (FRAME_DISPLAY_INFO (f)->n_planes == 32)
@@ -4154,9 +4154,9 @@ xg_update_frame_menubar (struct frame *f)
     }
 #endif
 
-  if (FRAME_MENUBAR_HEIGHT (f) != (req.height * scale))
+  if (FRAME_MENUBAR_HEIGHT (f) != req.height)
     {
-      FRAME_MENUBAR_HEIGHT (f) = req.height * scale;
+      FRAME_MENUBAR_HEIGHT (f) = req.height;
       adjust_frame_size (f, -1, -1, 2, 0, Qmenu_bar_lines);
     }
   unblock_input ();