From unknown Sat Jun 14 19:25:36 2025 X-Loop: help-debbugs@gnu.org Subject: bug#35396: 12.1.2; wrong interaction between auto-fill and latex comments Resent-From: gojjoe@gmail.com Original-Sender: "Debbugs-submit" Resent-CC: bug-auctex@gnu.org Resent-Date: Tue, 23 Apr 2019 15:15:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 35396 X-GNU-PR-Package: auctex X-GNU-PR-Keywords: To: 35396@debbugs.gnu.org X-Debbugs-Original-To: bug-auctex@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.15560324796636 (code B ref -1); Tue, 23 Apr 2019 15:15:01 +0000 Received: (at submit) by debbugs.gnu.org; 23 Apr 2019 15:14:39 +0000 Received: from localhost ([127.0.0.1]:54067 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hIx82-0001iy-Jf for submit@debbugs.gnu.org; Tue, 23 Apr 2019 11:14:38 -0400 Received: from eggs.gnu.org ([209.51.188.92]:43200) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1hIx81-0001il-RW for submit@debbugs.gnu.org; Tue, 23 Apr 2019 11:14:38 -0400 Received: from lists.gnu.org ([209.51.188.17]:55582) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1hIx7w-0002XX-7r for submit@debbugs.gnu.org; Tue, 23 Apr 2019 11:14:32 -0400 Received: from eggs.gnu.org ([209.51.188.92]:57582) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1hIx7v-0003cB-1o for bug-auctex@gnu.org; Tue, 23 Apr 2019 11:14:32 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1hIx7u-0002WP-0o for bug-auctex@gnu.org; Tue, 23 Apr 2019 11:14:31 -0400 Received: from mail-lf1-x131.google.com ([2a00:1450:4864:20::131]:45754) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1hIx7t-0002VR-Ov for bug-auctex@gnu.org; Tue, 23 Apr 2019 11:14:29 -0400 Received: by mail-lf1-x131.google.com with SMTP id t11so12051588lfl.12 for ; Tue, 23 Apr 2019 08:14:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=to:from:subject:message-id:date:user-agent:mime-version :content-language:content-transfer-encoding; bh=6/VHJnG1hHqSL/vGw9BfLZr0mjgVvPXNXjJZOxPJOr8=; b=liVnvfb2ohKbOs3XnTzI3Q1TYaaFutgxXPwnwO62kPTPDn5AUvWXEKtz3tJgUDska4 0lxV/F2ikT8Yx8EWYXPE4VoliaswMaRv5gyKtEejdRfsJPGowUwfYXkOynLRBKNMSGo8 m1ZE1Zq12y2pbPL2vfBhEmOm904O4n7rRVq0hg8OetPfxYJ+fGEsicdHR3Xut1vTrC2l Z00+Lg7mKG+j2mwAJFKD/NN+Hk5hOWTkFwNow3/O0QClwtLbKkUMdmh3SNF9+dX9qjQP t+bllccqIVnzAGcUoFhHjwRQmXv+K7rh61WxsVXW30QESuWhIG4+5og7ZZYxFNEcJwJ2 XQwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:to:from:subject:message-id:date:user-agent :mime-version:content-language:content-transfer-encoding; bh=6/VHJnG1hHqSL/vGw9BfLZr0mjgVvPXNXjJZOxPJOr8=; b=WyP4Qd9b2eN2mCWSFsKFY9Iav8en2q1M6S55PNd1ko1KBNnbyzocQFCzy5N63lXKKX oKykimkaOgoXiwuNz0RUymhyxgvJEOQClhUqrVxG6h3VHDg56WU6F2Q0F2ZSNrH4upqN crIlO6aUTFG6JDfu8A99Xo4URupG6QVWC5ZTbEpNNpmRUsisBlKYQhK6v/+9JeyGiu3k +LwXa8oz7U0UaqMSG2MprpMcDjBhsvABaI7Fwzx4mih3bdCtEXTxuPabX0k6HWtwmwcW udzRGmfcWRc8+wcgb56XqeqSCWkFGbFEIyzQ06sYefhDsxI2yrr0M4pt0f8iIDPQOtWL 1l5g== X-Gm-Message-State: APjAAAX30h7EiirQDpPYgSUFIj1a2sSK/pi4vzwFR7BtlVR+rXVI6dZu d/9ggLiPK/FpnsBRoJRxMiDNm/+A X-Google-Smtp-Source: APXvYqynJg09x4qHAjqwaGyVJ1Lf9fzNYFKjr8zz3KIu4VN0mEvXJ7sDeZHYcOPnJtZKHfQkbvtsuA== X-Received: by 2002:ac2:5495:: with SMTP id t21mr14174740lfk.3.1556032467211; Tue, 23 Apr 2019 08:14:27 -0700 (PDT) Received: from [10.81.0.6] ([46.29.2.69]) by smtp.gmail.com with ESMTPSA id d16sm3800413lfi.75.2019.04.23.08.14.25 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 23 Apr 2019 08:14:26 -0700 (PDT) From: gojjoe@gmail.com Message-ID: Date: Tue, 23 Apr 2019 17:14:24 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-CA Content-Transfer-Encoding: 8bit X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::131 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Spam-Score: -1.3 (-) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Hi all. – Problematic behaviour: When one is writing text in front of a comment '%' and auto-fill automatically inserts a newline, the point is suddenly moved to *within* the comment, ie on the right of '%'. – Expected behaviour: The point in the new line should stay to the left of the comment, ie of '%'. – Example: 1. Activate auto-fill-mode in a tex file where LaTeX mode is active. 2. Set fill-column to some value; here I use 20. 3. Suppose we have a line like this: 123456789% commented 4. Now we'd like to add some more text right before the "%", eg "-1234567890 abc". Note that "123456789-1234567890" is twenty characters long, so auto-fill should automatically insert a newline as we type the space after "0". Expected result: 123456789-1234567890 abc% commented [with point between 'c' and '%'] Instead we get this: 123456789-1234567890 % abccommented [with point between 'c' and 'c'] That is, our text has been continued *within* the comment, which wasn't our intention. – Further info: A. If the text before the comment is *already longer* than auto-fill-column when we type the space, and if auto-fill can carry some previous text to the new line, then everything works correctly. For example, If we have 123456789% commented And now we type " 1234567890X abc" (note: space instead of "-") right before the "%", we get 123456789 1234567890X abc% commented as desired. B. The length of the text after "%" seems to be irrelevant for this issue. Let me know what additional info to provide. Cheers! J Emacs : GNU Emacs 26.1 (build 1, i686-w64-mingw32) of 2018-05-30 Package: 12.1.2 AUCTeX-date "2019-02-08" window-system 'w32 LaTeX-version "2e"