/usr/share/doc/texinfo/html/Image-Syntax.html is in texinfo-doc-nonfree 4.13a-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 | <html lang="en">
<head>
<title>Image Syntax - GNU Texinfo 4.13</title>
<meta http-equiv="Content-Type" content="text/html">
<meta name="description" content="GNU Texinfo 4.13">
<meta name="generator" content="makeinfo 4.13">
<link title="Top" rel="start" href="index.html#Top">
<link rel="up" href="Images.html#Images" title="Images">
<link rel="next" href="Image-Scaling.html#Image-Scaling" title="Image Scaling">
<link href="http://www.gnu.org/software/texinfo/" rel="generator-home" title="Texinfo Homepage">
<!--
This manual is for GNU Texinfo (version 4.13, 18 September 2008),
a documentation system that can produce both online information and a
printed manual from a single source.
Copyright (C) 1988, 1990, 1991, 1992, 1993, 1995, 1996, 1997,
1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
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.2 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 are free to copy and modify
this GNU Manual. Buying copies from GNU Press supports the FSF in
developing GNU and promoting software freedom.''
-->
<meta http-equiv="Content-Style-Type" content="text/css">
<style type="text/css"><!--
pre.display { font-family:inherit }
pre.format { font-family:inherit }
pre.smalldisplay { font-family:inherit; font-size:smaller }
pre.smallformat { font-family:inherit; font-size:smaller }
pre.smallexample { font-size:smaller }
pre.smalllisp { font-size:smaller }
span.sc { font-variant:small-caps }
span.roman { font-family:serif; font-weight:normal; }
span.sansserif { font-family:sans-serif; font-weight:normal; }
--></style>
</head>
<body>
<div class="node">
<a name="Image-Syntax"></a>
<p>
Next: <a rel="next" accesskey="n" href="Image-Scaling.html#Image-Scaling">Image Scaling</a>,
Up: <a rel="up" accesskey="u" href="Images.html#Images">Images</a>
<hr>
</div>
<h4 class="subsection">12.2.1 Image Syntax</h4>
<p>Here is the synopsis of the <code>@image</code> command:
<pre class="example"> @image{<var>filename</var><span class="roman">[,</span> <var>width</var><span class="roman">[,</span> <var>height</var><span class="roman">[,</span> <var>alttext</var><span class="roman">[, </span><var>extension</var><span class="roman">]]]]</span>}
</pre>
<p><a name="index-Formats-for-images-579"></a><a name="index-Image-formats-580"></a>The <var>filename</var> argument is mandatory, and must not have an
extension, because the different processors support different formats:
<ul>
<li><a name="index-eps-image-format-581"></a>TeX reads the file <samp><var>filename</var><span class="file">.eps</span></samp> (Encapsulated PostScript
format).
<li><a name="index-pdftex_0040r_007b_002c-and-images_007d-582"></a><a name="index-png-image-format-583"></a><a name="index-jpeg-image-format-584"></a><a name="index-pdf-image-inclusions-585"></a>pdfTeX reads <samp><var>filename</var><span class="file">.png</span></samp>, <samp><var>filename</var><span class="file">.jpg</span></samp>,
<samp><var>filename</var><span class="file">.jpeg</span></samp>, or <samp><var>filename</var><span class="file">.pdf</span></samp> (in that
order). It also tries uppercase versions of the extensions. The PDF
format cannot support EPS images, so they must be converted first.
<li><code>makeinfo</code> includes <samp><var>filename</var><span class="file">.txt</span></samp> verbatim for
Info output (more or less as if it was an <code>@example</code>).
<li><code>makeinfo</code> uses the optional fifth argument <var>extension</var> to
<code>@image</code> for the filename extension, if it is specified. For example:
<p><a name="index-XPM-image-format-586"></a>
<pre class="example"> @image{foo,,,,.xpm}
</pre>
<p class="noindent">will cause <code>makeinfo</code> to look for <samp><span class="file">foo.xpm</span></samp> before any others.
</ul>
<p>The <var>width</var> and <var>height</var> arguments are described in the next
section.
<p>For TeX output, if an image is the only thing in a paragraph it
will ordinarily be displayed on a line by itself, respecting the
current environment indentation, but without the normal paragraph
indentation. If you want it centered, use <code>@center</code>
(see <a href="titlefont-center-sp.html#titlefont-center-sp"><code>@titlefont @center @sp</code></a>).
<p><a name="index-Alt-attribute-for-images-587"></a><a name="index-Images_002c-alternate-text-for-588"></a><a name="index-g_t_002d-_0028in-image-alt-string_0029-589"></a>For HTML output, <code>makeinfo</code> sets the <dfn>alt attribute</dfn> for
inline images to the optional <var>alttext</var> (fourth) argument to
<code>@image</code>, if supplied. If not supplied, <code>makeinfo</code> uses
the full file name of the image being displayed. The <var>alttext</var> is
taken as Texinfo text, so special characters such as ‘<samp><span class="samp">"</span></samp>’ and
‘<samp><span class="samp"><</span></samp>’ and ‘<samp><span class="samp">&</span></samp>’ are escaped in the HTML and XML output; also,
you can get an empty <code>alt</code> string with <code>@-</code> (a command
that produces no output; see <a href="_002d-and-hyphenation.html#g_t_002d-and-hyphenation">- and hyphenation</a>).
<p>For Info output, the <code>alt</code> string is also processed as Texinfo
text and output. In this case, ‘<samp><span class="samp">\</span></samp>’ is escaped as ‘<samp><span class="samp">\\</span></samp>’ and
‘<samp><span class="samp">"</span></samp>’ as ‘<samp><span class="samp">\"</span></samp>’; no other escapes are done.
<p><a name="index-PNG-image-format-590"></a><a name="index-JPEG-image-format-591"></a>If you do not supply the optional <var>extension</var> (fifth) argument,
<code>makeinfo</code> first tries <samp><var>filename</var><span class="file">.png</span></samp>; if that does
not exist, it tries <samp><var>filename</var><span class="file">.jpg</span></samp>. If that does not exist
either, it complains.
<p>In Info output, <code>makeinfo</code> writes a reference to the binary image
file (trying <var>filename</var> suffixed with <samp><var>extension</var></samp>,
<samp><var>.extension</var></samp>, <samp><span class="file">.png</span></samp>, or <samp><span class="file">.jpg</span></samp>, in that order)
if one exists. It also literally includes the <samp><span class="file">.txt</span></samp> file if one
exists. This way, Info readers which can display images (such as the
Emacs Info browser, running under X) can do so, whereas Info readers
which can only use text (such as the standalone Info reader) can
display the textual version.
<p><a name="index-g_t_0040samp_007b_005e_0040_0040_005eH_007d-for-images-in-Info-592"></a>The implementation of this is to put the following construct into the
Info output:
<pre class="example"> ^@^H[image src="<var>binaryfile</var>" text="<var>txtfile</var>"
alt="<var>alttext</var> ... ^@^H]
</pre>
<p class="noindent">where ‘<samp><span class="samp">^@</span></samp>’ and ‘<samp><span class="samp">^H</span></samp>’ stand for the actual null and
backspace control characters. If one of the files is not present, the
corresponding argument is omitted.
<p>The reason for mentioning this here is that older Info browsers (this
feature was introduced in Texinfo version 4.6) will display the above
literally, which, although not pretty, should not be harmful.
</body></html>
|