emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Bug: org-catch-invisible-edits still allows some invisible edits [9.1.9]
@ 2019-05-12 17:41 Vlad Shcherbina
  2019-05-17 20:31 ` Bruno Barbier
  0 siblings, 1 reply; 2+ messages in thread
From: Vlad Shcherbina @ 2019-05-12 17:41 UTC (permalink / raw)
  To: emacs-orgmode

Steps to reproduce:
1. runemacs.exe -Q
2. In the scratch buffer, M-x org-mode
3. M-: (setq org-catch-invisible-edits 'show-and-error)
    (could be also reproduced with 'smart)
4. Replace the content of the scratch buffer with the following:
* hello
** world
5. Position point at the end of "hello", press Tab to collapse.
So it looks like this:
* hello<point>...
6. Press Del.

Expected result:
Edit should be prevented because it deletes invisible character.

Actual result:
Edit is performed without any warning.
By the way, the editor ends up in corrupt state because the content
of the buffer is now "* hello** world", but it is displayed as
"* hello..." and you can't uncollapse it by pressing Tab anymore.

Version info:
GNU Emacs 26.2 (build 1, x86_64-w64-mingw32) of 2019-04-13
Org mode version 9.1.9 (release_9.1.0-65-g5e4542 @
c:/emacs/share/emacs/26.2/lips/org/)

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Bug: org-catch-invisible-edits still allows some invisible edits [9.1.9]
  2019-05-12 17:41 Bug: org-catch-invisible-edits still allows some invisible edits [9.1.9] Vlad Shcherbina
@ 2019-05-17 20:31 ` Bruno Barbier
  0 siblings, 0 replies; 2+ messages in thread
From: Bruno Barbier @ 2019-05-17 20:31 UTC (permalink / raw)
  To: Vlad Shcherbina, emacs-orgmode



Vlad Shcherbina <vlad.shcherbina@gmail.com> writes:

> Steps to reproduce:
> 1. runemacs.exe -Q
> 2. In the scratch buffer, M-x org-mode
> 3. M-: (setq org-catch-invisible-edits 'show-and-error)
>     (could be also reproduced with 'smart)
> 4. Replace the content of the scratch buffer with the following:
> * hello
> ** world
> 5. Position point at the end of "hello", press Tab to collapse.
> So it looks like this:
> * hello<point>...
> 6. Press Del.
>
> Expected result:
> Edit should be prevented because it deletes invisible character.
>
> Actual result:
> Edit is performed without any warning.
> By the way, the editor ends up in corrupt state because the content
> of the buffer is now "* hello** world", but it is displayed as
> "* hello..." and you can't uncollapse it by pressing Tab anymore.
>
> Version info:
> GNU Emacs 26.2 (build 1, x86_64-w64-mingw32) of 2019-04-13
> Org mode version 9.1.9 (release_9.1.0-65-g5e4542 @
> c:/emacs/share/emacs/26.2/lips/org/)


FWIW, I could reproduce using <deletechar> (bound to
delete-forward-char). Using DEL (bound to org-delete-backard-char),
everything works as expected.

 GNU Emacs 26.1 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.4) of
 2019-04-22

 emacs -Q:
   Org mode version 9.1.9 (release_9.1.9-65-g5e4542 @
   /usr/share/emacs/26.1/lisp/org/)
  
 fully configured emacs:
   Org mode version 9.2.3 (release_9.2.3-10-g385955 @ ...)


Bruno

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-05-17 19:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-12 17:41 Bug: org-catch-invisible-edits still allows some invisible edits [9.1.9] Vlad Shcherbina
2019-05-17 20:31 ` Bruno Barbier

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).