emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Farblos" <AKFKQU.9DF7RP@vodafonemail.de>
To: emacs-orgmode@gnu.org
Subject: [BUG] `org-entry-put' creates a new property drawer if case folding is turned off [9.5.2 (9.5.2 @ /usr/share/emacs/site-lisp/elpa/org-9.5.2/)]
Date: Tue, 07 Mar 2023 14:11:46 +0100	[thread overview]
Message-ID: <bfe85786b1b3471fbca89d4e0759bcb3@vodafonemail.de> (raw)

To reproduce, start on a Bourne shell command line with

cat << EOF > foo.org
* heading heading heading
:properties:
:foo: bar
:end:
EOF

Then start

emacs -Q foo.org

In Emacs continue:

M-x set-variable RET case-fold-search RET nil RET

C-c C-x p foo RET bar RET

For me Org then creates a new property drawer, so the buffer looks like this afterwards:

--- snip ---
* heading heading heading
:PROPERTIES:
:foo:      bar
:END:
:properties:
:foo: bar
:end:
--- snip ---

Root cause should be the following snippet in function `org-entry-put':

	 (let* ((range (org-get-property-block beg 'force))
	        (end (cdr range))
	        (case-fold-search t))

When moving `(case-fold-search t)' to before the call of `org-get-property-block' things work as expected.

Emacs  : GNU Emacs 28.2 (build 2, x86_64-pc-linux-gnu, X toolkit, cairo version 1.16.0, Xaw3d scroll bars)
 of 2023-01-18, modified by Debian
Package: Org mode version 9.5.2 (9.5.2 @ /usr/share/emacs/site-lisp/elpa/org-9.5.2/)




             reply	other threads:[~2023-03-07 13:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-07 13:11 Farblos [this message]
2023-03-07 14:28 ` [BUG] `org-entry-put' creates a new property drawer if case folding is turned off [9.5.2 (9.5.2 @ /usr/share/emacs/site-lisp/elpa/org-9.5.2/)] 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=bfe85786b1b3471fbca89d4e0759bcb3@vodafonemail.de \
    --to=akfkqu.9df7rp@vodafonemail.de \
    --cc=emacs-orgmode@gnu.org \
    /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).