From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#25824: 25.1; bugs about display specfications Date: Sat, 04 Mar 2017 18:00:13 +0200 Message-ID: <83mvd1jalu.fsf@gnu.org> References: <87bmtsnn4g.fsf@gmail.com> <83tw7kro9a.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1488643276 24118 195.159.176.226 (4 Mar 2017 16:01:16 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 4 Mar 2017 16:01:16 +0000 (UTC) Cc: 25824-done@debbugs.gnu.org To: ynyaaa@gmail.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Mar 04 17:01:13 2017 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ckC7J-0005V5-B4 for geb-bug-gnu-emacs@m.gmane.org; Sat, 04 Mar 2017 17:01:09 +0100 Original-Received: from localhost ([::1]:35771 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ckC7P-00008N-BK for geb-bug-gnu-emacs@m.gmane.org; Sat, 04 Mar 2017 11:01:15 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:60824) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ckC7G-000075-4x for bug-gnu-emacs@gnu.org; Sat, 04 Mar 2017 11:01:07 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ckC7D-0000uN-1w for bug-gnu-emacs@gnu.org; Sat, 04 Mar 2017 11:01:06 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:41980) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ckC7C-0000u9-NM for bug-gnu-emacs@gnu.org; Sat, 04 Mar 2017 11:01:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ckC7C-0008Fw-Gn for bug-gnu-emacs@gnu.org; Sat, 04 Mar 2017 11:01:02 -0500 Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-To: bug-gnu-emacs@gnu.org Resent-Date: Sat, 04 Mar 2017 16:01:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: cc-closed 25824 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Mail-Followup-To: 25824@debbugs.gnu.org, eliz@gnu.org, ynyaaa@gmail.com Original-Received: via spool by 25824-done@debbugs.gnu.org id=D25824.148864323631691 (code D ref 25824); Sat, 04 Mar 2017 16:01:02 +0000 Original-Received: (at 25824-done) by debbugs.gnu.org; 4 Mar 2017 16:00:36 +0000 Original-Received: from localhost ([127.0.0.1]:40178 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ckC6m-0008F4-Ac for submit@debbugs.gnu.org; Sat, 04 Mar 2017 11:00:36 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:41508) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ckC6l-0008Es-2r for 25824-done@debbugs.gnu.org; Sat, 04 Mar 2017 11:00:35 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ckC6c-0000hH-Lo for 25824-done@debbugs.gnu.org; Sat, 04 Mar 2017 11:00:29 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:47670) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ckC6c-0000hD-Hv; Sat, 04 Mar 2017 11:00:26 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:4381 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ckC6b-0001f5-QO; Sat, 04 Mar 2017 11:00:26 -0500 In-reply-to: <83tw7kro9a.fsf@gnu.org> (message from Eli Zaretskii on Fri, 24 Feb 2017 10:23:13 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] 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: 208.118.235.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:130188 Archived-At: > Date: Fri, 24 Feb 2017 10:23:13 +0200 > From: Eli Zaretskii > Cc: 25824@debbugs.gnu.org > > > From: ynyaaa@gmail.com > > Cc: 25824@debbugs.gnu.org > > Date: Fri, 24 Feb 2017 15:01:19 +0900 > > > > Eli Zaretskii writes: > > > Only if the replacement comes from a before- or after-string (in which > > > case the text won't be replaced, so you will have to hide it with some > > > invisible property). Put the 'raise' display property on the overlay > > > string, and you will have what you want. > > > > Overlays are not editable with kill and yank, > > so text properties are better. > > Then I'm afraid you are out of luck, because Emacs doesn't support > recursive 'display' properties, i.e. a 'display' property that is a > string which has another 'display' property for (a part of) that > string. > > > > What the display engine does is reserve space above > > > the baseline that is large enough for the enlarged font, and then draw > > > the "X" with a negative offset relative to the baseline, by enlarging > > > the 'descent' value of that particular glyph, which adds vertical > > > space _below_ the line. > > > > I wonder why the display engine does not take 'rase' into account > > when reserving space above the baseline. > > AFAIU, it's just a side effect of the implementation: 'raise' is > implemented as modifications of the ascent or descent, so it behaves > like these attributes of any glyph would. > > > > Does the below do what you want? If not, perhaps I don't understand > > > what you mean by "centered". > > > > > > (insert "A" (propertize "X" 'display '((raise -0.2) (height 2)))) > > > > It is enough for only one line. > > With blank areas, emacs can display fewer lines. > > Yes, there are limitations of what can be done in Emacs as far as text > layout is concerned. I've now clarified the relations between 'raise' and 'height' in the ELisp manual, and I'm closing this bug. Thanks.