Skip to content
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

Hide wiki markup as part of markdown-toggle-markup-hiding #861

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 27 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ using `package.el`. First, configure `package.el` and the MELPA Stable
repository by adding the following to your `.emacs`, `init.el`,
or equivalent startup file:

```lisp
```emacs-lisp
(require 'package)
(add-to-list 'package-archives
'("melpa-stable" . "https://stable.melpa.org/packages/"))
Expand All @@ -79,7 +79,7 @@ then you can automatically install and configure `markdown-mode` by
adding a declaration such as this one to your init file (as an
example; adjust settings as desired):

```lisp
```emacs-lisp
(use-package markdown-mode
:ensure t
:mode ("README\\.md\\'" . gfm-mode)
Expand All @@ -99,7 +99,7 @@ save the file where Emacs can find it (i.e., a directory in your
`load-path`). You can then configure `markdown-mode` and `gfm-mode`
to load automatically by adding the following to your init file:

```lisp
```emacs-lisp
(autoload 'markdown-mode "markdown-mode"
"Major mode for editing Markdown files" t)
(add-to-list 'auto-mode-alist
Expand Down Expand Up @@ -133,7 +133,7 @@ repository as above or install markdown-mode from
If you clone the repository directly, then make sure that Emacs can
find it by adding the following line to your startup file:

```lisp
```emacs-lisp
(add-to-list 'load-path "/path/to/markdown-mode/repository")
```

Expand Down Expand Up @@ -350,7 +350,7 @@ prefix. The most commonly used commands are described below.
preview window to appear at the bottom or right, you can
customize `markdown-split-window-direction`.

```lisp
```emacs-lisp
;; Set custom markdown preview function
(setq markdown-live-preview-window-function #'my-markdown-preview-function)

Expand Down Expand Up @@ -952,18 +952,17 @@ customization screen.

[Marked 2]: https://itunes.apple.com/us/app/marked-2/id890031187?mt=12&uo=4&at=11l5Vs&ct=mm

## Extensions

## Wiki Links Customization
Besides supporting the basic Markdown syntax, Markdown Mode also
includes syntax highlighting for `[[Wiki Links]]`. This can be
enabled by setting `markdown-enable-wiki-links` to a non-nil value.
Wiki links may be followed by pressing <kbd>C-c C-o</kbd> when the point
is at a wiki link. Use <kbd>M-p</kbd> and <kbd>M-n</kbd> to quickly jump to the
previous and next links (including links of other types).

Aliased or piped wiki links of the form `[[link text|PageName]]`
are also supported. Since some wikis reverse these components, set
are supported. Since some wikis reverse these components, set
`markdown-wiki-link-alias-first` to nil to treat them as
`[[PageName|link text]]`. If `markdown-wiki-link-fontify-missing`
`[[PageName|link text]]`.

If `markdown-wiki-link-fontify-missing`
is also non-nil, Markdown Mode will highlight wiki links with
missing target file in a different color. By default, Markdown
Mode only searches for target files in the current directory.
Expand All @@ -974,18 +973,31 @@ This value type is a symbol list. Possible values are
- `parent-directories` : search in parent directories
- `project` : search under project root

[SmartyPants][] support is possible by customizing `markdown-command`.
## Extensions
### SmartyPants

[SmartyPants][] is a free tool for easily translating plain ASCII punctuation
characters into "smart" typographic punctuation HTML entities. It can perform
the following transformations:
- straight quotes ( " and ' ) into “curly” quote HTML entities
- backticks-style quotes (``like this'') into “curly” quote HTML entities
- dashes (“--” and “---”) into en- and em-dash entities
- three consecutive dots (“...”) into an ellipsis entity

SmartyPants support is possible by customizing `markdown-command`.
If you install `SmartyPants.pl` at, say, `/usr/local/bin/smartypants`,
then you can set `markdown-command` to `"markdown | smartypants"`.
You can do this either by using <kbd>M-x customize-group markdown</kbd>
or by placing the following in your `.emacs` file:

```lisp
```emacs-lisp
(setq markdown-command "markdown | smartypants")
```

[SmartyPants]: http://daringfireball.net/projects/smartypants/

### LaTeX Mathematical Expressions

Syntax highlighting for mathematical expressions written
in LaTeX (only expressions denoted by `$..$`, `$$..$$`, or `\[..\]`)
can be enabled by setting `markdown-enable-math` to a non-nil value,
Expand Down Expand Up @@ -1068,7 +1080,7 @@ by `markdown-mode` and `gfm-mode` as described below.
for line wrapping in buffers. You can do this with a
`gfm-mode-hook` as follows:

```lisp
```emacs-lisp
;; Use visual-line-mode in gfm-mode
(defun my-gfm-mode-hook ()
(visual-line-mode 1))
Expand Down
Loading