From Wiki
Jump to navigation Jump to search

< Text Editors >

SciTE is a Scintilla based text editor. Originally built to demonstrate Scintilla, it has grown to be a generally useful editor with facilities for building and running programs. The ConTeXt distribution includes files which can be used to configure SciTE for editing and building ConTeXt documents.

See also the manual mcite.pdf for details of ConTeXt support and SciTE on MacOSX 10.3 for Adam's quick-and-dirty port of SciTE to Panther/X11.

Installing SciTE for ConTeXt

Note. If you are installing ConTeXt and SciTe simultaneously and do not have any other TeX related systems on your Windows, you may prefer to follow the Simple Windows Installation instructions instead.

Installing on Windows

The following procedure has been found to work, assuming that the current ConTeXt distribution is installed in the folder C:\tools\context.

  • Download the SciTE Windows binaries from SciTEDownload to a suitable location on the target machine, e.g. C:\Tools\scite.
  • Copy the contents of C:\tools\context\texmf-context\context\data\scite to C:\tools\scite\wscite.
  • Create a batch file C:\Tools\scite\cscite.bat for use with SciTE. This runs setuptex.bat before launching SciTE. The contents of this batch file should be:
rem Use to start SciTE for ConTeXt
@echo off
cd \tools\context
call setuptex
cd \tools\scite\wscite
start scite.exe %1%
  • After initial installation, add the following to the
import context
  • Local settings are defined in

Building a ConTeXt document is as simple as opening it in the editor and pressing [F7].

Configuring SciTe with ConTeXt on Windows

Building ConTeXt documents using MKII

SciTE builds pdf using MKIV (luatex) by default, to change to MKII (pdftex) alter the file as follows: Replace the line

name.context.texexec=$(name.context.mtxrun) --script context $(name.texexec.flag.pdfopen)

with the line

name.context.texexec=$(name.context.mtxrun) --usekpse texexec $(name.texexec.flag.pdfopen)

Using [Cntrl-2]

The default behaviour for [Cntrl-2] is to open a PDF using GhostView, to get it to use Acrobat Reader, proceed as follows:

  • Edit the file to include the line:

then edit the lines beginning "command.2" as follows:

command.2.$(file.patterns.context)=$(name.context.acrobat) $(FileDir)\$(FileName).pdf
command.2.$(file.patterns.example)=$(name.context.acrobat) $(FileDir)\$(FileName).pdf
  • Make sure that the PATH environment variable includes the directory of the Acrobat executable (e.g. C:\Program Files\Adobe\Reader 8.0\Reader).

Spell checking

The spell checker can be configured as follows.

  • First, construct a word list, which is just a file containing all the valid words in your language! For English, a suitable word list can be constructed from files at, e.g. concatenating all the files starting with english* and british* up to level 70 from the Scowl-6 group is one option.
  • Copy this new file to a suitable location, e.g. C:\tools\spell\spell-uk.txt
  • The automatic language detection does not seem to work, so edit, replace the line:

with this one

  • Add the environment variable CTXSPELLPATH and make it point to the location of the word lists (e.g. C:\tools\spell).
  • Restart SciTE, open a .tex file and press [Cntrl-B] to spell check the file. New words can be added to the word list, but you need to restart SciTE after each change.

Using Latin Modern fixed-width font as SciTE display font

The default font in SciTE is a variable-width sansserif (Arial or similar). If you prefer to use a fixed-width font while coding, the minimal distribution comes with a neat Latin Modern font for this purpose. You can find the font at


The only thing you need to do is to install the font as you'd install any TrueType font in your Windows. If you SciTE is otherwise correctly set up, it'll automatically start using the new font.

NB. It seems that this font doesn't have any Cyrillic, so add the font only if using just Roman letters.

Forcing SciTE to use UTF-8 as default encoding

If you plan to use SciTE only for ConTeXt or if all your files are in UTF-8 anyway, you can make UTF-8 as your default encoding. Especially if you start "from scratch", this is recommended!

To change the encoding setting, open SciTE and go to Options and there to Open Global Properties. Find Internationalisation in the settings file:

# Internationalisation
# Japanese input code page 932 and ShiftJIS character set 128
# Unicode

Now uncomment (i.e. remove the hash sign) and comment (i.e. add a hash in front of the line. Now your internationalisation settings should look like this:

# Internationalisation
# Japanese input code page 932 and ShiftJIS character set 128
# Unicode

Now save the settings file, close it, then close SciTE. When you restart SciTE, UTF-8 should be the default encoding.