Age | Commit message (Collapse) | Author | Files | Lines |
|
* The PACKAGE_URL_DEV is also mentioned in --help output and sciteco(1)
|
|
|
|
* It is no longer possible to accidentally open save point files
of the same or another SciTECO instance when typing something like
EB*.cpp$
* The use of a trailing ~ is common among editors. These files
will be recognized more easily as temporary by users.
* People will often already have VCS ignore rules for files with
trailing tilde. Therefore SciTECO savepoints will often be
already ignored by VCS.
* Since they still have a unique ".teco" prefix, they will not
be confused by other programs as backup files.
* Also mention in sciteco(1) that save point files are hidden on
Windows.
|
|
We used g_path_get_dirname() which does not always return strict prefixes
of the input file name. For file names without directory, it returns "."
(the current directory). This is useful for passing that directory to
functions expecting a proper directory (like g_dir_open()) but was
unsuitable for building file name candidates for autocompletion.
Therefore, we tried to determine if the dirname is a prefix of the filename.
This however failed for "hidden" file names beginning with dot.
All in all it is easier to calculate our own directory name based on
the previously calculated basename than to handle the current-directory
case with g_path_get_dirname(). Now we'll get "" for the current directory,
so we have to handle the empty-string-is-current-dir case.
|
|
this looks better in Unicode terminals
|
|
* for historic reasons, the backspace key can be transmitted as
^H by the terminal. Some terminal emulators might do that - these
are fixed by this commit.
* Use CTL_KEY('H') instead of standard C '\b' as the former is less
ambiguous given the confusion around the backspace character.
|
|
CTL_KEY_ESC_STR
* the reason for the CTL_KEY() macro is to get the control character
resulting from a CTRL+Key press -- at least this is how SciTECO
presents these key presses.
It is also a macro and may be resolved to a constant expression,
so it can be used in switch-case statements.
Sometimes it is clearer to use standard C escape sequences (like '\t').
* CTL_KEY('[') for escape is hard to read, so I always used '\x1B' which
is even more cryptic.
|
|
* the popup resetting was done after character insertion, so typing
0EB would clear the popup immediately
* the new implementation is functionally equivalent to the
old pre-reinsertion-commandline-handling, by resetting the popup
based on the immediate editing command before insertion
|
|
* has been changed in Scinterm some time ago
* I don't know if defining this makes actually any difference,
but Jinx does it.
|
|
* the Curses window associated with a Scinterm Scintilla view is
INDEED deleted automatically by scintilla_delete()
* The Scinterm documentation is WRONG on this.
* This has been broken in the SciTECO code for a long time.
Perhaps, for some obscure reason, this does not cause any
problems on NCurses. It results in instant segfaults on
MinGW/PDCurses though.
|
|
* 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.
|
|
when hacking Scintilla, it is useful to recompile it as
necessary. Since SciTECO calls the Scintilla/Scinterm Makefile
recursively, we do not know the libraries dependencies in
SciTECO's build system. It therefore makes sense to define
externally built targets as phony, so the recursive make
is called every time scintilla.a is required. If scintilla.a
is already up to date, the additional recursive make call
won't hurt.
|
|
warnings
* Clang++ does not see that the PC will never go beyong g_assert(false),
and so reports about possible unitialized variables
|
|
we are not guaranteed to reach the start parser state
again if the command is not terminated on the rubbed out
command line
|
|
|
|
|
|
|
|
* They are harmful. I removed most of them a long time ago
but kept some for their documenting character.
However, they will always result in additional checks (runtime
penalty) when the corresponding functions get called and cannot ensure that
only the declared exceptions are thrown at compile time.
|
|
|
|
* we cannot prevent GTK from delivering the function key presses,
as we can on Curses. Therefore Cmdline::fnmacro() checks again if
function keys are enabled.
|
|
* this is a Linux/glibc-only optimization
|
|
removal of ^T
|
|
(also replaces ^T)
* CTRL+G toggles the behaviour of the rubout (Backspace, ^W, ^U) commands:
When the so called immediate editing command modifier is enabled/active,
the rubout commands will do the opposite and insert from the rubbed out
command line.
This command is somewhat similar to Emacs' C-g command.
* The CTRL+G command also replaces the ^T immediate editing command
for auto-completing filenames in any string argument.
Now the TAB key can be used for that purpose after activating the
^G modifier.
^T is a classic TECO command that will be supported sooner or later
by SciTECO, so it's good to have it available directly.
|
|
cleanup/refactoring
* characters rubbed out are not totally removed from the command line,
but only from the *effective* command line.
* The rubbed out command line is displayed after the command line cursor.
On Curses it is grey and underlined.
* When characters are inserted that are on the rubbed out part of the command line,
the cursor simply moves forward.
NOTE: There's currently no immediate editing command for reinserting the
next character/word from the rubbed out command line.
* Characters resulting in errors are no longer simply discarded but rubbed out,
so they will stay in the rubbed out part of the command line, reminding you
which character caused the error.
* Improved Cmdline formatting on Curses UI:
* Asterisk is printed bold
* Control characters are printed in REVERSE style, similar to what
Scinterm does. The controll character formatting has thus been moved
from macro_echo() in cmdline.cpp to the UI implementations.
* Updated the GTK+ UI (UNTESTED): I did only, the most important API
adaptions. The command line still does not use any colors.
* Refactored entire command line handling:
* The command line is now a class (Cmdline), and most functions
in cmdline.cpp have been converted to methods.
* Esp. process_edit_cmd() (now Cmdline::process_edit_cmd()) has been
simplified. There is no longer the possibility of a buffer overflow
because of static insertion buffer sizes
* Cleaned up usage of the cmdline_pos variable (now Cmdline::pc) which
is really a program counter that used a different origin as macro_pc
which was really confusing.
* The new Cmdline class is theoretically 8-bit clean. However all of this
will change again when we introduce Scintilla views for the command line.
* Added 8-bit clean (null-byte aware) versions of QRegisterData::set_string()
and QRegisterData::append_string()
|
|
string-utils.cpp and string-utils.h
* also improved performance of String::append() by using g_realloc()
* added String::append() variant for non-null-terminated strings
|
|
* acts as a safe-guard against uninterrupted infinite loops
or other operations that are costly to undo in interactive mode.
If we're out of memory, it is usually too late to react properly.
This implementation tries to avoid OOMs due to SciTECO behaviour.
We cannot fully exclude the chance of an OOM error.
* The undo stack size is only approximated using the
UndoToken::get_size() method.
Other ways to measure the exact amount of allocated heap
(including size fields in every heap object or using sbrk(0) and
similar) are either costly in terms of memory or platform-specific.
This implementation does not need any additional memory per heap
object or undo token but exploits the fact that undo tokens
are virtual already. The size of an undo token is determined
at compile time.
* Default memory limit of 500mb should be OK for most people.
* The current limit can be queried with "2EJ" and set with <x>,2EJ.
This also works interactively (a bit tricky!)
* Limiting can be disabled. In this case, undo token processing
is a bit faster.
* closes #3
|
|
without a corresponding loop start (<)
* assertions were introduced very early when there was no proper error handling
in SciTECO. However it points to a macro programming error instead of
a SciTECO programming error and should not crash the editor.
* Perhaps it would be best to check for this kind of "syntax" error also
in parse-only modes. This is not done currently.
* part of the solution to issue #3
|
|
|
|
|
|
* since SCI_SETDOCPOINTER resets character representations
(should probably be submitted as a bug to Scintilla)
we have to reset the representations each time we load
a q-register into the q-reg view.
* since the SCI_SETREPRESENTION call does not do any redrawing
(and it would be very slow if it did), the lines with control
characters were laid out wrong (too much spaces).
This happened when editing a q-reg or the command-line.
* Since it is not obvious how to fix Scintilla's behaviour here,
we work around the issue by temporarily disabling the layout
cache.
|
|
* 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.
|
|
* also did some whitespace cleanup in SciTECO now that tabs are
displayed properly
|
|
the most noticable change is that a scroll-bar is displayed
by default (Curses UI)
* INSTALL instructions updated
|
|
|
|
|
|
* the ^I command was altered to insert indention characters
rather than plain tabs always.
* The <TAB> immediate editing command was added for all
insertion arguments (I, ^I but also FR and FS)
* documentation was extended for a discussion of indention
|
|
this is because ownership of the GError may be passed to GlibError()
|
|
* when throwing GlibError(), this is taken care of automatically.
* fixes a memleak since there may be resources associated with the
GError.
|
|
earlier
* Debian 7 is still at libglib v2.33 and since it should be
supported, I reimplemented the missing function (UNIX-only).
* This workaround can be removed once libglib v2.34 becomes common place.
Closes #2
|
|
|
|
|
|
* for non-existing directories, NULL was passed to g_dir_read_name().
This resulted in Glib errors being printed to stdout/stderr.
* this was broken in commit 427c9d
|
|
|
|
Windows
* this is actually UNTESTED on Windows
|
|
optimized screen refreshing/redrawing
* pressing e.g. TAB when the popup is showing a list of auto-completions
will show the next page, eventually beginning at the first one again.
* do not redraw curses windows in the UI methods directly. this resulted
in flickering during command-line editing macros and ordinary macro calls
because the physical screen was updated immediately.
Instead, window refreshing and updated is done centrally in
event_loop_iter() only after a key has been processed.
Also we use wnoutrefresh() and doupdate() to send as little to the
terminal (emulator) as possible.
|
|
* simplified code
* fixed spurious empty lines in the popup which truncated file names/tokens
that would otherwise be displayed
* fixed memleak when freeing the popup entry list
|
|
* added platform-dependant file_is_visible() function
|