Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tessi/8952935 to your computer and use it in GitHub Desktop.
Save tessi/8952935 to your computer and use it in GitHub Desktop.

Jumping, Finding, ...

Keybinding - Description
Ctrl-1 - Move to 1st tab (work every number)
Ctrl-p - Go to anything
Ctrl-g - Go to line
Ctrl-r - Go to symbol (e.g. section and labels)
Ctrl-m - Move to bracket
Ctrl-Shift-m - Select whole bracket
Ctrl-Shift-[\] - Fold and unfold code
Ctrl-l - Select line
Ctrl-Shift-d - Duplicate line
Ctrl-j - Join with next line
Alt-q - Wrap selection (removes all new lines in selection)
Ctrl-/ - Comment/ Uncomment
Ctrl-k, Ctrl-u - Upper case
Ctrl-k, Ctrl-l - Lower case

Compiling LaTeX files

Keybinding - Description
Ctrl-b - Save, build and open the tex files (if multi-file put %!TEX root = <master file path.tex> at the first line in the tex files)
Ctrl-l,backspace - Removing temporary files from build
Ctrl-l,t,f - Toggling window focus following a build
Ctrl-l,t,s - Toggling PDF syncing (forward search) following a build
Ctrl-l,t,? - Checking the status of toggles and defaults

Forward / Inverse Search

Keybinding - Description
Ctrl-l,j - Jump to the currently edited line in your pdf viewer
double-click - Text in Sumatra for inverse search
ctrl+click - text in evince pdf viewer for inverse search

References and Citations

Keybinding - Description
\ref{ or \cite or \citet or \citeyaer - Autotrigger a quick panel for refs or cites in .bib-file
Ctrl-l,t,a,r for refs;
Ctrl-l,t,a,c for cites
- Toggle auto trigger mode on/off

LaTeX Commands and Environments

Keybinding - Description
Ctrl-l,e - Inserts environment (hit tab to exit brackets)
Ctrl-l,Ctrl-n - Wraps selection in environment (change environment name, hit tab to exit)
Ctrl-l,c - Inserts command (then type command name or select before executing keybinding, hit tab to enter bracket text, hit tab to exit brackets)
Ctrl-l,C-c - Inserts command around selected text, enter command name and hit tab to exit
Ctrl-l,Ctrl-e - Gives you \emph{selection}, and the cursor moves to the end of the command.
Ctrl-l,Ctrl-b - Gives you \textbf{selection}
Ctrl-l,Ctrl-u - Gives you \underline{selection}
Ctrl-l,Ctrl-t - Gives you \texttt{selection}
shift-<enter> - inserts a new \item in list environment
shift+super+{up,down} - super/subscripts with braces
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment