minad / tempel

:classical_building: TempEl - Simple templates for Emacs
GNU General Public License v3.0
506 stars 24 forks source link

`abox` sample template expansion #110

Closed c-alpha closed 1 year ago

c-alpha commented 1 year ago

When I use the abox template from the README.org, I see an unexpected expansion behaviour. When expansion starts, everything looks as expected:

+--+
|  |
+--+

The cursor is blinking inside the box. So far so good. Now I type test and would expect the box to be expanded, surrounding the word test. This is what the actual result is, however:

+-----+test
|  |
+-----+

As soon as I hit the first key, the cursor jumps to the end of the box's top line, and text gets inserted there.

I have experimented a bit and found that it is the vertical bar (| aka pipe character) at the beginning of the second line which triggers this behaviour. If I modify the template to put any character other than a | at the beginning of the second line, the template works as expected.

minad commented 1 year ago

Hi! Thanks for the report. Unfortunately I cannot reproduce this in my setup in org-mode or text-mode. Can you please provide a precise recipe starting from emacs -Q (including Emacs and package versions)? I assume that some minor or major mode is interfering in your configuration, which handles the pipe character specially.

c-alpha commented 1 year ago

[...] I assume that some minor or major mode is interfering in your configuration, which handles the pipe character specially.

You nailed it (once again). It was Orgtbl Minor Mode which interfered. Many thanks!