emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@posteo.net>
To: Hammer Hu <hammer@posteo.net>
Cc: emacs-orgmode@gnu.org
Subject: Re: [BUG] Incorrect indentation when there are invisible/diplay properties on the line [9.6.7 ( @ /home/huzf/.cache/emacs_configs/default/elpa.28/org-9.6.7/)]
Date: Tue, 11 Jul 2023 11:28:43 +0000	[thread overview]
Message-ID: <87mt027klw.fsf@localhost> (raw)
In-Reply-To: <xwtdksxajc3etgkoimzvqgjn7sya6cj5znhaup6ttepdtlvtqp@lselyqcs6noh>

Hammer Hu <hammer@posteo.net> writes:

> When `org-modern' is installed and `org-modern-mode' is enable in a
> buffer, the fontification is augmented. See
> [[https://raw.githubusercontent.com/minad/org-modern/screenshots/example.gif]]
> for a demonstration.  But when I have `org-modern-mode' turned on,
> `org-adapt-indentation' to be `t', and indent some region, it becomes:
> ...
> #+begin_quote
> Thanks. I can reproduce the problem. It seems that `org-indent-region'
> or `org-indent-line' has issues computing the indentation if there are
> invisible/diplay properties on the line. This is not something we can
> fix in org-modern, since `org-modern' only augments the fontification
> and does not override indentation functionality. It should be repaired
> in Org directly if even - maybe ask on the Org issue tracker? I suggest
> you either don't use `org-adapt-identation' or set
> `org-modern-block-name' to nil. With `org-modern-block-name=nil' the
> issue also seems to go away.
> #+end_quote
>
> Emacs  : GNU Emacs 28.2.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.36, cairo version 1.17.6)
>  of 2023-01-07

Thanks for reporting!

Org relies on `current-indentation' to determine indentation.
AFAIU, `current-indentation' was not able to handle invisible and
display properties before Emacs 29.

May you please try to reproduce using Emacs 29 or newer?

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>


  reply	other threads:[~2023-07-11 11:29 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-10 15:22 [BUG] Incorrect indentation when there are invisible/diplay properties on the line [9.6.7 ( @ /home/huzf/.cache/emacs_configs/default/elpa.28/org-9.6.7/)] Hammer Hu
2023-07-11 11:28 ` Ihor Radchenko [this message]
     [not found]   ` <44rsvv2dwp2cnpbikqs7kysct5ylsxivm3scirj55efm7qvwat@flec34dbbdbb>
2023-07-11 13:22     ` Ihor Radchenko
2023-07-11 13:49       ` Hammer Hu
2023-07-11 15:07         ` Ihor Radchenko
2023-07-11 15:29           ` Hammer Hu
2023-07-12  8:42             ` Ihor Radchenko
2023-07-12 17:43               ` Hammer Hu
2023-07-12 17:48                 ` Ihor Radchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mt027klw.fsf@localhost \
    --to=yantar92@posteo.net \
    --cc=emacs-orgmode@gnu.org \
    --cc=hammer@posteo.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).