/usr/share/doc/texinfo/html/Tips.html is in texinfo-doc-nonfree 6.5.0-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<!-- This manual is for GNU Texinfo (version 6.5, 25 August 2017),
a documentation system that can produce both online information and a
printed manual from a single source using semantic markup.
Copyright (C) 1988, 1990, 1991, 1992, 1993, 1995, 1996, 1997,
1998, 1999, 2001, 2001, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
2010, 2011, 2012, 2013, 2014, 2015, 2016 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation; with no
Invariant Sections, with the Front-Cover Texts being "A GNU Manual",
and with the Back-Cover Texts as in (a) below. A copy of the license
is included in the section entitled "GNU Free Documentation
License".
(a) The FSF's Back-Cover Text is: "You have the freedom to copy and
modify this GNU manual. Buying copies from the FSF supports it in
developing GNU and promoting software freedom." -->
<!-- Created by GNU Texinfo 6.4.90, http://www.gnu.org/software/texinfo/ -->
<head>
<title>Tips (GNU Texinfo 6.5)</title>
<meta name="description" content="Tips (GNU Texinfo 6.5)">
<meta name="keywords" content="Tips (GNU Texinfo 6.5)">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<link href="index.html#Top" rel="start" title="Top">
<link href="Command-and-Variable-Index.html#Command-and-Variable-Index" rel="index" title="Command and Variable Index">
<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
<link href="index.html#Top" rel="up" title="Top">
<link href="Sample-Texinfo-Files.html#Sample-Texinfo-Files" rel="next" title="Sample Texinfo Files">
<link href="Obsolete-_0040_002dCommands.html#Obsolete-_0040_002dCommands" rel="prev" title="Obsolete @-Commands">
<style type="text/css">
<!--
a.summary-letter {text-decoration: none}
blockquote.indentedblock {margin-right: 0em}
blockquote.smallindentedblock {margin-right: 0em; font-size: smaller}
blockquote.smallquotation {font-size: smaller}
div.display {margin-left: 3.2em}
div.example {margin-left: 3.2em}
div.lisp {margin-left: 3.2em}
div.smalldisplay {margin-left: 3.2em}
div.smallexample {margin-left: 3.2em}
div.smalllisp {margin-left: 3.2em}
kbd {font-style: oblique}
pre.display {font-family: inherit}
pre.format {font-family: inherit}
pre.menu-comment {font-family: serif}
pre.menu-preformatted {font-family: serif}
pre.smalldisplay {font-family: inherit; font-size: smaller}
pre.smallexample {font-size: smaller}
pre.smallformat {font-family: inherit; font-size: smaller}
pre.smalllisp {font-size: smaller}
span.nolinebreak {white-space: nowrap}
span.roman {font-family: initial; font-weight: normal}
span.sansserif {font-family: sans-serif; font-weight: normal}
ul.no-bullet {list-style: none}
-->
</style>
</head>
<body lang="en">
<a name="Tips"></a>
<div class="header">
<p>
Next: <a href="Sample-Texinfo-Files.html#Sample-Texinfo-Files" accesskey="n" rel="next">Sample Texinfo Files</a>, Previous: <a href="_0040_002dCommand-Details.html#g_t_0040_002dCommand-Details" accesskey="p" rel="prev">@-Command Details</a>, Up: <a href="index.html#Top" accesskey="u" rel="up">Top</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Command-and-Variable-Index.html#Command-and-Variable-Index" title="Index" rel="index">Index</a>]</p>
</div>
<hr>
<a name="Tips-and-Hints"></a>
<h2 class="appendix">Appendix B Tips and Hints</h2>
<p>Here are some tips for writing Texinfo documentation:
</p>
<a name="index-Tips"></a>
<a name="index-Usage-tips"></a>
<a name="index-Hints"></a>
<ul>
<li> Write in the present tense, not in the past or the future.
</li><li> Write actively! For example, write “We recommend that …” rather
than “It is recommended that …”.
</li><li> Use 70 or 72 as your fill column. Longer lines are hard to read.
</li><li> Include a copyright notice and copying permissions.
</li></ul>
<a name="Index_002c-Index_002c-Index_0021"></a>
<h4 class="subsubheading">Index, Index, Index!</h4>
<p>Write many index entries, in different ways.
Readers like indices; they are helpful and convenient.
</p>
<p>Although it is easiest to write index entries as you write the body of
the text, some people prefer to write entries afterwards. In either
case, write an entry before the paragraph to which it applies. This
way, an index entry points to the first page of a paragraph that is
split across pages.
</p>
<p>Here are more index-related hints we have found valuable:
</p>
<ul>
<li> Write each index entry differently, so each entry refers to a different
place in the document.
</li><li> Write index entries only where a topic is discussed significantly. For
example, it is not useful to index “debugging information” in a
chapter on reporting bugs. Someone who wants to know about debugging
information will certainly not find it in that chapter.
</li><li> Consistently capitalize the first word of every concept index entry,
or else consistently use lowercase. Terse entries often call for
lowercase; longer entries for capitalization. Whichever case
convention you use, please use one or the other consistently! Mixing
the two styles looks bad.
</li><li> Always capitalize or use uppercase for those words in an index for
which this is proper, such as names of countries or acronyms. Always
use the appropriate case for case-sensitive names, such as those in C or
Lisp.
</li><li> Write the indexing commands that refer to a whole section immediately
after the section command, and write the indexing commands that refer to
a paragraph before that paragraph.
<p>In the example that follows, a blank line comes after the index
entry for “Leaping”:
</p>
<div class="example">
<pre class="example">@section The Dog and the Fox
@cindex Jumping, in general
@cindex Leaping
@cindex Dog, lazy, jumped over
@cindex Lazy dog jumped over
@cindex Fox, jumps over dog
@cindex Quick fox jumps over dog
The quick brown fox jumps over the lazy dog.
</pre></div>
<p>(Note that the example shows entries for the same concept that are
written in different ways—‘<samp>Lazy dog</samp>’, and ‘<samp>Dog, lazy</samp>’—so
readers can look up the concept in different ways.)
</p></li></ul>
<a name="Blank-Lines"></a>
<h4 class="subsubheading">Blank Lines</h4>
<ul>
<li> Insert a blank line between a sectioning command and the first following
sentence or paragraph, or between the indexing commands associated with
the sectioning command and the first following sentence or paragraph, as
shown in the tip on indexing. It makes the source easier to read.
</li><li> Always insert a blank line before a <code>@table</code> command and after an
<code>@end table</code> command; but never insert a blank line after an
<code>@table</code> command.
<p>For example,
</p>
<div class="example">
<pre class="example">Types of fox:
@table @samp
@item Quick
Jump over lazy dogs.
</pre><pre class="example">
</pre><pre class="example">@item Brown
Also jump over lazy dogs.
@end table
</pre><pre class="example">@noindent
On the other hand, …
</pre></div>
<p>Insert blank lines before and after <code>@itemize</code> … <code>@end
itemize</code> and <code>@enumerate</code> … <code>@end enumerate</code> in the
same way.
</p></li></ul>
<a name="Complete-Phrases"></a>
<h4 class="subsubheading">Complete Phrases</h4>
<p>Complete phrases are easier to read than …
</p>
<ul>
<li> Write entries in an itemized list as complete sentences; or at least, as
complete phrases. Incomplete expressions … awkward … like
this.
</li><li> Write the prefatory sentence or phrase for a multi-item list or table as
a complete expression. Do not write “You can set:”; instead, write
“You can set these variables:”. The former expression sounds cut off.
</li></ul>
<a name="Editions_002c-Dates-and-Versions"></a>
<h4 class="subsubheading">Editions, Dates and Versions</h4>
<p>Include edition numbers, version numbers, and dates in the
<code>@copying</code> text (for people reading the Texinfo file, and for the
legal copyright in the output files). Then use <code>@insertcopying</code>
in the <code>@titlepage</code> section for people reading the printed
output (see <a href="Short-Sample.html#Short-Sample">Short Sample</a>).
</p>
<p>It is easiest to handle such version information using <code>@set</code>
and <code>@value</code>. See <a href="_0040value-Example.html#g_t_0040value-Example"><code>@value</code> Example</a>, and <a href="GNU-Sample-Texts.html#GNU-Sample-Texts">GNU Sample Texts</a>.
</p>
<a name="Definition-Commands-2"></a>
<h4 class="subsubheading">Definition Commands</h4>
<p>Definition commands are <code>@deffn</code>, <code>@defun</code>,
<code>@defmac</code>, and the like, and enable you to write descriptions in
a uniform format.
</p>
<ul>
<li> Write just one definition command for each entity you define with a
definition command. The automatic indexing feature creates an index
entry that leads the reader to the definition.
</li><li> Use <code>@table</code> … <code>@end table</code> in an appendix that
contains a summary of functions, not <code>@deffn</code> or other definition
commands.
</li></ul>
<a name="Capitalization"></a>
<h4 class="subsubheading">Capitalization</h4>
<ul>
<li> Capitalize “Texinfo”; it is a name. Do not write the ‘<samp>x</samp>’ or
‘<samp>i</samp>’ in uppercase.
</li><li> Capitalize “Info”; it is a name.
</li><li> Write TeX using the <code>@TeX{}</code> command. Note the uppercase
‘<samp>T</samp>’ and ‘<samp>X</samp>’. This command causes the formatters to
typeset the name according to the wishes of Donald Knuth, who wrote
TeX. (Likewise <code>@LaTeX{}</code> for LaTeX.)
</li></ul>
<a name="Spaces"></a>
<h4 class="subsubheading">Spaces</h4>
<p>Do not use spaces to format a Texinfo file, except inside of
<code>@example</code> … <code>@end example</code> and other literal
environments and commands.
</p>
<p>For example, TeX fills the following:
</p>
<div class="example">
<pre class="example"> @kbd{C-x v}
@kbd{M-x vc-next-action}
Perform the next logical operation
on the version-controlled file
corresponding to the current buffer.
</pre></div>
<p>so it looks like this:
</p>
<blockquote>
<p>‘C-x v’ ‘M-x vc-next-action’ Perform the next logical operation on the
version-controlled file corresponding to the current buffer.
</p></blockquote>
<p>In this case, the text should be formatted with
<code>@table</code>, <code>@item</code>, and <code>@itemx</code>, to create a table.
</p>
<a name="g_t_0040code_002c-_0040samp_002c-_0040var_002c-and-_002d_002d_002d"></a>
<h4 class="subsubheading">@code, @samp, @var, and ‘<samp>---</samp>’</h4>
<ul>
<li> Use <code>@code</code> around Lisp symbols, including command names.
For example,
<div class="example">
<pre class="example">The main function is @code{vc-next-action}, …
</pre></div>
</li><li> Avoid putting letters such as ‘<samp>s</samp>’ immediately after an
‘<samp>@code</samp>’. Such letters look bad.
</li><li> Use <code>@var</code> around meta-variables. Do not write angle brackets
around them.
</li><li> Use three hyphens in a row, ‘<samp>---</samp>’, to indicate a long dash. TeX
typesets these as a long dash and the Info formatters reduce three
hyphens to two.
</li></ul>
<a name="Periods-Outside-of-Quotes"></a>
<h4 class="subsubheading">Periods Outside of Quotes</h4>
<p>Place periods and other punctuation marks <em>outside</em> of quotations,
unless the punctuation is part of the quotation. This practice goes
against some publishing conventions in the United States, but enables the
reader to distinguish between the contents of the quotation and the
whole passage.
</p>
<p>For example, you should write the following sentence with the period
outside the end quotation marks:
</p>
<div class="example">
<pre class="example">Evidently, ‘<samp>au</samp>’ is an abbreviation for ``author''.
</pre></div>
<p>since ‘<samp>au</samp>’ does <em>not</em> serve as an abbreviation for
‘<samp>author.</samp>’ (with a period following the word).
</p>
<a name="Introducing-New-Terms"></a>
<h4 class="subsubheading">Introducing New Terms</h4>
<ul>
<li> Introduce new terms so that a reader who does not know them can
understand them from context; or write a definition for the term.
<p>For example, in the following, the terms “check in”, “register” and
“delta” are all appearing for the first time; the example sentence should be
rewritten so they are understandable.
</p>
<blockquote>
<p>The major function assists you in checking in a file to your
version control system and registering successive sets of changes to
it as deltas.
</p></blockquote>
</li><li> Use the <code>@dfn</code> command around a word being introduced, to indicate
that the reader should not expect to know the meaning already, and
should expect to learn the meaning from this passage.
</li></ul>
<a name="Program-Invocation-Nodes"></a>
<h4 class="subsubheading">Program Invocation Nodes</h4>
<p>You can invoke programs such as Emacs, GCC, and <code>gawk</code> from a
shell. The documentation for each program should contain a section that
describes this. Unfortunately, if the node names and titles for these
sections are all different, they are difficult for users to find.
</p>
<p>So, there is a convention to name such sections with a phrase beginning
with the word ‘Invoking’, as in ‘Invoking Emacs’; this way, users can
find the section easily.
</p>
<a name="ANSI-C-Syntax"></a>
<h4 class="subsubheading">ANSI C Syntax</h4>
<p>When you use <code>@example</code> to describe a C function’s calling
conventions, use the ANSI C syntax, like this:
</p>
<div class="example">
<pre class="example">void dld_init (char *@var{path});
</pre></div>
<p>And in the subsequent discussion, refer to the argument values by
writing the same argument names, again highlighted with
<code>@var</code>.
</p>
<p>Avoid the obsolete style that looks like this:
</p>
<div class="example">
<pre class="example">#include <dld.h>
dld_init (path)
char *path;
</pre></div>
<p>Also, it is best to avoid writing <code>#include</code> above the
declaration just to indicate that the function is declared in a
header file. The practice may give the misimpression that the
<code>#include</code> belongs near the declaration of the function. Either
state explicitly which header file holds the declaration or, better
yet, name the header file used for a group of functions at the
beginning of the section that describes the functions.
</p>
<a name="texi_002delements_002dby_002dsize"></a><a name="Node-Length"></a>
<h4 class="subsubheading">Node Length</h4>
<p>Keep nodes (sections) to a reasonable length, whatever reasonable
might be in the given context. Don’t hesitate to break up long nodes
into subnodes and have an extensive tree structure; that’s what it’s
there for. Many times, readers will probably try to find a single
specific point in the manual, using search, indexing, or just plain
guessing, rather than reading the whole thing from beginning to end.
</p>
<p>You can use the <code>texi-elements-by-size</code> utility to see a list
of all nodes (or sections) in the document, sorted by size (either
lines or words), to find candidates for splitting. It’s in the
<samp>util/</samp> subdirectory of the Texinfo sources.
</p>
<a name="Bad-Examples"></a>
<h4 class="subsubheading">Bad Examples</h4>
<p>Here are several examples of bad writing to avoid:
</p>
<p>In this example, say, “ … you must <code>@dfn</code>{check
in} the new version.” That flows better.
</p>
<blockquote>
<p>When you are done editing the file, you must perform a
<code>@dfn</code>{check in}.
</p></blockquote>
<p>In the following example, say, “… makes a unified interface such as VC
mode possible.”
</p>
<blockquote>
<p>SCCS, RCS and other version-control systems all perform similar
functions in broadly similar ways (it is this resemblance which makes
a unified control mode like this possible).
</p></blockquote>
<p>And in this example, you should specify what ‘it’ refers to:
</p>
<blockquote>
<p>If you are working with other people, it assists in coordinating
everyone’s changes so they do not step on each other.
</p></blockquote>
<a name="And-Finally-_2026"></a>
<h4 class="subsubheading">And Finally …</h4>
<ul>
<li> Pronounce TeX as if the ‘<samp>X</samp>’ were a Greek ‘chi’, as the last
sound in the name ‘Bach’. But pronounce Texinfo as in ‘speck’:
“teckinfo”.
</li><li> Write notes for yourself at the very end of a Texinfo file after the
<code>@bye</code>. None of the formatters process text after the
<code>@bye</code>; it is as if the text were within <code>@ignore</code> …
<code>@end ignore</code>.
</li></ul>
<hr>
<div class="header">
<p>
Next: <a href="Sample-Texinfo-Files.html#Sample-Texinfo-Files" accesskey="n" rel="next">Sample Texinfo Files</a>, Previous: <a href="_0040_002dCommand-Details.html#g_t_0040_002dCommand-Details" accesskey="p" rel="prev">@-Command Details</a>, Up: <a href="index.html#Top" accesskey="u" rel="up">Top</a> [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Command-and-Variable-Index.html#Command-and-Variable-Index" title="Index" rel="index">Index</a>]</p>
</div>
</body>
</html>
|