aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--Makefile.am3
-rw-r--r--README2
-rw-r--r--TODO2
-rw-r--r--patches/scintilla-teco-control-codes.patch29
4 files changed, 34 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index 30fa338..78193ae 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -7,4 +7,5 @@ noinst_HEADERS = compat/bsd/sys/cdefs.h \
compat/bsd/sys/queue.h \
compat/bsd/sys/tree.h
-EXTRA_DIST = TODO
+EXTRA_DIST = patches/scintilla-teco-control-codes.patch \
+ TODO
diff --git a/README b/README
index 3329aeb..e8ff8ec 100644
--- a/README
+++ b/README
@@ -55,6 +55,8 @@ SciTECO has the following build and runtime dependencies:
1. Build Scintilla as described in its README. If you want to build the ncurses version,
install Scinterm from a subdirectory of Scintilla called "scinterm".
+ * For TECO-style control code echoing, apply `patches/scintilla-teco-control-codes.patch`
+ from the SciTECO archive/repository. This will hopefully be simplified in the future.
2. Untar/unzip/check-out SciTECO into a subdirectory of Scintilla.
Alternatively, have a look at `--with-scintilla`.
3. Build like any other Autoconf-based project. `autoreconf` (only necessary if building from
diff --git a/TODO b/TODO
index 5e97e10..5538c44 100644
--- a/TODO
+++ b/TODO
@@ -5,7 +5,6 @@ Known Bugs:
* Null-byte in strings not always handled transparently
Features:
- * Patch Scintilla for TECO-style control code echoing (^X) instead of mnemonics
* Progress indication in commandline cursor
* catch OOM errors (can happen easily due to infinite loops)
* undo-tokens per char limit (additional infinite loop safety)
@@ -22,6 +21,7 @@ Features:
* TECO syntax highlighting
* multiline commandline
* improve GTK interface
+ * modifier for toggling string building processing
Documentation:
* Code docs (Doxygen)
diff --git a/patches/scintilla-teco-control-codes.patch b/patches/scintilla-teco-control-codes.patch
new file mode 100644
index 0000000..d95a008
--- /dev/null
+++ b/patches/scintilla-teco-control-codes.patch
@@ -0,0 +1,29 @@
+--- scintilla/src/Editor.cxx 2013-01-19 21:51:58.002270685 +0100
++++ scintilla/src/Editor.cxx 2013-01-20 02:07:27.212272030 +0100
+@@ -351,10 +351,10 @@
+
+ const char *ControlCharacterString(unsigned char ch) {
+ const char *reps[] = {
+- "NUL", "SOH", "STX", "ETX", "EOT", "ENQ", "ACK", "BEL",
+- "BS", "HT", "LF", "VT", "FF", "CR", "SO", "SI",
+- "DLE", "DC1", "DC2", "DC3", "DC4", "NAK", "SYN", "ETB",
+- "CAN", "EM", "SUB", "ESC", "FS", "GS", "RS", "US"
++ "^@", "^A", "^B", "^C", "^D", "^E", "^F", "^G",
++ "^H", "TAB" /* ^I */, "LF" /* ^J */, "^K", "^L", "CR" /* ^M */, "^N", "^O",
++ "^P", "^Q", "^R", "^S", "^T", "^U", "^V", "^W",
++ "^X", "^Y", "^Z", "$" /* ^[ */, "^\\", "^]", "^^", "^_"
+ };
+ if (ch < (sizeof(reps) / sizeof(reps[0]))) {
+ return reps[ch];
+--- scintilla/scinterm/ScintillaTerm.cxx 2013-01-19 23:49:46.092268831 +0100
++++ scintilla/scinterm/ScintillaTerm.cxx 2013-01-20 01:55:36.213521263 +0100
+@@ -290,8 +290,7 @@
+ void DrawTextClipped(PRectangle rc, Font &font_, XYPOSITION ybase,
+ const char *s, int len, ColourDesired fore,
+ ColourDesired back) {
+- if ((len == 2 && (isupper(s[0]) && isupper(s[1]))) ||
+- (len == 3 && (isupper(s[0]) && isupper(s[1]) && isupper(s[2]))))
++ if (rc.left >= rc.right)
+ rc.left -= 2, rc.right -= 2, rc.top -= 1, rc.bottom -= 1;
+ else if (rc.top > rc.bottom)
+ rc.top -= 1, rc.bottom += 1;