/jEdit/tags/jedit-4-1-pre5/doc/FAQ/faq-items2.xml

# · XML · 537 lines · 494 code · 37 blank · 6 comment · 0 complexity · a1957c36cc7de482cf51009235d47638 MD5 · raw file

  1. <!-- jEdit buffer-local properties: -->
  2. <!-- :indentSize=1:noTabs=true:maxLineLen=72:tab Size=2: -->
  3. <!-- jEdit FAQ -->
  4. <!-- Copyright (C) 2002 John Gellene -->
  5. <!-- $Id: faq-items2.xml 4044 2002-02-18 15:22:27Z jgellene $
  6. -->
  7. <sect1 id="installing-jedit"><title>Installing and Starting jEdit</title>
  8. <para>
  9. This section deals with installing jEdit using the Java-based
  10. installation program, as well as installation issues that are specific
  11. to particular operating systems. It also deals with problems
  12. encountered in starting up jEdit.
  13. </para>
  14. <qandaset defaultlabel="qanda">
  15. <qandadiv id="install-general">
  16. <title>General installation questions</title>
  17. <qandaentry>
  18. <question id="easy-howto-install"><para>
  19. What is the easiest way to install jEdit?
  20. </para></question>
  21. <answer><para>
  22. First, make sure you have a working installation of the Java platform.
  23. To run jEdit, you will a platform package having a version number of at least 1.3.
  24. Versions 1.3, 1.3.1 or 1.4 will all work. If you do not have the Java platform,
  25. we recommend downloading the larger <quote>Software Development Kit</quote> (SDK), instead of
  26. the smaller <quote>Java Runtime Environment</quote> (JRE), because you will need
  27. the tools supplied with the SDK if you will be using Java for development.
  28. You will need to know the path of the Java application launcher, which is
  29. called <filename>java.exe</filename> on Windows systems and simply
  30. <filename>java</filename> on others.
  31. </para>
  32. <para>
  33. Next, decide whether you want the current stable version or the latest
  34. development version. The stable version is a good choice for first-time
  35. users. Download the Java installer for the version you have chosen from
  36. the jEdit web site; it consists of a single file with a name in the
  37. style <filename>jeditXXXinstall.jar</filename>.
  38. This file is a compressed archive containing all of the files you need
  39. for jEdit to run as well as an installer application written in Java.
  40. You can put this file anywhere on your hard disk that is convenient.
  41. </para>
  42. <para>
  43. To run the installer, do whatever you normally do to run a Java jar
  44. archive. If this is your first time, follow these steps:
  45. </para>
  46. <procedure>
  47. <step><para>Open a terminal or command interpreter window.</para></step>
  48. <step><para>Change the current directory to the directory in which you
  49. have stored the jEdit installer file.</para></step>
  50. <step><para>Run this command:
  51. <userinput>[full path to java application launcher] -jar
  52. jeditXXXinstall.jar</userinput></para>
  53. </step>
  54. </procedure>
  55. <para>
  56. The installer will load and display a series of dialogs for selecting a
  57. few simple options, including the directory in which you wish jEdit
  58. installed. It will also tell you how much disk space you need for
  59. the main program and various installation options.
  60. </para>
  61. <para>
  62. If this is your first download of jEdit, you should definitely install
  63. the set of macros that come with the application. Many of them are
  64. useful for all programmers, and even the ones you don't use can
  65. serve as models when you eventually begin writing your own macros.
  66. </para>
  67. <para>
  68. The installation process is very short. If you are installing the
  69. program on Windows and you select the jEditLauncher option, you should
  70. be able to start jEdit by clicking on any of the icons that the
  71. installation program provides. On other systems, you can enter
  72. <userinput>jedit</userinput> in a terminal window or create your own
  73. desktop or menu shortcut.
  74. </para></answer>
  75. </qandaentry>
  76. <qandaentry>
  77. <question id="install-no-such-file"><para>
  78. What should I do when the installer displays the message,
  79. <screen>No such file or directory</screen>?
  80. </para></question>
  81. <answer><para>
  82. The full message that you may receive from the Java application launcher
  83. begins as follows:
  84. <screen>Exception in thread "main" java.util.zip.ZipException: No such file or directory
  85. ...</screen>
  86. This means that the Java application launcher cannot read the
  87. jar archive file that you specified on the command line. If your Java
  88. runtime environment otherwise runs properly, then either you have named
  89. the incorrect file name or the installation file is corrupt or
  90. incomplete. Check the file name, download the installer again if
  91. necessary, and be sure to follow any specific instructions for your
  92. operating system posted on the <ulink
  93. url="http://www.jedit.org">jEdit web site</ulink>.
  94. </para></answer>
  95. </qandaentry>
  96. <qandaentry>
  97. <question id="install-noclassdef">
  98. <para>
  99. After downloading <filename>jeditXXXinstall.jar</filename> (the
  100. <filename>XXX</filename> represents the version number), I tried to run
  101. <userinput>java jeditXXXinstall.jar</userinput>, but got the error message,
  102. <screen>Exception in main(), NoClassDefFoundError: jeditXXXinstall/jar.</screen> What am I doing wrong?
  103. </para>
  104. </question>
  105. <answer>
  106. <para>
  107. You need to specify the <userinput>-jar</userinput> option for the Java
  108. application loader so that the loader will search the installation archive
  109. for the starting class file. Without the option, it treats the archive as a
  110. single class file (which it is not!), thus producing the error. The correct
  111. command line would be <userinput>java -jar jeditXXXinstall.jar</userinput>.
  112. </para>
  113. </answer>
  114. </qandaentry>
  115. </qandadiv>
  116. <qandadiv id="install-linux">
  117. <title>Installing jEdit on Linux systems</title>
  118. <qandaentry>
  119. <question id="install-jedit-home">
  120. <para>
  121. After installing jEdit on Linux, running the <userinput>jedit</userinput>
  122. command causes the error message:
  123. <screen>Warning: JAVA_HOME environment variable not set</screen>
  124. How can I fix this?
  125. </para>
  126. </question>
  127. <answer>
  128. <para>
  129. Your <filename>jedit</filename> shell script should
  130. be modified to set the <userinput>JAVA_HOME</userinput> variable
  131. to the directory containing the executables of
  132. your desired Java runtime environment (JRE).
  133. </para>
  134. </answer>
  135. </qandaentry>
  136. <qandaentry>
  137. <question id="install-mandrake-kaffe">
  138. <para>
  139. How can I get jEdit to run on Mandrake Linux 8.1? When I try to start the
  140. program, I keep getting an error which begins as follows:
  141. <screen>java/lang/NoClassDefFoundError: Ljavax/swing/text/Document; at
  142. java.lang.reflect.Method.invoke(Method.java:native) at
  143. kaffe.jar.ExecJarName.main</screen>
  144. </para>
  145. </question>
  146. <answer>
  147. <para>
  148. This version of Mandrake Linux uses the Open Source Kaffe package as its default
  149. Java virtual machine. Kaffe is compliant with version 1.1 (and to a limited extent,
  150. version 1.2) of the Java platform. However, the latest version of jEdit, version 4.0, requires
  151. at least version 1.3. You will need to install another Java package for Linux
  152. (either Blackdown, IBM or Sun) that complies with at least version 1.3.
  153. </para>
  154. </answer>
  155. </qandaentry>
  156. <qandaentry>
  157. <question id="install-linux-keyboard">
  158. <para>
  159. I installed jEdit 3.2.2 from the RPM on Mandrake 8.1 and I am unable to send any
  160. keyboard inputs to jEdit. But the mouse interacts with the program just fine. I
  161. have tried running it on Sun's JDK 1.3.1 and Blackdown's latest JDK (Dec. 2001)
  162. without any luck.
  163. </para>
  164. </question>
  165. <answer>
  166. <para>
  167. This problem has been reported with various combinations of window managers and
  168. desktop environments. The IBM JDK has not been reported to have this problem. In
  169. addition, there have not been reported problems with the Sun and Blackdown JDK's
  170. when running under the Sawfish window manager.
  171. </para>
  172. </answer>
  173. </qandaentry>
  174. </qandadiv>
  175. <qandadiv id="install-mac">
  176. <title>Install jEdit on MacOS</title>
  177. <qandaentry>
  178. <question id="install.mac9-basic">
  179. <para>How do I install jEdit on MacOS 8 or MacOS 9?</para>
  180. </question>
  181. <answer>
  182. <para>
  183. The latest version of jEdit, version 4.0, requires MacOS X, because the
  184. Java platforms of earlier MacOS version out outdated.
  185. </para>
  186. <para>
  187. The followng steps outline how to install jEdit 3.2.2 on Mac OS 9.1
  188. and earlier.
  189. </para>
  190. <procedure>
  191. <step><para>Download and install JBinary which
  192. is part of the MRJ SDK 2.2 package available from Apple.</para></step>
  193. <step><para>Once jBinary is installed, drag the jEdit installer to
  194. JBinary and JBinary will launch.</para></step>
  195. <step><para>In the Command window in the Class path box replace
  196. <userinput>jedit322install,</userinput> with
  197. <userinput>installer.Install</userinput>.</para></step>
  198. <step><para>Then click the Run button. The installer will
  199. install jEdit on your system.</para></step>
  200. </procedure>
  201. <para>
  202. Once you have completed installing jEdit locate the jedit.jar
  203. file and do the following:
  204. </para>
  205. <procedure>
  206. <step><para>Drag the <filename>jedit.jar</filename> to JBinary
  207. and JBinary will launch.</para></step>
  208. <step><para>In the Command window in the Class path box replace
  209. <userinput>jedit</userinput> with
  210. <userinput>org.gjt.sp.jedit.jEdit</userinput>.</para></step>
  211. <step><para>Then click the Save settings button. It will ask
  212. for an application name and will create a double-clickable icon
  213. on your desktop.</para></step>
  214. <step><para>Double-click on your icon to launch jEdit.</para></step>
  215. </procedure>
  216. </answer>
  217. </qandaentry>
  218. </qandadiv>
  219. <qandadiv id="install-windows">
  220. <title>Installing jEdit on Windows</title>
  221. <qandaentry>
  222. <question id="install-windows-basic"><para>
  223. Is there anything different about installing jEdit on Windows?
  224. </para></question>
  225. <answer><para>
  226. For the Microsoft Windows family of operating systems, jEdit
  227. provides an additional package of features called jEditLauncher.
  228. These features include:
  229. <itemizedlist>
  230. <listitem><para>
  231. Built-in shortcut icons for launching jEdit;
  232. </para></listitem>
  233. <listitem><para>
  234. Support for opening files in jEdit using custom entries in
  235. the context (right-click) menu of the Windows shell;
  236. </para></listitem>
  237. <listitem><para>
  238. Support for running BeanShell scripts in jEdit from
  239. outside the application;
  240. </para></listitem>
  241. <listitem><para>
  242. Support for launching jEdit and loading files using
  243. scripting languages such as VBScript, Perl and Python;
  244. </para></listitem>
  245. <listitem><para>
  246. Automatic uninstallation of jEdit using the
  247. <quote>Add/Remove Programs</quote> applet in Control Panel.
  248. </para></listitem>
  249. </itemizedlist>
  250. The package is a recommended option that is selected by default when you
  251. install jEdit. The Java installer application launches a separate
  252. Windows installer module for the native Windows executables that
  253. comprise the jEditLauncher package. If the installation involves an
  254. upgrade, you may be asked to reboot your computer to complete the process.
  255. </para></answer>
  256. </qandaentry>
  257. <qandaentry>
  258. <question id="install-windows-components"><para>
  259. Do I need any special Windows components to run jEditLauncher?
  260. </para></question>
  261. <answer><para>
  262. Regardless of the version of Windows that you use, if you have kept it
  263. reasonably up-to-date with service packs or component upgrades from
  264. Microsoft, you should have no trouble running jEditLauncher.
  265. Users of Windows 98, Windows ME, Windows NT (version 4.0),
  266. Windows 2000 and Windows XP have not reported problems involving missing
  267. components.
  268. </para>
  269. <para>
  270. Some users of older versions of Windows 95 may need to upgrade their
  271. version of the Windows Sockets package. Others may be missing
  272. Microsoft's package for supporting DCOM (Distributed Component
  273. Object Model) components on Windows 95. Both the <ulink url=
  274. "http://www.microsoft.com/windows95/downloads/contents/wuadmintools/s_wunetworkingtools/w95sockets2/">
  275. Windows Sockets upgrade</ulink> and the <ulink
  276. url="http://www.microsoft.com/com/dcom/dcom95/dcom1_3.asp">
  277. DCOM package</ulink> are available for download from Microsoft.
  278. </para></answer>
  279. </qandaentry>
  280. <qandaentry>
  281. <question id="install-windows-vm"><para>
  282. Can I run jEdit on Microsoft's virtual machine?
  283. </para></question>
  284. <answer>
  285. <para>
  286. The latest version of jEdit, version 4.0, requires at least
  287. version 1.3 of the Java 2 platform, and therefore will not
  288. be compatible with Microsoft's virtual machine.
  289. </para>
  290. <para>
  291. You can run jEdit version 3.2.2 if you put Sun's Swing 1.1.1
  292. package in the classpath of Microsoft's Java application loaders
  293. <command>jview</command> or <command>wjview</command>.
  294. An article describing the advantages and disadvantages
  295. of doing this, and detailing the necessary procedures, may
  296. be found on the <ulink
  297. url="http://community.jedit.org/article.php?sid=14&amp;mode=&amp;order=0">jEdit
  298. Community</ulink> web site.
  299. </para>
  300. </answer>
  301. </qandaentry>
  302. <qandaentry>
  303. <question id="install-windows-badcommand">
  304. <para>
  305. When trying to install jEdit on Windows Me with an MS-DOS prompt, after entering
  306. <userinput>java -jar jeditXXXinstall.jar</userinput> I get the message
  307. <userinput>bad command or file name</userinput>.
  308. I have tried various alternatives but still cannot install.
  309. </para>
  310. </question>
  311. <answer>
  312. <para>
  313. You should confirm that you have a Java runtime environment installed, which
  314. will include <filename>java.exe</filename> and the version that omits a separate
  315. terminal window, <filename>javaw.exe</filename>. Make sure that the directory
  316. containing <filename>java.exe</filename> or <filename>javaw.exe</filename>is found
  317. in the value of your <filename>PATH</filename> environment variable.
  318. Otherwise you should give the full path to the chosen loader on your command line.
  319. </para>
  320. </answer>
  321. </qandaentry>
  322. <qandaentry>
  323. <question id="install-windows-errmessage">
  324. <para>
  325. After installing jEdit on Windows, when I try to run
  326. <filename>jedit.exe</filename> I get the message
  327. <screen>The JEditLauncher component does not appear to be installed.</screen>
  328. </para>
  329. </question>
  330. <answer>
  331. <para>
  332. The dialog presenting this message asks if you would like to install the
  333. launcher. Select <userinput>Yes</userinput> and supply further information
  334. as prompted. A file named <filename>install.log</filename> is generated in the
  335. same directory as <filename>jedit.exe</filename> that
  336. contains information on the launcher's installation. You can send this file
  337. along with jEdit's Activity Log if you continue to have problems running jEdit
  338. with the launcher package.
  339. </para>
  340. </answer>
  341. </qandaentry>
  342. <qandaentry>
  343. <question id="install-error-regkey">
  344. <para>
  345. When I try to run the jEdit installation package in Windows, I get an error
  346. message, <screen>Error opening registration key
  347. "software\javasoft\java runtime environment".</screen> How can I fix this?
  348. </para>
  349. </question>
  350. <answer>
  351. <para>
  352. The problem is not with jEdit but may be caused by your installation of the Java
  353. runtime environment. Under Windows, Sun's Java application loader relies on
  354. entries in the Windows registry to find the files that create the runtime
  355. environment and a Java virtual machine. The loader (<filename>java.exe</filename>e or
  356. <filename>javaw.exe</filename>) is
  357. unable to find the necessary registration entry and therefore sends the error
  358. message. The best approach to fixing this is to uninstall and reinstall the JDK.
  359. </para>
  360. </answer>
  361. </qandaentry>
  362. </qandadiv>
  363. <qandadiv id="problems-starting">
  364. <title>Problems starting jEdit</title>
  365. <qandaentry>
  366. <question id="wont-start"><para>
  367. jEdit won't start. What should I do?
  368. </para></question>
  369. <answer><para>
  370. If you don't have a clue as to why you cannot run jEdit, it's
  371. best to perform a step-by-step diagnosis. Begin by finding the
  372. Java application loader you are using: <filename>java.exe</filename>,
  373. <filename>javaw.exe</filename> or <filename>java</filename>. Make sure
  374. it is running by entering its full path with the <userinput>-h</userinput>
  375. parameter in a terminal or console window. If you can't find
  376. the Java application loader, your Java runtime environment package
  377. may be missing or incomplete.
  378. </para>
  379. <para>
  380. Next, find where you have installed jEdit. You should look
  381. for the file <filename>jedit.jar</filename> which contains all
  382. of the application's Java class files in a compressed archive.
  383. </para>
  384. <para>
  385. Once you have both files, run the Java loader with the
  386. <userinput>-jar</userinput> option and with
  387. <filename>jedit.jar</filename> as the target. Make sure that
  388. you either specify full paths for both files or that the
  389. directories for the files are part of your <filename>PATH</filename>
  390. environment variable. If jEdit does not load at this point, the likely
  391. problem is a corrupt <filename>jedit.jar</filename> file. Try
  392. downloading the application again.
  393. </para>
  394. <para>
  395. If jEdit does load using this procedure, you need to examine
  396. the <quote>shortcut</quote> loading mechanism you wish to use.
  397. </para>
  398. <para>
  399. On Linux and MacOS X, you need to find and examine the <filename>jedit</filename>
  400. shell script provided by the installation routine to confirm that the
  401. script's commands target the correct files and locations, and that
  402. variables like <filename>JAVA_HOME</filename> are either defined in the
  403. script or elsewhere in your shell's environment. Don't forget to make
  404. sure that the script's file permissions allow you to execute it as a shell script.
  405. </para>
  406. <para>
  407. On Windows, if you are using a batch script to run jEdit, the
  408. same points (other than file permissions) apply to examining
  409. <filename>jedit.bat</filename>. If you are using
  410. jEditLauncher, run <userinput>jedit /p</userinput> in jEdit's
  411. installation directory from a command line to get the custom
  412. loader's setup dialog. Here you can check the paths for both
  413. the Java application loader and jEdit as well as any command
  414. line parameters for both programs. Make sure that you have
  415. placed Java and jEdit options in the correct input fields.
  416. If the parameters seems correct
  417. but jEdit will not load with the Windows launcher, try
  418. uninstalling and reinstalling the launcher by running
  419. <userinput>jedit /u</userinput> followed by
  420. <userinput>jedit /i</userinput>.
  421. </para>
  422. <para>
  423. If at this point you're still stuck, ask for help on the
  424. jedit-users mailing list, the jEdit Community
  425. <quote>Installation</quote> message board or on IRC.
  426. You're bound to find someone quickly.
  427. </para>
  428. </answer>
  429. </qandaentry>
  430. <qandaentry>
  431. <question id="start-missing-plugins"><para>
  432. After jEdit starts, I can't see all of the plugins I have downloaded.
  433. How can I make them appear?
  434. </para></question>
  435. <answer><para>
  436. If you use jEdit's Plugin Manager to download and install plugins, your
  437. plugins will be found in the <filename>jars</filename> subdirectory of
  438. one of two directories: either the directory in which jEdit is
  439. installed, or the current user's settings directory. These are the only
  440. location jEdit examines when it loads plugins at startup.
  441. </para>
  442. <para>
  443. The default location of the settings directory depends on your operating
  444. system. You can find out its location during a jEdit session by
  445. evaluating <userinput>jedit.getSettingsDirectory()</userinput> in BeanShell.
  446. </para>
  447. <para>
  448. The settings directory can be changed by using the
  449. <userinput>-settings</userinput> command line parameter. If you change the
  450. location of the settings directory with this parameter, jEdit will not
  451. be able to find plugin archive files in the old location.
  452. If you use or change the <userinput>-settings</userinput>
  453. parameter, make sure your plugins don't get left behind.
  454. </para>
  455. </answer>
  456. </qandaentry>
  457. </qandadiv>
  458. <qandadiv id="problems-running-general">
  459. <title>General problems running jEdit</title>
  460. <qandaentry>
  461. <question id="problems-out-of-memory"><para>
  462. During an editing session I get a error message about an
  463. <quote>OutOfMemoryError</quote> while working with a large file or
  464. performing a lengthy operation. The message reappears every time
  465. I retry the operation. How can I prevent this?
  466. </para></question>
  467. <answer><para>
  468. One solution that often works is to set or increase the allocation of
  469. memory to the heap for Java objects created by the Java Virtual Machine
  470. in which jEdit is running. Add the command line option
  471. <userinput>-mxXXm</userinput> to the options passed to the version of
  472. the Java application loader you are using (such as
  473. <filename>java</filename>, <filename>java.exe</filename> or
  474. <filename>javaw.exe</filename>). In place of the
  475. <userinput>XX</userinput> in the option, use a multiple of 16
  476. between 32 and 128. If you already are using the option, increase the
  477. numeric portion of the <userinput>-mxXXm</userinput> parameter in
  478. increments of 16. Many users have good results using 48 or 64, but you
  479. should try different values for the best result on your installation.
  480. </para>
  481. <para>
  482. If you are using the <userinput>-jar</userinput> command line option
  483. with Java to run jEdit, remember that the <userinput>-jar</userinput>
  484. parameter must be the last Java option, followed immediately by the path
  485. to <filename>jedit.jar</filename> and then any jEdit command line options.
  486. </para>
  487. <para>
  488. If out of memory errors occur while running a build or compilation
  489. operation from within jEdit, you can also have the operation run in an
  490. external process rather than inside the same Java Virtual Machine
  491. running jEdit. The AntFarm plugin, for example, lets you select this
  492. approach as a configuration option. In other cases, you can run an
  493. external program using the command line interface of the Console plugin,
  494. which will capture and display the output of the external process and in
  495. many cases parse the output for error information.
  496. </para></answer>
  497. </qandaentry>
  498. </qandadiv>
  499. </qandaset>
  500. </sect1>