dotfiles/vim/.vim/own-snippets/nroff.snippets

75 lines
874 B
Plaintext

# Text formatting
snippet p "Paragraph" bi
.PP
$0
endsnippet
snippet bf "Boldface" iw
.ft B
$1
.ft
$0
endsnippet
snippet it "Italic" iw
.ft I
$1
.ft
$0
endsnippet
snippet bfit "Boldface italic" iw
.ft BI
$1
.ft
$0
endsnippet
# Document structures
snippet title "Title header" bi
.TH ${1:TITLE} ${2:SECTION} ${3:EXTRA}
$0
endsnippet
snippet sect "Sectioned (unnumbered) headers" bi
.SH ${1:SECTION NAME}
$0
endsnippet
snippet ss "Subsectioned (unnumbered) headers" bi
.SS ${1:SUBSECTION NAME}
$0
endsnippet
snippet ol "Ordered list setup" bi
.nr step 1 1
.IP \n+[step]
$1
$0
endsnippet
snippet oli "Ordered list item" bi
.IP \n+[step]
$1
$0
endsnippet
snippet uli "Unordered list item" bi
.IP \[bu]
$1
$0
endsnippet
snippet dl "Definition-style list item" bi
.IP ${1:WORD}
${2:DESCRIPTION}
$0
endsnippet
snippet eq "Equation" bi
.EQ
${1:EQUATION}
.EN
endsnippet