-
Notifications
You must be signed in to change notification settings - Fork 167
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
frontmatter metadata is incorrectly folded #136
Comments
(defun outline-on-heading-p (&optional invisible-ok)
"Return t if point is on a (visible) heading line.
If INVISIBLE-OK is non-nil, an invisible heading line is ok too."
(save-excursion
(beginning-of-line)
(and (bolp) (or invisible-ok (not (outline-invisible-p)))
(looking-at outline-regexp)))) We cannot control its behaviour as we expected without overwriting function or advice feature. |
How about if we introduce an option to disable Setex headers (the ones underlined)? I only use ATX headers (the ones that go |
I disagree. Because it is markdown specification. And this is outline-mode issue. (I hope it should be customizable) However you can change it by following configuration. (defun my/markdown-mode-hook ()
(setq-local outline-regexp "^\\(?:\\(#+\\)[ \t]+\\(.*?\\)[ \t]*\\(#*\\)\\)$"))
(add-hook 'markdown-mode-hook #'my/markdown-mode-hook) |
markdown-mode has its own outline visibility cycling (section folding) functions which you should use rather than using The new commit (a646fea) adds code to un-hide text in the metadata block that outline-minor-mode mistakenly hides. |
So I found out about
markdown-use-pandoc-style-yaml-metadata
which is great. I use outline-minor-mode so that I can fold up all sections for example, but it ends up treating the line right before the end of the metadata block as a header.The text was updated successfully, but these errors were encountered: