Last active
June 16, 2021 11:47
-
-
Save xryuseix/6a4e65cb20a92b9f3e5eafec1710a0ca to your computer and use it in GitHub Desktop.
VSCode の LaTeX スニペット
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "sample": { | |
| "prefix": "sample", | |
| "body": [ | |
| "\\documentclass{jsarticle}", | |
| "\\usepackage{url} % URL", | |
| "\\usepackage{color} % 色付け", | |
| "\\usepackage{amsmath} % align環境", | |
| "\\usepackage{ascmac} % 枠付き文章", | |
| "\\usepackage{listings,jlisting} % ソースコード", | |
| "\\usepackage[dvipdfmx]{graphicx} % 画像", | |
| "\\usepackage[hang,small,bf]{caption} % 画像", | |
| "\\usepackage[subrefformat=parens]{subcaption} % 画像", | |
| "\\newcommand{\\code}[1]{ \\texttt{\\detokenize{#1}} } % インラインプログラム", | |
| "%ここからソースコードの表示に関する設定", | |
| "\\lstset{", | |
| " language=C++,", | |
| " basicstyle={\\ttfamily},", | |
| " identifierstyle={\\small},", | |
| " commentstyle={\\textit},", | |
| " keywordstyle={\\small\\bfseries},", | |
| " ndkeywordstyle={\\small},", | |
| " stringstyle={\\small\\ttfamily},", | |
| " frame={tb},", | |
| " breaklines=true,", | |
| " columns=[l]{fullflexible},", | |
| " numbers=left,", | |
| " xrightmargin=0zw,", | |
| " xleftmargin=3zw,", | |
| " numberstyle={\\scriptsize},", | |
| " stepnumber=1,", | |
| " numbersep=1zw,", | |
| " lineskip=-0.5ex", | |
| "}", | |
| "%ここまでソースコードの表示に関する設定", | |
| "", | |
| "\\title{レポートタイトル}", | |
| "", | |
| "\\author{学籍番号2600290027 石川琉聖}", | |
| "\\date{\\today}", | |
| "\\begin{document}", | |
| "\\maketitle", | |
| "\\section{セクション1}", | |
| "", | |
| "% 図\\ref{sample_image}はこのように挿入します.", | |
| "", | |
| "% \\begin{figure}[tb]", | |
| "% \\centering", | |
| "% \\includegraphics[width=15cm]{./sample_image.png}\\\\\\", | |
| "% \\caption{サンプルの図}", | |
| "% \\label{sample_image}", | |
| "% \\end{figure}", | |
| "", | |
| "プログラムは以下のように記します.短いコードは\\code{cout << \"Hello world!\" << endl;}のようにします\\footnote{これは脚注です}.", | |
| "", | |
| "\\begin{lstlisting}[caption=プログラムファイル名.cpp]", | |
| " #include <iostream>", | |
| " int main() {", | |
| " printf(\"hello world!\\n\");", | |
| " }", | |
| "\\end{lstlisting}", | |
| "", | |
| "数式は以下のように記します.", | |
| "", | |
| "\\begin{align}", | |
| " \\int^{b}_{a} f(x) dx &= \\lim_{n \\to \\infty} \\sum^{n-1}_{i=0} f(x_{i}) \\Delta x \\\\\\", | |
| " y &= \\frac{1}{x+1}", | |
| "\\end{align}", | |
| "", | |
| "枠付き文章と箇条書きはこのように.", | |
| "", | |
| "\\begin{screen}", | |
| " \\begin{enumerate}", | |
| " \\item 数字の箇条書き 1", | |
| " \\item 数字の箇条書き 2", | |
| " \\item 数字の箇条書き 3", | |
| " \\end{enumerate}", | |
| "\\end{screen}", | |
| "", | |
| "枠付き文章にタイトルをつけるならこのように.", | |
| "", | |
| "\\begin{itembox}[l]{枠付き文章のタイトル}", | |
| " \\begin{itemize}", | |
| " \\item 点の箇条書き 1", | |
| " \\item 点の箇条書き 2", | |
| " \\item 点の箇条書き 3", | |
| " \\end{itemize}", | |
| "\\end{itembox}", | |
| "", | |
| "引用\\cite{inyou}はこのようにします.URLは\\url{google.com}です.", | |
| "", | |
| "", | |
| "\\begin{thebibliography}{9}", | |
| " \\bibitem{inyou} これが引用サンプル", | |
| "\\end{thebibliography}", | |
| "", | |
| "\\end{document}" | |
| ], | |
| "description": "レポートサンプル" | |
| }, | |
| "template": { | |
| "prefix": "template", | |
| "body": [ | |
| "\\documentclass{jsarticle}", | |
| "\\usepackage{url} % URL", | |
| "\\usepackage{color} % 色付け", | |
| "\\usepackage{amsmath} % align環境", | |
| "\\usepackage{ascmac} % 枠付き文章", | |
| "\\usepackage{listings,jlisting} % ソースコード", | |
| "\\usepackage[dvipdfmx]{graphicx} % 画像", | |
| "\\usepackage[hang,small,bf]{caption} % 画像", | |
| "\\usepackage[subrefformat=parens]{subcaption} % 画像", | |
| "\\newcommand{\\code}[1]{ \\texttt{\\detokenize{#1}} } % インラインプログラム", | |
| "%ここからソースコードの表示に関する設定", | |
| "\\lstset{", | |
| " language=C++,", | |
| " basicstyle={\\ttfamily},", | |
| " identifierstyle={\\small},", | |
| " commentstyle={\\textit},", | |
| " keywordstyle={\\small\\bfseries},", | |
| " ndkeywordstyle={\\small},", | |
| " stringstyle={\\small\\ttfamily},", | |
| " frame={tb},", | |
| " breaklines=true,", | |
| " columns=[l]{fullflexible},", | |
| " numbers=left,", | |
| " xrightmargin=0zw,", | |
| " xleftmargin=3zw,", | |
| " numberstyle={\\scriptsize},", | |
| " stepnumber=1,", | |
| " numbersep=1zw,", | |
| " lineskip=-0.5ex", | |
| "}", | |
| "%ここまでソースコードの表示に関する設定", | |
| "", | |
| "\\title{レポートタイトル}", | |
| "", | |
| "\\author{学籍番号 氏名}", | |
| "\\date{\\today}", | |
| "\\begin{document}", | |
| "\\maketitle", | |
| "\\section{セクション1}", | |
| "サンプル文字", | |
| "\\end{document}", | |
| ], | |
| "description": "テンプレート" | |
| }, | |
| "image": { | |
| "prefix": "image", | |
| "body": [ | |
| "\\begin{figure}[tb]", | |
| " \\centering", | |
| " \\includegraphics[width=15cm]{./sample_image.png}\\\\\\", | |
| " \\caption{サンプルの図}", | |
| " \\label{sample_image}", | |
| "\\end{figure}", | |
| ], | |
| "description": "画像を表示" | |
| }, | |
| "source code": { | |
| "prefix": "code", | |
| "body": [ | |
| "\\begin{lstlisting}[caption=プログラムファイル名.cpp]", | |
| "\\end{lstlisting}", | |
| ], | |
| "description": "ソースコードを表示" | |
| }, | |
| "math": { | |
| "prefix": "math", | |
| "body": [ | |
| "\\begin{align}", | |
| "\\end{align}", | |
| ], | |
| "description": "数式を表示" | |
| }, | |
| "screen": { | |
| "prefix": "screen", | |
| "body": [ | |
| "\\begin{screen}", | |
| "\\end{screen}", | |
| ], | |
| "description": "角丸枠付き文章" | |
| }, | |
| "itembox": { | |
| "prefix": "itembox", | |
| "body": [ | |
| "\\begin{itembox}[l]{枠付き文章のタイトル}", | |
| "\\end{itembox}", | |
| ], | |
| "description": "タイトル有り枠付き文章" | |
| }, | |
| "enumerate": { | |
| "prefix": "enumerate", | |
| "body": [ | |
| "\\begin{enumerate}", | |
| " \\item 数字の箇条書き", | |
| "\\end{enumerate}", | |
| ], | |
| "description": "数字の箇条書き" | |
| }, | |
| "itemize": { | |
| "prefix": "itemize", | |
| "body": [ | |
| "\\begin{itemize}", | |
| " \\item 点の箇条書き", | |
| "\\end{itemize}", | |
| ], | |
| "description": "点の箇条書き" | |
| }, | |
| "bibtex": { | |
| "prefix": "bibtex", | |
| "body": [ | |
| "引用\\cite{inyou}はこのようにします.", | |
| "", | |
| "\\begin{thebibliography}{9}", | |
| " \\bibitem{inyou} これが引用サンプル", | |
| "\\end{thebibliography}", | |
| ], | |
| "description": "参考文献/引用" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment