Talk:Typographical Guidelines: Difference between revisions
(Talk page autocreated when first thread was posted.) |
No edit summary |
||
Line 1: | Line 1: | ||
== Typographic conventions inside code tags == | |||
To denote replaceable portions of sample commands / literal code snippets, HTML5 provides the VAR tag which combines nicely with CODE (e.g. can be used between <code> </code> tags.) Typically that's a preferable way to add placeholders to sections of a command string that would otherwise be <code>-enclosed, since it avoids breaking up the <code> formatting. | |||
So, take the example from "Combined Bold and Italic Text: | |||
* To connect to your remote server, type <code>ssh</code> '''''username@domain.name''''' in '''Konsole'''. | |||
I have no idea why '''''username@domain.name''''' is ''both'' bolded and italicized, since as far as I can tell the rules in previous sections don't call for bolding. Typically the placeholder (or "variable", hence VAR) elements would only be italicized, in which case <var> becomes ideal. Changing the source of that line to: | |||
<code><nowiki>* To connect to your remote server, type <code>ssh <var>username</var>@<var>domain.name</var></code> in '''Konsole'''.</nowiki></code> | |||
would lead to it formatting as: | |||
* To connect to your remote server, type <code>ssh <var>username</var>@<var>domain.name</var></code> in '''Konsole'''. | |||
Which seems much clearer and more readable. -- [[User:FeRDNYC|FeRDNYC]] ([[User talk:FeRDNYC|talk]]) 10:03, 19 December 2021 (UTC) |
Revision as of 10:03, 19 December 2021
Typographic conventions inside code tags
To denote replaceable portions of sample commands / literal code snippets, HTML5 provides the VAR tag which combines nicely with CODE (e.g. can be used between <code> </code> tags.) Typically that's a preferable way to add placeholders to sections of a command string that would otherwise be <code>-enclosed, since it avoids breaking up the <code> formatting.
So, take the example from "Combined Bold and Italic Text:
- To connect to your remote server, type
ssh
username@domain.name in Konsole.
I have no idea why username@domain.name is both bolded and italicized, since as far as I can tell the rules in previous sections don't call for bolding. Typically the placeholder (or "variable", hence VAR) elements would only be italicized, in which case <var> becomes ideal. Changing the source of that line to:
* To connect to your remote server, type <code>ssh <var>username</var>@<var>domain.name</var></code> in '''Konsole'''.
would lead to it formatting as:
- To connect to your remote server, type
ssh username@domain.name
in Konsole.
Which seems much clearer and more readable. -- FeRDNYC (talk) 10:03, 19 December 2021 (UTC)