diff options
| author | Craig Jennings <c@cjennings.net> | 2024-04-07 13:41:34 -0500 |
|---|---|---|
| committer | Craig Jennings <c@cjennings.net> | 2024-04-07 13:41:34 -0500 |
| commit | 754bbf7a25a8dda49b5d08ef0d0443bbf5af0e36 (patch) | |
| tree | f1190704f78f04a2b0b4c977d20fe96a828377f1 /devdocs/elisp/menu-separators.html | |
new repository
Diffstat (limited to 'devdocs/elisp/menu-separators.html')
| -rw-r--r-- | devdocs/elisp/menu-separators.html | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/devdocs/elisp/menu-separators.html b/devdocs/elisp/menu-separators.html new file mode 100644 index 00000000..fcf8a7c8 --- /dev/null +++ b/devdocs/elisp/menu-separators.html @@ -0,0 +1,22 @@ + <h4 class="subsubsection">Menu Separators</h4> <p>A menu separator is a kind of menu item that doesn’t display any text—instead, it divides the menu into subparts with a horizontal line. A separator looks like this in the menu keymap: </p> <div class="example"> <pre class="example">(menu-item <var>separator-type</var>) +</pre> +</div> <p>where <var>separator-type</var> is a string starting with two or more dashes. </p> <p>In the simplest case, <var>separator-type</var> consists of only dashes. That specifies the default kind of separator. (For compatibility, <code>""</code> and <code>-</code> also count as separators.) </p> <p>Certain other values of <var>separator-type</var> specify a different style of separator. Here is a table of them: </p> <dl compact> <dt><code>"--no-line"</code></dt> <dt><code>"--space"</code></dt> <dd> +<p>An extra vertical space, with no actual line. </p> </dd> <dt><code>"--single-line"</code></dt> <dd> +<p>A single line in the menu’s foreground color. </p> </dd> <dt><code>"--double-line"</code></dt> <dd> +<p>A double line in the menu’s foreground color. </p> </dd> <dt><code>"--single-dashed-line"</code></dt> <dd> +<p>A single dashed line in the menu’s foreground color. </p> </dd> <dt><code>"--double-dashed-line"</code></dt> <dd> +<p>A double dashed line in the menu’s foreground color. </p> </dd> <dt><code>"--shadow-etched-in"</code></dt> <dd> +<p>A single line with a 3D sunken appearance. This is the default, used separators consisting of dashes only. </p> </dd> <dt><code>"--shadow-etched-out"</code></dt> <dd> +<p>A single line with a 3D raised appearance. </p> </dd> <dt><code>"--shadow-etched-in-dash"</code></dt> <dd> +<p>A single dashed line with a 3D sunken appearance. </p> </dd> <dt><code>"--shadow-etched-out-dash"</code></dt> <dd> +<p>A single dashed line with a 3D raised appearance. </p> </dd> <dt><code>"--shadow-double-etched-in"</code></dt> <dd> +<p>Two lines with a 3D sunken appearance. </p> </dd> <dt><code>"--shadow-double-etched-out"</code></dt> <dd> +<p>Two lines with a 3D raised appearance. </p> </dd> <dt><code>"--shadow-double-etched-in-dash"</code></dt> <dd> +<p>Two dashed lines with a 3D sunken appearance. </p> </dd> <dt><code>"--shadow-double-etched-out-dash"</code></dt> <dd><p>Two dashed lines with a 3D raised appearance. </p></dd> </dl> <p>You can also give these names in another style, adding a colon after the double-dash and replacing each single dash with capitalization of the following word. Thus, <code>"--:singleLine"</code>, is equivalent to <code>"--single-line"</code>. </p> <p>You can use a longer form to specify keywords such as <code>:enable</code> and <code>:visible</code> for a menu separator: </p> <p><code>(menu-item <var>separator-type</var> nil . <var>item-property-list</var>)</code> </p> <p>For example: </p> <div class="example"> <pre class="example">(menu-item "--" nil :visible (boundp 'foo)) +</pre> +</div> <p>Some systems and display toolkits don’t really handle all of these separator types. If you use a type that isn’t supported, the menu displays a similar kind of separator that is supported. </p><div class="_attribution"> + <p class="_attribution-p"> + Copyright © 1990-1996, 1998-2022 Free Software Foundation, Inc. <br>Licensed under the GNU GPL license.<br> + <a href="https://www.gnu.org/software/emacs/manual/html_node/elisp/Menu-Separators.html" class="_attribution-link">https://www.gnu.org/software/emacs/manual/html_node/elisp/Menu-Separators.html</a> + </p> +</div> |
