mirror of
https://github.com/joaotavora/yasnippet.git
synced 2025-10-13 21:13:04 +00:00
1706 lines
53 KiB
HTML
1706 lines
53 KiB
HTML
<?xml version="1.0" encoding="utf-8"?>
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
|
|
<head>
|
|
<title>Yet another snippet extension</title>
|
|
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
|
|
<meta name="title" content="Yet another snippet extension"/>
|
|
<meta name="generator" content="Org-mode"/>
|
|
<meta name="generated" content="2013-11-24T12:11-0500"/>
|
|
<meta name="author" content="Noam Postavsky"/>
|
|
<meta name="description" content=""/>
|
|
<meta name="keywords" content=""/>
|
|
<style type="text/css">
|
|
<!--/*--><![CDATA[/*><!--*/
|
|
html { font-family: Times, serif; font-size: 12pt; }
|
|
.title { text-align: center; }
|
|
.todo { color: red; }
|
|
.done { color: green; }
|
|
.tag { background-color: #add8e6; font-weight:normal }
|
|
.target { }
|
|
.timestamp { color: #bebebe; }
|
|
.timestamp-kwd { color: #5f9ea0; }
|
|
.right {margin-left:auto; margin-right:0px; text-align:right;}
|
|
.left {margin-left:0px; margin-right:auto; text-align:left;}
|
|
.center {margin-left:auto; margin-right:auto; text-align:center;}
|
|
p.verse { margin-left: 3% }
|
|
pre {
|
|
border: 1pt solid #AEBDCC;
|
|
background-color: #F3F5F7;
|
|
padding: 5pt;
|
|
font-family: courier, monospace;
|
|
font-size: 90%;
|
|
overflow:auto;
|
|
}
|
|
table { border-collapse: collapse; }
|
|
td, th { vertical-align: top; }
|
|
th.right { text-align:center; }
|
|
th.left { text-align:center; }
|
|
th.center { text-align:center; }
|
|
td.right { text-align:right; }
|
|
td.left { text-align:left; }
|
|
td.center { text-align:center; }
|
|
dt { font-weight: bold; }
|
|
div.figure { padding: 0.5em; }
|
|
div.figure p { text-align: center; }
|
|
div.inlinetask {
|
|
padding:10px;
|
|
border:2px solid gray;
|
|
margin:10px;
|
|
background: #ffffcc;
|
|
}
|
|
textarea { overflow-x: auto; }
|
|
.linenr { font-size:smaller }
|
|
.code-highlighted {background-color:#ffff00;}
|
|
.org-info-js_info-navigation { border-style:none; }
|
|
#org-info-js_console-label { font-size:10px; font-weight:bold;
|
|
white-space:nowrap; }
|
|
.org-info-js_search-highlight {background-color:#ffff00; color:#000000;
|
|
font-weight:bold; }
|
|
/*]]>*/-->
|
|
</style>
|
|
<link rel="stylesheet" type="text/css" href="stylesheets/styles.css" />
|
|
<script type="text/javascript">
|
|
/*
|
|
@licstart The following is the entire license notice for the
|
|
JavaScript code in this tag.
|
|
|
|
Copyright (C) 2012-2013 Free Software Foundation, Inc.
|
|
|
|
The JavaScript code in this tag is free software: you can
|
|
redistribute it and/or modify it under the terms of the GNU
|
|
General Public License (GNU GPL) as published by the Free Software
|
|
Foundation, either version 3 of the License, or (at your option)
|
|
any later version. The code is distributed WITHOUT ANY WARRANTY;
|
|
without even the implied warranty of MERCHANTABILITY or FITNESS
|
|
FOR A PARTICULAR PURPOSE. See the GNU GPL for more details.
|
|
|
|
As additional permission under GNU GPL version 3 section 7, you
|
|
may distribute non-source (e.g., minimized or compacted) forms of
|
|
that code without the copy of the GNU GPL normally required by
|
|
section 4, provided you include this license notice and a URL
|
|
through which recipients can access the Corresponding Source.
|
|
|
|
|
|
@licend The above is the entire license notice
|
|
for the JavaScript code in this tag.
|
|
*/
|
|
<!--/*--><![CDATA[/*><!--*/
|
|
function CodeHighlightOn(elem, id)
|
|
{
|
|
var target = document.getElementById(id);
|
|
if(null != target) {
|
|
elem.cacheClassElem = elem.className;
|
|
elem.cacheClassTarget = target.className;
|
|
target.className = "code-highlighted";
|
|
elem.className = "code-highlighted";
|
|
}
|
|
}
|
|
function CodeHighlightOff(elem, id)
|
|
{
|
|
var target = document.getElementById(id);
|
|
if(elem.cacheClassElem)
|
|
elem.className = elem.cacheClassElem;
|
|
if(elem.cacheClassTarget)
|
|
target.className = elem.cacheClassTarget;
|
|
}
|
|
/*]]>*///-->
|
|
</script>
|
|
|
|
</head>
|
|
<body>
|
|
|
|
<div id="preamble">
|
|
|
|
</div>
|
|
|
|
<div id="content">
|
|
<h1 class="title">Yet another snippet extension</h1>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div id="table-of-contents">
|
|
<h2>Table of Contents</h2>
|
|
<div id="text-table-of-contents">
|
|
<ul>
|
|
<li><a href="#sec-1">1 Quick start</a></li>
|
|
<li><a href="#sec-2">2 Organizing snippets</a></li>
|
|
<li><a href="#expand-snippets">3 Expanding Snippets</a></li>
|
|
<li><a href="#sec-4">4 Reference</a></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="outline-container-1" class="outline-2">
|
|
<h2 id="sec-1"><span class="section-number-2">1</span> Quick start</h2>
|
|
<div class="outline-text-2" id="text-1">
|
|
|
|
|
|
<p>
|
|
<b>YASnippet</b> is a template system for Emacs. It allows you to type an
|
|
abbreviation and automatically expand it into function templates. Bundled
|
|
language templates includes: C, C++, C#, Perl, Python, Ruby, SQL, LaTeX, HTML,
|
|
CSS and more. The snippet syntax is inspired from TextMate's syntax, you can
|
|
even <a href="#import-textmate">import most TextMate snippets</a>
|
|
</p>
|
|
<p>
|
|
YASnippet is an original creation of <a href="http://pluskid.lifegoo.org">http://pluskid.lifegoo.org</a> who also wrote its predecessor
|
|
<a href="http://code.google.com/p/smart-snippet">http://code.google.com/p/smart-snippet</a>.
|
|
</p>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-1-1" class="outline-3">
|
|
<h3 id="sec-1-1"><span class="section-number-3">1.1</span> Watch a demo</h3>
|
|
<div class="outline-text-3" id="text-1-1">
|
|
|
|
|
|
<p>
|
|
On <a href="http://www.youtube.com/watch?v=ZCGmZK4V7Sg">youtube</a>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-1-2" class="outline-3">
|
|
<h3 id="sec-1-2"><span class="section-number-3">1.2</span> Installation</h3>
|
|
<div class="outline-text-3" id="text-1-2">
|
|
|
|
|
|
<p>
|
|
Clone this repository somewhere
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">$ cd ~/.emacs.d/plugins
|
|
$ git clone https://github.com/capitaomorte/yasnippet
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Add the following in your <code>.emacs</code> file:
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">(add-to-list 'load-path
|
|
"~/.emacs.d/plugins/yasnippet")
|
|
(require 'yasnippet)
|
|
(yas-global-mode 1)
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Add your own snippets to <code>~/.emacs.d/snippets</code> by placing files there or
|
|
invoking <a href="#yas-new-snippet"><code>yas-new-snippet</code></a>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-import-textmate" class="outline-3">
|
|
<h3 id="import-textmate"><a name="sec-1-3" id="sec-1-3"></a><span class="section-number-3">1.3</span> Import textmate snippets (rails example)</h3>
|
|
<div class="outline-text-3" id="text-import-textmate">
|
|
|
|
|
|
<p>
|
|
YASnippet lets you use TextMate bundles directly:
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">$ cd ~/.emacs.d/plugins
|
|
$ git clone https://github.com/capitaomorte/yasnippet
|
|
$ cd yasnippet
|
|
$ git submodule init
|
|
$ git submodule update
|
|
$ gem install plist trollop
|
|
$ rake convert_bundles # will convert ruby, rails and html bundles from drnic
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Then, in your <code>.emacs</code> file
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">(add-to-list 'load-path
|
|
"~/.emacs.d/plugins/yasnippet")
|
|
(require 'yasnippet)
|
|
(setq yas-snippet-dirs '("~/.emacs.d/snippets" "~/.emacs.d/extras/imported"))
|
|
(yas-global-mode 1)
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Open some rails file (model, app, etc) and start using the textmate
|
|
snippets. Consider that this is a work-in-progress and many snippets/commands
|
|
might not work. Patches welcome!
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-1-4" class="outline-3">
|
|
<h3 id="sec-1-4"><span class="section-number-3">1.4</span> Contributing snippets</h3>
|
|
<div class="outline-text-3" id="text-1-4">
|
|
|
|
|
|
<p>
|
|
Please <b>do not ask me</b> to add snippets to the default collection under
|
|
<code>/snippets</code>. This collection is considered frozen. By customizing
|
|
<a href="#yas-snippet-dirs"><code>yas-snippet-dirs</code></a> you can point yasnippet to good
|
|
snippet collections out there.
|
|
</p>
|
|
<p>
|
|
The <code>extras/textmate-import.rb</code> tool can import many actual Textmate
|
|
snippets. I'm focusing on developing it and the accompanying <code>yas-setup.el</code>
|
|
files that guide it with more difficult importations. The idea is to deprecate
|
|
<code>/snippets</code> and replace it with <code>extras/imported</code>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-1-5" class="outline-3">
|
|
<h3 id="sec-1-5"><span class="section-number-3">1.5</span> Documentation, issues, etc</h3>
|
|
<div class="outline-text-3" id="text-1-5">
|
|
|
|
|
|
<p>
|
|
Please refer to the comprehensive <a href="http://capitaomorte.github.com/yasnippet">documentation</a> for full
|
|
customization and support. If you think you've found a bug, please report it
|
|
on <a href="https://github.com/capitaomorte/yasnippet/issues">the GitHub issue tracker</a>. (please **do not** submit new
|
|
issues to the old <a href="http://code.google.com/p/yasnippet/issues/list">googlecode tracker</a>)
|
|
</p>
|
|
<p>
|
|
If you run into problems using YASnippet, or have snippets to contribute,
|
|
post to the <a href="http://groups.google.com/group/smart-snippet">yasnippet forum</a>. Thank you very much for using
|
|
YASnippet!
|
|
</p>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2" class="outline-2">
|
|
<h2 id="sec-2"><span class="section-number-2">2</span> Organizing snippets</h2>
|
|
<div class="outline-text-2" id="text-2">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-1" class="outline-3">
|
|
<h3 id="sec-2-1"><span class="section-number-3">2.1</span> Basic structure</h3>
|
|
<div class="outline-text-3" id="text-2-1">
|
|
|
|
|
|
<p>
|
|
Snippet collections can be stored in plain text files. They are arranged by
|
|
sub-directories naming <b>snippet tables</b>. These mostly name Emacs major names.
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">.
|
|
|-- c-mode
|
|
| `-- printf
|
|
|-- java-mode
|
|
| `-- println
|
|
`-- text-mode
|
|
|-- email
|
|
`-- time
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
The collections are loaded into <b>snippet tables</b> which the triggering
|
|
mechanism (see <a href="#expand-snippets">Expanding snippets</a>) looks up and
|
|
(hopefully) cause the right snippet to be expanded for you.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-2" class="outline-3">
|
|
<h3 id="sec-2-2"><span class="section-number-3">2.2</span> Setting up <code>yas-snippet-dirs</code></h3>
|
|
<div class="outline-text-3" id="text-2-2">
|
|
|
|
|
|
<p>
|
|
The emacs variable <a href="#yas-snippet-dirs"><code>yas-snippet-dirs</code></a> tells YASnippet
|
|
which collections to consider. It's used when you activate
|
|
<a href="#yas-global-mode"><code>yas-global-mode</code></a> or call
|
|
<a href="#yas-reload-all"><code>yas-reload-all</code></a> interactively.
|
|
</p>
|
|
<p>
|
|
The default considers:
|
|
</p>
|
|
<ul>
|
|
<li>a personal collection that lives in <code>~/.emacs.d/snippets</code>
|
|
</li>
|
|
<li>the bundled collection, taken as a relative path to <code>yasnippet.el</code> localtion
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
<p>
|
|
When you come across other snippet collections, do the following to try them
|
|
out:
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">;; Develop in ~/emacs.d/mysnippets, but also
|
|
;; try out snippets in ~/Downloads/interesting-snippets
|
|
(setq yas-snippet-dirs '("~/emacs.d/mysnippets"
|
|
"~/Downloads/interesting-snippets"))
|
|
|
|
;; OR, keeping yasnippet's defaults try out ~/Downloads/interesting-snippets
|
|
(setq yas-snippet-dirs (append yas-snippet-dirs
|
|
'("~/Downloads/interesting-snippets")))
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Collections appearing earlier in the list shadow snippets with same names
|
|
appearing in collections later in the list. <a href="#yas-new-snippet"><code>yas-new-snippet</code></a> always stores
|
|
snippets in the first collection.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-3" class="outline-3">
|
|
<h3 id="sec-2-3"><span class="section-number-3">2.3</span> The <code>.yas-parents</code> file</h3>
|
|
<div class="outline-text-3" id="text-2-3">
|
|
|
|
|
|
<p>
|
|
It's very useful to have certain modes share snippets between themselves. To do
|
|
this, choose a mode subdirectory and place a <code>.yas-parents</code> containing a
|
|
whitespace-separated list of other mode names. When you reload those modes
|
|
become parents of the original mode.
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">.
|
|
|-- c-mode
|
|
| |-- .yas-parents # contains "cc-mode text-mode"
|
|
| `-- printf
|
|
|-- cc-mode
|
|
| |-- for
|
|
| `-- while
|
|
|-- java-mode
|
|
| |-- .yas-parents # contains "cc-mode text-mode"
|
|
| `-- println
|
|
`-- text-mode
|
|
|-- email
|
|
`-- time
|
|
</pre>
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-4" class="outline-3">
|
|
<h3 id="sec-2-4"><span class="section-number-3">2.4</span> <span class="todo TODO">TODO</span> The <code>.yas-make-groups</code> file</h3>
|
|
<div class="outline-text-3" id="text-2-4">
|
|
|
|
|
|
<p>
|
|
If you place an empty plain text file <code>.yas-make-groups</code> inside one of the
|
|
mode directories, the names of these sub-directories are considered groups of
|
|
snippets and <a href="#snippet-menu">the menu</a> is organized much more cleanly:
|
|
</p>
|
|
<p>
|
|
(TODO image)
|
|
</p>
|
|
<p>
|
|
Another alternative way to achieve this is to place a <code># group:</code> directive
|
|
inside the snippet definition. See <a href="#writing-snippets">Writing Snippets</a>
|
|
</p>
|
|
|
|
|
|
|
|
<pre class="example">$ tree ruby-mode/
|
|
ruby-mode/
|
|
|-- .yas-make-groups
|
|
|-- collections
|
|
| |-- each
|
|
| `-- ...
|
|
|-- control structure
|
|
| |-- forin
|
|
| `-- ...
|
|
|-- definitions
|
|
| `-- ...
|
|
`-- general
|
|
`-- ...
|
|
</pre>
|
|
|
|
|
|
<p>
|
|
Yet another way to create a nice snippet menu is to write into
|
|
<code>.yas-make-groups</code> a menu definition. TODO
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-5" class="outline-3">
|
|
<h3 id="sec-2-5"><span class="section-number-3">2.5</span> <span class="todo TODO">TODO</span> The <code>.yas-setup.el</code> file</h3>
|
|
<div class="outline-text-3" id="text-2-5">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-5-1" class="outline-4">
|
|
<h4 id="sec-2-5-1"><span class="section-number-4">2.5.1</span> <span class="todo TODO">TODO</span></h4>
|
|
<div class="outline-text-4" id="text-2-5-1">
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-6" class="outline-3">
|
|
<h3 id="sec-2-6"><span class="section-number-3">2.6</span> <span class="todo TODO">TODO</span> The <code>.yas-compiled-snippet.el</code> file</h3>
|
|
<div class="outline-text-3" id="text-2-6">
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-6-1" class="outline-4">
|
|
<h4 id="sec-2-6-1"><span class="section-number-4">2.6.1</span> <span class="todo TODO">TODO</span></h4>
|
|
<div class="outline-text-4" id="text-2-6-1">
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-2-7" class="outline-3">
|
|
<h3 id="sec-2-7"><span class="section-number-3">2.7</span> The <code>.yas-skip</code> file</h3>
|
|
<div class="outline-text-3" id="text-2-7">
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-expand-snippets" class="outline-2">
|
|
<h2 id="expand-snippets"><a name="sec-3" id="sec-3"></a><span class="section-number-2">3</span> Expanding Snippets</h2>
|
|
<div class="outline-text-2" id="text-expand-snippets">
|
|
|
|
|
|
|
|
<p>
|
|
This section describes how YASnippet chooses snippets for expansion at point.
|
|
</p>
|
|
<p>
|
|
Maybe, you'll want some snippets to be expanded in a particular
|
|
mode, or only under certain conditions, or be prompted using
|
|
</p>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-3-1" class="outline-3">
|
|
<h3 id="sec-3-1"><span class="section-number-3">3.1</span> Triggering expansion</h3>
|
|
<div class="outline-text-3" id="text-3-1">
|
|
|
|
|
|
<p>
|
|
To make a snippet expand after the cursor:
|
|
</p>
|
|
<ul>
|
|
<li>Type the snippet's <b>trigger key</b> then calling <a href="#yas-expand"><code>yas-expand</code></a>. It's bound to
|
|
<code>TAB</code> and <code><tab></code> by default, to change it use
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
|
|
|
|
|
|
<pre class="example">(define-key yas-minor-mode-map (kbd "<tab>") nil)
|
|
(define-key yas-minor-mode-map (kbd "TAB") nil)
|
|
(define-key yas-minor-mode-map (kbd "<the new key>") 'yas-expand)
|
|
</pre>
|
|
|
|
|
|
<ul>
|
|
<li>Use the snippet's <b>keybinding</b>.
|
|
|
|
</li>
|
|
<li>Call <a href="#yas-insert-snippet"><code>yas-insert-snippet</code></a> (use <code>M-x yas-insert-snippet=</code> or its keybinding <code>C-c & C-s</code>).
|
|
|
|
</li>
|
|
<li>By expanding directly from the "YASnippet" menu in the menu-bar
|
|
|
|
</li>
|
|
<li>Using hippie-expand
|
|
|
|
</li>
|
|
<li>Use m2m's excellent auto-complete
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-4" class="outline-2">
|
|
<h2 id="sec-4"><span class="section-number-2">4</span> Reference</h2>
|
|
<div class="outline-text-2" id="text-4">
|
|
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-4-1" class="outline-3">
|
|
<h3 id="sec-4-1"><span class="section-number-3">4.1</span> Interactive functions</h3>
|
|
<div class="outline-text-3" id="text-4-1">
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-skip-and-clear-or-delete-char" class="outline-4">
|
|
<h4 id="yas-skip-and-clear-or-delete-char"><a name="sec-4-1-1" id="sec-4-1-1"></a><span class="section-number-4">4.1.1</span> <code>yas-skip-and-clear-or-delete-char</code> (&optional field)</h4>
|
|
<div class="outline-text-4" id="text-yas-skip-and-clear-or-delete-char">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-skip-and-clear-or-delete-char</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-exit-all-snippets" class="outline-4">
|
|
<h4 id="yas-exit-all-snippets"><a name="sec-4-1-2" id="sec-4-1-2"></a><span class="section-number-4">4.1.2</span> <code>yas-exit-all-snippets</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-exit-all-snippets">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-exit-all-snippets</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-exit-snippet" class="outline-4">
|
|
<h4 id="yas-exit-snippet"><a name="sec-4-1-3" id="sec-4-1-3"></a><span class="section-number-4">4.1.3</span> <code>yas-exit-snippet</code> (snippet)</h4>
|
|
<div class="outline-text-4" id="text-yas-exit-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-exit-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-abort-snippet" class="outline-4">
|
|
<h4 id="yas-abort-snippet"><a name="sec-4-1-4" id="sec-4-1-4"></a><span class="section-number-4">4.1.4</span> <code>yas-abort-snippet</code> (&optional snippet)</h4>
|
|
<div class="outline-text-4" id="text-yas-abort-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-abort-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-prev-field" class="outline-4">
|
|
<h4 id="yas-prev-field"><a name="sec-4-1-5" id="sec-4-1-5"></a><span class="section-number-4">4.1.5</span> <code>yas-prev-field</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-prev-field">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-prev-field</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-next-field" class="outline-4">
|
|
<h4 id="yas-next-field"><a name="sec-4-1-6" id="sec-4-1-6"></a><span class="section-number-4">4.1.6</span> <code>yas-next-field</code> (&optional arg)</h4>
|
|
<div class="outline-text-4" id="text-yas-next-field">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-next-field</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-next-field-or-maybe-expand" class="outline-4">
|
|
<h4 id="yas-next-field-or-maybe-expand"><a name="sec-4-1-7" id="sec-4-1-7"></a><span class="section-number-4">4.1.7</span> <code>yas-next-field-or-maybe-expand</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-next-field-or-maybe-expand">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-next-field-or-maybe-expand</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-describe-tables" class="outline-4">
|
|
<h4 id="yas-describe-tables"><a name="sec-4-1-8" id="sec-4-1-8"></a><span class="section-number-4">4.1.8</span> <code>yas-describe-tables</code> (&optional choose)</h4>
|
|
<div class="outline-text-4" id="text-yas-describe-tables">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-describe-tables</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-tryout-snippet" class="outline-4">
|
|
<h4 id="yas-tryout-snippet"><a name="sec-4-1-9" id="sec-4-1-9"></a><span class="section-number-4">4.1.9</span> <code>yas-tryout-snippet</code> (&optional debug)</h4>
|
|
<div class="outline-text-4" id="text-yas-tryout-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-tryout-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-load-snippet-buffer" class="outline-4">
|
|
<h4 id="yas-load-snippet-buffer"><a name="sec-4-1-10" id="sec-4-1-10"></a><span class="section-number-4">4.1.10</span> <code>yas-load-snippet-buffer</code> (table &optional interactive)</h4>
|
|
<div class="outline-text-4" id="text-yas-load-snippet-buffer">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-load-snippet-buffer</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-new-snippet" class="outline-4">
|
|
<h4 id="yas-new-snippet"><a name="sec-4-1-11" id="sec-4-1-11"></a><span class="section-number-4">4.1.11</span> <code>yas-new-snippet</code> (&optional no-template)</h4>
|
|
<div class="outline-text-4" id="text-yas-new-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-new-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-visit-snippet-file" class="outline-4">
|
|
<h4 id="yas-visit-snippet-file"><a name="sec-4-1-12" id="sec-4-1-12"></a><span class="section-number-4">4.1.12</span> <code>yas-visit-snippet-file</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-visit-snippet-file">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-visit-snippet-file</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-insert-snippet" class="outline-4">
|
|
<h4 id="yas-insert-snippet"><a name="sec-4-1-13" id="sec-4-1-13"></a><span class="section-number-4">4.1.13</span> <code>yas-insert-snippet</code> (&optional no-condition)</h4>
|
|
<div class="outline-text-4" id="text-yas-insert-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-insert-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-expand-from-keymap" class="outline-4">
|
|
<h4 id="yas-expand-from-keymap"><a name="sec-4-1-14" id="sec-4-1-14"></a><span class="section-number-4">4.1.14</span> <code>yas-expand-from-keymap</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-expand-from-keymap">
|
|
|
|
<p>Expand/run snippets from keymaps, possibly falling back to original binding.
|
|
</p>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-expand-from-trigger-key" class="outline-4">
|
|
<h4 id="yas-expand-from-trigger-key"><a name="sec-4-1-15" id="sec-4-1-15"></a><span class="section-number-4">4.1.15</span> <code>yas-expand-from-trigger-key</code> (&optional field)</h4>
|
|
<div class="outline-text-4" id="text-yas-expand-from-trigger-key">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-expand-from-trigger-key</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-about" class="outline-4">
|
|
<h4 id="yas-about"><a name="sec-4-1-16" id="sec-4-1-16"></a><span class="section-number-4">4.1.16</span> <code>yas-about</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-about">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-about</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-recompile-all" class="outline-4">
|
|
<h4 id="yas-recompile-all"><a name="sec-4-1-17" id="sec-4-1-17"></a><span class="section-number-4">4.1.17</span> <code>yas-recompile-all</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-recompile-all">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-recompile-all</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-compile-directory" class="outline-4">
|
|
<h4 id="yas-compile-directory"><a name="sec-4-1-18" id="sec-4-1-18"></a><span class="section-number-4">4.1.18</span> <code>yas-compile-directory</code> (top-level-dir)</h4>
|
|
<div class="outline-text-4" id="text-yas-compile-directory">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-compile-directory</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-reload-all" class="outline-4">
|
|
<h4 id="yas-reload-all"><a name="sec-4-1-19" id="sec-4-1-19"></a><span class="section-number-4">4.1.19</span> <code>yas-reload-all</code> (&optional interactive)</h4>
|
|
<div class="outline-text-4" id="text-yas-reload-all">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-reload-all</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-load-directory" class="outline-4">
|
|
<h4 id="yas-load-directory"><a name="sec-4-1-20" id="sec-4-1-20"></a><span class="section-number-4">4.1.20</span> <code>yas-load-directory</code> (top-level-dir &optional use-jit interactive)</h4>
|
|
<div class="outline-text-4" id="text-yas-load-directory">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-load-directory</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-minor-mode-on" class="outline-4">
|
|
<h4 id="yas-minor-mode-on"><a name="sec-4-1-21" id="sec-4-1-21"></a><span class="section-number-4">4.1.21</span> <code>yas-minor-mode-on</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-minor-mode-on">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-minor-mode-on</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-direct-keymaps-reload" class="outline-4">
|
|
<h4 id="yas-direct-keymaps-reload"><a name="sec-4-1-22" id="sec-4-1-22"></a><span class="section-number-4">4.1.22</span> <code>yas-direct-keymaps-reload</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-direct-keymaps-reload">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-direct-keymaps-reload</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-global-mode" class="outline-4">
|
|
<h4 id="yas-global-mode"><a name="sec-4-1-23" id="sec-4-1-23"></a><span class="section-number-4">4.1.23</span> <code>yas-global-mode</code> (&optional arg)</h4>
|
|
<div class="outline-text-4" id="text-yas-global-mode">
|
|
|
|
<p>Non-nil if Yas-Global mode is enabled.
|
|
See the command <a href="#yas-global-mode"><code>yas-global-mode</code></a> for a description of this minor mode.
|
|
Setting this variable directly does not take effect;
|
|
either customize it (see the info node `Easy Customization')
|
|
or call the function <a href="#yas-global-mode"><code>yas-global-mode</code></a>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-minor-mode" class="outline-4">
|
|
<h4 id="yas-minor-mode"><a name="sec-4-1-24" id="sec-4-1-24"></a><span class="section-number-4">4.1.24</span> <code>yas-minor-mode</code> (&optional arg)</h4>
|
|
<div class="outline-text-4" id="text-yas-minor-mode">
|
|
|
|
<p>Non-nil if yas minor mode is enabled.
|
|
Use the command <a href="#yas-minor-mode"><code>yas-minor-mode</code></a> to change this variable.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-expand" class="outline-4">
|
|
<h4 id="yas-expand"><a name="sec-4-1-25" id="sec-4-1-25"></a><span class="section-number-4">4.1.25</span> <code>yas-expand</code> (&optional field)</h4>
|
|
<div class="outline-text-4" id="text-yas-expand">
|
|
|
|
<p>Expand a snippet before point. If no snippet
|
|
expansion is possible, call command <code>org-self-insert-command</code>.
|
|
</p>
|
|
<p>
|
|
Optional argument <i>FIELD</i> is for non-interactive use and is an
|
|
object satisfying <a href="#yas--field-p"><code>yas–field-p</code></a> to restrict the expansion to.
|
|
</p></div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-4-2" class="outline-3">
|
|
<h3 id="sec-4-2"><span class="section-number-3">4.2</span> Customization variables</h3>
|
|
<div class="outline-text-3" id="text-4-2">
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-expand-only-for-last-commands" class="outline-4">
|
|
<h4 id="yas-expand-only-for-last-commands"><a name="sec-4-2-1" id="sec-4-2-1"></a><span class="section-number-4">4.2.1</span> <code>yas-expand-only-for-last-commands</code></h4>
|
|
<div class="outline-text-4" id="text-yas-expand-only-for-last-commands">
|
|
|
|
|
|
<p>
|
|
List of <code>last-command</code> values to restrict tab-triggering to, or nil.
|
|
</p>
|
|
<p>
|
|
Leave this set at nil (the default) to be able to trigger an
|
|
expansion simply by placing the cursor after a valid tab trigger,
|
|
using whichever commands.
|
|
</p>
|
|
<p>
|
|
Optionally, set this to something like '(self-insert-command) if
|
|
you to wish restrict expansion to only happen when the last
|
|
letter of the snippet tab trigger was typed immediately before
|
|
the trigger key itself.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-visit-from-menu" class="outline-4">
|
|
<h4 id="yas-visit-from-menu"><a name="sec-4-2-2" id="sec-4-2-2"></a><span class="section-number-4">4.2.2</span> <code>yas-visit-from-menu</code></h4>
|
|
<div class="outline-text-4" id="text-yas-visit-from-menu">
|
|
|
|
|
|
<p>
|
|
If non-nil visit snippets's files from menu, instead of expanding them.
|
|
</p>
|
|
<p>
|
|
This can only work when snippets are loaded from files.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-good-grace" class="outline-4">
|
|
<h4 id="yas-good-grace"><a name="sec-4-2-3" id="sec-4-2-3"></a><span class="section-number-4">4.2.3</span> <code>yas-good-grace</code></h4>
|
|
<div class="outline-text-4" id="text-yas-good-grace">
|
|
|
|
|
|
<p>
|
|
If non-nil, don't raise errors in inline elisp evaluation.
|
|
</p>
|
|
<p>
|
|
An error string "[yas] error" is returned instead.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-wrap-around-region" class="outline-4">
|
|
<h4 id="yas-wrap-around-region"><a name="sec-4-2-4" id="sec-4-2-4"></a><span class="section-number-4">4.2.4</span> <code>yas-wrap-around-region</code></h4>
|
|
<div class="outline-text-4" id="text-yas-wrap-around-region">
|
|
|
|
|
|
<p>
|
|
If non-nil, snippet expansion wraps around selected region.
|
|
</p>
|
|
<p>
|
|
The wrapping occurs just before the snippet's exit marker. This
|
|
can be overridden on a per-snippet basis.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-trigger-symbol" class="outline-4">
|
|
<h4 id="yas-trigger-symbol"><a name="sec-4-2-5" id="sec-4-2-5"></a><span class="section-number-4">4.2.5</span> <code>yas-trigger-symbol</code></h4>
|
|
<div class="outline-text-4" id="text-yas-trigger-symbol">
|
|
|
|
|
|
<p>
|
|
The text that will be used in menu to represent the trigger.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-use-menu" class="outline-4">
|
|
<h4 id="yas-use-menu"><a name="sec-4-2-6" id="sec-4-2-6"></a><span class="section-number-4">4.2.6</span> <code>yas-use-menu</code></h4>
|
|
<div class="outline-text-4" id="text-yas-use-menu">
|
|
|
|
|
|
<p>
|
|
Display a /YAS/nippet menu in the menu bar.
|
|
</p>
|
|
<p>
|
|
When non-nil, submenus for each snippet table will be listed
|
|
under the menu "Yasnippet".
|
|
</p>
|
|
<ul>
|
|
<li>If set to <code>abbreviate</code>, only the current major-mode
|
|
</li>
|
|
</ul>
|
|
|
|
<p>menu and the modes set in <a href="#yas-extra-modes"><code>yas-extra-modes</code></a> are listed.
|
|
</p>
|
|
<ul>
|
|
<li>If set to <code>full</code>, every submenu is listed
|
|
|
|
</li>
|
|
<li>It set to nil, don't display a menu at all (this requires a
|
|
<a href="#yas-reload-all"><code>yas-reload-all</code></a> call if the menu is already visible).
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
<p>
|
|
Any other non-nil value, every submenu is listed.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-choose-tables-first" class="outline-4">
|
|
<h4 id="yas-choose-tables-first"><a name="sec-4-2-7" id="sec-4-2-7"></a><span class="section-number-4">4.2.7</span> <code>yas-choose-tables-first</code></h4>
|
|
<div class="outline-text-4" id="text-yas-choose-tables-first">
|
|
|
|
|
|
<p>
|
|
If non-nil, and multiple eligible snippet tables, prompts user for tables first.
|
|
</p>
|
|
<p>
|
|
Otherwise, user chooses between the merging together of all
|
|
eligible tables.
|
|
</p>
|
|
<p>
|
|
This affects <a href="#yas-insert-snippet"><code>yas-insert-snippet</code></a>, <a href="#yas-visit-snippet-file"><code>yas-visit-snippet-file</code></a>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-choose-keys-first" class="outline-4">
|
|
<h4 id="yas-choose-keys-first"><a name="sec-4-2-8" id="sec-4-2-8"></a><span class="section-number-4">4.2.8</span> <code>yas-choose-keys-first</code></h4>
|
|
<div class="outline-text-4" id="text-yas-choose-keys-first">
|
|
|
|
|
|
<p>
|
|
If non-nil, prompt for snippet key first, then for template.
|
|
</p>
|
|
<p>
|
|
Otherwise prompts for all possible snippet names.
|
|
</p>
|
|
<p>
|
|
This affects <a href="#yas-insert-snippet"><code>yas-insert-snippet</code></a> and <a href="#yas-visit-snippet-file"><code>yas-visit-snippet-file</code></a>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-fallback-behavior" class="outline-4">
|
|
<h4 id="yas-fallback-behavior"><a name="sec-4-2-9" id="sec-4-2-9"></a><span class="section-number-4">4.2.9</span> <code>yas-fallback-behavior</code></h4>
|
|
<div class="outline-text-4" id="text-yas-fallback-behavior">
|
|
|
|
|
|
<p>
|
|
How to act when <a href="#yas-expand"><code>yas-expand</code></a> does <b>not</b> expand a snippet.
|
|
</p>
|
|
<ul>
|
|
<li><code>call-other-command</code> means try to temporarily disable /YAS/nippet
|
|
and call the next command bound to whatever key was used to
|
|
invoke <a href="#yas-expand"><code>yas-expand</code></a>.
|
|
|
|
</li>
|
|
<li>nil or the symbol <code>return-nil</code> mean do nothing. (and
|
|
<a href="#yas-expand"><code>yas-expand</code></a> returns nil)
|
|
|
|
</li>
|
|
<li>A Lisp form (apply <i>COMMAND</i> . <i>ARGS</i>) means interactively call
|
|
<i>COMMAND</i>, if <i>ARGS</i> is non-nil, call <i>COMMAND</i> non-interactively
|
|
with <i>ARGS</i> as arguments.
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-triggers-in-field" class="outline-4">
|
|
<h4 id="yas-triggers-in-field"><a name="sec-4-2-10" id="sec-4-2-10"></a><span class="section-number-4">4.2.10</span> <code>yas-triggers-in-field</code></h4>
|
|
<div class="outline-text-4" id="text-yas-triggers-in-field">
|
|
|
|
|
|
<p>
|
|
If non-nil, allow stacked expansions (snippets inside snippets).
|
|
</p>
|
|
<p>
|
|
Otherwise <a href="#yas-next-field-or-maybe-expand"><code>yas-next-field-or-maybe-expand</code></a> just moves on to the
|
|
next field
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-snippet-revival" class="outline-4">
|
|
<h4 id="yas-snippet-revival"><a name="sec-4-2-11" id="sec-4-2-11"></a><span class="section-number-4">4.2.11</span> <code>yas-snippet-revival</code></h4>
|
|
<div class="outline-text-4" id="text-yas-snippet-revival">
|
|
|
|
|
|
<p>
|
|
Non-nil means re-activate snippet fields after undo/redo.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-also-auto-indent-first-line" class="outline-4">
|
|
<h4 id="yas-also-auto-indent-first-line"><a name="sec-4-2-12" id="sec-4-2-12"></a><span class="section-number-4">4.2.12</span> <code>yas-also-auto-indent-first-line</code></h4>
|
|
<div class="outline-text-4" id="text-yas-also-auto-indent-first-line">
|
|
|
|
|
|
<p>
|
|
Non-nil means also auto indent first line according to mode.
|
|
</p>
|
|
<p>
|
|
Naturally this is only valid when <a href="#yas-indent-line"><code>yas-indent-line</code></a> is <code>auto</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-indent-line" class="outline-4">
|
|
<h4 id="yas-indent-line"><a name="sec-4-2-13" id="sec-4-2-13"></a><span class="section-number-4">4.2.13</span> <code>yas-indent-line</code></h4>
|
|
<div class="outline-text-4" id="text-yas-indent-line">
|
|
|
|
|
|
<p>
|
|
Controls indenting applied to a recent snippet expansion.
|
|
</p>
|
|
<p>
|
|
The following values are possible:
|
|
</p>
|
|
<ul>
|
|
<li><code>fixed</code> Indent the snippet to the current column;
|
|
|
|
</li>
|
|
<li><code>auto</code> Indent each line of the snippet with <code>indent-according-to-mode</code>
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
<p>
|
|
Every other value means don't apply any snippet-side indentation
|
|
after expansion (the manual per-line "$>" indentation still
|
|
applies).
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-prompt-functions" class="outline-4">
|
|
<h4 id="yas-prompt-functions"><a name="sec-4-2-14" id="sec-4-2-14"></a><span class="section-number-4">4.2.14</span> <code>yas-prompt-functions</code></h4>
|
|
<div class="outline-text-4" id="text-yas-prompt-functions">
|
|
|
|
|
|
<p>
|
|
Functions to prompt for keys, templates, etc interactively.
|
|
</p>
|
|
<p>
|
|
These functions are called with the following arguments:
|
|
</p>
|
|
<ul>
|
|
<li><i>PROMPT</i>: A string to prompt the user
|
|
|
|
</li>
|
|
<li><i>CHOICES</i>: a list of strings or objects.
|
|
|
|
</li>
|
|
<li>optional <i>DISPLAY-FN</i> : A function that, when applied to each of
|
|
</li>
|
|
</ul>
|
|
|
|
<p>the objects in <i>CHOICES</i> will return a string.
|
|
</p>
|
|
<p>
|
|
The return value of any function you put here should be one of
|
|
the objects in <i>CHOICES</i>, properly formatted with <i>DISPLAY-FN</i> (if
|
|
that is passed).
|
|
</p>
|
|
<ul>
|
|
<li>To signal that your particular style of prompting is
|
|
</li>
|
|
</ul>
|
|
|
|
<p>unavailable at the moment, you can also have the function return
|
|
nil.
|
|
</p>
|
|
<ul>
|
|
<li>To signal that the user quit the prompting process, you can
|
|
</li>
|
|
</ul>
|
|
|
|
<p>signal <code>quit</code> with
|
|
</p>
|
|
<p>
|
|
(signal 'quit "user quit!").
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-snippet-dirs" class="outline-4">
|
|
<h4 id="yas-snippet-dirs"><a name="sec-4-2-15" id="sec-4-2-15"></a><span class="section-number-4">4.2.15</span> <code>yas-snippet-dirs</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-snippet-dirs">
|
|
|
|
<p>Directory or list of snippet dirs for each major mode.
|
|
</p>
|
|
<p>
|
|
The directory where user-created snippets are to be stored. Can
|
|
also be a list of directories. In that case, when used for
|
|
bulk (re)loading of snippets (at startup or via
|
|
<a href="#yas-reload-all"><code>yas-reload-all</code></a>), directories appearing earlier in the list
|
|
shadow other dir's snippets. Also, the first directory is taken
|
|
as the default for storing the user's new snippets.
|
|
</p></div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-4-3" class="outline-3">
|
|
<h3 id="sec-4-3"><span class="section-number-3">4.3</span> Useful functions</h3>
|
|
<div class="outline-text-3" id="text-4-3">
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-active-keys" class="outline-4">
|
|
<h4 id="yas-active-keys"><a name="sec-4-3-1" id="sec-4-3-1"></a><span class="section-number-4">4.3.1</span> <code>yas-active-keys</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-active-keys">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-active-keys</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-hippie-try-expand" class="outline-4">
|
|
<h4 id="yas-hippie-try-expand"><a name="sec-4-3-2" id="sec-4-3-2"></a><span class="section-number-4">4.3.2</span> <code>yas-hippie-try-expand</code> (first-time?)</h4>
|
|
<div class="outline-text-4" id="text-yas-hippie-try-expand">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-hippie-try-expand</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-define-condition-cache" class="outline-4">
|
|
<h4 id="yas-define-condition-cache"><a name="sec-4-3-3" id="sec-4-3-3"></a><span class="section-number-4">4.3.3</span> <code>yas-define-condition-cache</code> (func doc &rest body)</h4>
|
|
<div class="outline-text-4" id="text-yas-define-condition-cache">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-define-condition-cache</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-unimplemented" class="outline-4">
|
|
<h4 id="yas-unimplemented"><a name="sec-4-3-4" id="sec-4-3-4"></a><span class="section-number-4">4.3.4</span> <code>yas-unimplemented</code> (&optional missing-feature)</h4>
|
|
<div class="outline-text-4" id="text-yas-unimplemented">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-unimplemented</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-inside-string" class="outline-4">
|
|
<h4 id="yas-inside-string"><a name="sec-4-3-5" id="sec-4-3-5"></a><span class="section-number-4">4.3.5</span> <code>yas-inside-string</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-inside-string">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-inside-string</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-default-from-field" class="outline-4">
|
|
<h4 id="yas-default-from-field"><a name="sec-4-3-6" id="sec-4-3-6"></a><span class="section-number-4">4.3.6</span> <code>yas-default-from-field</code> (number)</h4>
|
|
<div class="outline-text-4" id="text-yas-default-from-field">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-default-from-field</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-selected-text" class="outline-4">
|
|
<h4 id="yas-selected-text"><a name="sec-4-3-7" id="sec-4-3-7"></a><span class="section-number-4">4.3.7</span> <code>yas-selected-text</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-selected-text">
|
|
|
|
<p>The selected region deleted on the last snippet expansion.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-text" class="outline-4">
|
|
<h4 id="yas-text"><a name="sec-4-3-8" id="sec-4-3-8"></a><span class="section-number-4">4.3.8</span> <code>yas-text</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-text">
|
|
|
|
<p>Contains current field text.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-field-value" class="outline-4">
|
|
<h4 id="yas-field-value"><a name="sec-4-3-9" id="sec-4-3-9"></a><span class="section-number-4">4.3.9</span> <code>yas-field-value</code> (number)</h4>
|
|
<div class="outline-text-4" id="text-yas-field-value">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-field-value</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-verify-value" class="outline-4">
|
|
<h4 id="yas-verify-value"><a name="sec-4-3-10" id="sec-4-3-10"></a><span class="section-number-4">4.3.10</span> <code>yas-verify-value</code> (possibilities)</h4>
|
|
<div class="outline-text-4" id="text-yas-verify-value">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-verify-value</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-throw" class="outline-4">
|
|
<h4 id="yas-throw"><a name="sec-4-3-11" id="sec-4-3-11"></a><span class="section-number-4">4.3.11</span> <code>yas-throw</code> (text)</h4>
|
|
<div class="outline-text-4" id="text-yas-throw">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-throw</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-key-to-value" class="outline-4">
|
|
<h4 id="yas-key-to-value"><a name="sec-4-3-12" id="sec-4-3-12"></a><span class="section-number-4">4.3.12</span> <code>yas-key-to-value</code> (alist)</h4>
|
|
<div class="outline-text-4" id="text-yas-key-to-value">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-key-to-value</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-choose-value" class="outline-4">
|
|
<h4 id="yas-choose-value"><a name="sec-4-3-13" id="sec-4-3-13"></a><span class="section-number-4">4.3.13</span> <code>yas-choose-value</code> (&rest possibilities)</h4>
|
|
<div class="outline-text-4" id="text-yas-choose-value">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-choose-value</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-substr" class="outline-4">
|
|
<h4 id="yas-substr"><a name="sec-4-3-14" id="sec-4-3-14"></a><span class="section-number-4">4.3.14</span> <code>yas-substr</code> (str pattern &optional subexp)</h4>
|
|
<div class="outline-text-4" id="text-yas-substr">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-substr</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-text" class="outline-4">
|
|
<h4 id="yas-text"><a name="sec-4-3-15" id="sec-4-3-15"></a><span class="section-number-4">4.3.15</span> <code>yas-text</code> ()</h4>
|
|
<div class="outline-text-4" id="text-yas-text">
|
|
|
|
<p>Contains current field text.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-define-menu" class="outline-4">
|
|
<h4 id="yas-define-menu"><a name="sec-4-3-16" id="sec-4-3-16"></a><span class="section-number-4">4.3.16</span> <code>yas-define-menu</code> (mode menu &optional omit-items)</h4>
|
|
<div class="outline-text-4" id="text-yas-define-menu">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-define-menu</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-define-snippets" class="outline-4">
|
|
<h4 id="yas-define-snippets"><a name="sec-4-3-17" id="sec-4-3-17"></a><span class="section-number-4">4.3.17</span> <code>yas-define-snippets</code> (mode snippets)</h4>
|
|
<div class="outline-text-4" id="text-yas-define-snippets">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-define-snippets</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-expand-snippet" class="outline-4">
|
|
<h4 id="yas-expand-snippet"><a name="sec-4-3-18" id="sec-4-3-18"></a><span class="section-number-4">4.3.18</span> <code>yas-expand-snippet</code> (content &optional start end expand-env)</h4>
|
|
<div class="outline-text-4" id="text-yas-expand-snippet">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-expand-snippet</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-dropdown-prompt" class="outline-4">
|
|
<h4 id="yas-dropdown-prompt"><a name="sec-4-3-19" id="sec-4-3-19"></a><span class="section-number-4">4.3.19</span> <code>yas-dropdown-prompt</code> (<sub>prompt</sub> choices &optional display-fn)</h4>
|
|
<div class="outline-text-4" id="text-yas-dropdown-prompt">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-dropdown-prompt</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-completing-prompt" class="outline-4">
|
|
<h4 id="yas-completing-prompt"><a name="sec-4-3-20" id="sec-4-3-20"></a><span class="section-number-4">4.3.20</span> <code>yas-completing-prompt</code> (prompt choices &optional display-fn completion-fn)</h4>
|
|
<div class="outline-text-4" id="text-yas-completing-prompt">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-completing-prompt</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-no-prompt" class="outline-4">
|
|
<h4 id="yas-no-prompt"><a name="sec-4-3-21" id="sec-4-3-21"></a><span class="section-number-4">4.3.21</span> <code>yas-no-prompt</code> (<sub>prompt</sub> choices &optional <sub>display</sub>-fn)</h4>
|
|
<div class="outline-text-4" id="text-yas-no-prompt">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-no-prompt</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-ido-prompt" class="outline-4">
|
|
<h4 id="yas-ido-prompt"><a name="sec-4-3-22" id="sec-4-3-22"></a><span class="section-number-4">4.3.22</span> <code>yas-ido-prompt</code> (prompt choices &optional display-fn)</h4>
|
|
<div class="outline-text-4" id="text-yas-ido-prompt">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-ido-prompt</code>
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-x-prompt" class="outline-4">
|
|
<h4 id="yas-x-prompt"><a name="sec-4-3-23" id="sec-4-3-23"></a><span class="section-number-4">4.3.23</span> <code>yas-x-prompt</code> (prompt choices &optional display-fn)</h4>
|
|
<div class="outline-text-4" id="text-yas-x-prompt">
|
|
|
|
<p><b>/WARNING/</b>: no doc for symbol <code>yas-x-prompt</code>
|
|
</p></div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-4-4" class="outline-3">
|
|
<h3 id="sec-4-4"><span class="section-number-3">4.4</span> Useful variables</h3>
|
|
<div class="outline-text-3" id="text-4-4">
|
|
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-moving-away-p" class="outline-4">
|
|
<h4 id="yas-moving-away-p"><a name="sec-4-4-1" id="sec-4-4-1"></a><span class="section-number-4">4.4.1</span> <code>yas-moving-away-p</code></h4>
|
|
<div class="outline-text-4" id="text-yas-moving-away-p">
|
|
|
|
|
|
<p>
|
|
Non-nil if user is about to exit field.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-modified-p" class="outline-4">
|
|
<h4 id="yas-modified-p"><a name="sec-4-4-2" id="sec-4-4-2"></a><span class="section-number-4">4.4.2</span> <code>yas-modified-p</code></h4>
|
|
<div class="outline-text-4" id="text-yas-modified-p">
|
|
|
|
|
|
<p>
|
|
Non-nil if field has been modified by user or transformation.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-snippet-end" class="outline-4">
|
|
<h4 id="yas-snippet-end"><a name="sec-4-4-3" id="sec-4-4-3"></a><span class="section-number-4">4.4.3</span> <code>yas-snippet-end</code></h4>
|
|
<div class="outline-text-4" id="text-yas-snippet-end">
|
|
|
|
|
|
<p>
|
|
End position of the last snippet committed.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-snippet-beg" class="outline-4">
|
|
<h4 id="yas-snippet-beg"><a name="sec-4-4-4" id="sec-4-4-4"></a><span class="section-number-4">4.4.4</span> <code>yas-snippet-beg</code></h4>
|
|
<div class="outline-text-4" id="text-yas-snippet-beg">
|
|
|
|
|
|
<p>
|
|
Beginning position of the last snippet committed.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-dont-activate" class="outline-4">
|
|
<h4 id="yas-dont-activate"><a name="sec-4-4-5" id="sec-4-4-5"></a><span class="section-number-4">4.4.5</span> <code>yas-dont-activate</code></h4>
|
|
<div class="outline-text-4" id="text-yas-dont-activate">
|
|
|
|
|
|
<p>
|
|
If non-nil don't let <a href="#yas-global-mode"><code>yas-global-mode</code></a> affect some buffers.
|
|
</p>
|
|
<p>
|
|
If a function of zero arguments, then its result is used.
|
|
</p>
|
|
<p>
|
|
If a list of functions, then all functions must return nil to
|
|
activate yas for this buffer.
|
|
</p>
|
|
<p>
|
|
In Emacsen <= 23, this variable is buffer-local. Because
|
|
<a href="#yas-minor-mode-on"><code>yas-minor-mode-on</code></a> is called by <a href="#yas-global-mode"><code>yas-global-mode</code></a> after
|
|
executing the buffer's major mode hook, setting this variable
|
|
there is an effective way to define exceptions to the "global"
|
|
activation behaviour.
|
|
</p>
|
|
<p>
|
|
In Emacsen > 23, only the global value is used. To define
|
|
per-mode exceptions to the "global" activation behaviour, call
|
|
<a href="#yas-minor-mode"><code>yas-minor-mode</code></a> with a negative argument directily in the major
|
|
mode's hook.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-buffer-local-condition" class="outline-4">
|
|
<h4 id="yas-buffer-local-condition"><a name="sec-4-4-6" id="sec-4-4-6"></a><span class="section-number-4">4.4.6</span> <code>yas-buffer-local-condition</code></h4>
|
|
<div class="outline-text-4" id="text-yas-buffer-local-condition">
|
|
|
|
|
|
<p>
|
|
Snippet expanding condition.
|
|
</p>
|
|
<p>
|
|
This variable is a Lisp form which is evaluated every time a
|
|
snippet expansion is attempted:
|
|
</p>
|
|
<ul>
|
|
<li>If it evaluates to nil, no snippets can be expanded.
|
|
|
|
</li>
|
|
<li>If it evaluates to the a cons (require-snippet-condition
|
|
. <i>REQUIREMENT</i>)
|
|
|
|
<ul>
|
|
<li>Snippets bearing no "# condition:" directive are not
|
|
considered
|
|
|
|
</li>
|
|
<li>Snippets bearing conditions that evaluate to nil (or
|
|
produce an error) won't be considered.
|
|
|
|
</li>
|
|
<li>If the snippet has a condition that evaluates to non-nil
|
|
<i>RESULT</i>:
|
|
|
|
<ul>
|
|
<li>If <i>REQUIREMENT</i> is t, the snippet is considered
|
|
|
|
</li>
|
|
<li>If <i>REQUIREMENT</i> is <code>eq</code> <i>RESULT</i>, the snippet is
|
|
considered
|
|
|
|
</li>
|
|
<li>Otherwise, the snippet is not considered.
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
<li>If it evaluates to the symbol 'always, all snippets are
|
|
considered for expansion, regardless of any conditions.
|
|
|
|
</li>
|
|
<li>If it evaluates to t or some other non-nil value
|
|
|
|
<ul>
|
|
<li>Snippet bearing no conditions, or conditions that
|
|
evaluate to non-nil, are considered for expansion.
|
|
|
|
</li>
|
|
<li>Otherwise, the snippet is not considered.
|
|
</li>
|
|
</ul>
|
|
|
|
</li>
|
|
</ul>
|
|
|
|
|
|
<p>
|
|
Here's an example preventing snippets from being expanded from
|
|
inside comments, in <code>python-mode</code> only, with the exception of
|
|
snippets returning the symbol 'force-in-comment in their
|
|
conditions.
|
|
</p>
|
|
<p>
|
|
(add-hook 'python-mode-hook
|
|
'(lambda ()
|
|
(setq yas-buffer-local-condition
|
|
'(if (python-in-string/comment)
|
|
'(require-snippet-condition . force-in-comment)
|
|
t))))
|
|
</p>
|
|
<p>
|
|
The default value is similar, it filters out potential snippet
|
|
expansions inside comments and string literals, unless the
|
|
snippet itself contains a condition that returns the symbol
|
|
<code>force-in-comment</code>.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-before-expand-snippet-hook" class="outline-4">
|
|
<h4 id="yas-before-expand-snippet-hook"><a name="sec-4-4-7" id="sec-4-4-7"></a><span class="section-number-4">4.4.7</span> <code>yas-before-expand-snippet-hook</code></h4>
|
|
<div class="outline-text-4" id="text-yas-before-expand-snippet-hook">
|
|
|
|
|
|
<p>
|
|
Hooks to run just before expanding a snippet.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-after-exit-snippet-hook" class="outline-4">
|
|
<h4 id="yas-after-exit-snippet-hook"><a name="sec-4-4-8" id="sec-4-4-8"></a><span class="section-number-4">4.4.8</span> <code>yas-after-exit-snippet-hook</code></h4>
|
|
<div class="outline-text-4" id="text-yas-after-exit-snippet-hook">
|
|
|
|
|
|
<p>
|
|
Hooks to run after a snippet exited.
|
|
</p>
|
|
<p>
|
|
The hooks will be run in an environment where some variables bound to
|
|
proper values:
|
|
</p>
|
|
<p>
|
|
<a href="#yas-snippet-beg"><code>yas-snippet-beg</code></a> : The beginning of the region of the snippet.
|
|
</p>
|
|
<p>
|
|
<a href="#yas-snippet-end"><code>yas-snippet-end</code></a> : Similar to beg.
|
|
</p>
|
|
<p>
|
|
Attention: These hooks are not run when exiting nested/stacked snippet expansion!
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-key-syntaxes" class="outline-4">
|
|
<h4 id="yas-key-syntaxes"><a name="sec-4-4-9" id="sec-4-4-9"></a><span class="section-number-4">4.4.9</span> <code>yas-key-syntaxes</code></h4>
|
|
<div class="outline-text-4" id="text-yas-key-syntaxes">
|
|
|
|
|
|
<p>
|
|
List of character syntaxes used to find a trigger key before point.
|
|
The list is tried in the order while scanning characters
|
|
backwards from point. For example, if the list is '("w" "w_")
|
|
first look for trigger keys which are composed exclusively of
|
|
"word"-syntax characters, and then, if that fails, look for
|
|
keys which are either of "word" or "symbol"
|
|
syntax. Triggering after
|
|
</p>
|
|
<p>
|
|
foo-bar
|
|
</p>
|
|
<p>
|
|
will, according to the "w" element first try "bar". If that
|
|
isn't a trigger key, "foo-bar" is tried, respecting a second
|
|
"w_" element.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-extra-modes" class="outline-4">
|
|
<h4 id="yas-extra-modes"><a name="sec-4-4-10" id="sec-4-4-10"></a><span class="section-number-4">4.4.10</span> <code>yas-extra-modes</code></h4>
|
|
<div class="outline-text-4" id="text-yas-extra-modes">
|
|
|
|
|
|
<p>
|
|
A list of modes for which to also lookup snippets.
|
|
</p>
|
|
<p>
|
|
This variable probably makes more sense as buffer-local, so
|
|
ensure your use <code>make-local-variable</code> when you set it.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-verbosity" class="outline-4">
|
|
<h4 id="yas-verbosity"><a name="sec-4-4-11" id="sec-4-4-11"></a><span class="section-number-4">4.4.11</span> <code>yas-verbosity</code></h4>
|
|
<div class="outline-text-4" id="text-yas-verbosity">
|
|
|
|
|
|
<p>
|
|
Log level for <a href="#yas--message"><code>yas–message</code></a> 4 means trace most anything, 0 means nothing.
|
|
</p>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div id="outline-container-yas-keymap" class="outline-4">
|
|
<h4 id="yas-keymap"><a name="sec-4-4-12" id="sec-4-4-12"></a><span class="section-number-4">4.4.12</span> <code>yas-keymap</code></h4>
|
|
<div class="outline-text-4" id="text-yas-keymap">
|
|
|
|
|
|
<p>
|
|
The active keymap while a snippet expansion is in progress.
|
|
</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="postamble">
|
|
<p class="date">Date: 2013-11-24T12:11-0500</p>
|
|
<p class="author">Author: Noam Postavsky</p>
|
|
<p class="creator"><a href="http://orgmode.org">Org</a> version 7.9.3f with <a href="http://www.gnu.org/software/emacs/">Emacs</a> version 24</p>
|
|
<a href="http://validator.w3.org/check?uri=referer">Validate XHTML 1.0</a>
|
|
|
|
</div>
|
|
</body>
|
|
</html>
|