From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Third Newsgroups: gmane.emacs.devel Subject: Re: "Fix" sag scaling for hidpi Date: Sat, 13 Feb 2021 22:13:26 +0000 Message-ID: References: <871rdkte4f.fsf@gnus.org> <87h7mgqj60.fsf@gnus.org> <87h7mgovil.fsf@gnus.org> <87tuqfoeu3.fsf@gnus.org> <878s7roclp.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="19713"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Yuan Fu , Robert Pluim , Eli Zaretskii , monnier@iro.umontreal.ca, emacs-devel To: Lars Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Feb 13 23:14:58 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1lB3Bq-0004yk-Bb for ged-emacs-devel@m.gmane-mx.org; Sat, 13 Feb 2021 23:14:58 +0100 Original-Received: from localhost ([::1]:59430 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lB3Bp-0004yZ-E5 for ged-emacs-devel@m.gmane-mx.org; Sat, 13 Feb 2021 17:14:57 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54346) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lB3Ab-0003rX-LA for emacs-devel@gnu.org; Sat, 13 Feb 2021 17:13:41 -0500 Original-Received: from outbound.soverin.net ([2a01:4f8:fff0:2d:8::218]:37217) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lB3AV-0004HO-H6; Sat, 13 Feb 2021 17:13:41 -0500 Original-Received: from smtp.soverin.net (unknown [10.10.3.24]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by outbound.soverin.net (Postfix) with ESMTPS id 7FFF8600D0; Sat, 13 Feb 2021 22:13:31 +0000 (UTC) Original-Received: from smtp.soverin.net (smtp.soverin.net [159.69.232.138]) by soverin.net DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=idiocy.org; s=soverin; t=1613254410; bh=Eia61+qmjAJBnkhhpiqmF25t4hIDP/r9Hb15OAvEzDM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Q2faIGyVtwdtwIj0pVXTHhQ4Wk/Zjc7kgeNWoCm/35low6UqI7VyjSv8jX6lmFKIr oeshjIqEjr3xm6ah8otmxGL8cJ9DpkGZ4JPjiwJBX86D3xuOat0rDKpaSuAuBLXFk/ V3oDgyJeU1osunEMAAjvKbWUk3OtTrPurN1WiUyoSgwZO//p7fjPhoRTRegtvyzIWt jb2hQ0qyPhHP1ELsmTzZsApbcOnexA4MFvWkkO635AjGraGSeyBc/s2SjMKcIFLz2q f0g2pKfc2Q8MXHLQfbtgEi+zGN0FmTtaLmD9P+fvE+OvaD4s2Dc7zzU57rPkzMXSZO bCdWFER3VKi2w== Original-Received: by breton.holly.idiocy.org (Postfix, from userid 501) id 897DC202A6C5B7; Sat, 13 Feb 2021 22:13:26 +0000 (GMT) Mail-Followup-To: Alan Third , Lars Ingebrigtsen , Yuan Fu , emacs-devel , Eli Zaretskii , Robert Pluim , monnier@iro.umontreal.ca Content-Disposition: inline In-Reply-To: <878s7roclp.fsf@gnus.org> Received-SPF: pass client-ip=2a01:4f8:fff0:2d:8::218; envelope-from=alan@idiocy.org; helo=outbound.soverin.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:264667 Archived-At: On Sat, Feb 13, 2021 at 10:57:06PM +0100, Lars Ingebrigtsen wrote: > Alan Third writes: > > >> > Strange. When I do that with GDK_SCALE=2 I get both images as 333 > >> > pixels wide. The only thing that appears to have been scaled are the > >> > menus and toolbar, everything else is the exact same size as if I use > >> > GDK_SCALE=1. > >> > >> What's your `(image-compute-scaling-factor image-scaling-factor)'? > > > > 1 > > The scaling factor is heuristically determined by how big the default > face is. So I'm guessing that your Emacs is returning the size in > "logical pixels", which means that the heuristics don't trigger? I already wrote a C function to provide the real value to lisp. Would that be better? (I've already deleted the commit, but I'm getting real friendly with the git reflog tonight...) -- Alan Third