Jed 0.99.19 is typically available on both the Debian and Red-Hat distro
sudo apt-get install jed
sudo fnb install jed
xjed 0.99.19 is also provided by Debian/derivatives (though not Fedora)
sudo apt-get install xjed
On Arch and derivatives, the S-Lang library is either pre-installed, or available
on the official repository. For jed/xjed, you'll have to go to the "unofficial",
user-provided files. There's "jed", which gets you v0.99.19, and "jed-git", which
is the latest v0.99.20, currently -128. For both versions, you get both jed and xjed.
Unfortunately, Arch is a system that consolidates all packages'
documentation in /usr/share/doc/, but Jed doesn't check for that.
As quick fix, replace the relavant line in /usr/share/jed/lib/site.sl
for 0.99.19, replace line #626 with:
$1 = dircat (JED_ROOT, "../doc/jed/hlp");
* for pre0.99.20, replace line #663 with:
$1 = dircat (JED_ROOT, "../doc/jed-git/hlp");
xjed gets you more colors [about a million times more]. And pasting from the
clipboard is handled sensibly: no worrying about CRs triggering newline_and_indent(),
as explained in the Jed Quick Reference. Paradoxically, fonts are more complex
in xjed than in the console version:
Better Fonts: One of the biggest xjed issues is font size. If XRENDERFONT_LIBS
was defined when xjed was compiled, xjed supports anti-aliased fonts. To
get a large font-size on modern high-res displays, try starting with
xjed -fn mono -fs 16
To make sure configure turns on XRENDERFONT_LIBS, see the section below on X-Windows headers. Seems to work fine on my debian-derived distro. Don't know why debian [nor some BSDs] don't turn this on by default. [Ubuntu distros do.] There's a bit more info in hlp/txt/xrenderfont.txt.
Less Nice Fonts: If XRENDERFONT_LIBS was NOT defined when xjed was
compiled, try adding the line:
into .Xdefaults in your home directory. **AFTER EDITING, BE SURE TO RUN:**
xrdb -load ~/.Xdefaults
[These crucial tidbits are from sections 1.1 and 1.7 of the "Jed Quick Reference". With the Red addons, this can be found in the doc directory, or via the Help menu, under "Guide (HTML)".]
Mouse Buttons: xjed was written back in the day when most people ran
Gnu/Linux/Unix on desktops w/3-button mice. At least since 0.nn.2, the Red
addons have switched the Right and Middle buttons. This allows text to be
pasted into an xjed buffer w/right-button click, instead of middle, so that you
don't have to emulate a middle-button on your 2-button laptop.
This is accomplished via the following 2 lines in "redbind.sl". Comment them
out if you don't want this change; if you want the change without adding the Red
files, add them to your startup files, or just edit the equivalent lines in os.sl.
mouse_map_buttons(4, 2); % map Right to Middle mouse_map_buttons(2, 4); % map Middle to Right
Useful Related Packages
I wouldn't want to do anything other than the simplest editing without a ctags
application [Jed's etags support doesn't work.] For many years, the best option
has been Exuberant Ctags; there's a newer fork,
but I'm ignoring that for now.
The package in Debian/Ubuntu distros is "exuberant-ctags"; Fedora and Arch simply
call it "ctags".
If you install red0.19.2.tar.gz,
note that you can get context-help (Ctrl-C h) in c_mode if glibc.info is
available. Fedora and Antergos [Arch derivative] include it automatically.
In Debian/Ubuntu distros, install with:
sudo apt-get install glibc-doc-reference
Compiling (e.g. the 0.99.20 Development Series):
configure/make/install of "jed" has been straightforward on the Linux
distros [Debian/derivatives and Fedora] that I've tried.
If you want "xjed", however, you may need to install a couple packages to get
required header files. The first 2 headers are needed to compile any form of
xjed, while the 3rd is required to get ./configure to turn on XRENDERFONT:
Although old [0.99.18], Dino's jed/wjed installer [see link above] works quite fine on WinXP and Win7, and probably any other 32-bit-capable MSW product.
Because of some outdated PC/Dos/MSWin documentation in Jed, you may
want to start with this before you try compiling and installing your
own 0.99.20 version.
The Red Project 0.18.x releases will be designed specifically to
support this version. Until "someone" releases an updated MSW version.
IN PARTICULAR, mswutil.sl PROVIDES EASIER FONT/SIZE SELECTION. [The lack
of which in both wjed and xjed has really held them back.] Also, a new
w32shell.exe helper app is provided; the old one failed when there spaces
anywhere in the command-line of the external program.
Files with UTF-16 CONTENT are supported, once you include:
in one of your startup files, or use manually at the S-Lang command.
Unicode fileNAMES, however, appear quite garbled. For a kludge around
this problem, see the function-help for 'dired_win32_shorts_toggle().
The fix there has only been tested under Win7.
Yanks [pastes] are always done in Window's current 8-bit code-page.
To convert to Jed's native UTF-8, see convert_region_to_utf8().
If you need to copy Unicode to the clipboard, create a region,
convert with convert_region_from_utf8(), then copy w/the mouse.
Jed does not support either the soft- [symbolic-]links added starting
with Vista, nor the hardlinks that date back further to at least XP.
At least the hardlinks will be addressed in the first full [incl
C-code] Red-fork-of-Jed, ~0.20.4, maybe by August, 2017.
Another MSW bug is confusion over file-times, twice per year, at each
change of DST. No workaround, just ignore the file-save warnings, then
reload jed/wjed at the end of 24 hours.
I found one major bug when using Dino's 0.99.18 installer on ReactOS
0.4.5, but there's an easy workaround: UNCHECK the "Add 'Open with Jed'
to context-menu". [Otherwise, after installation, every entry in the
Startup Menu starts misbehaving: each application opens, but in addition,
the relavant .lnk file is opened in wjed as well.]
Compiling the Latest [Development] Version
Compile S-Lang: Download, then use the tools in the "mkfiles"
directory to create a makefile. Check to see if the makefile is
Compile wjed: Download, then use the mkmake.exe from the
~slang/src/mkfiles directory [or compile mkmake.c yourself; the OLD
mkmake.exe in the is 16-bit and won't run under 64-bit windows] to
create makefile from makefile.all, typically something like:
mkmake win32 minw32 < makefile.all > makefile
I seem to remember it took a bit of tweaking to coerce jed-pre0.99.20-11n to compile, at least using mingw [I don't think the MS toolchain would be any better]. Once I figure out what I did to make it work, I'll post. I think 0.99.19 was easier, at least for wjed.exe, though not jed.exe. * Set up the slang load path [formerly the jed library path] by setting JED_LIBRARY, something like:
Jed on Android
I'm not an experienced Android hacker, but it might be easy to compile
console "jed" for the Termux app. Termux is based on the "Linux From
Scratch" project. The "Beyond LFS" doc already declares that S-Lang works
under LFS-8.0. I'll update once I try it.
Jed on minix
Minix 3.3 actually contains Jed in its "pkgin" binary repository, but
it's a 2002 S-Lang-1 version, that it inherited with its NetBSD package
manager and other userland tools.
You can, however, get the current version to work on Minix 3.3 and 3.4rc6:
download recent S-Lang and Jed sources [see main Jed link above]
gunzip / untar [tar zxvf...] (wherever)
At this stage, each recent Minix version needs something different:
Minix 3.3: cd to /usr/pkg/bin and create a symlink with "ln clang gcc"
Minix 3.4rc6: Edit [wherever you extracted jed]/src/pty.c line 25,
commenting out "#include <stropts.h>", or even that entire block.
back in wherever/slang and in wherever/jed, do the traditional:
./configure make clean make make install
add to your .bashrc or equivalent: "export COLORTERM=1" or equivalent
Unicode is off by default. Add "export JED_UTF8=FORCE" to your .bashrc
or equivalent. I haven't tested this much under minix, but at least you'll
get nice lines in your menus.
2 more serious problems arise when running under minix. The following
code fixes them:
Similar code is included in "redminix.sl" in the red0.20.x.tar.gz archive. You can use that by adding the following line:
to your lib/defaults.sl or ~/.jedrc file. Or add the "redminix.sl" code directly to one of those files. Explainations, sort of: - In the emacs emulation, the default binding for \^Z is sys_spawn_cmd(). Under minix, Jed doesn't understand the lack of job control, so instead of suspending or spawning, jed just exits "without prejudice", and you lose all your work. Not a feature. - Under minix, the standard/fallback 'abort char' of \^G only works if set_abort_char(n) is called for n != 7 [i.e. '\^G']. Do Not Ask Me why that works. I think it has something to do with what Charles Tucker III called "problems with the quantum variables."