From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id cPXfKHsD32FnRQAAgWs5BA (envelope-from ) for ; Wed, 12 Jan 2022 17:36:11 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id uJdSJnsD32GlkwAA9RJhRA (envelope-from ) for ; Wed, 12 Jan 2022 17:36:11 +0100 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 737ABCD7B for ; Wed, 12 Jan 2022 17:36:11 +0100 (CET) Received: from localhost ([::1]:48412 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n7gba-0002Cn-CD for larch@yhetil.org; Wed, 12 Jan 2022 11:36:10 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38700) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n7fqm-0005vH-Ul for emacs-orgmode@gnu.org; Wed, 12 Jan 2022 10:47:49 -0500 Received: from [2a00:1450:4864:20::136] (port=44567 helo=mail-lf1-x136.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n7fql-0006TE-Aj for emacs-orgmode@gnu.org; Wed, 12 Jan 2022 10:47:48 -0500 Received: by mail-lf1-x136.google.com with SMTP id o15so9523463lfo.11 for ; Wed, 12 Jan 2022 07:47:46 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:subject:user-agent:mail-followup-to:date:message-id :mime-version; bh=ynE0KG4C11gEzQfZdgciaOepQgQ5PjdT1sRgRUGcPJc=; b=dWkQYIRYsjZriQ7+UENEfMelW8MUNu7vEOTRFiXTfHaFOji5Jd7MR2tRx3csE4T1S9 cBJDJ4BmgAWQgFMr4ZV9+0XvHDJoNicKPKVZaIaTzt0HUpJQBuRrh2uD4Is/P1TSNy5z R3ViTsx6uKjEi/D23kRgqQPVvyJq64OvUx1IOg64WmhvzRw4I1eHhox8qziIrQ64xbEJ Vuj4qi1MBXnjk3dCxZnpZNnPeZHjhqB608lb2EA9Y8ZhMSl8duxJS9GUZvO+ET2rL3/K Vedyi6RiB7D1JlzYPLE0fomyd0VUG9yDF2LGTu5wHGerKQpeQHC6u6pnowFSBgbKrlw+ PxAw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:user-agent:mail-followup-to:date :message-id:mime-version; bh=ynE0KG4C11gEzQfZdgciaOepQgQ5PjdT1sRgRUGcPJc=; b=08EtTLUq24OGmDI63McoBd3CuWLGrEfz57nipRwFLRTcObuWRWjskURHoORMq03jwa Chc36c4crOxR9sfrzywuYFFWi4BqD81iafuWijHqxCyAXI2dAsjA1se8zwSFcWR6Fr61 s4JPnXHgobw6MjbzB+D11z7QE7bmO4oqacmjqHG3XeXTSoTw3Kb00JxYB9D0Vug1sg98 kxHph3IRC8js5YIWFnc0VVWI4d2qDR9TJpBysmIqJo3iA9rKpS3RThZqPsZSi27QUd7W 0HsxZ+DC3JCE9GutzYfnqlWBb7HN2cutLP7xl2XhIu1SwjrfWM1hXB94/PDfMOeo5M8M Yv9A== X-Gm-Message-State: AOAM532lYH3n31DJGeIrF+KxY+kBxM+keaZFASmY7XIKGYa4jalXTjr9 2V8HFVGy7jid1yOuh4hKdQ91VJjmOEm10Q== X-Google-Smtp-Source: ABdhPJxr2L/QiVZOegHlcNTjgCH813kCWYmq9xCoZ9W+wu5huCWyFTbQ4gmKQBKy2XVdpLBAaWXkmA== X-Received: by 2002:a05:6512:ea9:: with SMTP id bi41mr254312lfb.54.1642002464564; Wed, 12 Jan 2022 07:47:44 -0800 (PST) Received: from thinkmax (host-176-37-1-68.b025.la.net.ua. [176.37.1.68]) by smtp.gmail.com with ESMTPSA id m9sm4878ljp.72.2022.01.12.07.47.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 12 Jan 2022 07:47:44 -0800 (PST) From: Max Brieiev To: emacs-orgmode@gnu.org Subject: Converting document from hard whitespace indentation to org-indent-mode User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) Mail-Followup-To: emacs-orgmode@gnu.org Date: Wed, 12 Jan 2022 17:47:11 +0200 Message-ID: <878rvl9csg.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:1450:4864:20::136 (failed) Received-SPF: pass client-ip=2a00:1450:4864:20::136; envelope-from=max.brieiev@gmail.com; helo=mail-lf1-x136.google.com X-Spam_score_int: -12 X-Spam_score: -1.3 X-Spam_bar: - X-Spam_report: (-1.3 / 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no autolearn_force=no X-Spam_action: no action X-Mailman-Approved-At: Wed, 12 Jan 2022 11:35:11 -0500 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" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1642005371; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=ynE0KG4C11gEzQfZdgciaOepQgQ5PjdT1sRgRUGcPJc=; b=aEogfsGITANRz1Uo77OEFt2yIkEd6mKii9yNG8ieOZia6C7P0xPwnUH8J7aBq9WpjR1cHq 5wjylH1KfPHT+Fs0EH5af4JAkIlBUD00b0QpU7N0UOGeSGhQoWI/VPjtkEwTLxm9dk7zJg tKBz3VgtpmSGDa5bQvqbeYrX+ERvjQDnX421pV0NDdrJneDrBJPiZE/FWokxLXM9ESQErT c+OX1lu0K4qw5I47nFSnmnz5Apdq4hyX5s+2blJ69bWnsTSfRmRzl1DYLnL4iXaHGyVWGl hybSNt7WrlzBDHLhpO4n+kZTodt/jxLQJaIlhbnnulgMK+e9Z3+W8gE3gtDJMg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1642005371; a=rsa-sha256; cv=none; b=fXX+RfVdyS1kfQwFJY8X178SzYwtE1hIU47T3JY41iKm+G0KpOvrc95Yau5IMdNP4BDLcd AAx2ji9UUhpgeVJJap9R0tojYIcHw3BwylcnYxPCuWXEcYMw7S1judU4III6IuinwR9fD5 a9VsQrRJpL2y2E7ikGYMAeOpRNr82iEVOEOyp3fjt0AeY0zQVbkWkCNgpWXucRUXkm4ge1 pPqA3QYZW/YBDkfwT/kHnJe8OdJg6kiwqsgwlH+skIlPUqcSJfYwsz42hrhJXTsUmel3fr ccF5wloVOO1MdbOI9kaNshh9tTLfVQshOOxac/4m71muhdEnsBuhp68JSpmvyw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=dWkQYIRY; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Spam-Score: -7.82 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=dWkQYIRY; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Queue-Id: 737ABCD7B X-Spam-Score: -7.82 X-Migadu-Scanner: scn0.migadu.com X-TUID: alSOFrEpNvVg Several of my documents use indentation to line up with the headings, like below: * Top level headline paragraph + list item lorem ipsum dolor sit amet ** Second level some text *** Third level more text I would like to strip leading whitespace, so that I could switch to =org-indent-mode= to have a nice view of the document instead of using hard whitespace indentation. Basically I want to: - strip leading whitespace, - but preserve the indentation of lists and src blocks - refill all paragraphs according to what =org-fill-paragragh= would do. How would I do it programmatically? My current Elisp knowledge is poor. Thanks in advance.