diff --git a/assets/stylesheets/app/_flight_manual.scss b/assets/stylesheets/app/_flight_manual.scss
index 5603493fe6..fb5092159f 100644
--- a/assets/stylesheets/app/_flight_manual.scss
+++ b/assets/stylesheets/app/_flight_manual.scss
@@ -516,6 +516,38 @@ h1.document-title {
}
}
+ details {
+ &:not([open]) summary {
+ cursor: pointer;
+ }
+
+ summary:focus {
+ outline: none;
+ }
+
+ ul {
+ margin-top: 9px;
+ }
+
+ li {
+ margin-bottom: 9px;
+ }
+
+ > ul {
+ margin-left: 12px;
+ }
+
+ > br,
+ ul > br,
+ li > br:last-of-type {
+ display: none;
+ }
+
+ strong code {
+ color: #00AA88;
+ }
+ }
+
pre.highlight {
color: $codeTextColor;
background: $codeBgColor;
diff --git a/content/hacking-atom/sections/creating-a-grammar.md b/content/hacking-atom/sections/creating-a-grammar.md
index d2dda0fdbe..164479ec72 100644
--- a/content/hacking-atom/sections/creating-a-grammar.md
+++ b/content/hacking-atom/sections/creating-a-grammar.md
@@ -87,10 +87,10 @@ Here is a simple example:
```coffee
scopes:
- 'call_expression > identifier': 'entity.name.function'
+ 'call_expression > identifier': 'entity.function.call'
```
-This entry means that, in the syntax tree, any `identifier` node whose parent is a `call_expression` should be highlighted using three classes: `syntax--entity`, `syntax--name`, and `syntax--function`.
+This entry means that, in the syntax tree, any `identifier` node whose parent is a `call_expression` should be highlighted using three classes: `syntax--entity`, `syntax--function`, and `syntax--call`. For a list of conventional classes, see the [Syntax Naming Conventions](../syntax-naming-conventions/) section.
Note that in this selector, we're using the [immediate child combinator](https://developer.mozilla.org/en-US/docs/Web/CSS/Child_selectors) (`>`). Arbitrary descendant selectors without this combinator (for example `'call_expression identifier'`, which would match any `identifier` occurring anywhere within a `call_expression`) are currently not supported.
@@ -104,14 +104,14 @@ scopes:
function_declaration > identifier,
call_expression > identifier,
call_expression > field_expression > field_identifier
- ''': 'entity.name.function'
+ ''': 'entity.function'
```
You can use the [`:nth-child` pseudo-class](https://developer.mozilla.org/en-US/docs/Web/CSS/:nth-child) to select nodes based on their order within their parent. For example, this example selects `identifier` nodes which are the fourth (zero-indexed) child of a `singleton_method` node.
```coffee
scopes:
- 'singleton_method > identifier:nth-child(3)': 'entity.name.function'
+ 'singleton_method > identifier:nth-child(3)': 'entity.function'
```
Finally, you can use double-quoted strings in the selectors to select *anonymous* tokens in the syntax tree, like `(` and `:`. See [the Tree-sitter documentation](http://tree-sitter.github.io/tree-sitter/using-parsers#named-vs-anonymous-nodes) for more information about named vs anonymous tokens.
@@ -123,7 +123,7 @@ scopes:
"/",
"+",
"-"
- ''': 'keyword.operator'
+ ''': 'keyword.operator.arithmetic.symbolic'
```
##### Text-based Mappings
@@ -133,21 +133,31 @@ You can also apply different classes to a syntax node based on its text. Here ar
```coffee
scopes:
- # Apply the classes `syntax--builtin` and `syntax--variable` to all
- # `identifier` nodes whose text is `require`.
- 'identifier': {exact: 'require', scopes: 'builtin.variable'},
+ # Apply the classes `syntax--entity`, `syntax--function`, and
+ # `syntax--support` to all `identifier` nodes whose text is `require`.
+ 'identifier': {
+ exact: 'require',
+ scopes: 'entity.function.support'
+ },
- # Apply the classes `syntax--type` and `syntax--integer` to all
- # `primitive_type` nodes whose text starts with `int` or `uint`.
- 'primitive_type': {match: /^u?int/, scopes: 'type.integer'},
+ # Apply the classes `syntax--entity`, `syntax--type`, `syntax--fundamental`,
+ # and `syntax--integer` to all `primitive_type` nodes whose text starts
+ # with `int` or `uint`.
+ 'primitive_type': {
+ match: /^u?int/,
+ scopes: 'entity.type.fundamental.integer'
+ },
- # Apply the classes `syntax--builtin`, `syntax--class`, and
- # `syntax--name` to `constant` nodes with the text `Array`,
- # `Hash` and `String`. For all other `constant` nodes, just
- # apply the classes `syntax--class` and `syntax--name`.
+ # Apply the classes `syntax--entity`, `syntax--type`, `syntax--class`, and
+ # `syntax--support` to `constant` nodes with the text `Array`, `Hash` or
+ # `String`. For other `constant` nodes, apply the classes `syntax--entity`,
+ # `syntax--type`, and `syntax--class`.
'constant': [
- {match: '^(Array|Hash|String)$', scopes: 'builtin.class.name'},
- 'class.name'
+ {
+ match: '^(Array|Hash|String)$',
+ scopes: 'entity.type.class.support'
+ },
+ 'entity.type.class'
]
```
@@ -164,15 +174,15 @@ If multiple selectors in the `scopes` object match a node, the node's classes wi
```coffee
scopes:
- 'call_expression > identifier': 'entity.name.function'
+ 'call_expression > identifier': 'entity.function'
# If we did not include the second selector here, then this rule
# would not apply to identifiers inside of call_expressions,
# because the selector `call_expression > identifier` is more
# specific than the selector `identifier`.
'identifier, call_expression > identifier': [
- {exact: 'require', scopes: 'builtin.variable'},
- {match: '^[A-Z]', scopes: 'constructor'},
+ {exact: 'require', scopes: 'entity.function.support'},
+ {match: '^[A-Z]', scopes: 'entity.type.constructor'},
]
```
diff --git a/content/hacking-atom/sections/creating-a-theme.md b/content/hacking-atom/sections/creating-a-theme.md
index a5dd9fa865..40f871b332 100644
--- a/content/hacking-atom/sections/creating-a-theme.md
+++ b/content/hacking-atom/sections/creating-a-theme.md
@@ -36,7 +36,7 @@ Atom will display a new window, showing the motif-syntax theme, with a default s
Open up `styles/colors.less` to change the various color variables which have already been defined. For example, turn `@red` into `#f4c2c1`.
-Then open `styles/base.less` and modify the various selectors that have already been defined. These selectors style different parts of code in the editor such as comments, strings and the line numbers in the gutter.
+Then open `styles/editor.less` and `styles/syntax.less` and modify the various selectors that have already been defined. These selectors style different parts of code in the editor such as keywords, strings, and the line numbers in the gutter.
As an example, let's make the `.gutter` `background-color` into `@red`.
diff --git a/content/hacking-atom/sections/syntax-naming-conventions.md b/content/hacking-atom/sections/syntax-naming-conventions.md
new file mode 100644
index 0000000000..383b674be1
--- /dev/null
+++ b/content/hacking-atom/sections/syntax-naming-conventions.md
@@ -0,0 +1,712 @@
+---
+title: Syntax Naming Conventions
+---
+
+### Syntax Naming Conventions
+
+Naming conventions provide predefined names for similar tokens in different languages. These language-agnostic names, called syntax classes, help themes highlight code without relying on language-specific vocabulary.
+
+When creating a language grammar, use these conventions to determine which syntax classes correspond to your syntax nodes. When creating a syntax theme, use these conventions to determine which syntax classes correspond to your theme colors.
+
+#### Guidelines for Language Grammars
+
+The syntax classes are organized into nested categories. In a language grammar, multiple nested classes can be applied to a syntax node by appending them with periods, as in `entity.function.call`. The order in which classes are appended does not affect the resulting highlighting. However, we recommend following their hierarchy to stay consistent.
+
+Root classes, like `▶ entity`, must not be appended to other root classes, unless explicitly allowed in this documentation. Main classes indicated in bold green, like __function
__, must be used for coherent highlighting. Shared classes indicated in brackets, like `[call]`, can be appended when relevant. You may create additional classes if they clarify your grammar and do not introduce conflicts with existing classes.
+
+#### Guidelines for Syntax Themes
+
+In a syntax theme, styling can be applied to a syntax class with the `syntax--` prefix, as in `syntax--entity`. When targeting a nested class, specify its parent classes by prepending them with periods, as in `syntax--entity.syntax--function.syntax--call`. A typical styling rule would look like this:
+
+```css
+.syntax--entity.syntax--function.syntax--call {
+ color: blue;
+}
+```
+
+#### List of Syntax Classes
+
+Click on root classes to reveal more nested classes.
+
+
+ __`keyword`__ — A keyword.
+
+ - __`[symbolic]`__ — A keyword with no alphabetic characters.
+
+ - __`control`__ — A control or structure keyword.
+
+ - `condition` — A condition keyword.
+ Examples: `if`, `else`, `elif`.
+
+ - `loop` — A loop keyword.
+ Examples: `for`, `for`...`in`, `for`...`of`, `do`, `while`.
+
+ - `exception` — An exception keyword.
+ Examples: `try`, `catch`, `finally`.
+
+ - `jump` — A keyword used to jump to/from a statement.
+ Examples: `break`, `continue`, `pass`, `return`, `yield`, `throw`, `await`.
+
+ - `package` — A keyword for imports or exports.
+ Examples: `import`, `from`, `include`, `export`, `require`.
+
+ - `directive` — An instruction given to the compiler.
+ Examples: `#include`, `#define`, `#ifdef`, `using`, `package`, `use strict`.
+
+ - `evaluate` — A keyword used to evaluate an expression.
+ Examples: `assert`, `with`...`as`.
+
+
+
+ - __`storage`__ — A storage keyword.
+
+ - `modifier` — A keyword to detail the behavior of an entity.
+ Examples: `static`, `abstract`, `final`, `throws`, `get`, `extends`.
+
+ - `declaration` — A keyword to declare an entity.
+ Examples: `let`, `const`, `func`, `def`, `class`, `enum`, `typedef`, `namespace`.
+
+
+
+ - __`type`__ — A type keyword.
+ Examples: `char`, `int`, `bool`, `void`.
+
+ - `wildcard` — A wildcard keyword for an unknown type.
+ Example: `?` in `List> list`.
+
+
+
+ - __`operator`__ — An operator keyword. Includes overloaded operators.
+
+ - `logical` — A logical operator.
+ Examples: `and`, `not`, `or`, `!`, `&&`, `||`.
+
+ - `ternary` — A ternary condition operator.
+ Examples: `?`, `:`.
+
+ - `assignment` `(compound)` — An assignment operator.
+ Examples: `=`, `:=`, `+=`, `-=`, `*=`, `%=`.
+
+ - `comparison` — A comparison operator.
+ Examples: `==`, `<`, `>`, `!=`, `in`, `instanceof`.
+
+ - `arithmetic` — An arithmetic operator.
+ Examples: `+`, `-`, `/`, `*`, `@`, `++`, `--`.
+
+ - `pointer` `(reference)` `(dereference)` — A pointer operator.
+ Examples: `&`, `*`.
+
+ - `bitwise` — A bitwise operator.
+ Examples: `<<`, `>>`, `|`, `&`, `^`, `~`.
+
+ - `instance` — A instance operator.
+ Examples: `del`, `delete`, `new`, `typeof`.
+
+ - `composition` — A composition operator (Haskell).
+ Example: `.`.
+
+ - `combinator` — A combinator operator (CSS).
+ Examples: `>`, `+`, `~`, `&`.
+
+
+
+ - __`function`__ — A function keyword.
+ Example: `super`.
+
+ - __`variable`__ — A variable keyword.
+ Examples: `this`, `self`, `@`.
+
+
+
+
+ __`entity`__ — An identifier.
+
+ - `[parameter]` — A parameter in a definition or declaration or call.
+ Examples: `myFunction(parameter = argument)`, `class MyClass {}`.
+
+ - `[argument]` — An argument in a call.
+ Examples: `instance.method(argument)`, `new MyClass(argument)`.
+
+ - `[definition]` — An entity that is being defined or declared.
+ Examples: `my_variable` in `let my_variable`, `myFunction` in `def myFunction()`.
+
+ - `[call]` — An entity that is being called.
+ Examples: `myFunction` in `myFunction()`, `MyClass` in `new MyClass(argument)`.
+
+ - `[mutable]` — An entity whose properties or value can be changed.
+ Examples: `var mutable`, `let mutable`.
+
+ - `[immutable]` — An entity whose properties or value cannot be changed.
+ Examples: `const immutable`, `final immutable`.
+
+ - __`[support]`__ — A built-in/imported/conventional entity that can usually be redefined.
+ Examples: `self`, `cls`, `arguments`, `iota`, `len`, `print`, `loop`, `int`, `bool`.
+
+ - __`variable`__ — A variable.
+
+ - `member` — A member variable in an object.
+ Examples: `{property: value}`, `object.attribute`.
+
+
+
+ - __`function`__ — A function.
+
+ - `cast` — A type casting function that is not a type itself.
+ Examples: `as.matrix()`, `toInt()`.
+
+ - `method` `(constructor)`— A method in an object.
+ Examples: `{method: (parameter) => value}`, `object.method()`.
+
+ - `lambda` — A lambda.
+ Example: `lambda = ->() {}`.
+
+ - `infix` — A function used in infix notation.
+ Example: ``1 `function` 2``.
+
+
+
+ - __`operator`__ — An operator.
+
+ - __`[symbolic]`__ — An operator with no alphabetic characters.
+ Examples: `%>%`, `<+>`.
+
+
+
+ - __`type`__ — A type.
+
+ - `[cast]` — A type used for type casting, eventually in functional notation.
+ Examples: `float(32)`, `int(3.2)`, `matrix()`.
+
+ - `[constructor]` — A type used as a constructor, eventually in functional notation.
+ Examples: `new MyClass()`.
+
+ - __`fundamental`__ — A fundamental primitive or composite type.
+ Examples: `char`, `int`, `bool`, `rune`, `list`, `map`, `tuple`.
+
+ - `class` — A class.
+ Examples: `MyClass`, `String`, `List`.
+
+ - `inherited` — An inherited class.
+ Example: `class Child < Inherited`.
+
+ - `mixin` — A mixin class.
+ Example: `module Mixin` (Ruby).
+
+ - `generic` — A generic class.
+ Examples: ``, ``.
+
+ - `exception` — An exception.
+ Example: `AssertionError`.
+
+ - `abstract` — An abstract class.
+ Example: `abstract class Abstract` (Java)
+
+
+
+ - `interface` — An interface.
+ Example: `Vehicle` in `public interface Vehicle {}`.
+
+ - `enumeration` — An enumeration.
+ Example: `Color` in `enum Color{red, green, blue}`.
+
+ - `structure` — A structure.
+ Examples: `Address` in `type Address struct {}`.
+
+ - `union` — An union.
+ Example: `IPv4` in `union IPv4 {}`.
+
+ - `alias` — An alias.
+ Example: `Number` in `typedef int Number`.
+
+
+
+ - `annotation` — An annotation.
+ Examples: `@Override` (Java), `#[test]` (Rust), `[Obsolete]` (C#).
+
+ - `namespace` — A namespace.
+ Examples: `namespace Namespace {}` (C++), `namespace::function()` (Rust).
+
+ - `package` — A package.
+ Example: `from package import entity`.
+
+ - `label` — A statement label.
+ Example: `goto label`.
+
+ - `lifetime` — A lifetime (Rust).
+ Example: `'static`.
+
+ - __`tag`__ — A tag (HTML).
+ Examples: `body`, `div`, `input`.
+
+ - __`attribute`__ `(id)` `(class)` — An attribute (HTML).
+ Example: ``.
+
+ - __`property`__ — A property (CSS).
+ Example: `{property: value}`.
+
+ - __`selector`__ `(tag)` `(id)` `(class)` `(pseudo-)` `(attribute)` — A selector (CSS).
+ Examples: `#id`, `.class`, `:hover`, `:not`, `::before`, `::after`, `[attribute]`.
+
+
+
+
+ __`string`__ — A string or part of a string.
+
+ - `[argument]` — An argument in a call.
+ Examples: `myFunction("string")`, `new MyClass('string')`.
+
+ - `[mutable]` — A mutable string. Specified when mutable and immutable coexist.
+ Example: `'string'` (Ruby).
+
+ - `[immutable]` — An immutable string. Specified when mutable and immutable coexist.
+ Example: `:immutable` (Ruby).
+
+ - `[key]` — A key in a key-value pair.
+ Example: `{"key" => value}`.
+
+ - `[quoted]` — A quoted string.
+ Examples: `"string"`, `'string'`, `$"template string"`, `/^regexp string$/`.
+
+ - `[unquoted]` — An unquoted string.
+ Example: `'key': unquoted`.
+
+ - __`[part]`__ — A part of a string.
+
+ - `interpolation` — An interpolation.
+ Examples: `${variable}`, `{variable:<30}`.
+
+ - `placeholder` — A placeholder.
+ Examples: `%()d`, `{0:.2f}`, `%-#10x`, `\1`.
+
+ - `format` — A format specifier.
+ Examples: `<30`, `d`, `.2f`, `-#10x`.
+
+
+
+ - __`regexp`__ — A regular expression.
+ Example: `/^regexp$/`.
+
+ - __`[part]`__ — A part of a regular expression.
+
+ - __`language`__ — A regular expression keyword.
+
+ - __`[symbolic]`__ — A keyword with no alphabetic characters.
+
+ - `control` `(anchor)` `(reference)` `(mode)` — A control token.
+ Examples: `^`, `$`, `\b`, `\k`, `\1`, `i` in `(?i)`, `g` in `/^regexp$/g`.
+
+ - `operator` `(quantifier)` — A quantifier operator.
+ Examples; `?`, `*`, `+`, `{1,2}`.
+
+
+ - __`variable`__ — A regular expression variable.
+ Examples: `(?)`, `\k`.
+
+ - `group` — A regular expression group.
+ Examples: `(capture)`, `(?:non-capture)`.
+
+ - `lookaround` — A regular expression lookaround.
+ Example: `(?=lookahead)`.
+
+ - `set` — A regular expression set.
+ Example: `[^A-Z]`.
+
+
+
+
+
+ - `template` — A template string.
+ Examples: `$"string {interpolation}"`, `` `string ${interpolation}` ``.
+
+ - `heredoc` — A here document.
+ Example: `<
+
+
+
+ __`constant`__ — A literal other than a string.
+
+ - `[argument]` — An argument in a call.
+ Examples: `myFunction(constant)`, `float(constant)`.
+
+ - `[key]` — A key in a key-value pair.
+ Example: `{key: value}`.
+
+ - `[quoted]` — A quoted constant.
+ Example: `'a'`.
+
+ - `[unquoted]` — An unquoted constant.
+ Example: `#color`.
+
+ - __`[support]`__ — A built-in or imported or conventional constant.
+ Examples: `absolute`, `blue`, `screen`.
+
+ - __`[language]`__ — A literal keyword.
+
+ - __`[symbolic]`__ — A keyword with no alphabetic characters.
+ Example: `...` (Python).
+
+ - `boolean` — A boolean.
+ Examples: `true`, `false`.
+
+ - `null` — A null value.
+ Examples: `None`, `null`, `nil`.
+
+ - `undefined` — An undefined value.
+ Example: `undefined`.
+
+ - `numeric` — A numeric word.
+ Example: `Infinity`.
+
+
+
+ - __`numeric`__ — A number.
+
+ - `integer` — An integer.
+ Example: `2`.
+
+ - `decimal` — A decimal number.
+ Example: `.17`.
+
+ - `hexadecimal` — A hexadecimal number.
+ Example: `0x29`.
+
+ - `unit` — A length unit (CSS).
+ Examples: `%`, `px`, `pt`, `em`.
+
+ - `duration` — A duration (Lilypond).
+ Examples: `8`, `2.`.
+
+
+
+ - __`character`__ — A character.
+ Example: `'a'`.
+
+ - `[escape]` — An escape sequence.
+ Examples: `\"`, `\\`, `\i`, `\?`, `\u2661`, `\n`, `\d`, `\W`.
+
+ - __`code`__ — A substitute for another character.
+ Examples: `<`, `\x2f`, `\n`.
+
+ - `shorthand` — A shorthand for other characters (RegExp).
+ Examples: `.`, `\d`, `\W`, `\s`.
+
+ - `range` — A range of characters (RegExp).
+ Examples: `a-z`, `0-9`.
+
+ - `whitespace` — A whitespace character.
+ Examples: `\t`, `\f`.
+
+ - `newline` — A newline character.
+ Examples: `\n`, `\r`.
+
+
+
+ - `unicode` — A unicode code point.
+ Example: `\u2661`.
+
+ - `hexadecimal` — A hexadecimal code point.
+ Example: `\x2f`.
+
+ - `octal` — An octal code point.
+ Example: `\143`.
+
+
+
+
+
+ - `color` — A color (CSS).
+ Examples: `crimson`, `#a35`.
+
+ - `prefix` — A color prefix.
+ Example: `#`.
+
+
+
+ - `font` — A font (CSS).
+ Examples: `Helvetica`, `Times New Roman`.
+
+ - `style` — A style (CSS).
+ Examples: `break-word`, `solid`, `absolute`.
+
+
+
+
+ __`text`__ — Plain text.
+
+
+ __`markup`__ — Stylized text.
+
+ - `heading` — A heading.
+ Example: `# Heading`.
+
+ - `list` — A list item.
+ Examples: `1. item`, `- item`.
+
+ - `quote` — A quote.
+ Example: `> quote`.
+
+ - `bold` — Bold text.
+ Example: `**bold**`.
+
+ - `italic` — Italic text.
+ Example: `*italic*`.
+
+ - `underline` — Underlined text.
+ Example: `__underline__`.
+
+ - `strike` — Striked-through text.
+ Example: `~~strike~~`.
+
+ - `raw` — Raw unformatted text or code.
+ Example: `` `raw` ``.
+
+ - `link` — An url or path or reference.
+ Examples: `url.com`, `(path)` in `[alt](path)`, `[reference]`.
+
+ - `alt` — Alternate text for a link.
+ Examples: `[alt]`, `![alt]`.
+
+ - `critic` — A critic.
+
+ - `inserted` — An insertion.
+ Example: `{++ inserted ++}`.
+
+ - `deleted` — A deletion.
+ Example: `{-- deleted --}`.
+
+ - `changed` — A modification.
+ Example: `{~~ from ~> to ~~}`.
+
+ - `commented` — A comment.
+ Example: `{>> commented <<}`.
+
+ - `highlighted` — A highlight.
+ Example: `{== highlighted ==}`.
+
+
+
+
+
+
+ __`comment`__ — A comment or part of a comment. Includes comments in strings.
+
+ - __`[part]`__ — A part of a comment.
+
+ - `caption` — A caption in a comment.
+ Examples: `@param`, ``, `NOTE`, `TODO`, `FIXME`.
+
+ - `path` — A path in a comment.
+ Example: `path/to/my-file`.
+
+ - `term` `(variable)` `(function)` `(operator)` `(type)` — A documented entity.
+ Examples: `type` and `variable` in `@param {type} variable`.
+
+
+
+ - `line` — A one-line comment.
+ Example: `# comment`.
+
+ - `block` — A multi-line comment.
+ Example: `/* ... */`.
+
+
+
+
+ __`punctuation`__ — A punctuation mark.
+
+ - __`definition`__ — Punctuation that defines tokens.
+
+ - __`string`__ — Punctuation for a string.
+ Examples: `"`, `'`, `$"`.
+
+ - __`regexp`__ — Punctuation for a regular expression.
+ Examples: `r"`, `/`.
+
+
+
+ - __`constant`__ — Punctuation for a literal other than a string.
+
+ - __`character`__ — Punctuation for a character.
+ Example: `'`.
+
+
+
+ - __`markup`__ — Punctuation for text styling (Markdown).
+ Examples: `_`, `*`, `~`, `#`, `-`. `1.`, `[`, `]`.
+
+ - __`comment`__ — Punctuation for a comment.
+ Examples: `//`, `#`, ``.
+
+ - `collection` — Punctuation for a collection (array, set, map, etc.).
+ Examples: `[`, `]`, `{`, `}`.
+
+ - `variable` — Punctuation for a variable.
+ Example: `$`.
+
+ - `function` `(generator)` — Punctuation for a function.
+ Examples: `` ` ``, `*`.
+
+ - `operator` — Punctuation for an operator.
+ Examples: `(`, `)`.
+
+ - `package` `(wildcard)` — Punctuation for a package.
+ Examples: `.`, `*`.
+
+ - `annotation` — Punctuation for an annotation.
+ Examples: `@` (Java), `#![]` (Rust).
+
+ - `decorator` — Punctuation for a decorator.
+ Example: `@` (Python).
+
+ - `tag` — Punctuation for a tag (HTML).
+ Examples: `<`, `/>`.
+
+ - `selector` `(wildcard)` — Punctuation for a selector (CSS).
+ Examples: `*`, `.`, `#`, `:`, `::`, `[`, `]`.
+
+
+
+ - __`operation`__ — Punctuation to operate on tokens.
+
+ - `variadic` — Punctuation to operate on variadic arguments.
+ Examples: `...`, `*`, `**`.
+
+ - `lambda` — Punctuation to operate on lambda parameters.
+ Example: `->` in `(parameter) -> expression`.
+
+
+
+ - __`association`__ — Punctuation to associate values to tokens.
+
+ - `pair` — Punctuation to associate an expression to a key.
+ Examples: `:` in `key: value`, `=>` in `None => println!("Nothing")`.
+
+ - `iterator` — Punctuation to associate an expression to an iterator.
+ Example: `:` in `auto& iterator : items`.
+
+
+
+ - __`accessor`__ — Punctuation to access contained entities.
+
+ - `member` — Punctuation for member access.
+ Examples: `.`, `->`.
+
+ - `scope` — Punctuation for scope resolution.
+ Example: `::`.
+
+
+
+ - __`delimiter`__ — Punctuation to delimit tokens.
+
+ - __`string`__ — Punctuation to delimit tokens in a string.
+
+ - __`[part]`__ — Punctuation to delimit a part of a string.
+
+ - `interpolation` — Punctuation to delimit an interpolation.
+ Examples: `#{`, `${`, `}`.
+
+ - `placeholder` — Punctuation to delimit a placeholder.
+ Examples: `{`, `}`, `%`, `%(`, `)`.
+
+ - `format` — Punctuation to delimit a format specifier.
+ Example: `:`.
+
+
+
+ - __`regexp`__ — Punctuation to delimit tokens in a regular expression.
+
+ - __`[part]`__ — Punctuation to delimit a part of a regular expression.
+
+ - `group` — Punctuation to delimit a group.
+ Examples: `(?:`, `(`, `(?P`, `)`.
+
+ - `lookaround` — Punctuation to delimit a lookaround.
+ Examples: `(?=`, `(?!`, `)`.
+
+ - `disjunction` — Punctuation to delimit a disjunction.
+ Example: `|`.
+
+ - `set` — Punctuation to delimit a set.
+ Examples: `[^`, `[`, `]`.
+
+ - `mode` — Punctuation to delimit a mode specifier.
+ Examples: `(?`, `)`.
+
+
+
+
+
+
+
+ - __`comment`__ — Punctuation to delimit tokens in a comment.
+
+ - __`[part]`__ — Punctuation to delimit a part of a comment.
+
+ - `caption` — Punctuation to delimit a caption.
+ Examples: `<`, `>`, `:`.
+
+ - `term` — Punctuation to delimit a documented entity.
+ Examples: `{` and `}` in `{type}`.
+
+
+
+
+
+ - `parameters` — Punctuation to delimit parameters.
+ Examples: `(`, `)`.
+
+ - `arguments` — Punctuation to delimit arguments.
+ Examples: `(`, `)`.
+
+ - `subscript` — Punctuation to delimit a subscript.
+ Examples: `[`, `]`.
+
+ - `type` — Punctuation to delimit a type or return type.
+ Examples: `<`, `:`, `->`, `(`, `)`.
+
+ - `body` — Punctuation to delimit a body.
+ Examples: `{`, `}`, `:`.
+
+ - `statement` — Punctuation to delimit a statement.
+ Examples: `{`, `}`, `:`.
+
+ - `expression` — Punctuation to delimit an expression.
+ Examples: `(`, `)`.
+
+ - `embedded` — Punctuation to delimit embedded code.
+ Examples: `~~~`, `<%=`, `%>`.
+
+ - `package` — Punctuation to delimit package imports or exports.
+ Examples: `(` `)`, `{`, `}`.
+
+
+
+ - __`separator`__ — Punctuation to separate similar tokens.
+ Examples: `,`, `\`.
+
+ - __`terminator`__ — Punctuation to terminate a statement.
+ Example: `;`.
+
+
+
+
+ `[invalid]` — An invalid token. Appendable to every class.
+
+ - `deprecated` — A deprecated token which should no longer be used.
+
+ - `illegal` — An illegal token which doesn't belong there.
+
+
+
+
+ `meta` — A larger part of the document encompassing multiple tokens.
+
+ - `function` — A function definition block.
+
+ - `class` — A class definition block.
+
+ - `embedded` — A language embedded in another.
+
+
+
diff --git a/data/toc.yml b/data/toc.yml
index 3c7727fef0..c21f0cefe7 100644
--- a/data/toc.yml
+++ b/data/toc.yml
@@ -32,6 +32,7 @@ Chapters:
- Creating a Theme
- Creating a Grammar
- Creating a Legacy TextMate Grammar
+ - Syntax Naming Conventions
- Publishing
- Iconography
- Debugging