aboutsummaryrefslogtreecommitdiffhomepage
AgeCommit message (Collapse)AuthorFilesLines
2025-02-16implemented mouse support via special ^KMOUSE and <EJ> with negative keysRobin Haberkorn11-61/+439
* You need to set 0,64ED to enable mouse processing in Curses. It is always enabled in Gtk as it should never make the experience worse. sample.teco_ini enables mouse support, since this should be the new default. `sciteco --no-profile` won't have it enabled, though. * On curses, it requires the ncurses mouse protocol version 2, which will also be supported by PDCurses. * Similar to the Curses API, a special key macro ^KMOUSE is inserted if any of the supported mouse events has been detected. * You can then use -EJ to get the type of mouse event, which can be used with a computed goto in the command-line editing macro. Alternatively, this could have been solved with separate ^KMOUSE:PRESSED, ^KMOUSE:RELEASED etc. pseudo-key macros. * The default ^KMOUSE implementation in fnkeys.tes supports the following: * Left click: Edit command line to jump to position. * Ctrl+left click: Jump to beginning of line. * Right click: Insert position or position range (when dragging). * Double right click: insert range for word under cursor * Ctrl+right click: Insert beginning of line * Scroll wheel: scrolls (faster with shift) * Ctrl+scroll wheel: zoom (GTK-only) * Currently, there is no visual feedback when "selecting" ranges via right-click+drag. This would be tricky to do and most terminal emulators do not appear to support continuous mouse updates.
2025-02-15fixup: set the GH_TOKEN environment variable to fix using the `gh` tool in ↵Robin Haberkorn1-0/+2
nightly builds
2025-02-15nightly builds: use Github API to download pkg2appimage toolRobin Haberkorn1-2/+2
* the filenames contain commit hashes now, so it's no longer trivial to do with wget * should fix nightly builds
2025-02-15redefining labels is a warning nowRobin Haberkorn5-64/+94
* Allowing label redefinitions might have been useful when used as comments, since you will want to be able to define arbitrary comments. However as flow control constructs, this introduced a certain ambiguity since gotos might jump to different locations, depending on the progression of the parser. * On the other hand, making label redefinition an error might disqualify labels as comments when writing or porting classic TECO code. Therefore, it has been made a warning as a compromise. * Added test case
2025-01-20AppImage: added AppStream metadataRobin Haberkorn4-0/+58
Should improve the SciTECO site at the AppImages Hub (appimage.github.io). We will have to make another PR before the site gets updated.
2025-01-19Mac OS nightly builds are relocatable nowRobin Haberkorn1-1/+4
* This means you should be able to install them into non-root directories. E.g.: sudo installer -pkg sciteco-curses_nightly_macos_x86_64.pkg -target test-installation
2025-01-19support :EF for saving a file before closing itRobin Haberkorn4-46/+60
Analoguous to :EX, but always saves the file like EW$, not only if it's dirty.
2025-01-19file and directory auto completions can now be case-insensitiveRobin Haberkorn2-8/+70
* This is not simply determined at compile-time but queries the concrete path at least on Windows and OS X. * The Windows implementation is kind of hacky and relies on undocumented behavior. It's also not even tested yet! * On Linux and FreeBSD completions will always be case-sensitive as they used to be. There does not appear to be any API to query case sensitivity of a given path or even the entire file system. At most, we could white-list a number of case-insensitive file systems.
2025-01-13updated copyright to 2025Robin Haberkorn67-67/+67
2025-01-13mention the Alpine package and updated TODORobin Haberkorn3-4/+18
2024-12-30support +line[,column] and filename:line:column syntaxes when opening filesRobin Haberkorn7-35/+94
* This is done via the new opener.tes in the standard library. * Some programs that use $EDITOR expect the +line syntax to work. * You can copy filename:line:column directly from GCC error messages and filename:line from grep output. * Since there may be safe file names beginning with "+" or containing colons, there needs to be a way to turn this off, especially for scripts that don't know anything about the filenames to open. This is done with "--". Unfortunately, the first "--", that stops parameter processing, is always removed from the command line and not passed down into TECO land. This is not a problem for stand-alone scripts, since the script filename is already stopping option processing, so "--" would get passed down. But when calling the profile via `sciteco -- ...`, you could prevent leading minus signs to cause problems but since the `--` is removed, opener.tes cannot use it as a hint. Therefore, we introduced `-S` as a new alternative to `--`, that's always passed down as `--` (i.e. it is equivalent to "-- --"). In other words, `sciteco -S *` will always open exactly the specified files without any danger of misinterpreting certain file names. Should we ever switch to a custom option parsing algorithm, we might preserve "--" (unless after --mung) and thus get rid of "-S". * This advanced behavior can be tweaked by the user relatively easily. In the easiest case, we could replace M[opener] with <:L;R 0X.f [* @EB/^EN.f/ ]* L> in ~/.teco_ini to completely disable the special syntax.
2024-12-28updated cheat sheet: @Xq, S...$^SC and lots of microtypographic improvementsRobin Haberkorn1-46/+54
2024-12-28website: added v2.3.0 screenshotRobin Haberkorn1-0/+4
2024-12-28Debian: disabled parallel builds when running the test suiteRobin Haberkorn2-3/+3
* Hopefully makes the log easier to read in case of failures. There may still be 2 runs concurrently since we build Curses and Gtk in parallel. * Updated homepage. * Ubuntu plucky builds are failing. See https://launchpadlibrarian.net/765999455/buildlog_ubuntu-plucky-amd64.sciteco_2.3.0-0ppa1~plucky1_BUILDING.txt.gz This may have been a spurious failure due to xvfb-run. It may be less likely with --no-parallel. Theoretically we could bump the Debian package version in order to test that, but the PPA is practically not used by anybody anyway.
2024-12-28Scintilla/Gtk apparently no longer depends on g_module and we draw in ↵Robin Haberkorn1-2/+1
g_module along with glib anyway
2024-12-28avoid some compiler warningsRobin Haberkorn3-4/+4
2024-12-27fixup: fixed installation of dependencies for win64-gtkRobin Haberkorn1-4/+4
2024-12-27nightly builds now include 64-bit Windows builds (MINGW64)Robin Haberkorn2-30/+28
* 32-bit binaries have been dropped, even though we could build both. But there is virtually no demand for 64-bit binaries left. * I continue to build 32-bit versions during CI, so that at least something still builds and tests under 32-bit.
2024-12-27distribute.mk: added Poudriere commands (FreeBSD packaging tests)Robin Haberkorn1-0/+14
* This does not build the current source tree. You must still have a properly set up ports tree somewhere.
2024-12-25prepared v2.3.0 releasev2.3.0Robin Haberkorn4-7/+45
2024-12-25FreeBSD port: overwrite BINMODE, fixing `make package` without rootRobin Haberkorn1-0/+4
Turns out that the FreeBSD ports Makefiles install programs and scripts with 0555 by default, i.e. without write permissions. This broke the install-exec-hook unless building as root. Unfortunately, this also broke the Poudriere builds at the FreeBSD build servers. See https://pkg-status.freebsd.org/package19/data/141amd64-default-build-as-user/aa1f9b124e36/logs/errors/sciteco-curses-2.2.0.log
2024-12-24added session.fossil for setting up buffer sessions per Fossil repositoryRobin Haberkorn1-0/+0
* This goes into session.vcs as well. * `fossil info` does not allow printing only the local-root property, so we have to do some parsing afterwards.
2024-12-24simplified session.svn: no need to mess around with XMLRobin Haberkorn1-0/+0
* In fact, since SVN has --no-newline, this is even simpler than on Git and Mercurial. * This requires at least Subversion v1.9 (2015, so should be safe).
2024-12-24added AX_REQUIRE_DEFINED() macro: should fix builds on systems without the ↵Robin Haberkorn1-0/+37
autoconf archive (including CI)
2024-12-24added AX_WITH_CURSES for more robust ncurses checksRobin Haberkorn5-16/+601
* Turns out that on SunOS/OmniOS the ncurses port does not ship with a ncursesw pkg-config file, but the ncurses file is for a version, that does contain widechar support as well. * Instead of adding yet another recursive PKG_CHECK_MODULES() call, we now use the AX_WITH_CURSES() macro, which is probably more robust. This should at least fix ./configure on OmniOS. * It also adds a number of feature C macros, that could be useful to check in the future. * At the moment, we strive to support all X/Open-compatible Curses libraries, but both enhanced and color functions are required. Therefore plain SVr4 Curses is not supported. * source: https://www.gnu.org/software/autoconf-archive/ax_with_curses.html
2024-12-24introduced true block and EOL commentsRobin Haberkorn83-196/+297
* The previous convention of !* ... *! are now true block comments, i.e. they are parsed faster, don't spam the goto table and allow embedding of exclamation marks - only "*!" terminates the comment. * It is therefore now forbidden to have goto labels beginning with "*". * Also support "!!" to introduce EOL comments (like C++'s //). This disallows empty labels, but they weren't useful anyway. This is the shortest way to begin a comment. * All comment labels have been converted to true comments, to ensure that syntax highlighting works correctly. EOL comments are used for single line commented-out code, since it's easiest to uncomment - you don't have to jump to the line end. This is a pure convention / coding style. Other people might do it differently. * It's of course still possible to abuse goto labels as comments as TECO did for ages. * In lexing / syntax highlighting, labels and comments are highlighted differently. * When syntax highlighting, a single "!" will first be highlighted as a label since it's not yet unambiguous. Once you type the second character (* or !), the first character is retroactively styled as a comment as well.
2024-12-23Curses: don't install PNG iconsRobin Haberkorn4-10/+7
* They are used at runtime only by the GTK port. * Their existence can cause problems if OS-specific build systems have to clean these files from the staging directory afterwards. This was the case on FreeBSD where the committer refused to remove these files after installation. In the official FreeBSD port, we therefore currently ship the PNG icons unnecessarily. * They are now installed and shipped only on GTK builds.
2024-12-23uploaded target release to v2.3.0Robin Haberkorn2-2/+2
2024-12-22freebsd port: enabled LTORobin Haberkorn1-0/+2
This is not done automatically when building ports. The FreeBSD binaries were thus the only ones without LTO. We should prefer WITH_LTO, even once we add something like --enable-lto, as WITH_LTO enables Clang-specific ThinLTO support.
2024-12-22updated TODORobin Haberkorn1-17/+26
2024-12-22Curses: fixed inserting null-byte (^@) by pressing Ctrl+@Robin Haberkorn1-3/+3
* g_utf8_get_char_validated() returns -2 for null-bytes (sometimes!?)
2024-12-22fixed lexing (syntax highlighting) of the null-character (^@) in SciTECO codeRobin Haberkorn3-4/+8
* Apparently g_utf8_get_char_validated() sometimes(!) returns -2 for null-characters, so it was considered an invalid byte sequence. * What's strange and unexplainable is that other uses of the function, as are behind nA and nQq, did not cause problems and returned 0 for null-bytes. * This also fixes syntax higlighting of .teco_session files which use the null-byte as the string terminator. (.teco_session files are not highlighted automatically, though.)
2024-12-22fixed indention in interface-curses/interface.cRobin Haberkorn1-9/+9
This is a purely cosmetic change.
2024-12-22fixed crashes while setting special Q-Registers with EU (string-building ↵Robin Haberkorn3-7/+17
characters) * The teco_qreg_vtable_t::get_string() method should support returning the length optionally (may be NULL). This already worked with teco_doc_get_string(), even though it wasn't documented, and therefore didn't cause problems with regular Q-Registers.
2024-12-22support external Scintilla lexer libraries and Scintillua in particularRobin Haberkorn5-12/+124
* @ES/SCI_SETILEXER/lib^@name/ now opens the lexer <name> in library <lib>. * You need to define the environment variable $SCITECO_SCINTILLUA_LEXERS to point to the lexers/ subdirectory (containing the *.lua files). Perhaps this should default to the dirname of <lib>? * The semantics of SCI_NAMEOFSTYLE have been changed: It now returns style ids when given style names, so you can actually write Scintillua lexer *.tes files. This will be superfluous if we had a way to return strings from Scintilla messages into Q-Registers, e.g. 23@EPq/SCI_NAMEOFSTYLE/. * We now depend on gmodule as well, but it should always be part of glib. It does not change the library dependencies of any package. It might result in gmodule shared libraries to be bundled in the Win32 and Mac OS packages if they weren't already.
2024-12-21slightly improved the hash bang replacement on SciTECO scripts after ↵Robin Haberkorn1-1/+1
installation * use the new ::FS and ^Q commands
2024-12-17freebsd port: synced with the version in FreeBSD portsRobin Haberkorn2-2/+3
Rodrigo Osorio re-included the PNGs even for sciteco-curses. Should be fixed at the Autoconf-level, by only installing the PNGs on GTK.
2024-12-17updated Scintilla to v5.5.4: contains a few optimizationsRobin Haberkorn1-0/+0
Unfortunately, it does not help with the slowdowns when editing files with very long lines.
2024-12-17sped up opening very large UTF-8 files by temporarily disabling the ↵Robin Haberkorn1-11/+33
line-character index * checks for character consistency (of UTF-8 byte sequences) were slowing down things significantly in Scintilla * It got even worse if the file indeed contained non-ANSI codepoints as reading in chunks of 1024 would sometimes mean that incomplete byte sequences would be read. Some large 160mb test files wouldn't load even after minutes. They now load in seconds. * This does NOT yet solve the slowdowns when operating on very long lines.
2024-12-16README: mention FreeBSD port and added link to the newsgrouper.org.uk web ↵Robin Haberkorn2-5/+11
frontend to alt.lang.teco * This appears to be the only remaining working web frontend to alt.lang.teco. * There is https://www.usenetarchives.com/threads.php?id=alt.lang.teco which has an archive of very old posts, which is cool, but they appear to have stopped synchronizing somewhere around 2022. * https://alt.lang.teco.narkive.com/ is broken and also not fully synchronized. * Google Groups stopped working in February 2024. * The FreeBSD port isn't yet in any quartely branch, so it's unlikely somebody can just pkg install it (yet).
2024-12-14README/NEWS: better use links to the Libera webchat - Github does not render ↵Robin Haberkorn2-2/+2
ircs-URLs (refs #29)
2024-12-14README: mention the new IRC chatroomRobin Haberkorn2-4/+2
2024-12-14update sciteco.tes: this again highlights commands, but not Q-Register namesRobin Haberkorn1-2/+2
It's a bit easier on the eyes.
2024-12-14fixed ^Y after FK...$: take the deleted text into accountRobin Haberkorn1-2/+8
* I.e. you can now write FK...$^YD to delete up to AND the matched pattern.
2024-12-13SciTECO lexing: fixed styling of commands after dollar or escape (when used ↵Robin Haberkorn1-1/+2
as a separate command)
2024-12-13fixed lexer.checkheader: restore dot in case of successRobin Haberkorn1-1/+1
2024-12-13fixup 244a54a18b7db6af177c9d10f3224772f08d7484: abuse the Scintilla view's ↵Robin Haberkorn3-11/+13
"identifier" to enable lexing in the container * SCI_SETILEXER(NULL) is not a reliable way to do that since that's the default for all views. * This was breaking the git.tes lexer for instance and was unnecessarily driving teco_lexer_style() on plain-text documents. * Since we currently do not implement the ILexer5 C++ interface and teco_view_t is just a pointer alias, we are abusing the view's "identifier" instead. This is probably sufficient, as long as there is only one lexer "in the container". Otherwise, there should perhaps be a single C++ class that does nothing but wrapping a callback into an ILexer5 object with a C ABI.
2024-12-13document the FK...$^SR idiomRobin Haberkorn3-2/+3
* We don't actually have to negate ^S results after FK. For deleting the matched pattern, you can use ^YD or -^SD.
2024-12-13updated README: mention community resourcesRobin Haberkorn1-0/+10
2024-12-13updated INSTALL: how to install dependencies on Fedora and FreeBSDRobin Haberkorn1-0/+10