From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: michael-franzese@gmx.com Newsgroups: gmane.emacs.help Subject: Re: Strange behaviour of auto-fill Date: Sat, 24 Apr 2021 01:23:45 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27972"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Help Gnu Emacs To: Christopher Dimech Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Sat Apr 24 01:25:51 2021 Return-path: Envelope-to: geh-help-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 1la5BG-0007B9-Nz for geh-help-gnu-emacs@m.gmane-mx.org; Sat, 24 Apr 2021 01:25:50 +0200 Original-Received: from localhost ([::1]:57196 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1la5BF-0008TX-QW for geh-help-gnu-emacs@m.gmane-mx.org; Fri, 23 Apr 2021 19:25:49 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:54022) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1la59I-0007dF-R4 for help-gnu-emacs@gnu.org; Fri, 23 Apr 2021 19:23:48 -0400 Original-Received: from mout.gmx.net ([212.227.17.22]:33443) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1la59G-0007pb-Ui for help-gnu-emacs@gnu.org; Fri, 23 Apr 2021 19:23:48 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1619220225; bh=V1Bvn32dFGXyKeHUIJv3v9R1lPOUXSAuArfOk5vXSl0=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date:In-Reply-To:References; b=d0MMva507L7dv1XaT19z3KdaK7dM/U3rmzwWd1OPl8YXGLbU0Pf61HyPcjTlLrISL 76INWyPXxnaeP+f82IdSj1eyj1O37U0aZzOkGmjTS9NuXpcxSoK832XZW4M6NKNsOv K49WbHS4y+KRosLgLOUE/G6NfInqqvB4SAruXC5c= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from [213.165.168.94] ([213.165.168.94]) by web-mail.gmx.net (3c-app-mailcom-bs03.server.lan [172.19.170.169]) (via HTTP); Sat, 24 Apr 2021 01:23:45 +0200 Importance: normal Sensitivity: Normal In-Reply-To: X-UI-Message-Type: mail X-Priority: 3 X-Provags-ID: V03:K1:4Yx2sLFdYBa9Sn66e0YqgB9x/U1sgVmLJXeNSRaQbUB0SL9VI/NVZX1oojq5vFr3ql7fi XNyARTvanZtmcMCKa39gO3FgPfa7vcUIydfCjMTp5vD1+QMyYCLy7Nb7O9c4aev6rW8kRus489bw gUFGnGiIlRCJ9VKK+qWIiJmBTg8m+1WNW8hknZuJ5OKBXL0qIuBj+Wsrv1w8S+A3UgoyfguhQNBe iyfaw+4q1tQU+goX9PbVXb5iq2Q6bnDiVUyF+BQHB4Pb/0KR/0t8NxHdCdeN68hBxu2RhgNCPy+r v0= X-UI-Out-Filterresults: notjunk:1;V03:K0:2TZuAZcpRfM=:yMGjrSX0u47TLTFi9uATQL LpbEo3u6Cp+jYTpkQpCY7QGcEW8uO9/8Qbv65yGEH/MFNH4Kf/qXSiG3h2DQACzpqUpCbHYSD anr+N4KWBfUm8LLjIs5sVrhQ53lPTqrO+caTHQJ6/4q9T2rzdMhN6Yb9e9tIAzY9O2SBP8Sfh wSHpVTlu61jzBRiYEFrrugpmiM9svJa47mUdfvHdgJE0P5tJGvTdOesaHjmrMfPb4ZTkYvX1/ TxQ+951s1IsHiAlKu0zcX6f4WrdI9bPPoI16IBMY8CjD9HrdiVrLlZcL2zD7KGv8BnCmNR0Vd /S0R9GQS9MPRpwXh11/13HXx8KBd5CXss8uJh/8k5NDptJ7eaO9u3Xmx1fcIshrvowNHSvLAt edoZ/vrK+ZVN1doJLB5Go9rNungPKkkRekwhPUJgUcA/AzrRpT0JF6FmFDGCZpezBroXOA9lO M2h7rr8K0GWLD4bFTrx+feUK6d3nefxEH0JnnBnkcEB1LhKQ2gDjwIwAgEn1hxfnMlMArlX6S PnwZWljPqmonrIHPDzZzqf+pBEwKHauSeSrq77jjWodajFURtMAbjCf9lDIrRhQXNyuK5o833 Dh30icfjj9KYKkSpdSy/POla07uXS9D225KqF1GuhaUrKeadhwiC3qxg3+Y+5l6r1UM3/GRFQ 8dymuldA11gEeGPQKSRMjIeDO5WfhSp45LYVinrqGIo6UlkVOUE+EiUBhznAgsbG26HHhiMBb QjyiGEnkFcS8gqrdGf4khgRx/ZX8yYTXmCECte6nyGWjU4lHnYwaKY4R1S+ZA4HPOAbNAnLX Received-SPF: pass client-ip=212.227.17.22; envelope-from=michael-franzese@gmx.com; helo=mout.gmx.net X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.io gmane.emacs.help:129138 Archived-At: Actually, when I call (turn-off-auto-fill) after calling (setq-default auto-fill-function 'do-auto-fill) does tell turn the mode off. > Sent: Saturday, April 24, 2021 at 11:21 AM > From: "Christopher Dimech" > To: michael-franzese@gmx.com > Cc: "Help Gnu Emacs" > Subject: Re: Strange behaviour of auto-fill > > > Have had another go and noticed that calling > > (turn-off-auto-fill) > > will not break lines if the following is present > > (setq-default auto-fill-function 'do-auto-fill) > > My impression would be for developers to take a closer look at the > code, so that it's use would be simplified. Or perhaps some good > examples on how to use it, as it does not look so clear to me. > > > Sent: Saturday, April 24, 2021 at 9:42 AM > > From: michael-franzese@gmx.com > > To: "Help Gnu Emacs" > > Subject: Strange behaviour of auto-fill > > > > I am trying to set "auto-fill", with some tools to change "on-off" beh= aviour. > > > > Things get very confusing. When I comment out "(setq-default auto-fil= l-function 'do-auto-fill)", "auto-fill-mode" will still break comments eve= n though "break-line" is "0" > > and one sets "(auto-fill-mode 0)". > > > > > > > > (setq-default auto-fill-function 'do-auto-fill) > > (defvar break-line 0) > > > > (defun break-line-ddd () > > "Breaks long lines using auto-fill tool." > > (interactive) > > > > (pcase break-line > > ((or 'nil 0) > > (setq comment-auto-fill-only-comments nil) > > (auto-fill-mode 0) > > (message "%s %s" > > "Disable: Break line; " break-line) > > (setq break-line 1)) > > (1 > > (setq fill-column 72) > > (setq comment-auto-fill-only-comments t) > > (auto-fill-mode 1) > > (message "%s" "Enable: Break only comments") > > (setq break-line 2)) > > (_ > > (setq comment-auto-fill-only-comments nil) > > (auto-fill-mode 1) > > (message "%s" "Enable: Break all long lines") > > (setq break-line 0)) )) > > > > (defun break-line-set () > > "Breaks long lines using auto-fill." > > (break-line-ddd) > > (global-set-key (kbd "H-b") #'break-line-ddd) ) > > > > (break-line-set) > > > > > > >