From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:700:3204::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id WNQ3CoPEnmWVpgAAkFu2QA (envelope-from ) for ; Wed, 10 Jan 2024 17:23:31 +0100 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 6ET4AoPEnmVOvwAAe85BDQ (envelope-from ) for ; Wed, 10 Jan 2024 17:23:31 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=positron.solutions header.s=google header.b="d578T/xO"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1704903810; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=1JM/WsPC/8pZWJ2pbigqFVN/9PXlwawv382f/9ZQtjw=; b=LxZwz+wIrTilNwDgcVzrZcUupk56pRos3jUp0J49xGB0/3bhgx5UCFQfOTFVkVuv129zvd NKzxOzjxxRH/DKRPZH95os/QpfISekm4sN4autqkTD8j1Jge0FdvccCg8zcrlNIDMBncut ib2IU9bSUoL4t4muNoR/hbsWMlJ60Xlndrh0iDye7e2rfLAoFXG4S4xYQHNsALGf6yj91b ZM6OnRSA1cWcu3gwiIqu4+vgNxMfBf3OQwBZp6/vJdMWaCL+mAfmn67uEcBdBCJDGkpZUj 9d9yK64DVOhFL6tDmdZTK5g/1RguWQAB3OUoqD2LsDzPJmFhwJHt3wJygXbovA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1704903810; a=rsa-sha256; cv=none; b=ad1JNLfr9sHEXZXaX+SbIdX0stL+L4TIn40KxMTZSvKS7YU7KncKK4vJd12Ee5oruJQ+KK 2mBTkG3Ufm4BvtA1LPLnKSH7xuy2qweydNkhL0VGKsUZLLBdVRkK75D2Oh/JVlkYZ5d8za fjL1GdPik8brhOgpbDmcHq6USfST7ywyCjh1I8MPqpKcoiRXvcvXPifFsKMkSI8LboE5Xx Vtq5v+aZHMFtbs1V2Udw59YABgKhQ1bWO+VLfSM6UYrHoWoD+IVXgfePxZzUTNtEsi0MXl kNF7Qt7dl6I57nJ6d7ME1onNq6fPKSdfKGgWUqSa/Jky/M0/X6IlGN9xamcpkQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=positron.solutions header.s=google header.b="d578T/xO"; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=none Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 5C047690EE for ; Wed, 10 Jan 2024 17:23:30 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rNbLp-0002Sm-2Y; Wed, 10 Jan 2024 11:22:45 -0500 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 1rNbLn-0002QH-My for emacs-orgmode@gnu.org; Wed, 10 Jan 2024 11:22:43 -0500 Received: from mail-yb1-xb36.google.com ([2607:f8b0:4864:20::b36]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rNbLl-0005it-Rc for emacs-orgmode@gnu.org; Wed, 10 Jan 2024 11:22:43 -0500 Received: by mail-yb1-xb36.google.com with SMTP id 3f1490d57ef6-dae7cc31151so3310901276.3 for ; Wed, 10 Jan 2024 08:22:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=positron.solutions; s=google; t=1704903760; x=1705508560; darn=gnu.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=1JM/WsPC/8pZWJ2pbigqFVN/9PXlwawv382f/9ZQtjw=; b=d578T/xONNPG6qrs0IyH2vffXmZWJnHjpOGI010hm22gv9hL9UxN8zEj3LXw421Ar3 DjRg2qae0gge2F5jkjLvDT6AFczu696LsAgu8dpQfGnE7EpDm4WiB8Eho64HtOxIK6vx ZeYE7epgiMDQo1yaHy3Ns3QeowzypjxuH3Gmi0VfQGr1q2eO4CvNpZFhrgJohSlBG+lw 4yDW1esd2hcCJr20tfkkC6q3rfNCA5GnzZ/lbb5hGv9EUXUQqptdZZVZvkoqML4rjq4p eUmlIVxpMVTf9r61LvxnXPblqpm+NrxbKcu+YeR8yXbNsww9IstquH6nd/WQbusXLtWZ HzuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704903760; x=1705508560; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=1JM/WsPC/8pZWJ2pbigqFVN/9PXlwawv382f/9ZQtjw=; b=QRrxVK14xtx9Bhv/hvdtvF5+Y40yHFzxt+3qtfPxz3LwzuEFSWNX3hhNSwJ7t70P15 G0u+Hq+PQ/8pwovquETMAsKVBeXOiIvF029M9YaBROfztyOTJtW2Vw3KNcC/RMDeLrk6 MIEBjALXphzu3fKUsBA7SEHVWDzoOlRGZUfn0VOC6RZ3L+k48sr/rGB/sDoSTV05MJlD XXqSj1WiccSCC0aCy31jroRFsdXz/WX7ccsbWHOHoTWzSrDTYrtiqpSedJHSNPQLgiw6 XyGs8KIHcZUDT16tGW5tSS6C8/nDgz9CLuZiSDlWA85HmCs9zhQAF49RNGsejPZPwTM+ 5Jmw== X-Gm-Message-State: AOJu0YwN0NShC6MvAwXlC3VNi62e3sZn2U2Zlc3qOJKhP4gTnLYmFQkI e/pidq4Jt4NmoT+xidT3ajgUaf9okZvFi5YgJ9p0OwXsSI+xg9ru/pJN6fA/sFo= X-Google-Smtp-Source: AGHT+IH371/43PGpbj64VANlc4v+K9WzWOigJ2ayq/199Ap42uLnI25372DvNX4/Uap+XRwyRPZMduybCpXIrjNnE5E= X-Received: by 2002:a05:6902:2410:b0:dbc:d8e9:37bf with SMTP id dr16-20020a056902241000b00dbcd8e937bfmr1159124ybb.122.1704903760213; Wed, 10 Jan 2024 08:22:40 -0800 (PST) MIME-Version: 1.0 References: <874jflqsdl.fsf@localhost> <87le8xkx0q.fsf@localhost> In-Reply-To: <87le8xkx0q.fsf@localhost> From: Psionic K Date: Thu, 11 Jan 2024 01:22:29 +0900 Message-ID: Subject: Re: org-(un)fill-buffer To: Ihor Radchenko Cc: Psionic K , emacs-orgmode@gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::b36; envelope-from=exec@positron.solutions; helo=mail-yb1-xb36.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Queue-Id: 5C047690EE X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -6.32 X-Spam-Score: -6.32 X-TUID: 8larE+ZdReI4 If I run fill-region on a buffer, there's a lot of errors where the lack of element awareness means filling is attempted on text that does not fill properly, such as property drawers, keywords, and even src-blocks without newline separations. The result requires way too much cleanup. It is critical to be able to unfill documents for people to migrate off of hard newlines and onto visual line mode with variable pitched fonts. I could probably convert this to a region-based command and we could shadow fill-region. It might be slightly tricky to deal with the region if it overlaps elements, but if I had to do it now, I would make the inclusion of part of an element include all of that element. On Thu, Jan 11, 2024 at 12:47=E2=80=AFAM Ihor Radchenko wrote: > > Psionic K writes: > > >> You may instead just run > >> (let ((fill-column most-positive-fixnum)) (fill-region (point-min) (po= int-max))) > > No. That will have to be run manually on every element and every line > > of every list. I suppose let's just not talk about it further and > > I'll submit a patch so there's no confusion. > > May you please elaborate what is wrong with `fill-region'? > > > This is the org-fill-buffer command, done generically for people who wa= nt > > to fill or unfill the entire buffer, as is required when alternating > > between hard newline filling and visual line mode filling. > > ... > > * lisp/org.el: (org-fill-buffer) this command walks the tree and will > > call fill-paragraph on every paragraph or plain-list element, enabling > > the user to quickly cycle between hard newlines or visual-line-mode. > > They can also adjust the fill, such as after removing indentation. > > I'd rather make use of the existing Emacs toggles that control filling, > so that `fill-region' works as expected. > > -- > Ihor Radchenko // yantar92, > Org mode contributor, > Learn more about Org mode at . > Support Org development at , > or support my work at --=20 =EB=82=A8=EB=B0=B1=ED=98=B8 =EB=8C=80=ED=91=9C =EA=B2=B8 =EA=B3=B5=EB=8F=99 =EC=B0=BD=EC=97=85=EC=9E=90 =ED=8F=AC=EC=A7=80=ED=8A=B8=EB=A1=A0