From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Visuwesh Newsgroups: gmane.emacs.bugs Subject: bug#73752: 29.4; Ligatures are randomly rendered with extra spaces Date: Tue, 29 Oct 2024 19:24:26 +0530 Message-ID: <871pzz10bx.fsf@gmail.com> References: <86zfn9ycis.fsf@gnu.org> <86o735als7.fsf@gnu.org> <87o73534dn.fsf@gmail.com> <86h68x8nuz.fsf@gnu.org> <86ed418niu.fsf@gnu.org> <87jzds3lay.fsf@gmail.com> <86iktc6zp5.fsf@gnu.org> <87wmhs19rh.fsf@gmail.com> <86frog6thm.fsf@gnu.org> <87o73318ql.fsf@gmail.com> <86wmhr5acv.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13074"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: luangruo@yahoo.com, 73752@debbugs.gnu.org, xuan@xlk.me To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Oct 29 14:56:20 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1t5mhn-0003Ai-OJ for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 29 Oct 2024 14:56:19 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t5mhZ-0000LQ-2Q; Tue, 29 Oct 2024 09:56:05 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t5mhX-0000LF-9h for bug-gnu-emacs@gnu.org; Tue, 29 Oct 2024 09:56:03 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t5mhW-0003z0-VN for bug-gnu-emacs@gnu.org; Tue, 29 Oct 2024 09:56:03 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=7lFJK2MdtblT+Qc+EqwfhMz3F1nrzFUR0K18ebnBbvo=; b=jtvQ22PdxBbatksvbwWJI8kVwPhDo4K0RVL3cViVIoBamY5J7Eb620NAyL2mGK1nOWVletntZHt3m50ijlDa9HlhsrXp+tMeawSyOduf6e7niRgGwioo9DuYV/T9P/RWzGzeXt1YhI/gNE3mJfODKvrSOHPKC9xFD++oYk0z5+StcxqjabjLxPTgkaGdHLtfPYGl1hcFa5rLHyTvVS8KyNjdJiAf/yQ+M2bHtJrUUEGaG/uPJVlbc9Bjj05nzRuVSwnJziqBnBIXKBY6q07hjQicClTJeYvaO2MytEumpF5HUqjKf3ruaEJTgucPTbJhAfk1wW1z7kfyHWzzDQtkcA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t5mhW-0005lb-Kt for bug-gnu-emacs@gnu.org; Tue, 29 Oct 2024 09:56:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Visuwesh Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 29 Oct 2024 13:56:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 73752 X-GNU-PR-Package: emacs Original-Received: via spool by 73752-submit@debbugs.gnu.org id=B73752.173021014022057 (code B ref 73752); Tue, 29 Oct 2024 13:56:02 +0000 Original-Received: (at 73752) by debbugs.gnu.org; 29 Oct 2024 13:55:40 +0000 Original-Received: from localhost ([127.0.0.1]:56483 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t5mh9-0005jZ-1q for submit@debbugs.gnu.org; Tue, 29 Oct 2024 09:55:39 -0400 Original-Received: from mail-pg1-f194.google.com ([209.85.215.194]:55628) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t5mh7-0005j6-Ak for 73752@debbugs.gnu.org; Tue, 29 Oct 2024 09:55:38 -0400 Original-Received: by mail-pg1-f194.google.com with SMTP id 41be03b00d2f7-7ea68af2f62so4344741a12.3 for <73752@debbugs.gnu.org>; Tue, 29 Oct 2024 06:55:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1730210071; x=1730814871; darn=debbugs.gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=7lFJK2MdtblT+Qc+EqwfhMz3F1nrzFUR0K18ebnBbvo=; b=K2BKRO2XsrQVS/2NhnCrS+8Y2/Xy0LMi4pEZ9yudCOUh9chkgm4GMQkFMOyjkWao0A pRcKr62b0j2jFGho92vqgyEbcP65K4ZKUjp5KpvE9OYcrNJhBN1ogfJDP1tSLeymM9lA kWgaf+99wIwsEbWcIaSozU3D58F4swiW9f5Js8EuKPFzGmRWPv4e9mFdhr9HcaLytCpd udbMAsCrKgKrTDQsoirFg2OxiSIFWDfv8u2Gmoj7Fkr2KF4TTmzflI4/v6sB5kQktG0z K5G+bZt2254dvWoFM94v3b3a7D75zZ1jRqcpllGrwntFuAulhXSoomWNAoI/pU0emM/3 SpKg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730210071; x=1730814871; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=7lFJK2MdtblT+Qc+EqwfhMz3F1nrzFUR0K18ebnBbvo=; b=EWdJ8qXo20Wt59foxNe7hiVw1rnbZQeeX71QhHCeVm3xVUYVcMpnaXmdfsR3/d+LfI vB1L87/4dH285iDpcNSxL1ApTUWMyYOmSfkO7inUpnDb0KOC/WLeTxw+LS0ltB9Khkul W9uxXtBnExIclPmp2G0uB8TTf1Gjt2OHAXeadv32DWB/DgSBqA+YHqcpK/c6RvBN8JGe zCroTkchvUVRccI2A1m5RfUpd2OO/pbhl1F0Fcowg+Wo2HLCN6chOJ6gh4tZzHCoV3Le YMXSihskzzNPKTPgPhqkVlsbYPzplAZqcRpcJMu3Sy+EDe4VhWPXQTubEurBoWGV71DC bF5Q== X-Forwarded-Encrypted: i=1; AJvYcCWljzAtijlfTo0PduHlQcYGJBuxMIgsBhX2UshR+qQfCi2boFRP1oVzbSgkd/tIXq7LCnpPZQ==@debbugs.gnu.org X-Gm-Message-State: AOJu0YwuF+q8+2IYJ9DGrrTMh2frNx6kZgr3K4WnrXfNnih6GKIIE4g4 3fTu51CpV3W2GhXKin0TBMazNimO0TfLs8BF/Yg/PJWIFNEaotKv X-Google-Smtp-Source: AGHT+IEQt4/2fV5LXFkLO8cN7uRCGHopFqdmdtwD2JLJrdu7DVgEgW6qKK101nhRqCKvea8h/68Qxw== X-Received: by 2002:a05:6a21:399:b0:1d8:b962:6087 with SMTP id adf61e73a8af0-1d9a83aaf44mr17047155637.10.1730210071265; Tue, 29 Oct 2024 06:54:31 -0700 (PDT) Original-Received: from localhost ([115.240.90.130]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-72057931826sm7537824b3a.67.2024.10.29.06.54.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Oct 2024 06:54:30 -0700 (PDT) In-Reply-To: <86wmhr5acv.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 29 Oct 2024 15:04:16 +0200") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:294490 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable [=E0=AE=9A=E0=AF=86=E0=AE=B5=E0=AF=8D=E0=AE=B5=E0=AE=BE=E0=AE=AF=E0=AF=8D = =E0=AE=85=E0=AE=95=E0=AF=8D=E0=AE=9F=E0=AF=8B=E0=AE=AA=E0=AE=B0=E0=AF=8D 29= , 2024] Eli Zaretskii wrote: >> From: Visuwesh >> Cc: luangruo@yahoo.com, 73752@debbugs.gnu.org, xuan@xlk.me >> Date: Tue, 29 Oct 2024 16:29:48 +0530 >>=20 >> >> Is this hash dependent on the font driver? >> > >> > No. Only the font used for the composed characters is recorded, not >> > the font backend which opened it. But fonts are managed by the font >> > backend, so maybe there's some leakage by that way. >>=20 >> OK, thanks. I wonder if we could compare the value returned by >> font-info if something has gone wrong with the font object used to >> compute the hash for the glyph?=20=20 > > That would not be the first thing I'd look at. According to the > screenshots, it is more likely that a wrong cache entry is used for a > composition, which uses the "wrong" font variant. IOW, the font used > itself is fine, it just is not the font that's supposed to be used > with the composed characters in that place. > > So I would first look at the font object stored in the header of the > cached composition. > >> > Btw, how frequently do you use different frames,=20 >>=20 >> Quite often, I would say. I usually have two frames but it can go >> upwards of 5 to 6 if I have a mouse attached to my laptop. >>=20 >> > and how likely are you to have different definitions for the same >> > faces on different frames in the same Emacs session at the same time? >>=20 >> I don't quite understand this question. Are you asking if I have any >> "frame-specific" face attributes i.e., non-nil FRAME argument in >> set-face-attribute? > > Yes. > >> If so, no. > > OK, so one more theory eats dust (we don't record the frame in the > composition cache). > >> > The only way I see to investigate this is to wait for this to happen, >> > then attach GDB to Emacs and look at the problematic compositions in >> > the cache, comparing them to the corresponding compositions in a fresh >> > Emacs session. I can tell what to look for with GDB, if that helps. >>=20 >> That would help. But given how hard it is to reproduce this issue on my >> end, I don't know when I can get back... > > It would not be useful for me to give instructions before you actually > hit the problem (because the code will change until then), so if you > want to try this, get back to me when you do reproduce the problem > (and then attach GDB and leave the Emacs session under GDB for any > investigations I'd ask you to do). I seem to have run into the issue. The attached images "cascadia-code-bold-15-good" and "-bad.png" are the desired and misaligned composite text of "-->" rendered in Cascadia Code bold 15 font. The same text is composed fine with Cascadia Code bold 17. --=-=-= Content-Type: image/png Content-Disposition: attachment; filename=cascadia-bold-15-good.png Content-Transfer-Encoding: base64 iVBORw0KGgoAAAANSUhEUgAAADcAAAApEAYAAADBl23uAAACQ0lEQVR4nO3asaqycBjH8d95DdNC HFpzCFy6gLqCwE3voNnVC2jpNryAoCsQhCZXh3Bp1KWx0EUE7f8OEYeX80YUhT2d57M4pPDA9//P lL6KoiiKQghcoWmapmnXPmVt+dP2AOwxHI4oDkcUhyOKwxHF4YjicER9TLgsy7IsA+q6ruu67Wle j3y43W632+2A6XQ6nU6B+Xw+n8+B0+l0Op3anu51yIcbDofD4RAwTdM0TWC1Wq1WK8B1Xdd1257u hS6vvK4dqcjzPM9zISaTyWQyubzCE8LzPM/z2p7u+b5uvauUJEmSJOBwOBwOh/sXRlVVVVUB3W63 2+0+uryApmmapgHOYwOdTqfT6fw873g8Ho9HwLZt27aBNE3TNAUWi8VisQCWy+VyuXx8jrdxa8f5 vu/7/vcKvvfY6/V6vd7j1z/7GIZhGIbt7pZn+M+a/ZdhGIZhAJZlWZZ16+yfyrIsyxJQVVVV1fuv v7js3PPYgKIoiqJcPz9JkiRJgP1+v9/vgcFgMBgMgNFoNBqNHp/jbXzKPe4iCIIgCISQZVmWZSF0 Xdd1XYg4juM4bnu65/mYcJvNZrPZCHHe2d9f0VEURVHU9nTPRz7cdrvdbrdC9Pv9fr8vxPlH0Ofc y64h/xw3Ho/H4zHgOI7jOMB6vV6v18BsNpvNZm1P9zo3Hwf4rwvvifyO+604HFEcjigORxSHI4rD EcXhiOJwRHE4ojgcURyOKA5HFIcjisMRxeGI4nBEcTiiOBxRHI4oDkcUhyPqLzZoQ2AFsez5AAAA AElFTkSuQmCC --=-=-= Content-Type: image/png Content-Disposition: attachment; filename=cascadia-bold-15-bad.png Content-Transfer-Encoding: base64 iVBORw0KGgoAAAANSUhEUgAAADsAAAAoEAYAAAAQ917FAAACP0lEQVR4nO3asauqcBTA8ZM+Ck1J UJfQQehfsH+hzT+gwbnVP6DFf8PRodktEZpaHaSlsRYXodAxovOGR1y4vHu5t3jXPO98Fpc4nPj+ TKh6TdM0TYOoqqqqqsCIENpegP0bHJYoDksUhyWKwxLFYYnisERxWKI4LFGdD3s8Ho/HI8D1er1e r21v8zo6G3a/3+/3e4DpdDqdTgF83/d9H+B2u91ut7a3a19nw1qWZVkWwGQymUwmAKvVarVaASwW i8Vi0fZ2L+D+I0BX1XVd1zWi67qu6yL+eVeIQRAEQdD2du3p3cOKoiiKIsDpdDqdTt8/IIIgCIIA oGmapmmPz3nPNE3TNAGqqqqq6uPXnc/n8/kM4Hme53kAh8PhcDgALJfL5XIJEIZhGIbP79MZ97BR FEVR9Hbiv3sdjUaj0QgxjuM4jh+f8/6apmmaps/PybIsy7K276Of8+se2LZt27YBZrPZbDb77Cj8 naIoiqIAjMfj8Xj8+Jz3DMMwDOPr83a73W63AyjLsixLAF3XdV0HcBzHcZzn9+mMrj9j79br9Xq9 Ruz3+/1+/+0TJM/zPM/b3u7ndT7sZrPZbDaIkiRJkoQoy7Isy4jb7Xa73ba9XXs6G7YoiqIoEIfD 4XA4RBwMBoPB4P97ln6ks2Evl8vlckGcz+fz+RwxSZIkSdre6nX0+M9sNHX2myf2OQ5LFIclisMS xWGJ4rBEcViiOCxRHJYoDksUhyWKwxLFYYnisERxWKI4LFEcligOS9RvD66YFGVCkuoAAAAASUVO RK5CYII= --=-=-=--