jEdit - programmer's & webmaster's text editor
jEdit is a excellent text editor, ideal for programming purposes. It’s the best HTML editor, CSS editor, PHP or RUBY editor, as well as Notepad replacement. As each computer program, jEdit has opponents and fans, pros and cons. Will it work for you? I bet you'll like it, but at least it's worth to give it a try.
Article content
In this tutorial you will find:
jEdit pros and cons
The best of all numerous advantages od jEdit is that everything in jEdit can be configured for individual preferences, everything can be adjusted, it can be taught to do everything you want it to.
Paradoxically, the same advantages are also it's main disadvantage. To configure jEdit properly you need some time. Spending precious time at start it's not an optimistic perspective so many users give up after pure jEdit considering it to be poor tool.
It's a big mistake, because jEdit is worth spending some time on installing valuable plugins, macros, configuring them, adjusting default preferences to work nice and effectively.
Videos and screenshots
Watch jEdit live on this playlist of screen captures:
Pros
Briefly, the main advantages of jEdit are:
- it's free, for commercial purposes also, open source released on GNU GPL
- it's cross-platform, it's written in Java so it works on various operating systems (Windows, Linux and Mac)
- it has powerful abilities to extend and adjusting to user preferences (all keyboard shortcuts, menu, offers recording of macros, writing own scripts)
- offers huge number of plugins extending jEdit capabilities (FTP connection, syntax autocomplete, project managing)
- it has extended search & replace mechanism based on regular expressions
- opposite to dedicated editors, jEdit supports very well numerous programing languages (Java, PHP, HTML, XML, CSS, C++, SQL, Ruby On Rails and many more)
- includes syntax highlighting for over 150 language modes
Cons
Generally speaking, jEdit has no disadvantages, but searching by force as disadvantages could be considered that:
- it's free, so it has no direct support from the author. Instead it it's available great support in the huge jEdit Community and extended help system.
- it's written in Java, so it runs slow on slower machines. Fortunately there is cure for it
- it's cross-platform, the GUI is not typical for the specyfic operating system
- there is no language versions (English interface, support for UNICODE)
- project site is in very poor condition
Installing jEdit
Installing jEdit on Linux
Linux packages are hosted at jEdit Homepage. Instructions on how to install jEdit on Ubuntu Linux can be found in Instalacja jEdita na Ubuntu (use Google Translate if you need English version). Once you installed it, you should begin the process of configuring jEdit.
Linux users usually know what they do, so i’ll write detailed instructions only for Windows users. Admittedly the install process is different, but the rules of configuration are the same. If you install jEdit on removable disk, it will work on the other operating systems as well.
Installing jEdit on Windows
Basic version of jEdit
jEdit requires Java environment to run. The best way to obtain Java is directly from Sun Microsystems site.
You can download latest jEdit installer from jEdit official site. I recommend you install latest development version (beta) which is better than official stable, beside authors make a stipulation that it can work unstable.
There is available a Windows install package (.exe), but I will describe how to install jEdit using Java based installer (.jar file), which does not require administrative rights.
jEdit is released under terms of GNU GPL.
As target directory I have choosen "C:\Program Files\jEdit" (different to default one).
When install wizard is complete, you can launch jEdit executing jedit.jar file (C:\Program Files\jEdit\jedit.jar)
During first launch you will see the valuable help window. There is also a tip of the day window displayed where you can learn some useful stuff.
jEdit Launcher
First thing you need is jEdit Launcher, which is an executable file starting jEdit. jEdit Launcher allows associate files specified files and adds useful commands to explorer’s context menu such as: "Open with jEdit", "Open *.ext with jEdit" and "Diff with jEdit" (JDiff plugin required).
Downloaded jEdit Launcher archive contains doc (documentation), bin (programms), src (source files) and config folders. Copy it to the location where jEdit is installed.
To use jEdit Shell Extension you it’s needed to register, jeditext.dll library, so go to:
start>run cmd Enter regsvr32 "c:\program files\jedit\bin\jeditext.dll" Enter
Once you properly registered this library, right clicking on a file on windows explorer you will see two new, very useful commands:"Open with jEdit" i "Open *.ext with jEdit", but using it requires configuring jEdit Launcher. You can do it in two ways:
- Running configuration wizard (C:\Program Files\jEdit\bin\jecfg.exe)
- Manually editing and running .reg file (C:\Program Files\jEdit\config\launcher.reg)
This is my configuration file (launcher.reg):
Windows Registry Editor Version 5.00 [HKEY_CURRENT_USER\Software\www.jedit.org\jEditLauncher\4.0] "Java Executable"="C:\\Program Files\\Java\\jre1.5.0_04\\bin\\javaw.exe" "Java Options"="-mx128m -jar" "jEdit Target"="C:\\Program Files\\jEdit\\jedit.jar" "jEdit Options"="-reuseview" "jEdit Working Directory"="C:\\Program Files\\jEdit\\"
Notice: Use double slashes as separators ("\\") in place traditional "\" separator
Associate with common used files
You can edit file associations in Windows Explorer (Win+E, Tools>Folder options...>File types).
If jedit.exe does not accept command line parameters, you can fix that by running following commands in Windows console:
cmd /c ftype exefile="%1" %* cmd /c assoc .exe=exefile regsvr32 /i shell32.dll
Configure jEdit
Global configuration
In menu "Utilities>Global options..." you can change settings which apply to all the files
jEdit>General
change: default character separator: Unix (\n) change: default character encoding: UTF-8 [Apply]jEdit>Encodings
Uncheck all encodings except those i use: UTF-8, ISO-8859-1, ISO-8859-2, Windows-1250, US-ASCIIjEdit>Editing
wrap margin: 100 tab width: 4 indent width: 4 word wrap: soft soft (emulated with spaces) tabs deep indent default editing mode: htmljEdit>Docking
File system browser>right
jEdit>Gutter
Enable line numberingjEdit>jEdit Plugin Manager
[Update mirror list] Europe: MESH-Solutions (Dusseldorf, Germany) (choose nearest to you)
jEdit>Shortcuts
Edit it as you like. You can find here some handy stuff.
"File system browser>default|show hidden files"
I prefer using bold font for edited text, which causes it to be better legible among tags which are displayed in normal weight. (Utilities>Global Options...>Text Area>Text font>Font style>bold) and gray color in place of black (Utilities>Global Options...>Text Area>Text color>RGB>70,70,70)
I use Andale Mono font which is also more legible than Terminal or commonly used Courier.
Startup speed up
As all programs written in Java jEdit startup takes some time. But it's not as bad as it could be. Here is some info from my Windows:
- jEdit with seven open buffers - 49,5 MB RAM
- Thunderbird 1.5 - 61,1 MB
- Firefox 2 - 68,8 MB
You can speed up jEdit by running a copy of jEdit server at Windows startup which is running in system background. To do so, you'll have to add to Autostart menu link to jEdit'a with two parameters: -background -nogui, for example: "C:\Program Files\jEdit\bin\jEdit.exe" -background -nogui
You can also disable displaying splash screen at startup (Uncheck "Show splash screen on startup" in "Utilities>Global Options...>Appearance"menu.
Installing plugins
Basically, "raw copy" of jEdit isn't ideal editor for programmers. But after installing full set of specific plugins shows how powerful jEdit is.
Plugins extending jEdit’s functionality are usually distributed as .jar archives. Most of jEdit plugins, sorted by category you will find in jEdit plugins repository.
jEdit is equipped with handy plugin manager which is the most comfortable way to download the plugins from repository. ("Plugins>Plugin manager..."). However, not all plugins are listed in plugins manager. You can google for some more or newer versions of the plugins.
To manually install plugin you have to place .jar archive to the plugins folder, accordingly:
- C:\Documents and Settings\user\.jedit\jars - only for this user
- C:\Program Files\jEdit\jars - install for all users
After placing .jar's to proper folder you have to enable plugin in Plugin Manager (Manage tab) and restart jEdit if necessary.
Most valuable plugins
Of course which plugin is the most valuable depends on what you want to do with jEdit. Most valuable for webdeveloper and programmer are:
BufferTabs
BufferTabs Plugin adds tabs at the bottom of the jEdit window, allowing to easily to switch between open files (buffers).
It's good to enable option: "Plugins>Plugin Options...>BufferTabs" > "Enable BufferTabs by default" (at start).
Ctags
In jEdit you can use tools based on Exuberant CTags. To do that, you should install CTags, then install and configure suitable plugins:
CTagsSidekick plugin adds features useful for program structure browsing (C, C++, Perl, Python, Bash, Java, JavaScript, Lisp, Make, PHP, Ruby, Scheme, SQL, YACC, XML, Ant, Cobol, Eiffel, AWK, Fortran and Pascal).
CtagsInterface plugin is a Ctags frontend.
First Mate
First Mate Plugin adds automatic closing of quotes and parenthesis, allows to change the default action at the end of line (for example insert colon and new line). Those features are known for TextMate Editor users.
FTP
FTP Plugin enables to open FTP connection for direct editing files on the remote server.
FTP Plugin requires some other plugins, which are installed by Plugin Manager automatically.
Easy to use: "File>Open>Plugins>FTP>Connect to FTP Server"
InfoViewer
InfoViewer Plugin adds ability to view edited file in integrated or external web browser.
To use external browser it is necessary to setup path in "Plugins>Plugin Options...>InfoViewer>Choose Browser>External Browser". (for example "C:\Program Files\Mozilla Firefox\firefox.exe", you can specify also additional command line parameters supported by browser).
It's useful to set keyboard shortcut, for example F10 to preview in browser
("Utilities>Global Options...>jEdit>Shortcuts|Plugin: InfoViewer|Open current buffer with browser|F10|[Apply]")
JDiff
JDiff PLugin is a visual diff utility for jEdit. Works great if you use it with "Diff with jEdit" shell extension context menu entry available within jEdit Launcher
JTidy
JTidy Plugin it's a HTML/XML code formatter. Checks and corrects the code. Very useful and handy tool. Requires XML plugin.
My settings for jTidy plugin
General
- Encoding: raw
- Tidy signature: off
- Markup: on
- No generated output: off
- Show warnings: on
- Quiet output: off
- Gnu Emacs error reporting style: on
- Write back files with tidied content: on
- Keep last modified time: on
Wrap/Indent
- Wrap: 100
- Wrap attributes: off
- Wrap scripts literals: off
- Wrap ASP: on
- Wrap JSTE: on
- Wrap PHP: on
- Tab size: 4
- Indent: auto
- Indent spaces: 4
- Indent attributes: off
- Literal attributes: off
Format
- all off, except:
- Quote marks
- Quote non-breaking spaces
- Quote ampersands
Clean
- all off, except:
- Fix backslashes
- Drop empty paragraphs
- Fix Coldfusion elements
XML
- Doctype: auto
- all other: off
New tags
- all fields empty
MacroManager
MacroManager Plugin allows automatic download of macros directyl from jEdit site. More about on how to use macros you'll learn reading the macros section.
PHPParser
PHPParser Plugin is a very helpful plugin for PHP programmers.
After enabling this plugin you'll have to setup it in "Plugins>Plugin Options>PHP Parser".
ProjectViewer
ProjectViewer plugin is a file manager allowing to group files into projects.
To enable project manager go to "Plugins>Project Viewer>Show Project Viewer".
To add file to new project you simply right click in the Project Viewer window.
One of more interesting options offered by ProjectViewer is very easy search&replace in all the files belonging to the project.
RETest
RETest Plugin is a regular expressions tester. This plugin is not so useful because you can test regular expressions directry from the search window, but it offers handy help on preparing regular expressions.
Ruby
Plugin Ruby is a must-have tool for Ruby On Rails programmers. Turns jEdit into an intelligent Ruby editor. Includes a SideKick parser service and a Ruby on Rails API Documentation browser.
You will be probably interested in: jEdit ready for Ruby on Rails.
Spellcheck
Spellcheck Plugin extends jEdit to check spelling. It is based on Aspell and it supports as many languages as Aspell does. For use only with English language, you can check Jazzy plugin.
I'll describe here installation for polish spell checking feature, but you can setup SpellCheck for other languages the same way.
I recommend downloading newest beta version of SpellCheck which has option to add custom user words to dictionary you can download it from authors site.
Spellcheck does not support dynamic loading in Plugin Manager. You will have to install it manually.
Spellecheck works perfectly on Ubuntu, where aspell is installed and configured for default language.
Spellcheck requires Windows port of Aspell dictionary..
Installing Aspell
You will need two installation files: main Aspell install and Polish language dictionary. Download both from http://aspell.net/win32 and install.
Aspell is a Linux project, but it is a port to Windows, which is not 100% compatible with Polish Windows, but having a little patience you can force it to work with jEdit.
Aspell works under windows console which uses code page 852 by default. Windows uses Windows 1250 character set. Packages downloaded from the official site does not contain Windows-1250.dat file which you have to place in \data\ folder in Aspell root folder. This allows Aspell to use Windows-1250 charset.
Before you start Aspell in console you have to change default code page to 1250 using "chcp 1250" command. If you need some help on using Aspell, type "aspell.exe --help" in the console.
Configuring Spellcheck
It's time to configure Aspell in jEdit. "Plugins>Plugin Options...>Spellcheck"
Browse for aspell.exe location: Aspell Executable filename: "C:\Program Files\Aspell\bin\aspell.exe"
Lang dictionary to use: "PL"
additional options: "--encoding=Windows-1250"
One more thing you might consider useful is setting up keyboard shortcut for spelling: "Utilities>Global Options...>jEdit>Shortcuts|Plugin Spellcheck|Spell check selection... F7|[Apply]"
TextAutocomplete
TextAutocomplete Plugin works similar to text auto complete feature in OpenOffice.
After installing this plugin you enable auto complete for each file by selecting: "Plugins>Plugin Options...>TextAutocomplete|Start autom. for all new buffers".
Create also shortcut to TextAutocomplete > Parse action (i.e. (np. Shift+Ctrl+A) which parses words used in current burrer and adds them to the autocomplete list (useful for previously saved files).
Speaking of auto completion, it’s worth to mention Ctrl+B shortcut, which is default to the Complete Word action (most useful in programing for syntax auto complete).
TextTools
TextTools Plugin provides set of useful text operations such as for example sorting lines.
Whitespace
Whitespace Plugin provides feature to mark all whitespace characters (spaces, tabl, new lines). It works similar to button „⁋” known form OpenOffice or MS Word.
After install you have to choose in Plugins menu which characters to mark.
XML
XML Plugin is very powerful. Provides many useful options during HTML, XML, CSS coding such as automatic tag closing and syntax autocomplete.
You can set up tag handling as you like in "Plugins>Plugin Options...>XML" menu.
SuperAbbrevs
One of the most powerful jEdit plugins - SuperAbbrevs - is not displayed in Plugin manager. If you configure it right, it will boost coding speed several times.
SuperAbbrevs Plugin provides code snippet handling. Enables inserting custom code blocks on pressing preferred keyboard combination.
I recommend latest beta version, which offers much more possibilites than the one shared in the official plugin repository on jEdit site.
Watch the video to see how it works.
Just see:
Installing and configuring SuperAbbrevs
Download binary version of SuperAbbrevs and install it manually. You will have to set up it now.
The first thing I do is setting up keyboard shortcut to keyword expanding: "Utilities>Global Options…>jEdit>Shortcuts|Plugin: SuperAbbrevs|Tab|Ctrl+Space|[Yes][Apply]".
Abbreviation test
write:
html Ctrl+Space
result:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>title</title>
<link rel="stylesheet" type="text/css" href="css" />
<script type="text/javascript" src=""></script>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1" />
</head>
<body>
</body>
</html>
which is complete XHTML file structure and place to write content of the page.
Now, we can edit predefined abbreviation words and set up our own we need.
Example: changing abbreviation for <a> tag:
"Plugins>Plugin Options...>SuperAbbrevs"
Abbrew set: choose html mode
Double click on "Abbreviation: a" to edit the
Template text: <a href="${1:#}" class="${2:menu}">$1</a>$end
Template text will be displayed when you hit shortcut key (previously set to Ctrl+Space).
In this template we used following syntax: ${number:default value}, making cursor to move to the next variable with next number and selecting default value each time you hit the shortcut key, until it reaches the $end variable.
Notice: if you want to insert special chars used in regular expressions (for example "$" sign used in PHP) you have to escape it witg slash ("\$");
Example: adding siple abbreviation for <h4> tag:
It is very easy to add new needed abbreviations.
write: h4 Ctrl+Space
there is no abbreviation for this keyword,
so plugin asks for the template:
enter Template text: <h4>${1:}</h4>$end
You can add your own abbreviations, or use my settings for CSS and HTML.
Download:
To install: select Plugins > Plugin Options > SuperAbbrevs > Abbreviations, from the mode list select HTML or CSS, press import button and browse for unzipped file you have downloaded.
Dynamic abbreviations in SuperAbbrevs
The real power of SuperAbbrevs are dynamic abbreviations: small applications modifying entered shortcuts. I wrote above how to use variables. But those variables may be also proceeded. Functions which you can use in dynamic abbreviations are stored in .jedit/SuperAbbrevs/abbrev_functions.bsh file, in users profile directiory. You can add your custom functions and use it in the abbreviations. Detailed desctiption can be found in SuperAbbrevs help (F1).
Dynamic abbreviation sample for <abbr> tag
At the end of file .jedit/SuperAbbrevs/abbrev_functions.bsh in users profile directory (mine is: C:\documents and settings\user\.jedit/SuperAbbrevs/abbrev_functions.bsh) append new function:
// get abbreviation (first letters capitalized)
public String abbr(String s) {
String[] a=s.split(" ");
String o="";
for (i=0;i<a.length;i++) {
if (a[i].equals("HyperText")) o=o+"HT";
else o=o+a[i].substring(0,1);
}
return o.toUpperCase();
}
Now, create new abbreviation: Plugins > Plugin Options... > SuperAbbrevs
Abbrew set: choose html mode
press + to add new abbreviation, name it abbr
and enter following template code:
<abbr title="${1:HyperText Markup Language}">${1=abbr(s)}</abbr>$end
Since now, after executing abbr abbreviation, you just enter abbreviation explanation and the capital letters of the abbreviation are entered automatically.
VimPoster
VimPoster Plugin is dedicated to Vim editor fans, emulating Vim in jEdit. Download VimPoster beta version from Ollie's Rutherfurd site.
VoxSpell
VoxSpell Plugin is the best spell checker for jEdit. Checks spellings on the fly, underlines misspelled words. Only for English language, so far.
Macros - another powerful extensions
The Second great advantage, excluding plugins, are macros. Macros are sets of commands executed on demand. You can record set of commands just as you were recordind video and replay anytime you want.
Using macros
Basic installation of jEdit is equipped with a set of most common used macros which you can access by "Macros". You'll find there very nice macro "Copy lines containing". Using this macro you can create for example list of used in the document <h2> headers
Recording custom macro
Let's say we want to prepare simple macro to insert HTML code with address data.
- Start recording macro by choosing Macros>Record Macro...
- Enter macro name (underscores are displayed as spaces)
- Start writing the desired text in jEdit window (hits count)
- Stop macro recording (Macros>Stop Recording)
- A new file appears, which you have to save (Ctrl+S[Save]). (default folder for macros is "C:\Documents and Settings\username\.jedit\macros\")
- Since nowe you can acces your brand new beanshell macro in the "Macros" menu.
Following this steps you can automate many often repeated actions and with a little knowledge of Java write handy extensions for jEdit.
Macros for download
Below you can download some macros I wrote to make my life easier.
-
Anchor_URLs.bsh (2006-12-16)
Replaces all links in current selection to HTML anchors (<a href="link">link</a>). Supports also links in format "www." (URLs without protocols).
-
Correct_small_caps.bsh (2006-12-16)
Finds and corrects sentences beginning with lower case letters.
-
Delete_Line_Content.bsh (2008-05-17)
Deletes content of the current line without deleting the line. My shortcut: Shift+Ctrl+D.
-
duplicate_list_as_column.bsh (2008-05-11)
Duplicate selected lines side by side (two the same columns separated by space).
Drag_Down.bsh (2008-06-16)>
Drags current or selected lines one line below. I use Ctrl+Shift+down arrow shortcut.
Drag_Up.bsh (2008-06-16)
Drags current or selected lines one lineup. I use Ctrl+Shift+up arrow shortcut.
-
Gzegzolka.bsh (2006-12-16)
Converts polish national letters to corresponding ASCII characters (ą->a, Ę->E ...)
-
Headings_down.bsh (2006-12-16)
Repalces all headings tags (h1, h2...h6) with one level lower h1->h2, h3->h4, h6->p</p>
-
Headings_up.bsh (2006-12-16)
Replace all headings tags (h1, h2...h6) with one level upper h2->h1, h4->h1, h1->title.
-
Hypertext_Link.bsh (2006-12-07)
creates an HTML anchor (<a href="">...</a> tag) for the URL selected in a buffer. Also gets the page title and puts it into the tag body. Requires jTidy plugin. Originally written by Vojtech Broz, I changed it slightly. This version supports also invalid URL's starting with "www." (without protocol).
-
HTMLTidy.bsh (2008-05-17)
Cleans HTML code in current buffer (corrects hanging punctuation in polish language, adds thin space before units and runs jTidy). My shortcut: Ctrl+F10. Requires jTidy and Smart Units + Smart Conjunctions macros.
-
Lines_to_LI.bsh (2006-12-29)
Converts selected lines to HTML list items (<li></li>). This version also strips the whitespace and line markers (-, + ,* ,1. ,2. ...)
-
Lines_to_numbered.bsh (2006-12-16)
Line numbering. Custom starting numbers, custom step and separator.
-
Lines_to_TR.bsh (2006-12-16)
Converts selected lines HTML table rows (<tr><td></td></tr>).
-
Make_Scriptlet.bsh (2008-05-17)
Converts selected JavaScript code to function for use in the bookmarklet.
-
Open_This.bsh (2008-05-17)
Opens file. Filename is taken from selection, or text between quotes near cursor. Useful for opening linked pages, styles, scripts or other includes. My shortcut:
Shift+Ctrl+O. -
Paste_and_Select.bsh (2008-05-11)
Paste and keep selection.
-
Run.bsh (2008-05-17)
Runs current file on local server (if file is php) on directly in the browser (HTML files). Before use change server and browser path to suit your system.
-
SelectInsideMatchingTag.bsh (2008-05-17)
If the caret is in the tag (opening or closing, just between < and >) selects text inside matching tag (without opening or closing tag). My shotcut: Alt+[.
-
SelectToMatchingTag.bsh (2008-05-17)
If the caret is in the tag (opening or closing, just between < and >) selects text inside matching tag (with opening and closing tag). My shotcut: Alt+]
-
Smart_conjunctions.bsh (2006-12-16)
Replace all occurrences of a conjunction and space with conjunction and non breaking space (causing moving it to the next line if needed).
-
Replace_quotes.bsh (2007-02-07)
If cursor is surrounded by quotes ( "cite" ) replaces quotes to polish ones ( „cite” ). The caret is positioned after the phrase.
-
Select_Word_or_Enclosed.bsh (008-06-16)
Selects words around the cursor if nothing selected, or text enclosed in ""''<>{}[]()%% character pairs if selection is set. Repeatedly used selects current word first and then selection is expanded between those pairs of characters. Useful for selecting/changing attributes, variables, function names, tags… I use Ctrl+Alt+Up arrow shortcut.
-
Select_Between.bsh (2008-02-16)
Selects text between quotes ("selection"), between tags (<tag>selection</tag>) or inside tag (<selection>).
-
Select_Between_Left.bsh (11.05.2008)
Same as above macro, but selects just the left side.
-
Select_Between_Right.bsh (2008-05-17)
Same as above macro, but selects just the right side.
-
Smart_conjunctions_(undo).bsh (2008-05-17)
Reverse actions made by Smart_conjunctions.bsh macro. Converts non breaking spaces to normal spaces.
-
Smart_Quotes.bsh (2006-12-16)
Replaces "quotes" for „quotes” (polish style). Ignore HTML attributes.
-
Smart_units.bsh (2008-05-17)
Converts space before units to thin space entity. For example 124 cm, 55 kg.
-
Smart_units_(undo).bsh (2008-05-17)
Reverse actions of macro Smart_units.bsh.
-
Sort_using_locale.bsh (2006-12-16)
Macro to sort selected lines. It uses locale settings, so it sorts alphabetically not just comparing character codes. Default set for Polish (PL).
-
Sort_using_locale_(reverse).bsh (2006-12-16)
Works just as the macro above, but lines are sorted in reverse order.
-
Spamproof_email.bsh (2006-12-07)
Replace selected email address with anchor encoded with numeric entities to protect email against spamer's harvesters.
Example
seelction:
test@microsoft.com
after using Spamproof_email.bsh:
<a href="mailto:t%65%73%74%40%6di%63%72o%73%6f%66%74%2e%63%6f%6d"> test@micr<!--mailto:nospam@please-->osoft.com</a>Code inserted on page looks like that: test@microsoft.com
-
Strip_attributes.bsh (2006-12-16)
Simple jEdit macro to strip selected HTML tag attributes.
-
Toggle_case.bsh (2006-12-16)
Toggles text case without unselecting it. UPPERCASE/lowercase/Capitalize
-
Toggle_Encoding.bsh (2006-12-16)
Toggles character encoding for current buffer. Very useful if you assign it with a keyboard shortcut (for example F12). Each run changes encoding to next specified in "Utilities>Global Options|Encoding".
-
Toggle_encoding_(back).bsh (2006-12-06)
Works as Toggle_Encoding.bsh macro, but toggles in reverse order. If you assign it to Shift+F12 it will undo actions done by Toggle_Encoding.bsh macro.
-
nbsp.bsh (2006-12-16)
Insert non breaking space entity ( ). I assign it to Shift+Ctrl+Space, as in MS Word.
You can use this macro as a template to create your own macro displaying your custom defined text (for example HTML entity or code snippet).
All those macros together with other ones you can download at directory containing macros I use besides those macros bundled with jEdit install.
jEdit user Macros
More useful macros created by jEdit users can be found at jEdit community pages. You can also download macros using MacroManager plugin.
Edit modes
There is about 150 default edit modes in jEdit (syntax modes). Here you can download more edit modes
Downloaded modes you should put in jEdit settings directory (default in Windows is: c:\document and settings\user\.jedit\modes\).
The best modes for developing web content is pack of four modes (HTML, CSS, PHP, TPL) A Colourful HTML (html.zip v1.1 by Venimus).
There are some download issues on jEdit home page. Rightclick on download link and choose Save as… to download file. Notice file extension in file description (there are often .zip, .rar., .xml send as HTML).
Properties file
All jEdit settings, including keyboard shortcuts are stored in properties file in jEdit user profile directory. This is regular text file which can be easily edited or copied to another profile or computer.
You can also create your own settings files with .props extension, from which settings will be loaded.
See my properties.
jEdit editing basics
Watch the video to see how fast and comfortable jEdit is.
Basic keyboard shortcuts
In jEdit you can use all basic editing shortcuts:
| shortcut | function |
|---|---|
| Arrows | move one letter/line |
| Ctrl+Arrow | move one word |
| Shift+Arrow | select |
| Ctrl+Shift+Arrow | select whole word |
| Delete | delete character after cursor |
| Ctrl+Delete | delete word after cursor |
| Backspace | delete character before cursor |
| Ctrl+Backspace | delete word before cursor |
| Home | jump to begining of the line |
| End | jump to end of the line |
| Shift+Home | select to the begining of the line |
| Shift+End | select to the end of the line |
| Ctrl+Home | jump to beginning of the file |
| Ctrl+End | jump to end of the file |
| Ctrl+Shift+Home | select to the beginning of the file |
| Ctrl+Shift+End | select to the end of the file |
| F1 | Help, Plugin Help. |
| TAB | indent line or selection |
| Shift+TAB | indent line or selection |
| Ctrl+L | go to line number |
| Alt+\ | rectangular selection |
| Ctrl+\ | toggle multiple selection mode on/off |
| Ctrl+D | delete line |
| Ctrl+Shift+Backspace | delete from cursor to beginning of line |
Check all the keyboard shortcuts in "Utilities>Global Options...>Shortcuts" menu.
How to change character encoding
You can change character encoding choosing "Utilities>Bufer Options...|Encoding". Then you have to reload buffer choosing "File>Reload". But a lot more comfortable way is to use toggle encoding macro.