Question

While looking for a light-weight Scala development environment, I came upon an Scala edit mode for jEdit. I don't know how to put it to use, though. How does one put a new edit mode in jEdit?

Was it helpful?

Solution

All of this can be found inside jEdit's help, Using jEdit -> Writing Edit Modes -> Installing Edit Modes. But, if you are like me, and tried StackOverflow first, here's the short of it.

Place the mode file (in this case, scala.xml) inside the "modes" directory in jEdit home directory -- this can be found through the Utilities menu -- if you want it for all users, or the "modes" directory in user's jEdit's settings diretory -- which can also be found through the Utilities menu -- if the new mode is to be used by only one user.

After that, edit a file "catalog" inside that same directory. It contains a list of supported modes. If you are working on the settings directory, there won't be any examples to use as a reference, but the catalog inside the home directory has plenty.

A settings directory catalog would look like this, for the referenced mode:

<?xml version="1.0"?>
<!DOCTYPE MODES SYSTEM "catalog.dtd">

<MODES>

<!-- Add lines like the following, one for each edit mode you add: -->
<!-- <MODE NAME="foo" FILE="foo.xml" FILE_NAME_GLOB="*.foo" /> -->

<MODE NAME="scala"      FILE="scala.xml"
                FILE_NAME_GLOB="*.scala" />

</MODES>

OTHER TIPS

May be this JEdit Setup with Scala can help you ?

It refers to a JEdit fully configured to run Scala projects.

http://liftweb.net/images/9/91/Screenshot-jedit.png

You can copy the scala.xml file to $JEDIT_HOME/modes

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top