PageRenderTime 41ms CodeModel.GetById 15ms RepoModel.GetById 1ms app.codeStats 0ms

/jEdit/tags/jedit-4-2-pre14/doc/users-guide/files.xml

#
XML | 554 lines | 539 code | 1 blank | 14 comment | 0 complexity | 6d027a4d7b77a40d9635fb3477ce60dc MD5 | raw file
Possible License(s): BSD-3-Clause, AGPL-1.0, Apache-2.0, LGPL-2.0, LGPL-3.0, GPL-2.0, CC-BY-SA-3.0, LGPL-2.1, GPL-3.0, MPL-2.0-no-copyleft-exception, IPL-1.0
  1. <!-- jEdit buffer-local properties: -->
  2. <!-- :tabSize=1:indentSize=1:noTabs=true:wrap=soft:maxLineLen=80: -->
  3. <!-- :xml.root=users-guide.xml: -->
  4. <chapter id="files"><title>Working With Files</title>
  5. <sect1 id="creating"><title>Creating New Files</title>
  6. <para>
  7. <guimenu>File</guimenu>&gt;<guimenuitem>New</guimenuitem> (shortcut:
  8. <keycap>C+n</keycap>) opens a new,
  9. empty, buffer.
  10. Another way to create a new file is to specify a non-existent file
  11. name when starting jEdit on the command line.
  12. A new file will be created on disk when the buffer is saved
  13. for the first time.
  14. </para>
  15. </sect1>
  16. <sect1 id="opening"><title>Opening Files</title>
  17. <para>
  18. <guimenu>File</guimenu>&gt;<guimenuitem>Open</guimenuitem> (shortcut: <keycap>C+o</keycap>) displays
  19. a file system browser dialog box and loads the specified file into a new
  20. buffer.
  21. </para>
  22. <para>
  23. Multiple files can be opened at once by holding down
  24. <keycap>Control</keycap> while clicking on them in the file system browser.
  25. The file system browser supports auto-completion;
  26. typing the first few characters of a listed file name will select the
  27. file.
  28. </para>
  29. <para>
  30. More advanced features of the file system browser are described in
  31. <xref linkend="vfs-browser"/>.
  32. </para>
  33. <para>
  34. The <guimenu>File</guimenu>&gt;<guimenuitem>Recent Files</guimenuitem> menu
  35. lists recently viewed files. When a recent file is opened, the caret
  36. is automatically moved to its previous location in that file.
  37. The number of recent files to remember can be changed and caret
  38. position saving can be disabled in the <guibutton>General</guibutton> pane of
  39. the <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  40. dialog box; see <xref linkend="general-pane" />.
  41. </para>
  42. <para>
  43. The <guimenu>Utilities</guimenu>&gt;<guimenuitem>Current Directory</guimenuitem>
  44. menu lists all files and directories in the current buffer's directory.
  45. Selecting a file opens it in a buffer for editing; selecting a directory
  46. opens it in the file system browser (see <xref linkend="vfs-browser" />).
  47. </para>
  48. <note>
  49. <para>
  50. Files that you do not have write access to are opened in read-only
  51. mode, where editing is not permitted.
  52. </para>
  53. </note>
  54. <tip>
  55. <para>
  56. jEdit supports transparent editing of GZipped files; if a file begins with
  57. the GZip <quote>magic number</quote>, it is automatically decompressed
  58. before loading and compressed when saving. To compress an existing file,
  59. you need to change a setting in the
  60. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Buffer Options</guimenuitem>
  61. dialog box; see <xref linkend="buffer-opts"/> for details.
  62. </para>
  63. </tip>
  64. </sect1>
  65. <sect1 id="saving"><title>Saving Files</title>
  66. <para>
  67. Changed made in a buffer do not affect the file on disk until the
  68. buffer is <firstterm>saved</firstterm>.
  69. </para>
  70. <para>
  71. <guimenu>File</guimenu>&gt;<guimenuitem>Save</guimenuitem> (shortcut:
  72. <keycap>C+s</keycap>)
  73. saves the current buffer to disk.
  74. </para>
  75. <para>
  76. <guimenu>File</guimenu>&gt;<guimenuitem>Save As</guimenuitem> renames
  77. the buffer and saves it in a new location. Note that
  78. using this command to save over another open buffer will close the other
  79. buffer, to stop two buffers from being able to share the same path name.
  80. </para>
  81. <para>
  82. <guimenu>File</guimenu>&gt;<guimenuitem>Save a Copy As</guimenuitem> saves
  83. the buffer to different location but does not rename it., but doesn't rename the
  84. buffer, and doesn't clear the <quote>modified</quote> flag. Note that
  85. using this command to save over another open buffer will automatically reload
  86. the other buffer.
  87. </para>
  88. <para>
  89. <guimenu>File</guimenu>&gt;<guimenuitem>Save All</guimenuitem>
  90. (shortcut: <keycap>C+e C+s</keycap>) saves all
  91. open buffers to disk, asking for confirmation first. The confirmation dialog can be disabled in the <guilabel>General</guilabel> pane of the <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem> dialog box.
  92. </para>
  93. <sect2><title>Two-Stage Save</title>
  94. <para>
  95. To prevent data loss in the unlikely case that jEdit should crash in the
  96. middle of saving a file, files are first saved to a temporary file named
  97. <filename>#<replaceable>filename</replaceable>#save#</filename>. If this
  98. operation is successful, the original file is replaced with the temporary
  99. file.
  100. </para>
  101. <para>
  102. However, in some situations, this behavior is undesirable. For example,
  103. on Unix this creates a new i-node so while jEdit retains file permissions, the owner and group of the
  104. file are reset, and if it is a hard link the link is broken. The
  105. <quote>two-stage save</quote> feature can be disabled in the <guibutton>General</guibutton>
  106. pane of the
  107. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  108. dialog box; see <xref linkend="general-pane"/>.
  109. </para>
  110. </sect2>
  111. <sect2 id="autosave"><title>Autosave and Crash Recovery</title>
  112. <para>
  113. The autosave feature protects your work from computer crashes and
  114. such. Every 30 seconds, all buffers with unsaved changes are
  115. written out to their respective file names, enclosed in hash
  116. (<quote>#</quote>) characters. For example, <filename>program.c</filename>
  117. will be autosaved to <filename>#program.c#</filename>.
  118. </para>
  119. <para>
  120. Saving a buffer using
  121. one of the commands in the previous section automatically deletes the
  122. autosave file, so they will only ever be visible in the unlikely
  123. event of a jEdit (or operating system) crash.
  124. </para>
  125. <para>
  126. If an autosave file is
  127. found while a buffer is being loaded, jEdit will offer to recover the
  128. autosaved data.
  129. </para>
  130. <para>
  131. The autosave interval can be changed
  132. in the <guibutton>Autosave and Backup</guibutton> pane of the
  133. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  134. dialog box; see <xref linkend="autosave-backups-pane" />.
  135. </para>
  136. </sect2>
  137. <sect2 id="backups"><title>Backups</title>
  138. <para>
  139. The backup feature can be used to roll back to the previous version
  140. of a file after changes were made. When a buffer is saved
  141. for the first time after being opened, its original contents are
  142. <quote>backed up</quote> under a different file name.
  143. </para>
  144. <para>
  145. The behavior of the backup feature is specified in the <guibutton>Autosave and Backup</guibutton> pane of the
  146. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  147. dialog box; see <xref linkend="autosave-backups-pane"/>.`
  148. </para>
  149. <para>
  150. The default behavior is to back up the original contents
  151. to the buffer's file name suffixed with a tilde (<quote>~</quote>).
  152. For example, a file named <filename>paper.tex</filename> is backed up to
  153. <filename>paper.tex~</filename>.
  154. </para>
  155. <itemizedlist>
  156. <listitem><para>
  157. The <guilabel>Max number of backups</guilabel> setting determines the
  158. number of backups to save. Setting this to zero disables the backup
  159. feature. Settings this to more than one adds numbered suffixes to file
  160. names. By default only one backup is saved.
  161. </para>
  162. </listitem>
  163. <listitem><para>
  164. If the <guilabel>Backup directory</guilabel> setting is non-empty, backups
  165. are saved in that location. Otherwise, they are saved in the same directory
  166. as the original file. The latter is the default behavior.
  167. </para>
  168. </listitem>
  169. <listitem><para>
  170. The <guilabel>Backup filename prefix</guilabel> setting is the prefix that
  171. is added to the backed-up file name. This is empty by default.
  172. </para></listitem>
  173. <listitem><para>
  174. The <guilabel>Backup filename suffix</guilabel> setting is the suffix that
  175. is added to the backed-up file name. This is <quote>~</quote> by default.
  176. </para></listitem>
  177. <listitem><para>
  178. Backups can optionally be saved in a specified backup directory, instead of
  179. the directory of the original file. This can reduce clutter.
  180. </para></listitem>
  181. <listitem><para>
  182. The <guilabel>Backup on every save</guilabel> option is off by default,
  183. which results in a backup only being created the first time a buffer is
  184. saved in an editing session. If switched on, backups are
  185. created every time a buffer is saved.
  186. </para></listitem>
  187. </itemizedlist>
  188. </sect2>
  189. </sect1>
  190. <sect1 id="line-separators"><title>Line Separators</title>
  191. <para>
  192. Unix systems use newlines (<literal>\n</literal>) to mark line endings in
  193. text files. The MacOS uses carriage-returns (<literal>\r</literal>).
  194. Windows uses a carriage-return followed by a newline
  195. (<literal>\r\n</literal>). jEdit can read and write files in all three formats.
  196. </para>
  197. <para>
  198. The line separator used by the in-memory representation of file
  199. contents is always the newline character.
  200. When a file is being loaded, the line separator used in the file on disk
  201. is stored in a per-buffer property, and all line-endings are converted to
  202. newline characters for the in-memory representation.
  203. When the buffer is consequently saved, the value of the property replaces
  204. newline characters when the buffer is saved to disk.
  205. </para>
  206. <para>
  207. There are several ways to change a buffer's line separator:
  208. </para>
  209. <itemizedlist>
  210. <listitem><para>In
  211. the <guimenu>Utilities</guimenu>&gt;<guimenuitem>Buffer
  212. Options</guimenuitem> dialog box. See <xref linkend="buffer-opts" />.</para>
  213. </listitem>
  214. <listitem><para>By clicking the line separator indicator in the status bar. See <xref linkend="status-bar"/>.</para></listitem>
  215. <listitem><para>
  216. From the keyboard, if a keyboard shortcut has been assigned to the <guimenuitem>Toggle Line Separator</guimenuitem> command in the <guibutton>Shortcuts</guibutton> pane of the
  217. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  218. dialog box. By default, this command does not have a keyboard shortcut.
  219. </para></listitem>
  220. </itemizedlist>
  221. <para>
  222. By default, new files are saved with your operating system's native line
  223. separator. This can be changed in the
  224. <guibutton>General</guibutton> pane of the
  225. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  226. dialog box; see <xref linkend="general-pane" />. Note that changing this
  227. setting has no effect on existing files.
  228. </para>
  229. </sect1>
  230. <sect1 id="encodings"><title>Character Encodings</title>
  231. <para>
  232. A character encoding is a mapping from a set of characters to their on-disk representation. jEdit can use any encoding supported by the Java platform.
  233. </para>
  234. <para>
  235. Buffers in memory are always stored in <literal>UTF-16</literal> encoding, which means each character is mapped to an integer between 0 and 65535. <literal>UTF-16</literal> is the native encoding supported by Java, and has a large enough range of characters to support most human languages.
  236. </para>
  237. <para>
  238. When a buffer is loaded, it is converted from its on-disk representation to <literal>UTF-16</literal> using a specified encoding.
  239. </para>
  240. <para>
  241. The default encoding, used to load files for which no
  242. other encoding is specified, can be set in the <guibutton>General</guibutton> pane of the
  243. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  244. dialog box; see <xref linkend="general-pane"/>. Unless you change this setting, it will be your operating system's native encoding, for example <literal>MacRoman</literal> on the MacOS,
  245. <literal>windows-1252</literal> on Windows, and <literal>ISO-8859-1</literal> on
  246. Unix.
  247. </para>
  248. <para>
  249. An encoding can be explicitly set when opening a file in the file system browser's <guimenu>Commands</guimenu>&gt;<guisubmenu>Encoding</guisubmenu> menu.
  250. </para>
  251. <para>
  252. Note that there is no general way to auto-detect the encoding used by a file, however in a few cases it is possible:
  253. </para>
  254. <itemizedlist>
  255. <listitem><para><literal>UTF-16</literal> and <literal>UTF-8Y</literal> files are auto-detected, because they begin with a certain fixed character sequence. Note that plain UTF-8 does not mandate a specific header, and thus cannot be auto-detected, unless the file in question is an XML file.</para></listitem>
  256. <listitem><para>Encodings used in XML files with an XML PI like the following are auto-detected:</para>
  257. <programlisting><![CDATA[<?xml version="1.0" encoding="UTF-8">]]></programlisting>
  258. </listitem>
  259. </itemizedlist>
  260. <para>
  261. The encoding that will be used to save the current buffer is shown in the status bar, and can be changed in the <guimenu>Utilities</guimenu>&gt;<guimenuitem>Buffer
  262. Options</guimenuitem> dialog box. Note that changing this setting has no effect on the buffer's contents; if you opened a file with the wrong encoding and got garbage, you will need to reload it.
  263. </para>
  264. <para>
  265. If a file is opened
  266. without an explicit encoding specified and it appears in the recent file list,
  267. jEdit will use the encoding last used
  268. when working with that file; otherwise the default encoding will be used.
  269. </para>
  270. <sect2><title>Commonly Used Encodings</title>
  271. <para>
  272. While the world is slowly converging on UTF-8 and UTF-16 encodings for storing text, a wide range of older encodings are still in widespread use and Java supports most of them.
  273. </para>
  274. <para>
  275. The simplest character encoding still in use is ASCII, or <quote>American
  276. Standard Code for Information Interchange</quote>. ASCII encodes Latin
  277. letters used in English, in addition to numbers and a range of punctuation
  278. characters.
  279. Each each ASCII character consists of 7 bits, there is a limit of 128 distinct characters, which makes it unsuitable for anything other than English text. jEdit will load and save files as
  280. ASCII if the <literal>US-ASCII</literal> encoding is used.
  281. </para>
  282. <para>
  283. Because ASCII is unsuitable for international use, most operating
  284. systems use an 8-bit extension of ASCII, with the first 128 values
  285. mapped to the ASCII characters, and the rest used to encode accents, umlauts, and
  286. various more esoteric used typographical marks. The three
  287. major
  288. operating systems all extend ASCII in a different way. Files written by
  289. Macintosh programs can be read using the <literal>MacRoman</literal>
  290. encoding; Windows text files are usually stored as
  291. <literal>windows-1252</literal>. In the Unix world, the <literal>8859_1</literal>
  292. character encoding has found widespread usage.
  293. </para>
  294. <para>
  295. On Windows, various other encodings, referred to as <firstterm>code
  296. pages</firstterm> and identified by number, are used to
  297. store non-English text. The corresponding Java encoding name is
  298. <literal>windows-</literal> followed by the code page number, for example <literal>windows-850</literal>.
  299. </para>
  300. <para>
  301. Many common cross-platform international character sets are also supported;
  302. <literal>KOI8_R</literal> for Russian text, <literal>Big5</literal> and
  303. <literal>GBK</literal> for Chinese, and <literal>SJIS</literal> for
  304. Japanese.
  305. </para>
  306. </sect2>
  307. </sect1>
  308. <sect1 id="vfs-browser"><title>The File System Browser</title>
  309. <para>
  310. <guimenu>Utilities</guimenu>&gt;<guimenuitem>File System
  311. Browser</guimenuitem> displays the file system browser.
  312. By default, the file system browser is shown in a floating window. This window can be docked using the commands in its top-left corner popup menu; see <xref linkend="docking" />.
  313. </para>
  314. <para>
  315. The file system browser can be customized in the
  316. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  317. dialog box; see <xref linkend="vfs-browser-pane"/>.
  318. </para>
  319. <sect2><title>Navigating the File System</title>
  320. <para>
  321. The directory to browse is specified in the <guibutton>Path</guibutton> text
  322. field. Clicking the mouse in the text field automatically selects its
  323. contents allowing a new path to be quickly typed in. If a relative path is
  324. entered, it will be resolved relative to the current path. This text field
  325. remembers previously entered strings; see <xref linkend="history" />.
  326. The same list of previously browsed directories is also listed in the
  327. <guimenu>Utilities</guimenu>&gt;<guisubmenu>Recent Directories</guisubmenu>
  328. menu; selecting one opens it in the file system browser.
  329. </para>
  330. <para>
  331. To browse a listed directory, double-click it (or if you have a three-button
  332. mouse, you can click the middle mouse button as well). Alternatively, click
  333. the disclosure
  334. widget next to a directory to list its contents in place.
  335. To browse higher up in the directory hierarchy, double-click one of the parent
  336. directories in the parent directory list.
  337. </para>
  338. <para>
  339. Files and directories in the file list are shown in different colors
  340. depending on what glob patterns their names match. The patterns and colors
  341. can be customized in the
  342. <guibutton>File System Browser</guibutton>&gt;<guibutton>Colors</guibutton>
  343. pane of the
  344. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  345. dialog box.
  346. </para>
  347. <para>
  348. To see a specific set of files only (for example,
  349. those whose names end with <filename>.java</filename>), enter a glob pattern
  350. in the <guibutton>Filter</guibutton> text field.
  351. This text fields remembers previously entered strings.
  352. See <xref linkend="globs" /> for information about glob patterns.
  353. </para>
  354. <para>
  355. Unopened files can be opened by double-clicking (or by
  356. clicking the middle mouse button). Open files have their names underlined,
  357. and can be selected by single-clicking.
  358. Holding down <keycap>Shift</keycap>
  359. while opening a file will open it in a new view.
  360. </para>
  361. <para>
  362. Clicking a file or directory with the right mouse button displays a popup
  363. menu containing various commands. <!-- Note that attempting to delete
  364. a directory containing files will give an error;
  365. only empty directories can be deleted. -->
  366. </para>
  367. <tip>
  368. <para>
  369. The file list sorting algorithm used in jEdit handles numbers in file names
  370. in an intelligent manner. For example, a file named
  371. <filename>section10.xml</filename> will be placed after a file named
  372. <filename>section5.xml</filename>. A conventional letter-by-letter
  373. sort would have placed these two files in the wrong order.
  374. </para>
  375. </tip>
  376. </sect2>
  377. <sect2><title>The Tool Bar</title>
  378. <para>
  379. The file system browser has a tool bar containing a number of buttons.
  380. Each item in the <guibutton>Commands</guibutton>
  381. menu (described below) except
  382. <guimenuitem>Show Hidden Files</guimenuitem> and
  383. <guisubmenu>Encoding</guisubmenu> has a corresponding tool bar button.
  384. </para>
  385. </sect2>
  386. <sect2><title>The Commands Menu</title>
  387. <para>
  388. Clicking the <guibutton>Commands</guibutton> button displays a menu
  389. containing the following items:
  390. </para>
  391. <itemizedlist>
  392. <listitem><para><guimenuitem>Parent Directory</guimenuitem> - moves up in
  393. the directory hierarchy.</para></listitem>
  394. <listitem><para><guimenuitem>Reload Directory</guimenuitem> - reloads the
  395. file list from disk.</para></listitem>
  396. <listitem><para><guimenuitem>Root Directory</guimenuitem> - on Unix,
  397. goes to the root directory (<filename>/</filename>). On Windows and MacOS X,
  398. lists all mounted drives and network shares.</para></listitem>
  399. <listitem><para><guimenuitem>Home Directory</guimenuitem> - displays your
  400. home directory.</para></listitem>
  401. <listitem><para><guimenuitem>Directory of Current Buffer</guimenuitem> - displays the
  402. directory containing the currently active buffer.</para></listitem>
  403. <listitem><para><guimenuitem>New File</guimenuitem> - opens new, empty,
  404. buffer in the current directory. The file will
  405. not actually be created on disk until the buffer is saved.</para></listitem>
  406. <listitem><para><guimenuitem>New Directory</guimenuitem> - creates a new
  407. directory after prompting for the desired name.</para></listitem>
  408. <listitem><para><guimenuitem>Search in Directory</guimenuitem> -
  409. displays the search and
  410. replace dialog box set to search all files in the current directory. If a
  411. file is selected when this command is invoked, its extension becomes the
  412. file name filter for the search;
  413. otherwise, the file name filter entered in the browser is used.
  414. See <xref linkend="search-replace" /> for details.</para></listitem>
  415. <listitem><para><guimenuitem>Show Hidden Files</guimenuitem> - toggles if
  416. hidden files are to be shown in the file list.</para></listitem>
  417. <listitem><para><guisubmenu>Encoding</guisubmenu> - a menu for selecting
  418. the character encoding to use when opening files. See
  419. <xref linkend="encodings"/>.</para></listitem>
  420. </itemizedlist>
  421. </sect2>
  422. <sect2><title>The Plugins Menu</title>
  423. <para>
  424. Clicking the <guibutton>Plugins</guibutton> button displays a menu
  425. containing plugin commands. For information
  426. about plugins, see <xref linkend="using-plugins" />.
  427. </para>
  428. </sect2>
  429. <sect2><title>The Favorites Menu</title>
  430. <para>
  431. Clicking the <guibutton>Favorites</guibutton> button displays a menu
  432. showing all files and directories in the favorites list. The
  433. <guimenuitem>Add to Favorites</guimenuitem> item adds the currently selected file to the favorites list. If nothing is selected, the current directory is added. To remove
  434. a file from the favorites, invoke
  435. <guimenuitem>Edit Favorites</guimenuitem>, which will show the favorites
  436. list in the file system view, then select <guimenuitem>Delete</guimenuitem>
  437. from the right-click menu of the entry you want to remove.
  438. </para>
  439. </sect2>
  440. <sect2><title>Keyboard Shortcuts</title>
  441. <para>
  442. Completion behaves differently in file dialogs than in the stand-alone file system browser window.
  443. </para>
  444. <para>
  445. In the file dialog, keyboard input goes in the file name field by default. Pressing <keycap>Enter</keycap> opens the file or directory path that is either fully or partially entered in the file name field. Typing the first few characters of a file's name selects that file. If the file name field is empty and nothing is selected, <keycap>/</keycap> lists the root directory on Unix and the list of drives on Windows. There are two handy abbreviations that may be used in file paths: <keycap>~</keycap> expands to the home directory, and <keycap>-</keycap> expands to the current buffer's directory.
  446. </para>
  447. <para>
  448. For example, to open a file <filename>/home/slava/jEdit/doc/TODO.txt</filename>, you might enter <filename>~/j/d/to</filename>.
  449. </para>
  450. <para>
  451. In the stand-alone file system browser, keyboard input is handled slightly differently. There is no file name field, instead shortcuts are active when the file tree has keyboard focus. Additionally, pressing <keycap>/</keycap>, <keycap>~</keycap> or <keycap>-</keycap> always immediately goes to the root, home and current buffer's directory, respectively.
  452. </para>
  453. </sect2>
  454. </sect1>
  455. <sect1 id="reloading"><title>Reloading From Disk</title>
  456. <para>
  457. When a view is brought to the foreground, jEdit checks if any open buffers were modified on disk by another application. All affected buffers are listed in a dialog box. By default, buffers without unsaved changes are automatically reloaded.
  458. This feature can be disabled, or changed to prompt if files should be reloaded first, in the <guibutton>General</guibutton>
  459. pane of the
  460. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  461. dialog box; see <xref linkend="global-opts" />.
  462. </para>
  463. <para>
  464. <guimenu>File</guimenu>&gt;<guimenuitem>Reload</guimenuitem> can be used to
  465. reload the current buffer from disk at any other
  466. time; a confirmation dialog box will be displayed first if the buffer
  467. has unsaved changes.
  468. </para>
  469. <para>
  470. <guimenu>File</guimenu>&gt;<guimenuitem>Reload All</guimenuitem>
  471. discards unsaved changes in all open buffers and reload them from disk,
  472. asking for confirmation first.
  473. </para>
  474. </sect1>
  475. <sect1 id="threaded-io"><title>Multi-Threaded I/O</title>
  476. <para>
  477. To improve responsiveness and perceived performance,
  478. jEdit executes all buffer input/output operations asynchronously.
  479. While I/O is in progress, the status bar displays the number of
  480. remaining I/O operations.
  481. </para>
  482. <para>
  483. The <guimenu>Utilities</guimenu>&gt;<guisubmenu>Troubleshooting</guisubmenu>&gt;<guimenuitem>I/O
  484. Progress
  485. Monitor</guimenuitem> command displays a window with more detailed status
  486. information and progress meters. By default, the <guimenuitem>I/O Progress Monitor</guimenuitem> is shown in a floating window. This window can be docked using the commands in its top-left corner popup menu; see <xref linkend="docking" />. I/O requests can also be aborted in
  487. this window, however note that aborting a buffer save can result in data loss.
  488. </para>
  489. <!-- <para>
  490. By default, four I/O threads are created, which means that up
  491. to four buffers can be loaded or saved simultaneously. The number of
  492. threads can be changed in the
  493. <guibutton>Loading and Saving</guibutton> pane of the
  494. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global Options</guimenuitem>
  495. dialog box; see <xref linkend="global-opts" />. Setting the number to zero
  496. disables multi-threaded I/O completely; doing this is not recommended.
  497. </para> -->
  498. </sect1>
  499. <sect1 id="printing"><title>Printing</title>
  500. <para>
  501. <guimenu>File</guimenu>&gt;<guimenuitem>Print</guimenuitem>
  502. (shortcut: <keycap>C+p</keycap>)
  503. prints the current buffer.
  504. </para>
  505. <para>
  506. <guimenu>File</guimenu>&gt;<guimenuitem>Page Setup</guimenuitem>
  507. displays a dialog box for changing your operating system's print settings,
  508. such as margins, page size, print quality, and so on.
  509. </para>
  510. <para>
  511. The print output
  512. can be customized in the <guibutton>Printing</guibutton> pane of the
  513. <guimenu>Utilities</guimenu>&gt;<guimenuitem>Global
  514. Options</guimenuitem> dialog box; see <xref linkend="printing-pane"/>. The following settings can be changed:
  515. </para>
  516. <itemizedlist>
  517. <listitem><para>The font to use when printing.</para></listitem>
  518. <listitem><para>If a header with the file name should be printed on each
  519. page.</para></listitem>
  520. <listitem><para>If a footer with the page number and current date should be
  521. printed on each page.</para></listitem>
  522. <listitem><para>If line numbers should be printed.</para></listitem>
  523. <listitem><para>If the output should be color or black and white.</para></listitem>
  524. <listitem><para>The tab size to use when printing - this will usually be
  525. less than the text area tab size, to conserve space in the printed output.
  526. </para></listitem>
  527. </itemizedlist>
  528. </sect1>
  529. <sect1 id="closing-exiting"><title>Closing Files and Exiting jEdit</title>
  530. <para>
  531. <guimenu>File</guimenu>&gt;<guimenuitem>Close</guimenuitem>
  532. (shortcut: <keycap>C+w</keycap>)
  533. closes the current buffer. If it has unsaved changes, jEdit
  534. will ask if they should be saved first.
  535. </para>
  536. <para>
  537. <guimenu>File</guimenu>&gt;<guimenuitem>Close All</guimenuitem>
  538. (shortcut: <keycap>C+e C+w</keycap>)
  539. closes all buffers. If any buffers have unsaved
  540. changes, they will be listed in a dialog box where they can be saved
  541. or discarded. In the dialog box, multiple buffers to operate on at
  542. once can be selected by clicking on them in the list while holding
  543. down <keycap>Control</keycap>. After all buffers have been closed, a new
  544. untitled buffer is opened.
  545. </para>
  546. <para>
  547. <guimenu>File</guimenu>&gt;<guimenuitem>Exit</guimenuitem>
  548. (shortcut: <keycap>C+q</keycap>)
  549. will completely exit jEdit, prompting if unsaved buffers should be saved
  550. first.
  551. </para>
  552. </sect1>
  553. </chapter>