From f421c8fcf3c47c78c666906165006969ff21429e Mon Sep 17 00:00:00 2001 From: Robin Haberkorn Date: Thu, 27 Feb 2025 11:38:42 +0300 Subject: implemented ncurses clipboard support via external processes * As an alternative to OSC-52, which is rarely supported by terminal emulators. * Makes the new mouse support much more useful since you rely on good builtin clipboard support. You can no longer e.g. just double-click a word to copy it into the "primary" selection as terminal emulators do by default. * Set $SCITECO_CLIPBOARD_SET/GET e.g. to xclip, way-copy, pbcopy or some wrapper script. * This is currently using POSIX-specific popen() API, so it behaves a bit different to command execution via EC/EG. I am not sure if it's worth rewriting with the GSpawn-API, since it will be used only on POSIX anyway and a GSpawn-based implementation is likely to be a bit larger. * Should there be some small command-line utility for interacting (esp. pasting) via OSC-52, built-in OSC-52 support could well be removed from SciTECO. Currently, I know only of https://github.com/theimpostor/osc/ and it requires very recent Go compilers. (I still haven't tested it. Quite possibly, pasting when run as a piped command is impossible.) --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index e355c24..69e98e8 100644 --- a/configure.ac +++ b/configure.ac @@ -173,7 +173,7 @@ AC_CHECK_FUNCS([memset setlocale strchr strrchr fstat sscanf], , [ # glib defines G_OS_UNIX instead... case $host in *-*-linux* | *-*-*bsd* | *-*-darwin* | *-*-cygwin* | *-*-haiku*) - AC_CHECK_FUNCS([realpath readlink pathconf fchown dup dup2 getpid open read kill mmap], , [ + AC_CHECK_FUNCS([realpath readlink pathconf fchown dup dup2 getpid open read kill mmap popen pclose], , [ AC_MSG_ERROR([Missing libc function]) ]) AC_SEARCH_LIBS(dladdr, [dl], , [ -- cgit v1.2.3