markdown(9)
[Home]
[Commands]
[Variables]
[Macro-Dev]
[Glossary]
SYNOPSIS
FILES
hkmd.emf - Markdown file hook definition
md.eaf - Markdown abbreviation file
md.etf - Markdown template file
EXTENSIONS
.md, .rmd, .tmd - Markdown files
DESCRIPTION
The Markdown file hook provides a editing environment for Markdown files. The file hook provides highlighting, folding of section, document outline using item-list and abbreviations. Fenced code blocks within triple backticks can be highlighted using the declared code block language.
File recognition is performed using the standard file extension .md, .tmd or .rmd.
Abbreviations
The installation comes with a default abbreviation file for Markdown code editing which can be used by writing short abbreviations like "h1" for a default level 1 header, "bo" for bold text, "url" for an URL, or "cc" for a code chunk - and then pressing the key-binding for the
expand-abbrev-handle(3) command. The list of abbreviations can be used interactively in the GUI version of MicroEmacs using the
abbrev-list(3) command.
Folding and Information Hiding
Generic folding is enabled within the Markdown files. The folds occur about the level 2 headers, so headers with two hash symbols at the beginning of a line. The following commands are supported to show and hide the function bodies.
collapse-all(3) (un)folds all regions in the file,
collapse-current(3) (un)folds the current region.
List Items
Item listing is available and the level 1 and 2 headers of the file are displayed in the item-list.
Short Cuts
The short cut keys used within the buffer are:-
C-c C-c - Comment out the current line.
C-c C-d - Uncomment the current line.
f2 - (un)fold the current region
f3 - (un)fold all regions
f6 - list items
esc f6 - close list items
Code Chunk Highlighting
Inside code chunks as well syntax hilghlighting for a few programming languages like Tcl (tcl), R (r), GraphViz Dot (dot), Python (py), SQL (sql), MicroEmacs macro code (emf)or Javascript (js) is available. Here an example which should be highlighted within a Markdown file using the R file hook:
```{r}
x = 1
test = function () {
print("Test")
}
```
SEE ALSO
(c) Copyright JASSPA 2025
Last Modified: 2025/09/19
Generated On: 2025/09/29