From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED.blaine.gmane.org!not-for-mail From: Ergus Newsgroups: gmane.emacs.devel Subject: Question about display engine Date: Wed, 7 Aug 2019 02:54:11 +0200 Message-ID: <20190807005411.qfzzpz5cjrajbwn2@Ergus> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Injection-Info: blaine.gmane.org; posting-host="blaine.gmane.org:195.159.176.226"; logging-data="55180"; mail-complaints-to="usenet@blaine.gmane.org" User-Agent: NeoMutt/20180716 Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Aug 07 02:54:28 2019 Return-path: Envelope-to: ged-emacs-devel@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 1hvADj-000EGt-PQ for ged-emacs-devel@m.gmane.org; Wed, 07 Aug 2019 02:54:27 +0200 Original-Received: from localhost ([::1]:36818 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hvADi-0007Sm-5Y for ged-emacs-devel@m.gmane.org; Tue, 06 Aug 2019 20:54:26 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:38696) by lists.gnu.org with esmtp (Exim 4.86_2) (envelope-from ) id 1hvADf-0007Sg-3s for emacs-devel@gnu.org; Tue, 06 Aug 2019 20:54:23 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hvADe-0002aV-3j for emacs-devel@gnu.org; Tue, 06 Aug 2019 20:54:23 -0400 Original-Received: from sonic313-21.consmr.mail.ir2.yahoo.com ([77.238.179.188]:45670) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hvADd-0002Zw-Nu for emacs-devel@gnu.org; Tue, 06 Aug 2019 20:54:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=aol.com; s=a2048; t=1565139258; bh=jL5+s4QeK413XdNgqH1oVTfn/B2XunnQ5iuQTJtKInM=; h=Date:From:To:Cc:Subject:From:Subject; b=h09TepBPSQSLvl75edMj/uJFYVige0xljyhA6PfQC9O+V6wKLPNK/EuyTyxpt6HMLGtmd1UQc8UVf0bELsUbhBNgi6Ph8RzDIy9+0GfvnGxQuSLDhQogwZKWomvRpM6HhtBbnQm/Y1MHkHEaHVbBbcUigtYy0ZB8N+/6FLhqPyQE4et7KbaqNupf/vYiZA9uEi6tfO36hVi9Mlw9DXPLen4nykK8TRlmPjGKr0fTh23REmZXC6MTUwM7+YU+zENbHP5GVm3MdXl4NWhMSd4fn+TlGOAwmqT/FfgVvcNL7LY0Bi5mvK6kfQt8ahm5WDcs6LX55BodDx7h/6pMUtMoeg== X-YMail-OSG: LYa3A.IVM1l5EI0A6t27QIzCYv8rBt9jwOsGUg8b44c6e7jCNIcAvQr8FxlEB1p FG7QJCrYe5XCs68Y.wIyx.L2P9zBdZkAmqbYU_6.m3vVMC8hgzhKacDmXP0.ee2Uwafyu5aXQGW8 nSicnXAdEWFzCitiWEgdxDIZo7BKxOfRsLtgzJj0hjGflJpnJo3o7azgXJbowH95HtIRcmXke.T2 bvPZMPPzwJNaz47qNcjNBxOLILlkVvaQYupmrqp7Bk6c7lKv_K4cW12W95WI6DQUl40L3b85mZQZ GlfuZhsT6aIK0z6Fo.UOHi4jNsj.Tnsv_Z7.0z3J_IAa3OVMCvEynE0zyqE222WgY3yU7CrPP3hK SfgrWl0Cu_qmJoLND0.mnCxSU_DDeKJBA6NUDV0je2yFvGhZb.sZezV6XL3pjcfqd9y.bNlUKu2k LuObavSE8nyHfPFTmvVPC4.UpfQ9gszQKp2BTo5sY988DMv0dIBtlxqmmZ56H4WFCq9Pq38LVp9N MbPaG_Q7Ej_FbQa.ZRhDocxmT3RhJYfNx4nNop.SGf6D0.ZUW9YVEXp3zMUYjulk7s6x.Z_XShR5 TdTXYsne9YUN8B_LGXNdWDR1Rs9gIjZaCdZsVJEjDp0X5CejullR5tkyC8cYojs3bvEl.evyOZMf BlqTvVURfYLg9w4VzKyEahgn1xZ7jZbuI0k5eYJY3lH7WSsVbtBJcw1DhHJ6fsZ6kICTfrnKmkiF 48NVc3iT1qzboE5lMsOTHyXo_KTFNQauaUr5aUaowEIQcXj5ZRqVbYbHpG3pY5iObNPzc6.Z71Af d0lUKjODm15vyYB0.VxxOd6ar7fYUOkO1LCTPOgSzV Original-Received: from sonic.gate.mail.ne1.yahoo.com by sonic313.consmr.mail.ir2.yahoo.com with HTTP; Wed, 7 Aug 2019 00:54:18 +0000 Original-Received: by smtp411.mail.ir2.yahoo.com (Oath Hermes SMTP Server) with ESMTPA ID a44c5393e37858db16b5ad228ff5f964; Wed, 07 Aug 2019 00:54:15 +0000 (UTC) Content-Disposition: inline X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 77.238.179.188 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.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:239213 Archived-At: Hi: Sorry to bother with this. Fixing the issue 36858 in text mode I found that the extend_face_to_end_of_line uses the same face for the last char in the line. This is useful to extend selection face the whole line, but this created a difference with gui emacs when the last face was underlined or overlined because in tui the underline is extended for the entire line. To fix this I need to create a new face to extend until the end of the line that has the same properties than it->face_id except that the underline and overline properties will be disabled. I can produce the desired effect doing: ```Lisp (defface my_new_face '((t :weight normal :slant normal :underline nil :overline nil :strike-through nil :box nil :inverse-video nil :stipple nil))) ``` ```C DEFSYM (my_new_face, "my-new-face"); it->face_id = merge_faces (it->w, my-new-face, 0, it->face_id) ``` But this seems very dirty. How can I produce the same effect in the right way? (I mean create a new face_id based on it->face_id but with :underline nil :overline nil... etc?) And only with C code. Any help, suggestion? Thanks in advance, Ergus