From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Robert Pluim Newsgroups: gmane.emacs.bugs Subject: bug#31223: [PATCH] Fix empty/incorrect GTK menus on HiDPI monitors with window scaling factor > 1 Date: Mon, 02 Dec 2019 11:35:03 +0100 Message-ID: References: <0425bcb6-97ee-4845-3571-9db492966a34@web.de> <3d8e4309-c7df-c70a-a47c-36422d6c6ded@web.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="125340"; mail-complaints-to="usenet@blaine.gmane.org" Cc: 31223@debbugs.gnu.org To: Tobias Bading Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Dec 02 11:36:11 2019 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([209.51.188.17]) by blaine.gmane.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1ibj3q-000WU8-Rj for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Dec 2019 11:36:11 +0100 Original-Received: from localhost ([::1]:33728 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibj3p-0006e0-LP for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Dec 2019 05:36:09 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35735) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ibj3j-0006df-I7 for bug-gnu-emacs@gnu.org; Mon, 02 Dec 2019 05:36:04 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ibj3i-0001gU-JG for bug-gnu-emacs@gnu.org; Mon, 02 Dec 2019 05:36:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:59396) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ibj3h-0001gB-Ou for bug-gnu-emacs@gnu.org; Mon, 02 Dec 2019 05:36:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ibj3h-0004Hq-Ls for bug-gnu-emacs@gnu.org; Mon, 02 Dec 2019 05:36:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Robert Pluim Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 02 Dec 2019 10:36:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31223 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: help Original-Received: via spool by 31223-submit@debbugs.gnu.org id=B31223.157528291316417 (code B ref 31223); Mon, 02 Dec 2019 10:36:01 +0000 Original-Received: (at 31223) by debbugs.gnu.org; 2 Dec 2019 10:35:13 +0000 Original-Received: from localhost ([127.0.0.1]:37136 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ibj2v-0004Gj-Ja for submit@debbugs.gnu.org; Mon, 02 Dec 2019 05:35:13 -0500 Original-Received: from mail-wm1-f42.google.com ([209.85.128.42]:53612) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ibj2t-0004GQ-Nm for 31223@debbugs.gnu.org; Mon, 02 Dec 2019 05:35:12 -0500 Original-Received: by mail-wm1-f42.google.com with SMTP id u18so21199035wmc.3 for <31223@debbugs.gnu.org>; Mon, 02 Dec 2019 02:35:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :mime-version:content-transfer-encoding; bh=MFnLpwjumNB36kZ3GFRtpg4K5L0lHzS1Gx1gCJlanNs=; b=EEEJY5uWH7wLsRQdhcawiCOj1r6MYPQiN3KjHZBouKxqBeZxe6D1/0RjtV7feL2v9L c+rHTiO/n+ndk6zzZze2F8FuGx/IKgUYVvaOjGKjfcLXEsHOain1uTGfYwX5STt+lIys go3H4GH24BP6BAaFU1wZqeMSDxHZCIAKZINZtBkooDYwI+rrjB6H5wjvKPQtxjh7cttb aaOnpWCsiEAt7HcYvpOkY9HcRETkPRO9519+XxG9A6vASnvqdNZe69GAvSGNwglF3Iug YZqns08KpcygbCHgYoe3xWVzFqbJS+GdUPIoo0fuY96I3Ke8Cd6fySXH/cIdVHzf+3vi 6sIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-transfer-encoding; bh=MFnLpwjumNB36kZ3GFRtpg4K5L0lHzS1Gx1gCJlanNs=; b=drCNN/a9z/iM9h+9elsEFNpHZfIiAMca1oJIoSnKvYaOuf8tfJMTzPfSMwDwc00gq+ f7coTZ95hI2hDO+IX+CuAQdiSlAjQyyuNv81c4pYuX5/HNAoC0kV/okEFoJct7/igrtJ ykGtT/fyUwAa/FOY6T3p3iXEAK0FxrkqwsAe7zKKFSgKc6M0c0iHiCjrRiubglE4kLCn /45C5klGRHBriDCAtU/Mdt/EVcW1tZa6ISEx423Hw0m8Pb/Wey1yKY09pg5fFvf7F0Jd 3GYxHYkpfEcWYhFCY3WCbzw7NNpWovos3Ttnie0NOH0bSz7RumBPXC2b5KriEndYDlEz EPkg== X-Gm-Message-State: APjAAAVhzOJDvLKN2jUa+B82tZzCaFmbBxuZIsLUfrnjckbflTc4bFvo KEowzddYJnSHDn0dJISwA6X4VNGI X-Google-Smtp-Source: APXvYqwt1tlW9iwriFRPwMq9LdeWYyDJ/f7Sl9EktqWDlnQZTaxtB1JC0SdTAD1KEsg1LWMeXZhlyA== X-Received: by 2002:a1c:750f:: with SMTP id o15mr26418904wmc.161.1575282905232; Mon, 02 Dec 2019 02:35:05 -0800 (PST) Original-Received: from rpluim-mac ([149.5.228.1]) by smtp.gmail.com with ESMTPSA id u14sm39992034wrm.51.2019.12.02.02.35.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Dec 2019 02:35:04 -0800 (PST) In-Reply-To: (Robert Pluim's message of "Thu, 28 Nov 2019 10:44:08 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.51.188.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:172759 Archived-At: >>>>> On Thu, 28 Nov 2019 10:44:08 +0100, Robert Pluim s= aid: >>> This seems correct as well. Probably rec.x and rec.y need scaling as Tobias> well, for >>> the multi-monitor case, which will require some cabling for me to t= est. Tobias> Good point. The documentation of gdk_monitor_get_geometry() says Tobias> "Retrieves the size and position of an individual monitor withi= n the display Tobias> coordinate space. The returned geometry is in "application pixe= ls", not in Tobias> "device pixels" (see gdk_monitor_get_scale_factor())." Tobias> Unfortunately, I don't have a second monitor at hand to test th= is. So initial testing seems to show that the x/y positions of the second monitor need scaling as well, but I didn=CA=BCt get around to testing all the scaling/relative positioning combinations. Since that=CA=BCs a less common use case, we can apply your patch in the meantime. Do you have an Emacs copyright assignment on file? If not, Eli, is the patch small enough to apply without an assignment? Thanks Robert