summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-05-17Merge pull request #211 from jakubrekowski/patch-1Luke Smith
Added info about include X11 in ubuntu.
2020-05-17Added info about include X11 in ubuntu.Jakub Rekowski
Added comment with X11 path in systems based on ubuntu.
2020-05-16Revert "support REP (repeat) escape sequence"Hiltjo Posthuma
This reverts commit e8392b282c2eaa28725241a9612804fb55113da4. There is currently a bug in older ncurses versions (like on OpenBSD) where a fix for a bug with REP is not backported yet. Most likely in tty/tty_update.c: Noticed while using lynx (which uses ncurses/curses). To reproduce using lynx: echo "Z0000000" | lynx -stdin or using the program: int main(void) { WINDOW *win; win = initscr(); printw("Z0000000"); refresh(); sleep(5); return 0; } This prints "ZZZZZZZ" (incorrectly).
2020-05-16support REP (repeat) escape sequenceAvi Halachmi (:avih)
The sequence \e[Nb prints the last printed char N (more) times if it's printable, and it's ignored after newline or other control chars. This is Ecma-048/ANSI-X3.6 sequence and not DEC VT. It's supported by xterm, and ncurses uses it when possible, e.g. when TERM is xterm* (and with this commit also st*). xterm supports only codepoints<=255, possibly due to internal limits. We support any value/codepoint which was placed in a cell. To test: - tput rep 65 4 -> prints 'AAAA' - printf "\342\225\246\033[4b" -> prints U+2566 1+4 times.
2020-05-16Add rin terminfo capabilityRoberto E. Vargas
Tianlin Qu discovered that st is missing rin (scroll back #1 lines).
2020-05-16Make shift+wheel behaves as shift+Prev/Nextk0ga
St uses a very good hack where mouse wheel genereates ^Y and ^E, that are the same keys that less and vi uses for backward and fordward scrolling. Scroll, as many terminal emulators, use shift+Prev/Next for scrolling, but it is also using ^E and ^Y for scroling, characters that are reserved in the POSIX shell in emacs mode for end of line and yanking, making scroll unsable in st. This patch adds a new hack, making shift+wheel returning the same sequences than shift+Prev/Next, meaning that scroll or any other similar program will not be able to differentiate between them.
2020-05-13Merge pull request #208 from trissim/wal-oscLuke Smith
Pywal live reload with OSC patch and transparency fix
2020-05-13Reverted bg opacity back to 0.8 for upstream mergeTristan Simas
2020-05-13added the xclearwin patch to fix dirty borders after changing colorsTristan Simas
2020-05-13Added OSC patch and changes xsetcolorname for live reloading pywal colors ↵Tristan Simas
while keeping transparency
2020-05-12Fix selection: selscrollJakub Leszczak
2020-05-12Fix selection: ignore ATTR_WRAP when rectangular selection in getselJakub Leszczak
2020-05-12Fix selection: selclear in tputcJakub Leszczak
2020-05-12Added ligatures patchmackarelfish
2020-05-09code-style: add fallthrough commentHiltjo Posthuma
Patch by Steve Ward, thanks.
2020-05-09optimize column width calculation and utf-8 encode for ASCIIHiltjo Posthuma
In particular on OpenBSD and on glibc wcwidth() is quite expensive. On musl there is little difference.
2020-05-09fix for incorrect (partial) written sequences when libc wcwidth() == -1Hiltjo Posthuma
Fix an issue with incorrect (partial) written sequences when libc wcwidth() == -1. The sequence is updated to on wcwidth(u) == -1: c = "\357\277\275" but len isn't. A way to reproduce in practise: * st -o dump.txt * In the terminal: printf '\xcd\xb8' - This is codepoint 888, on OpenBSD it reports wcwidth() == -1. - Quit the terminal. - Look in dump.txt (partial written sequence of "UTF_INVALID"). This was introduced in: " commit 11625c7166b7e4dad414606227acec2de1c36464 Author: czarkoff@gmail.com <czarkoff@gmail.com> Date: Tue Oct 28 12:55:28 2014 +0100 Replace character with U+FFFD if wcwidth() is -1 Helpful when new Unicode codepoints are not recognized by libc." Change: Remove setting the sequence. If this happens to break something, another solution could be setting len = 3 for the sequence.
2020-05-09tiny code-style and typo-fix in commentHiltjo Posthuma
2020-05-09auto-sync: draw on idle to avoid flicker/tearingAvi Halachmi (:avih)
st could easily tear/flicker with animation or other unattended output. This commit eliminates most of the tear/flicker. Before this commit, the display timing had two "modes": - Interactively, st was waiting fixed `1000/xfps` ms after forwarding the kb/mouse event to the application and before drawing. - Unattended, and specifically with animations, the draw frequency was throttled to `actionfps`. Animation at a higher rate would throttle and likely tear, and at lower rates it was tearing big frames (specifically, when one `read` didn't get a full "frame"). The interactive behavior was decent, but it was impossible to get good unattended-draw behavior even with carefully chosen configuration. This commit changes the behavior such that it draws on idle instead of using fixed latency/frequency. This means that it tries to draw only when it's very likely that the application has completed its output (or after some duration without idle), so it mostly succeeds to avoid tear, flicker, and partial drawing. The config values minlatency/maxlatency replace xfps/actionfps and define the range which the algorithm is allowed to wait from the initial draw-trigger until the actual draw. The range enables the flexibility to choose when to draw - when least likely to flicker. It also unifies the interactive and unattended behavior and config values, which makes the code simpler as well - without sacrificing latency during interactive use, because typically interactively idle arrives very quickly, so the wait is typically minlatency. While it only slighly improves interactive behavior, for animations and other unattended-drawing it improves greatly, as it effectively adapts to any [animation] output rate without tearing, throttling, redundant drawing, or unnecessary delays (sounds impossible, but it works).
2020-05-06tmux fix, including compile-time errorsLuke Smith
2020-05-06auto-sync patchLuke Smith
2020-05-05boxdraw addedLuke Smith
2020-05-05cleanupLuke Smith
2020-04-30replace exit(3) by _exit(2) in signal handler sigchld()Jan Klemkow
exit(3) is not async-signal-safe but, _exit(2) is. This change prevents st to crash and dump core.
2020-04-28Merge branch 'pasbi-master'Luke Smith
2020-04-28less opaque to compensate for darker bgLuke Smith
2020-04-28regex updateLuke Smith
2020-04-28fix with upstreamLuke Smith
2020-04-27bump version to 0.8.3Hiltjo Posthuma
2020-04-19Update XIM cursor position only if changedIvan Tham
Updating XIM cursor position is expensive, so only update it when cursor position changed.
2020-04-16no longer embed dmenu to prevent error if dmenuLuke Smith
has no alpha patch
2020-04-15Merge branch 'master' of github.com:LukeSmithxyz/stLuke Smith
2020-04-15following links now separate scriptLuke Smith
this avoids the effects of swallow in dwm it also will not produce dmenu without found urls
2020-04-15cleanupLuke Smith
2020-04-11just remove the EOF messageHiltjo Posthuma
2020-04-11Add st-mono terminfo entryRoberto E. Vargas Caballero
This entry is intended for monocolor display and it is very helpful for color haters.
2020-04-11config.def.h: add a comment for the scroll variableHiltjo Posthuma
2020-04-11Fix small typosHiltjo Posthuma
2020-04-11Launch scroll program with the default shellQuentin Rameau
2020-04-11Update FAQ with the last modificationsRoberto E. Vargas Caballero
2020-04-11Add terminfo entries for backspace modeRoberto E. Vargas Caballero
St used to use backspace as BS until the commit 230d0c8, but due to general lack of knowledge of lusers, we moved to the most common configuration in linux to avoid answering the same question 3 times per month. With the most common configuration we have a backspace that returns a DEL, and we have a Delete key that doesn't return a DEL character neither a BS. When dealing with devices connected using a serial line (or even with Plan9) it is more common Backspace as BS and Delete as DEL. For this reason, st is not always the best tool when you talk with a serial device. This patch adds new terminfo entries for Backspace as BS and Delete as DEL. A patch for confg.h is also added, to make easier switch between both configurations.
2020-04-11Fix style issueRoberto E. Vargas Caballero
2020-04-11ttyread: test for EOF while reading ttyRoberto E. Vargas Caballero
When a read operation returns 0 then it means that we arrived to the end of the file, and new reads will return 0 unless you do some other operation such as lseek(). This case happens with USB-232 adapters when they are unplugged.
2020-04-11Add support for scroll(1)Roberto E. Vargas Caballero
Scroll is a program that stores all the lines of its child and be used in st as a way of implementing scrollback. This solution is much better than implementing the scrollback in st itself because having a different program allows to use it in any other program without doing modifications to those programs.
2020-04-10Merge pull request #190 from eGredius/patch-1Luke Smith
Get rid of NUL character in PS1
2020-04-10Get rid of NUL character in PS1GregW
The first grep in the original script will return "binary file matches" if there are NUL characters in PS1, e.g, emojis. The added line gets rid of NUL characters.
2020-04-10make argv0 not static, fixes a warning with tccHiltjo Posthuma
Reported by Aajonus, thanks!
2020-04-02mouseshortcuts: fix custom modifier on releaseAvi Halachmi (:avih)
This line didn't work at mshortcuts at config.h: /* mask button function arg release */ { ShiftMask, Button2, selpaste, {.i = 0}, 1 }, and now it does work. The issue was that XButtonEvent.state is "the logical state ... just prior to the event", which means that on release the state has the Button2Mask bit set because button2 was down just before it was released. The issue didn't manifest with the default shift + middle-click on release (to override mouse mode) because its specified modifier is XK_ANY_MOD, at which case match(...) ignores any specific bits and simply returns true. The issue also doesn't manifest on press, because prior to the event Button<N> was not down and its mask bit is not set. Fix by filtering out the mask of the button which we're currently matching. We could have said "well, that's how button events behave, you should use ShiftMask|Button2Mask for release", but this both not obvious to figure out, and specifically here always filtering does not prevent configuring any useful modifiers combination. So it's a win-win.
2020-04-01middle click pastes selection againLuke Smith
2020-04-01Merge branch 'master' of github.com:LukeSmithxyz/stLuke Smith