VSCode_LaTeX/dictionary/text_symbols.ts

107 lines
8.4 KiB
TypeScript

import { latex_types } from "./symbol_types";
export default {
begin: {
detail: "\\begin{<environment>} ... \\end{<environment>}",
insertText: "begin{$1}\n\t$0\n\\end{$1}",
documentation: "Environment Snippet",
kind: latex_types.snippet
},
input: {
detail: "\\input{<filename>}",
insertText: "input{${0:<filename>}}",
documentation: "Includes the sourcecode from the target .tex file.",
kind: latex_types.keyword
},
include: {
detail: "\\include{<filename>}",
insertText: "include{${0:<filename>}}",
documentation: "Includes the rendered content from the target .tex file on a new page. Note: If \\includeonly is specified in the preamble, all NOT specified files are ignored.",
kind: latex_types.keyword
},
includegraphics: {
detail: "\\includegraphics[<key>=<value>,...]{<filename>}\nRequired package \"graphicx\"",
insertText: "includegraphics[$1]{${0:<filename>}}",
documentation: "Use the command \\includegraphics[<key>=<value>,...]{<file>} to include <file> into your document. The optional parameter accepts a comma separated list of <key>'s and associated <value>'s. The <key>'s can be used to alter the width, height and rotation of the included graphic.",
kind: latex_types.keyword
},
verbatiminput: {
detail: "\\verbatiminput{<filename>}\nRequired package \"verbatim\"",
insertText: "verbatiminput{${0:<filename>}}",
documentation: "Allows to include raw ASCII text into your document as if it was inside a verbatim environment.",
kind: latex_types.keyword
},
lstinputlisting: {
detail: "\\lstinputlisting{<filename>}\nRequired package \"lstlisting\"",
insertText: "lstinputlisting{${0:<filename>}}",
documentation: "Allows to include Source Code.",
kind: latex_types.keyword
},
"usepackage": { insertText: "usepackage{$1}", documentation: "usepackage", kind: latex_types.keyword },
"newenvironment": { insertText: "newenvironment{${1:name}}[$2]{$3}{$0}", documentation: "newenvironment", kind: latex_types.keyword },
"newcommand": { insertText: "newcommand{${1:name}}[$2]{$3}", documentation: "newcommand", kind: latex_types.keyword },
"renewcommand": { insertText: "renewcommand{${1:name}}[$2]{$3}", documentation: "renewcommand", kind: latex_types.keyword },
"today": { insertText: "today", documentation: "The current Date", kind: latex_types.symbol },
"TeX": { insertText: "TeX", documentation: "The TeX symbol", kind: latex_types.symbol },
"LaTeX": { insertText: "LaTeX", documentation: "The LaTeX symbol", kind: latex_types.symbol },
"LaTeXe": { insertText: "LaTeXe", documentation: "The current LaTeX symbol", kind: latex_types.symbol },
"newline": { insertText: "newline", documentation: "Starts a new line", kind: latex_types.keyword },
"newpage": { insertText: "newpage", documentation: "Starts a new page", kind: latex_types.keyword },
"linebreak": { insertText: "newpage[]", detail: "Optional Param: int 0-4.", documentation: "Suggests a line break to the LaTeX compiler. Optional parameter: int from 0 to 4, a value lower 4 may be ignored if it would look bad.", kind: latex_types.keyword },
"nolinebreak": { insertText: "nolinebreak[]", detail: "Optional Param: int 0-4.", documentation: "Suggests no line break to the LaTeX compiler. Optional parameter: int from 0 to 4, a value lower 4 may be ignored if it would look bad.", kind: latex_types.keyword },
"pagebreak": { insertText: "nolinebreak[]", detail: "Optional Param: int 0-4.", documentation: "Suggests a page break to the LaTeX compiler. Optional parameter: int from 0 to 4, a value lower 4 may be ignored if it would look bad.", kind: latex_types.keyword },
"nopagebreak": { insertText: "nolinebreak[]", detail: "Optional Param: int 0-4.", documentation: "Suggests no page break to the LaTeX compiler. Optional parameter: int from 0 to 4, a value lower 4 may be ignored if it would look bad.", kind: latex_types.keyword },
"section": { insertText: "section{$1}", documentation: "Section", kind: latex_types.keyword },
"section*": { insertText: "section*{$1}", documentation: "Section", kind: latex_types.keyword },
"subsection": { insertText: "subsection{$1}", documentation: "Sub Section", kind: latex_types.keyword },
"subsection*": { insertText: "subsection*{$1}", documentation: "Sub Section", kind: latex_types.keyword },
"subsubsection": { insertText: "subsubsection{$1}", documentation: "Sub Sub Section", kind: latex_types.keyword },
"subsubsection*": { insertText: "subsubsection*{$1}", documentation: "Sub Sub Section", kind: latex_types.keyword },
"paragraph": { insertText: "paragraph{$1}", documentation: "paragraph", kind: latex_types.keyword },
"paragraph*": { insertText: "paragraph*{$1}", documentation: "paragraph", kind: latex_types.keyword },
"label": { insertText: "label{$1}$0", documentation: "Label", kind: latex_types.keyword },
"ref": { insertText: "ref{$1}$0", documentation: "Reference", kind: latex_types.keyword },
"eqref": { insertText: "eqref{$1}$0", documentation: "Equation reference", kind: latex_types.keyword },
"pageref": { insertText: "pageref{$1}$0", documentation: "Page reference", kind: latex_types.keyword },
"index": { insertText: "index{$1}$0", documentation: "Creates a index Entrie", kind: latex_types.keyword },
emph: { insertText: "emph{$1}$0", documentation: "Emphasize Text", kind: latex_types.function },
underline: { insertText: "underline{$1}$0", documentation: "Bold Text", kind: latex_types.function },
textrm: { insertText: "textrm{$1}$0", documentation: "Font: Roman", kind: latex_types.function },
rmfamily: { detail: "{\\rmfamily ... }", documentation: "Font: Roman", kind: latex_types.keyword },
textit: { insertText: "textit{$1}$0", documentation: "Font: Italic", kind: latex_types.function },
itshape: { detail: "{\\itshape ... }", documentation: "Font: Italic", kind: latex_types.keyword },
textmd: { insertText: "textmd{$1}$0", documentation: "Font: Medium weight", kind: latex_types.function },
mdseries: { detail: "{\\mdseries ... }", documentation: "Font: Medium weight", kind: latex_types.keyword },
textbf: { insertText: "textbf{$1}$0", documentation: "Font: Boldface", kind: latex_types.function },
bfseries: { detail: "{\\bfseries ... }", documentation: "Font: Boldface", kind: latex_types.keyword },
textup: { insertText: "textup{$1}$0", documentation: "Font: Upright", kind: latex_types.function },
upshape: { detail: "{\\upshape ... }", documentation: "Font: Upright", kind: latex_types.keyword },
textsl: { insertText: "textsl{$1}$0", documentation: "Font: Slanted", kind: latex_types.function },
slshape: { detail: "{\\slshape ... }", documentation: "Font: Slanted", kind: latex_types.keyword },
textsf: { insertText: "textsf{$1}$0", documentation: "Font: Sans serif", kind: latex_types.function },
sffamily: { detail: "{\\sffamily ... }", documentation: "Font: Sans serif", kind: latex_types.keyword },
textsc: { insertText: "textsc{$1}$0", documentation: "Font: Small caps", kind: latex_types.function },
scshape: { detail: "{\\scshape ... }", documentation: "Font: Small caps", kind: latex_types.keyword },
texttt: { insertText: "texttt{$1}$0", documentation: "Font: Typewriter", kind: latex_types.function },
ttfamily: { detail: "{\\ttfamily ... }", documentation: "Font: Typewriter", kind: latex_types.keyword },
textnormal: { insertText: "textnormal{$1}$0", documentation: "Font: Normal", kind: latex_types.function },
normalfont: { detail: "{\\normalfont ... }", documentation: "Font: Normal", kind: latex_types.keyword },
// TODO: need a specific type in different environments!!!
"centering": { insertText: "centering", documentation: "Centers the content of figure or minipage content", kind: latex_types.keyword },
"caption": { insertText: "caption{$1}$0", documentation: "Figure description", kind: latex_types.function },
"verb": { insertText: "verb|$1|$0", detail: "Do not use verbatim environment and the \\verb command within parameters of other commands.", documentation: "Environment content will be directly printed, as if typed on a typewriter, with all line breaks and spaces, without any LaTeX command being executed.", kind: latex_types.environment },
"verb*": { insertText: "verb*|$1|$0", detail: "Do not use verbatim environment and the \\verb command within parameters of other commands.", documentation: "Environment content will be directly printed, as if typed on a typewriter, with all line breaks and spaces, without any LaTeX command being executed. The additional * lets spaces be printed visible.", kind: latex_types.environment },
"ldots": { insertText: "ldots", documentation: "3 lower dots", kind: latex_types.symbol },
};