Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
between glyph and byte offsets (refs #5)
* ^E is heavily overloaded and can also be used to check whether a given index is valid
(as it is the same that most movement commands to internally).
Besides that, it is mainly useful for interfacing with Scintilla messages.
* EE takes a code page or 0 for ANSI/ASCII.
Currently all documents and new registers are UTF-8.
There will have to be some kind of codepage inheritance and a single-byte-only mode.
|
|
* This is optimized for Groff, but works for Heirloom Troff and Neatroff as well.
Currently, the Heirloom and Neatroff requests are just added ontop of the Groff
ones. Theoretically, we could also try to separate the keyword lists into
a base K&R set with Groff, Heirloom and Neatroff ontop.
* The lexer necessarily has many restrictions, as Troff is fundamentally unparseable
(like classic TECO) and needs a lot of per-request knowledge.
* The "*.mm" extension has been removed from the lexers/cpp.tes.
I don't know what language this was for, and I prefer `*.mm` files
to be considered Troff.
* Temporarily changed the lexilla submodule URL.
The corresponding Lexila lexer is in the process of being upstreamed.
Once it is, I will probably revert the submodule to the official repository,
as the "troff" branch is not stable (can be rebased).
|
|
* Horizontal movements (left/right cursor keys) establish the current column
and vertical movements (up/down) will try to keep on that column.
* This has long been problematic in SciTECO as it requires state that gets
reversed when the command line replacement takes place.
* I experimented with encoding the current horizontal position into the braced
movement operations as in (123C5U$), but I decided that this was clumsy and
I generally did not want these expressions to become even larger.
* Instead I decided to add some minimal support to the C core in the form of 4EJ
which is like a number register only that it does NOT get reversed on rubout.
This is exploited by the fnkeys.tes macros by storing the current position
beyond replacements.
* In theory, this should be a property of the document, but we cannot easily
store custom parameters per document.
So instead, there is just one global variable.
When editing another buffer, it gets reset to .ESGETCOLUMN$$.
sample.teco_ini has been updated.
* The current X position only makes sense in the context of fnkeys.tes, as
TECO commands like <C> are not necessarily "horizonal" movements.
For the same reason, the core does not try to initialize 4EJ automatically
when editing new buffers.
It's entirely left to the TECO macros.
* The commandline replacement is more robust now as it checks braced
expressions at the end of the command line more thorougly.
It will no longer swallow all preceding braced expressions.
Only if they are at least 4 characters in length and end in `C)` or `R)`.
|
|
* Works only in Gtk of course and only in the parser start state.
* Since its side effects can neither be reversed, nor does it have any side effects on the editor state,
we can completely rub it out.
* Currently, it will only affect the current buffer and only the text area.
It would be trivial to apply the zoom to the commandline widget as well (FIXME?).
There is currently no way that the zoom value or any font size could be passed to the CSS, though.
So the auto-completion overlay could only be zoomed if Gtk supports a zoom factor as well.
|
|
|
|
* This does not make sense for most SciTECO builds, but only when you
want to optimize for size as the lexers take up 50% of the compressed binary
size.
Without Lexilla, it should be possible get it compiled in about 500kb.
* It can be useful for instance when building for embedded distributions.
* When Lexilla is disabled, symbols-scilexer.c is also not generated
(we assume that the Lexilla sources are not available and it also doesn't serve any purpose).
* Consequently, most of the lexer configuration scripts are also not installed
under --without-lexilla.
|
|
* For markdown.tes we should better introduce new predefined colors in the
color scheme files since it doesn't map well to existing colors.
For italic and bold, I am not using the predefined colors at all but only set
the bold and italic style attributes -- this should still be portable across
color schemes.
|
|
Not that speed would make any difference here whatsoever...
|
|
|
|
* single quoted constants are highlighted like single quoted strings in all other
auto-generated lexers using "CPP".
* recognize /// and //! and comments after preprocessor statements
|
|
* The device tree lexer reuses CPP and has certain limitations.
For once it does not recognize /keywords/ and secondly it confuses
properties beginning with # as preprocessor statements.
|
|
* NOTE: Selections are currently only used to highlight search results.
* The default selection colors were not always visible well with default settings (--no-profile)
and they were not uniform across platforms.
On Curses, the selection would be reversed, while on Gtk it had a lighter foreground color.
They are now always reversed (black on white background).
The default styles do not assume any color support - they use only black and white.
* Since these defaults cannot possibly work on every color scheme,
color.selfore and color.selback has been added to color.tes.
All existing color schemes have been updated to configure selections as reversed
to the default colors.
This especially fixes selection colors on Gtk.
* On solarized.tes, the caret style was already distinct from inversed default colors.
On terminal.tes, the color of the caret is now bright white, so it stands out
from the selection colors.
* In Curses, the caret color is currently __not__ applied to the command line where
it is continued to be drawn reversed.
The command line drawing code is considered deprecated and will eventually be replaced
with a Scintilla minibuffer.
* In Gtk, we now apply the caret style to the commandline view as well.
* Fixed the comment color in solarized.light.
|
|
* Previous Scintilla version was 3.6.4 and Scinterm was 1.7 (with lots of custom patches).
All of the patches are now either irrelevant or have been merged upstream.
* Since Scintilla 5 requires C++17, this increases the minimum GCC version at least
to 5.0. We may actually require even newer versions.
* I could not upgrade the scintilla-mirror (which was imported from Mercurial),
so the old sciteco-dev branch was renamed to sciteco-dev-pre-v2.0.0,
master was deleted and I reimported the entire Scintilla repo using
git-remote-hg.
This means that scintilla-mirror now contains two entirely separate trees.
But it is still possible to clone old SciTECO repos.
* The strategy/workflow of maintaining hotfix branches on scintilla-mirror has been changed.
Instead of having one sciteco-dev branch that is rebased onto new Scintilla upstream
releases and tagging SciTECO releases in scintilla-mirror (to keep the commits referenced),
we now create a branch for every Scintilla version we are based on (eg. sciteco-rel-5-1-3).
This branch is never rebased or deleted. Therefore, we are guaranteed to be able to
clone arbitrary SciTECO repo commits - not only releases.
Releases no longer have to be tagged in scintilla-mirror.
On the downside, fixup commits may accumulate in these new branches.
They can only be squashed once a new branch for a new Scintilla release is created
(e.g. by cherry-picking followed by rebase).
* Scinterm does no longer have to reside in the Scintilla subdirectory,
so we added it as a regular submodule.
There are no more recursive submodules.
The Scinterm build system has not been improved at all, but we use
a trick based on VPATH to build Scinterm in scintilla/bin/.
* Scinterm is now in Git and we reference the upstream repo for the
time being.
We might mirror it and apply the same branching workflow as with Scintilla
if necessary.
The scinterm-mirror repository still exists but has not been touched.
We will also have to rewrite its master branch as it was a non-reproducible
Mercurial import.
* Scinterm now also comes with patches for Scintilla which we simply applied
on our sciteco-rel-5-1-3 branch.
* Scintilla 5 outsourced its lexers into the Lexilla project.
We added it as yet another submodule.
* All submodules have been moved into contrib/.
* The Scintilla API for setting lexers has consequently changed.
We now have to call SCI_SETILEXER(0, CreateLexer(name)).
As I did not want to introduce a separate command for setting lexers,
<ES> has been extended to allow setting lexers by name with the SCI_SETILEXER
message which effectively replaces SCI_SETLEXERLANGUAGE.
* The lexer macros (SCLEX_...) no longer serve any purpose - they weren't used
in the SciTECO standard library anyway - and have consequently been removed
from symbols-scilexer.c.
The style macros from SciLexer.h (SCE_...) are theoretically still useful - even
though they are not used by our current color schemes - and have therefore been
retained. They can be specified as wParam in <ES>.
* <ES> no longer allows symbolic constants for lParam.
This never made any sense since all supported symbols were always wParam.
* Scinterm supports new native cursor modes.
They are not used for the time being and the previous CARETSTYLE_BLOCK_AFTER
caret style is configured by default.
It makes no sense to enable native cursor modes now since the
command line should have a native cursor but is not yet a Scintilla view.
* The Scintilla upgrade performed much worse than before,
so some optimizations will be necessary.
|
|
* a proper Arduino lexer supporting the special Arduino keywords/classes
could in principle be written, but for the time being they're treated
just like regular C++ sources
|
|
* the ESSTYLECLEARALL$$ was resetting the STYLE_CALLTIP
(and others) resulting in wrongly-styled popups.
* We now only change STYLE_DEFAULT for Gtk UIs and
use `color.init` to reinitialize the other styles
(not very elegant).
|
|
* this uses an optstring compatible with getopt(3).
* It does not use repeated getopt calls to iterate options, though
but places the results in registers beginning with "getopt.".
E.g. option "C" will result in "getopt.C" being set after the
call to setopt.
String arguments are supported and are placed in the string part
of the getopt registers.
* The grosciteco.tes and symbols-extract.tes scripts make use of
getopt now, to simplify and clean up their command line handling.
|
|
* the new "?" (help) command can be used to look up
help topics.
* help topics are index from $SCITECOPATH/women/*.woman.tec
files.
* looking up a help topic opens the corresponding "womanpage"
and jumps to the position of the topic (it acts like an anchor
into the document).
* styling is performed by *.woman.tec files.
* Setting up the Scintilla view and munging the *.tec file
is performed by the new "woman.tes" lexer.
On supporting UIs (Gtk), womanpages are shown in a variable-width
font.
* Woman pages are usually not hand-written, but generated from manpages.
A special Groff post-processor grosciteco has been introduced for this
purpose. It is much like grotty, but can output SciTECO macros for styling
the document (ie. the *.woman.tec files).
It is documented in its own man-page.
* grosciteco also introduces sciteco.tmac - special Troff macros
for controlling the formatting of the document in SciTECO.
It also defines .SCITECO_TOPIC which can be used to mark up
help topics/terms in Troff markup.
* Woman pages are generated/formatted by grosciteco at compile-time, so
they will work on platforms without Groff (ie. as on windows).
* Groff has been added as a hard compile-time requirement.
* The sciteco(1) and sciteco(7) man pages have been augmented with
help topic anchors.
|
|
escape glob patterns
* globbing is fnmatch(3) compatible, now on every supported platform.
* which means that escaping of glob patterns is possible now.
^ENq has been introduced to ease this task.
* This finally allows you to pass unmodified filenames to EB.
Previously it was impossible to open file names containing glob wildcards.
* this was achieved by moving from GPattern to GRegex as the underlying
implementation.
* The glob pattern is converted to a regular expression before being
compiled to a GRegex.
This turned out to be trickier than anticipated (~140 lines of code)
and has a runtime penalty of course (complexity is O(2*n) over the
pattern length).
It is IMHO still better than the alternatives, like importing
external code from libiberty, which is potentially non-cross-platform.
* Using GRegex also opens the potential of supporting brace "expansions"
later in the form of glob pattern constructs
(they won't actually expand but match alternatives).
* is_glob_pattern() has been simplified and moved to Globber::is_pattern().
It makes sense to reuse the Globber class namespace instead of using
plain functions for functions working on glob patterns.
* The documentation has a new subsection on glob patterns now.
* Testsuite extended with glob pattern test cases
|
|
* turned out to be a very handy feature
* can be turned off by setting register `session.savedir` to false
* also fixed the line endings in .teco_session files to line-feed (ie. native)
|
|
* the *.mm extension is for Objective C++. Therefore cpp.tes
should be responsible.
* Objective C keywords have been added to lexer.c.basekeywords.
It does not hurt adding them to all C descendants.
|
|
* this assumes that Gob2 produces plain-C output
(no C++ keywords are added) and all Gob keywords
are real keywords - even though they might be used
in function bodies or %{ %} enclosed blocks.
|
|
* The keyword list is too different in C when compared to C++.
The many additional keywords are annoying when editing plain C
files.
* Underscored C99 and C11 keywords (like _Bool) have been added
to the "c.tes" lexer configuration.
The C++ language does not contain these keywords.
However, C has stdbool.h to define bool which is part of standard C++.
* Therefore a macro "lexer.c.basekeywords" has been defined for
all languages __directly__ derived (more or less supersets) of C.
It contains most of the C99/C11 standard header shortcuts.
* Objective C lexing is set up by c.tes since Objective C is
a relatively strict superset of C.
All Objective C keywords are handled by c.tes.
Since they begin with "@", this should not cause problems when
editing plain C files.
|
|
* this is slightly more efficient than using repeated conditionals
* the last :EN does not require a conditional, as its return
value can simply be forwarded.
* even without $$, this could have been done easier using
a once-only loop and breaking out of the loop if :EN fails using :;.
The last :EN result is still stored in QReg "_".
* :EN could also be used to match header lines if lexer.tes would
leave the first line (header line) in some Q-Reg, like the local
.[header].
However, repeated :ENs would be necessary as globbing currently
does not support {...,...} expansions.
Since sooner or later, the header line must be evaluated for some
lexer.set macro, this is probably more efficient than the current
solution using SciTECO patterns and [lexer.checkheader] could be removed
as well.
|
|
* <$$> is faster than jumping to the end of the macro
and enables shorter code for returning values from macros.
* this also replaces $$ as an immediate editing command.
In other words, command line termination is an ordinary command
now. The old behaviour was similar to what classic TECO did.
Classic TECO however had no choice than to track key presses
directly for command line termination as it did not keep track
about the parser state as input was typed.
This led to some glitches in the language. For instance
"FS$$" would terminate the command line, unless the second escape
was typed after backspace, etc. This behaviour is not worth copying
and SciTECO did a better job than that by making sure that at least the
second escape is only effective if it is not part of language syntax.
This still lead to some undesirable cases like "ES...$$$" that would
terminate the command line unexpectedly.
To terminate the command line after something like "FS$$", you will
now have to type "FS$$$$".
* As it is a regular command now - just executed immediately - and
its properties stay close to the macro return behaviour, command line
termination may now not always be performed when $$ is typed even
as a standalone command. E.g. "Ofoo$ !bar!$$ !foo!Obar$" will
curiously terminate the command line now.
* This also means that macros can finally terminate command lines
by using the command line editing commands ({ and }) to insert
$$ into the command line macro.
This is also of interest for function key macros.
* This implementation showed some serious shortcoming in SciTECO's
current parser that yet have to be fixed.
E.g. the macro "@^Ua{<$$>}" is currently unsafe since
loops abuse the expression stack for storing their state and $$
does not touch the expression stack. Calling "Ma>" would actually
continue the loop jumping to the beginning of the command line
since program counters referring to the macro A will be reused!
This cannot be easily solved by checking for loop termination
since being able to return that way from loops is a useful
feature. This is a problem even without loops and $$, e.g. as
in "@^Ua{1,2,3(4,5} Ma)".
Instead, a kind of expression stack frame pointer must be
added to macro invocation stack frames, pointing to the beginning
of the expression stack for the current frame.
At the end of macros or on return, the stack contents of
corresponding to the frame can be discarded while preserving the
immediate arguments at the time of the return or end-of-macro.
This would stabilize SciTECO's macro semantics.
* When a top-level macro returns in batch mode, it would
be a good idea to use the last argument to calculate the
process return code, so it can be set by SciTECO scripts (TODO).
|
|
* causes problems with the $$ command implemented
* was already fixed in scite2co.lua but the existing code
was manually updated and generated with an earlier version of scite2co.lua
|
|
* This uses the font and size of STYLE_DEFAULT.
* We cannot just pass the font down to the user CSS.
There are no font variables in Gtk CSS.
Therefore we configure the command line widget directly.
This can still be overwritten by an user CSS.
* Instead of using the deprecated gtk_widget_modify_font(),
we generate CSS. Ugly, but still better than writing our
own style provider.
* Font setting is exposed to the user using a new optional
Q-Reg "lexer.font". The numeric part is the point size
multiplied with 100 (fractional point size).
* Font setting in lexer.auto is skipped in Curses
where it is irrelevant anyway to speed up startup.
* Perhaps the "Monospace" font name is also a good default
value instead of Courier?
fixup
|
|
* the lexer names used in SciTE property files are not SCLEX constants
but the internal LexerModule names, so auto-generated SciTECO lexer
configurations can only be set by name, i.e. via SETLEXERLANGUAGE,
since we cannot easily map those names to SCLEX constants.
* should be about as fast as using SCI_SETLEXER (since SciTECO has to
look up symbolic names as well at runtime).
* this especially fixes opening *.mak files -- often Makefiles
but identified as "Mako" files. The macro "lexer.set.mako" used
the wrong SCLEX_ symbol.
* will also fix the HTML and all other lexers that use the
SCLEX_HTML/hypertext lexer.
* all lexer files have been updated, to be more compatible
with scite2co.lua's output. This eases lexer updates in the
future.
|
|
* use black on light white as the default popup colors
(e.g. in --no-profile mode). this looks less annoying than
black on light blue and is more often more readable
(since light blue will be rendered quite dark often).
It's no longer necessary to highlight the popup with (distinct)
colors.
Keeping the foreground black ensures that there's a brighter
foreground color for bold entries in case the terminal does
not support bold fonts.
* the `terminal.tes` scheme keeps the default popup style.
However since it uses white on black as the default colors,
this will often still stand out from the message line
(on 16 color terminals).
* `solarized.tes` now uses a similar high-contrast popup style
with either a bright or dark background.
The foreground colors have been chosen so that bright variants
exist for non-bold terminals - although these bright variants
do not stand out very much.
|
|
* see http://ethanschoonover.com/solarized
* I don't know if I want this port to be linked into
the main solarized repository as it is certainly not perfect.
* However both light and dark modes are supported and
usable since to SciTECO's new theming support.
* Set -U[solarized.light] before munging to enable light
mode.
* Registers function key F5 to toggle between light and
dark modes.
* Works on ncurses (with some restrictions) and almost all
other PDCurses ports.
GTK+ also works somewhat, but not all parts of the GTK+
UI are currently themable.
|
|
* the RGB values of the 8 standard colors defined by color.tes
were wrong (i.e. did not correspond to the normal 8 color codes
defined by Scinterm but only the bright versions).
Except for `color.black` which referred to terminal color 0.
* now we define the 16 colors defined by Scinterm, allowing color
schemes to explicitly use bright color versions without using the
bold attribute. On 8 color terminals, the bold attribute might
still be the only way to get a bright color.
* terminal.tes: Use bright default color instead of relying on bold
to get bright color versions. This is especially important for
comments which where relied on bold black to be rendered grey.
This did not work by default on terminals supporting bold fonts
(e.g. OS X Terminal) or GTK+. The scheme now works on more
terminals out of the box and on GTK+ and is thus a good default
color scheme.
* Color schemes will now also define the default style, the line number
style and caret foreground/background.
`color.calltip` is now also defined for STYLE_CALLTIP and can later
be used to style SciTECO's custom popup widget.
|
|
* added a new OPTIONAL behaviour for QRegSpecMachines
* allows you to implement commands that have an optional Q-Register
argument that should not be initialized if undefined.
* Using QRegSpecMachine::fail() you may still check for existence of
the register conditionally to emulate the QREG_REQUIRED behaviour.
* Using :Q for checking for register existence makes sense, because
usually you will want to check for both existence and non-emptyness
as in :Qq">. So in this common case, you no longer have to
keep in mind that the register may also be undefined.
* This finally allows us to create arrays in the Q-Register
tables without keeping a separate entry for the number of elements.
E.g. an array.0 to array.N can be iterated like this:
0Ui <:Q[array.^E\i]:; ! work with element i ! %i>
|
|
* this simplifies profile setup
* should anybody wish to load the default function key macros but
not enable function key support, he/she can still explicitly call
"64,0ED" to disable them again.
|
|
* ^FCLOSE is inserted when the "Close" key is pressed.
It is used by the GTK+ UI to deliver window close requests
and SIGTERM occurrences.
(this replaces the "Break" key used before in the GTK+ UI).
* The default action of ^FCLOSE is to quit SciTECO, therefore
window closing is possible even in --no-profile mode for instance.
* fixed a minor memleak in Cmdline::fnmacro()
* added ^FCLOSE implementation to fnkeys.tes to insert EX.
This currently has the disadvantage of overwriting
the error message with syntax errors if there are modified buffers
but it will at least not close the window if there are modified
buffers.
* SIGTERM will now be similar to SIGINT by default instead of
terminating SciTECO right away.
* the GTK+ UI handles SIGTERM by emulating the "close" key while
still interrupting like SIGINT.
* GTK+: SIGTERM and ^C will interrupt by sending SIGINT to the
entire process group instead of simply setting `sigint_occurred`.
This fixes interrupting EC and EG commands with long-running
or hanging programs and is relevant to the solution of #4.
|
|
* The unnamed buffer must be handled separately since the "lexer.test..." macros
assume that register "*" is non-empty.
Else it will be configured for some arbitrary lexer.
* this was a regression compared to v0.6.4
|
|
* EN may now be used for matching file names (similar to fnmatch(3)).
This is used to check the current buffers file extension in the
lexer configuration macros instead of using expensive Q-Register
manipulations.
This halves the overall startup time - it is now acceptable even
with the current amount of lexer configurations.
* EN may now be used for checking file types.
session.tes has been simplified.
* BREAKS macro portability (EN now has 2 string arguments).
* The Globber class has been extended to allow filtering of
glob results by file type.
|
|
* these are still not all languages supported by Scintilla.
scite2co.lua does not do a good job of generating styles when
SciTE's property files use hardcoded colors/fonts.
This commit only includes reasonably good conversion results.
The remaining languages need some additional manual labor.
* Even these lexers are not perfect and should be revised by comparing
them with SciTE's properties.
* So many lexers make the "lexer.auto" macro too slow.
We need some optimization. E.g. the search-command optimization
described in TODO, or an extended EN command for globbing manually
specified file names.
|
|
* they are updated with the results of scite2co.lua
This makes it easier in the future to update lexer settings
based on the property files of new SciTE releases.
|
|
SciTE properties files
|
|
* fnkeys.tes has been updated to enable the command line
editing macros (cursor keys, etc.) only in the "start" state.
This avoids the annoying effect of inserting the macros
into string arguments where they have no effect and must be
rubbed out again.
|
|
* this is recommended by Automake since wildcards are not
portable. However we rely on GNU Make extensions in other
places.
* This fixes out-of-source builds.
* The lists can be updated relatively easily with SciTECO
(EN command...)
|
|
It reinserts when the immediate editing modifier is disabled and
rubs out when it is enabled - without modifying the state of the
^G modifier.
|
|
* session.hg sets up the buffer session in the current
Mercurial repository
* session.vcs is a convenience macro that may be used in
profiles to enable buffer sessions per repo for all supported
VCS (Git, Hg and SVN)
|
|
Subversion working copy
* it uses "svn info --xml" since otherwise the output of "svn info" might
be localized.
|
|
automatically when files are given.
this allows you to use sciteco in a Git repository to edit a specific file,
without changing the buffer session. Also useful if SciTECO is used as the GIT_EDITOR
without thrashing the repository's session every time a commit message is edited.
|
|
|
|
$SCITECOPATH on Windows
* $SCITECOCONFIG has been introduced, so have a macro-accessible location
for the profile, buffer session etc.
This is set to the program dir on Windows. That way, the config files
will be found, regardless of the current working dir, but it may also
be set up for Unix-like environments on Windows.
* $SCITECOPATH defaults to the program dir + "/lib" now on Windows.
* The default profile is now always called ".teco_ini". Also on Windows.
Platform differences like this would need to be documented.
* The sample teco.ini has been renamed to "sample.teco_ini" for clarity
|
|
* EW can save Q-Registers now
* the new E% may be used to save a q-register without making it
the current document
|
|
|
|
this is more consistent with SciTECO's idea of abstract registers
and allows the currend buffer to be saved on the Q-Register stack.
This allows the idiom: [* ! ...change current buffer... ! ]*
|