jrblevin / markdown-mode

Emacs Markdown Mode
http://jblevins.org/projects/markdown-mode/
GNU General Public License v3.0
877 stars 160 forks source link

Hide markup even if markdown-fontify-whole-heading-line is enabled #781

Closed kuranari closed 11 months ago

kuranari commented 11 months ago

Description

Hide markup even if markdown-fontify-whole-heading-line is enabled.

(set-face-attribute 'markdown-header-face-1 nil :height 1.5 :background "pink" :extend t)
(set-face-attribute 'markdown-header-delimiter-face nil :background "green" :extend t)

Closing tag is present

# Headline #
markdown-fontify-whole-heading-line: t markdown-fontify-whole-heading-line: nil
Markdown-hide-markup: t image image
Markdown-hide-markup: nil image image

Closing tag is not present

# Headline
markdown-fontify-whole-heading-line: t markdown-fontify-whole-heading-line: nil
Markdown-hide-markup: t screencapture-markdown-fontify-whole-heading-line-t-markdown-hide-markup-1 screencapture-markdown-fontify-whole-heading-line-nil-markdown-hide-markup-1
Markdown-hide-markup: nil screencapture-markdown-fontify-whole-heading-line-t-markdown-hide-markup--1 screencapture-markdown-fontify-whole-heading-line-nil-markdown-hide-markup--1
Screenshot script ```elisp ;; This code depends on the 'screencapture' utility of macOS. (dolist (fontify-whole-line '(nil t)) (dolist (markup-hiding '(-1 +1)) (setq markdown-fontify-whole-heading-line fontify-whole-line) (markdown-toggle-markup-hiding markup-hiding) (sit-for 0.1) (let ((filename (format "~/screencapture-markdown-fontify-whole-heading-line-%s-markdown-hide-markup-%s.png" fontify-whole-line markup-hiding))) (shell-command (concat "screencapture " filename))))) ```

Related Issue

https://github.com/jrblevin/markdown-mode/issues/773

Type of Change

Checklist

kuranari commented 11 months ago

I'm not certain about the behavior(especially when the closing tag is present). Please feel free to comment :)

syohex commented 11 months ago

I think it looks good thanks