From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Daniele Nicolodi Newsgroups: gmane.emacs.devel Subject: Re: Increase default `line-spacing' to 0.05, 0.10 or 0.15 [proposal] Date: Sat, 8 May 2021 11:40:55 +0200 Message-ID: References: <83mtt7chrt.fsf@gnu.org> <83zgx5agt2.fsf@gnu.org> <72d55429-37ee-cb16-c939-2b274a936136@grinta.net> <83k0o9abub.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3292"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.10.0 Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 08 11:42:21 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 1lfJTY-0000jq-Ix for ged-emacs-devel@m.gmane-mx.org; Sat, 08 May 2021 11:42:20 +0200 Original-Received: from localhost ([::1]:41712 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lfJTX-0000oN-Hn for ged-emacs-devel@m.gmane-mx.org; Sat, 08 May 2021 05:42:19 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:49962) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lfJSJ-0008Gk-LY for emacs-devel@gnu.org; Sat, 08 May 2021 05:41:03 -0400 Original-Received: from grinta.net ([109.74.203.128]:44356) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lfJSD-00033A-Se; Sat, 08 May 2021 05:41:03 -0400 Original-Received: from black.local (p4fe717e2.dip0.t-ipconnect.de [79.231.23.226]) (Authenticated sender: daniele) by grinta.net (Postfix) with ESMTPSA id 0DE45E0804; Sat, 8 May 2021 09:40:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=grinta.net; s=2020; t=1620466856; bh=TNI1DngW/pRGcYiDRlQCEKPLbr2c7CXTwTwAt8fI1s4=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=V5+gbxdQvZEczuZXdVOFKbHcwJD1fUvJ4Ceci7MVMyN9vFHi+ka5Htk+WF3YAgZe/ P6L0VyO1vGGNCdIHrcbiTGuEw79d+ijKuq4vCD+CULzyf6r4AmGPPN1uqtMnUzNy0n ImcmOdJL4giwrkXE8GHGCVFFStmyvSXpRy/z0gi6aM6DmT1sHelFay2zoq21hF3zg/ YG31QrXpKuoJH168ooY5XKJiTdFhVhmfxDu2wD2uA2jvWDINF0SM34K35cLywwQdNS JUumxJmM7iSVfMHFeOb3fvfB8mo06DC/i2+WcpUHzyh4zwyYiGF8mT2ysmqhdsrC3S inHjUNvRSFP/A== In-Reply-To: <83k0o9abub.fsf@gnu.org> Content-Language: en-US Received-SPF: pass client-ip=109.74.203.128; envelope-from=daniele@grinta.net; helo=grinta.net X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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, NICE_REPLY_A=-0.001, 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:269033 Archived-At: On 08/05/2021 10:06, Eli Zaretskii wrote: >> From: Daniele Nicolodi >> Date: Sat, 8 May 2021 09:51:12 +0200 >> >> On 08/05/2021 08:19, Eli Zaretskii wrote: >>> On the implementation side, I'm not sure I understand how do you >>> intend to implement these values: 110% of what? Line spacing is >>> eventually a pixel value; you can, of course, compute it in percents >>> of the font size, but then the nominal spacing will not have the 100% >>> or 1.0 value, right? So how do you intend to convert the value in the >>> menu into the actual line-spacing value? >> >> The documentation for the line-spacing variable says: >> >> Documentation: >> Additional space to put between lines when displaying a buffer. The >> space is measured in pixels, and put below lines on graphic displays, >> see ‘display-graphic-p’. >> If value is a floating point number, it specifies the spacing relative >> to the default frame line height. A value of nil means add no extra space. >> >> I think the values in the menu would simply be divided by 100. > > So you are saying that 100% would mean line-spacing equal to the > default frame line height? That would mean the line height that is > twice as high as the default, so (a) 100% is hardly a good > description, and (b) how do you provide an option to get back to the > default value? > > IOW, the default is that we add zero spacing, and that makes percent > notation not trivially convertible. As the doc string says, this is > _additional_ space. I have no idea what the author of the patch had in mind, I wa trying to offer an interpretation. But, indeed simply dividing by 100 does not work. Dividinng by 100 and subtracting 1 results in a number in the correct range. However, I agree that "line spacing 100%" is a very bad description of what the setting does. Either the setting is called line "line height" with suggested values an a neighborhood of 100%, or "line spacing" with values in a neighborhood of 0% (ie 0%, 5%, 10% or so). Cheers, Dan