-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 229a459
Showing
23 changed files
with
246 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# Ignore macOS specific files | ||
.DS_Store | ||
.AppleDouble | ||
.LSOverride | ||
._* | ||
.fseventsd | ||
.Spotlight-V100 | ||
|
||
# Ignore all existing snippets of the Texpad creators | ||
Bold.snippet | ||
Description.snippet | ||
Displaymath.snippet | ||
Enumerate.snippet | ||
Equation.snippet | ||
Verbatim.snippet | ||
Typewriter.snippet | ||
Tabular.snippet | ||
Quotation.snippet | ||
Itemize.snippet | ||
Italic.snippet | ||
Floating Table.snippet | ||
Preamble.snippet | ||
Matrix.snippet | ||
Figure.snippet |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
% A snippet to insert a floating figure that consists of more than one figure | ||
% Needs \usepackage{graphicx} | ||
% and \usepackage{subcaption} | ||
group = Floating | ||
insert at cursor = | ||
\begin{figure}[hbt] | ||
\centering | ||
\begin{subfigure}[b]{0.49\textwidth} | ||
\includegraphics[width=\textwidth]{} | ||
\caption{} | ||
\label{subfigure:} | ||
\end{subfigure} | ||
~ % add some space between the images: ~, \hfill, \quad, \qquad, <blank line>, ... | ||
\begin{subfigure}[b]{0.49\textwidth} | ||
\includegraphics[width=\textwidth]{} | ||
\caption{} | ||
\label{subfigure:} | ||
\end{subfigure} | ||
\caption{<SELECTION>} | ||
\label{figure:} | ||
\end{figure} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
% Displays 2 figures side by side with separate labels and captions | ||
% Needs \usepackage{graphicx} | ||
ctrl key = w | ||
group = Floating | ||
insert at cursor = | ||
\begin{figure}[hbt] | ||
\centering | ||
\begin{minipage}{0.49\textwidth} | ||
\centering | ||
\includegraphics[scale=0.2]{images/} | ||
\caption{} | ||
\label{figure:} | ||
\end{minipage} | ||
\begin{minipage}{0.49\textwidth} | ||
\centering | ||
\includegraphics[scale=0.2]{images/} | ||
\caption{} | ||
\label{figure:} | ||
\end{minipage} | ||
\end{figure} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
% BibLaTeX - Article in a journal | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@article{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
journaltitle = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
% BibLaTeX - Article in a conference proceeding | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@InProceedings{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
booktitle = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
% BibLaTeX - Book | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@book{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
% BibLaTeX - Misc | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@misc{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
% BibLaTeX - MV book | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@mvbook{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
% BibLaTeX - Online resource | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@online{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
year = {}, | ||
url = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
% BibLaTeX - Part of a book | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@inbook{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
booktitle = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
% BibLaTeX - Report | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@report{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
type = {}, | ||
institution = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
% BibLaTeX - Technical manual | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@manual{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
% BibLaTeX - Thesis | ||
ctrl key = | ||
group = BibLaTeX | ||
insert at cursor = | ||
@thesis{<SELECTION>, | ||
author = {}, | ||
title = {}, | ||
type = {}, | ||
institution = {}, | ||
year = {} | ||
% more options available | ||
} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
% Quotes a text | ||
% Needs \usepackage[autostyle=true,german=quotes]{csquotes} | ||
ctrl key = n | ||
group = Inline | ||
insert at cursor = \enquote{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
% Include is basically like \input{} with \clearpage before and after \input{}. It's faster than \input{}, but can't be nested, can't appear in preamble and forces page breaks around the included text. | ||
ctrl key = j | ||
group = Other | ||
insert at cursor = | ||
\include{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
% Include a PDF file | ||
% Needs \usepackage{pdfpages} | ||
ctrl key = s | ||
group = Other | ||
insert at cursor = | ||
\includepdf[pages=-]{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
% Imports commands from another TeX file into the target file. It's equivalent to typing all commands from the other TeX file right into the target file. | ||
ctrl key = k | ||
group = Other | ||
insert at cursor = | ||
\input{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
% Include source code in a block environment within latex | ||
% Needs \usepackage{listings} | ||
% See also \lstloadlanguages and \lstset | ||
ctrl key = c | ||
group = Environment | ||
insert at cursor = | ||
\begin{lstlisting} | ||
<SELECTION> | ||
\end{lstlisting} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
% Include source code inline | ||
% Needs \usepackage{listings} | ||
% See also \lstloadlanguages and \lstset | ||
ctrl key = o | ||
group = Inline | ||
insert at cursor = | ||
\lstinline[columns=fixed]{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
% Include source code from a file | ||
% Needs \usepackage{listings} | ||
% See also \lstloadlanguages and \lstset | ||
ctrl key = h | ||
group = Environment | ||
insert at cursor = \lstinputlisting{<SELECTION>} |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
% Inline math mode | ||
ctrl key = r | ||
group = Inline | ||
insert at cursor = $<SELECTION>$ |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# Texpad snippets | ||
|
||
Starting with version 1.5, Texpad makes it easy to insert regularly used blocks of text into your document. Texpad ships only a small number of helpful snippets and misses some I often use. Feel free to contribute and extend my small collection. | ||
|
||
## Required packages | ||
Some of the snippets require the usage of additonal packages in LaTeX: | ||
| Snippet | Package | | ||
| ------------- |:-------------:| | ||
| 2FiguresSideBySide | \usepackage{graphicx} | | ||
| 2FiguresIn1 | \usepackage{graphicx} and \usepackage{subcaption} | | ||
| IncludePDF | \usepackage{pdfpages} | | ||
| ListingInline | \usepackage{listings} | | ||
| ListingInputFile | \usepackage{listings} | | ||
| ListingBlock | \usepackage{listings} | | ||
| Url | \usepackage{hyperref} | | ||
| Enquote | \usepackage[autostyle=true,german=quotes]{csquotes} | | ||
|
||
# Installation | ||
Copy the snippets to `~/Library/Application Support/Texpad/Snippets`. | ||
|
||
# License ![CC BY-SA 4.0](https://i.creativecommons.org/l/by-sa/4.0/80x15.png) | ||
The snippets are release under the [CC BY-SA 4.0 license](http://creativecommons.org/licenses/by-sa/4.0/). See the [license text](https://creativecommons.org/licenses/by-sa/4.0/legalcode) file for additional details. |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
% Transform a url as text into a clickable text (link) in pdf | ||
% Needs \usepackage{hyperref} | ||
ctrl key = u | ||
group = Inline | ||
insert at cursor = \url{<SELECTION>} |