From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#71763: [PATCH] Inconsistency in bitmap overlay drawing for macOS Date: Sun, 27 Oct 2024 15:41:16 +0200 Message-ID: <86o7358xz7.fsf@gnu.org> References: <86frsy684o.fsf@gnu.org> <86ttcx92k7.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="39524"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71763@debbugs.gnu.org, daniel@dpettersson.net To: Gerd =?UTF-8?Q?M=C3=B6llmann?= Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Oct 27 14:42:49 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 1t53Xc-000A62-Eh for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 27 Oct 2024 14:42:48 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t53XJ-0000pU-0g; Sun, 27 Oct 2024 09:42:29 -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 1t53XH-0000p5-LT for bug-gnu-emacs@gnu.org; Sun, 27 Oct 2024 09:42:27 -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 1t53XH-0000Xd-Di for bug-gnu-emacs@gnu.org; Sun, 27 Oct 2024 09:42:27 -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:References:In-Reply-To:From:Date:To:Subject; bh=MlD7bk676ezm8Cd8ywCc5h0KPjEy+CTG9JxYJPoHBTY=; b=OsYdqtWTO8u7MZpUFHyEQ+GFUNXLqv2MQNw9t4Eu6+BMtd6Stc1BXsIooFSbYdUNMOraifZ5IRIUQ2BYT6su+Z0dQxHETuxkTiqdqdIESKugcM0fjV2c5NNWEpdHVWyhG/+rwa96k+tjpg2/yK3q5ThelcUhQNwVk1XldrdWce69JZETYln7qp60uqw4yciR7SRT2AKURYvg2WJ2GaKFFnCDSleE2Z6DmWFRKUi37jC0tNqAbsyMK1GCDd/ENDvlTZcE+3MxM6lAVGIAzrQzJFw4XLmDGOlh+LGf0bicKw7lqu1oy3lG2Xczxk5QwE7AN6dmiSPPDtrlIFyZTc+BDA==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t53Xq-00075Q-4W for bug-gnu-emacs@gnu.org; Sun, 27 Oct 2024 09:43:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 27 Oct 2024 13:43:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71763 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 71763-submit@debbugs.gnu.org id=B71763.173003652327137 (code B ref 71763); Sun, 27 Oct 2024 13:43:02 +0000 Original-Received: (at 71763) by debbugs.gnu.org; 27 Oct 2024 13:42:03 +0000 Original-Received: from localhost ([127.0.0.1]:44310 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t53Ws-00073X-JS for submit@debbugs.gnu.org; Sun, 27 Oct 2024 09:42:03 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:46000) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t53Wq-00072w-I6 for 71763@debbugs.gnu.org; Sun, 27 Oct 2024 09:42:01 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t53WB-0000TO-No; Sun, 27 Oct 2024 09:41:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=MlD7bk676ezm8Cd8ywCc5h0KPjEy+CTG9JxYJPoHBTY=; b=sQnMmfsTiy/eg0M2pJKF soTwNWwTIkeWl1PtxS5vIcyBvW3jSGmXAzSAwVOuuE+LConl3tWi4suzVpQfHFPbhYiSxjE0gkDUf 0K9zibQWQQveWdkYstb4PmLwJ8Z9/QwXBCuYn7VK7nr/vS9aQqzkjjwg0IGq0PjXO4ZwXsKam5rqn eQzA++1mIfaPolwcxtsPJZAV0+P3fomuRDwioo01hcBPS8m030dDBkBKOiP2sLGsMrHC/IQbDQ/Jm IKlO2tHut2m+WlXJknDYZjqse7UEvrKpz2BIiqRn9MGwGGTkCWSlX0C/NRHp1lvimjlK8fbENL9M0 iO2h6pC5RpexMQ==; In-Reply-To: (message from Gerd =?UTF-8?Q?M=C3=B6llmann?= on Sun, 27 Oct 2024 14:23:49 +0100) 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:294359 Archived-At: > From: Gerd Möllmann > Cc: Daniel Pettersson , 71763@debbugs.gnu.org > Date: Sun, 27 Oct 2024 14:23:49 +0100 > > > Thanks, but maybe Gerd (CCed) will agree to look at this? > > The struct draw_fringe_bitmap_params is not documented very well, so > I've looked at fringe.c for what its overlay_p member means. I landed in > draw_fringe_bitmap_1, where draw_fringe_bitmap_params::overlay_p is set > if that function is called with an overlay parameter that fits some > criterion, which one can try to figure out in its caller > draw_fringe_bitmap. It apparently has something to do with drawing a > cursor in a fringe, and then also drawing an overlay arrow. Thanks for taking a look. > Didn't even know until a few minutes ago that the cursor can land in > the fringe. See overflow-newline-into-fringe. It was added in Emacs 22 (and is ON by default, as you can see by typing enough characters on a line and ending the line with a newline, such that the last character before the newline fits completely on the screen line). > And I'm wondering if that ever happens in the left fringe, It can, if the window shows RTL text, which starts at the right edge of the window. > and/or if the overlay arrow appears only on the left. In an RTL buffer, the arrow should appear on the right. > Anyway. Assuming that I read the code correctly, that we are drawing a > cursor and overlay arrow on top of each other, then I think Daniel's > patch makes sense, because drawing the overlay arrow should not clear > under it and erase what was drawn for the cursor before. > > That's about what I could find out. NS should do something different if > overlay_p is set or not, I think that's for sure. And if Daniel says it > works, that's goog enough for me I guess. Thanks. If possible, can you also tell what the current code does wrong, that this patch fixes?