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#57669: 29.0.50; C-n, C-p off under long lines Date: Sat, 10 Sep 2022 16:22:03 +0300 Message-ID: <83tu5f9xfo.fsf@gnu.org> References: <87y1uujufi.fsf@dick> <87illxka46.fsf@dick> <8335d1dr39.fsf@gnu.org> <87mtb8hezl.fsf@dick> <838rmsd4cc.fsf@gnu.org> <878rmsh9me.fsf@dick> <87zgf8fsv3.fsf@dick> <83zgf8bkmn.fsf@gnu.org> <83v8pwbjvy.fsf@gnu.org> <87a678fnnz.fsf@dick> <83r10kbex8.fsf@gnu.org> <875yhwflw7.fsf@dick> <83pmg4bcjt.fsf@gnu.org> <87wnace31g.fsf@dick> <87k06cdx8m.fsf@dick> <87fsh0dt7y.fsf@dick> <8335czbpe6.fsf@gnu.org> <87y1urcryx.fsf@dick> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3889"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 57669@debbugs.gnu.org To: dick Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Sep 10 15:23:10 2022 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 1oX0Rx-0000nF-VY for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 10 Sep 2022 15:23:10 +0200 Original-Received: from localhost ([::1]:41390 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oX0Rw-0001lT-FU for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 10 Sep 2022 09:23:08 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:50350) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oX0Rr-0001lG-8A for bug-gnu-emacs@gnu.org; Sat, 10 Sep 2022 09:23:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48142) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oX0Rq-0006G9-RM for bug-gnu-emacs@gnu.org; Sat, 10 Sep 2022 09:23:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1oX0Rq-0007St-Ho for bug-gnu-emacs@gnu.org; Sat, 10 Sep 2022 09:23: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: Sat, 10 Sep 2022 13:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 57669 X-GNU-PR-Package: emacs Original-Received: via spool by 57669-submit@debbugs.gnu.org id=B57669.166281615228645 (code B ref 57669); Sat, 10 Sep 2022 13:23:02 +0000 Original-Received: (at 57669) by debbugs.gnu.org; 10 Sep 2022 13:22:32 +0000 Original-Received: from localhost ([127.0.0.1]:36841 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oX0RM-0007Rx-20 for submit@debbugs.gnu.org; Sat, 10 Sep 2022 09:22:32 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:40422) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oX0RJ-0007Rj-My for 57669@debbugs.gnu.org; Sat, 10 Sep 2022 09:22:30 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:50426) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oX0RE-00068s-93; Sat, 10 Sep 2022 09:22:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Ru4IjuINLTZyEO+1MLCfqtBhS9ZJ6KzMyGI5cgqRILk=; b=go40UPQXORY/ +3vQ+1IU20TsT6+vY55cK/ieVriFUaSFP01zWrW+JMP6Lv5s6+JCbNkWkVZNxnIQA5k3wco7kd+h+ 4iT5D8R2BloOXfIvFD81EkpCisp/ZXFShsH+fzADGpvQenp2kRxKd/9bNromHs+k6dCeQu9yauXqt qi9d/aZiwmpdyuqPGWVpjitqXcoU+D71Zry94PmXh2kea9WSAlA12pf0U6gvD3WA9taYWbJXt0/mu uM7rOIeRpd0o9jJ2XYH5lvSgJBkELIdFkWKVGaZdCbVh9HDHr+0WTRxbn70pJprijIJjQRzzyChNI wI82OvIJkNgKS17qd363BA==; Original-Received: from [87.69.77.57] (port=1198 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oX0RD-0001cd-N8; Sat, 10 Sep 2022 09:22:24 -0400 In-Reply-To: <87y1urcryx.fsf@dick> (message from dick on Sat, 10 Sep 2022 08:51:50 -0400) 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" Xref: news.gmane.io gmane.emacs.bugs:242103 Archived-At: > From: dick > Cc: 57669@debbugs.gnu.org > Date: Sat, 10 Sep 2022 08:51:50 -0400 > > monospace-p I agree is an heuristic like narrowing. In the majority of > cases of long lines, it applies the algebraic shortcut when it thinks it > can get away with it. Btw, the way you reset the monospace flag in add_text_properties is also problematic: the code is looking only at the specific face that is the value of the property. But Emacs applies faces by merging them with other sources of face information, not just by using the single face named by the property. As the simplest example, consider a face whose only non-unspecified attribute is :inherit -- in that case, AFAIU your code will not reset the monospace flag, but when Emacs will actually use the face for rendering, it will follow the inheritance chain and might find there one of the face attributes your code does care about. Also, I don't see the monospace flag being reset if the face's font is not a fixed-pitch one. Did I miss something?