Commits
- Commit:
e8f1308586839dc079356a8ef9843d946192cdb4- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Receive only a wchar_t in tchar()
It makes simpler the conversion from utf8 input string and
makes simpler the checks done in tputc, but it still requires
a lot of additional conversions that will be removed later.
- Commit:
d65ebe9aed0389761894c4f00de6b13e552c1d02- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
First step to plain unicode representation
tprinter() is used in tputc, so a first step is to change it
to accept a wchar_t instead of a multibyte string. This patch makes
more ugly the code because it needs a lot of conversions, but
they will be removed later.
- Commit:
28f56c8842a2a473d1c618dcfed964a1dd1493c6- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Remove last parameter of utf8encode
This parameter was always UTF_SIZ, so it is better remove it and
use directly UTF_SIZ in in.
- Commit:
23af75fc752f703299921b5a4e866a3ac83b5479- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Simplify utf8decodebyte using some locals
These local variables help to make expressions simpler and avoid
use a pointer as induction variable in a for loop.
- Commit:
c7a945c4086ab913cd8a05997bfbc1906645eff4- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Add missed names of charset sequences
- Commit:
5afb3862ba368de8888c0c570098baababc7bc19- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Add support for utmp in st
St runs an interactive shell and not a login shell, and it means
that profile is not loaded. The default terminal configuration
in some system is not the correct for st, but since profile is
not loaded there is no way of getting a script configures the
correct values.
St doesn't update the utmp files, this is the job of another
suckless tool, utmp. Utmp also opens a login shell (it is the
logical behaviour when you create a new user record) it is a
good option execute utmp and then get a correct input in
utmp, wtmp and lastlog file, and execute the content of the
profile.
- Commit:
0392d165d07143eec29c730364006bc0613e1198- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Remove indentation level in xdrawcursor
- Commit:
98a1085d0e7c3d84e19185ba666c4b0c725cd974- From:
- Ben Hendrickson <ben@1m7.com>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Removing wrapping newlines from selection
When getting selected text, lines that were wrapped because of length
ought not include the wrapping newline in the selection.
This comes up, for example, when copying a bash command that is long
enough to wrap from the console and pasting it back into the console.
The extra newline breaks it.
Similiarly, changes behavior when trimming whitespace from the end of a
physical line to only do so if the line does not wrap. Otherwise we are
trimming whitespace from the middle of a logical line, which may change
its meaning.
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
51466e019a67e9319e6c5a7fa4205842ca860b71- From:
- Ivan Delalande <colona@ycc.fr>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Change the behavior of word snapping on delimiters
This makes any sequence of identical delimiters be considered a single
word in word-snapping mode. This seems more coherent for this mode and
is similar to what xterm does.
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
c490a60b804f467490cd4d8275a181dc37edef9f- From:
- Ivan Delalande <colona@ycc.fr>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Move calls to selsnap into selnormalize
This simplifies getbuttoninfo() and bpress(), and fixes a bug which made word
snapping behave incorrectly when a delimiter was at the beginning or end of
line.
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
83dea7fd7bb5f6e8a11a7ac8a734d8016d1ed0cb- From:
- Alexander Huemer <alexander.huemer@xx.vu>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Improve readability of enum members
The 'left shift from one' notation of power of two integers is more
expressive than the result.
Signed-off-by: Alexander Huemer <alexander.huemer@xx.vu>
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
e5f6736ee0a0f29a14afec5494a5b3f204cedc1c- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Add eschandle()
We already have a csihandle() function, where is located code about
CSI sequences, so it is logical do the same with ESC sequences.
This change helps to simplify tcontrol(), which has a complex flow
and should be rewritten.
- Commit:
a3549c2eecf12b3453e6c86ba1721e7837f23746- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Improve execsh() and don't allow anonymous shells
This patch improves the shell selection on execsh and forbid
shell with users don't registered in the passwd file.
- Commit:
8342036f983288046e03a34055c10fc6b6b11017- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Fix definition of CONTROLC0
DEL character is not thecnically talking a C0 control character,
although it has some common properties with them, so it is useful
for us consider it as C0. Before this patch DEL (\177), was not
ignored as it ought to be.
- Commit:
9d9e049eac3dacb2725f9d792f7cdd2230062313- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Make useful DEL in application mode
DEL key has to generate the sequence ^[P in application mode,
because such sequence means delete current character. It implies
that the character sent in keypad mode must be ^? (DEL character).
- Commit:
177d888dff2fdf987dfa7fc3eb8495fa107879ad- From:
- Quentin Carbonneaux <q@c9x.me>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
reset the alt screen in treset
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
fa04911c91a049f397337d3436c4a5692da558fa- From:
- Quentin Carbonneaux <q@c9x.me>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
simplify loop in tresize
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
1926305318cf020e20732461293d3e8c1c201734- From:
- Alexander Huemer <alexander.huemer@xx.vu>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Simplify README
The term 'virtual terminal emulator' was broken. There is nothing
virtual about it, it's a terminal emulator.
Signed-off-by: Alexander Huemer <alexander.huemer@xx.vu>
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
8f3e6a577d0d9733d356c0b691fea7b523d8ade7- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Fix man page and usage()
Man page was repeating -f option, the second time instead of -i,
and this option was lost in usage() message. This patch also indent
the output of usage().
- Commit:
f8b4998b32cbabe2090dc8027720203d6cd2d24d- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Convert VT102ID to a config variable
VT102ID is the sequence that the terminal returns when it is inquired
to identify itself. This value should be configurable in the same
way that another st parameters.
- Commit:
6530025bcaf3a65083667a93ae50035bd7137bae- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Fix portability problem in techo()
ISCONTROL chechks if a value is between 0 and 0x1f or
between 0x80 and 0x9f. Char signess depends of architecture
and compiler, so in some environment the second case is
always false (and wrong), Techo() calls ISCONTROL with a
char variable, whose type cannot be changed because tpuc()
expects a pointer to char, so the solution is to insert a
cast in the call to ISCONTROL.
- Commit:
d4a17316d33f3c5a0017d7fe6e7e174883ccaa97- From:
- noname <noname@inventati.org>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Don't set dirty all lines because tswapcreen do it
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
20c4f122543b67c0cdcefd151eb38b3bee599c10- From:
- noname <noname@inventati.org>
- Via:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
tresize return value is not used
Signed-off-by: Roberto E. Vargas Caballero <k0ga@shike2.com>
- Commit:
821a6e00a5a9395f40c10c00d19c569bd0f2688e- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Remove ul capability
This capability indicates that underscore '_' overstrike current
letter under the cursor. It means that you can generate a
underline 'b' using 'b^H_', because it writes a 'b' then backward
one characther and then overstrike '_'. St has not such behaviour,
so it is an error to have this capability.
- Commit:
8de8ae3923b3b91b034077c8c35acba629588233- From:
- Roberto E. Vargas Caballero <k0ga@shike2.com>
- Date:
Unset mode when clearing regions
tclearregion() was clearing regions using spaces and the current
attributes of the terminal. It was correct with all the modes excepct
underline, because they didn't affect the space character, but in
the case of underline it was a problem. A easy way of seeing this
problem is writing this in the last line of the terminal:
tput smul ; echo first; tput rmul; echo second; echo third
Fist was underlined, and second and third were not underlined, but
the spaces at the right of second was underlined becuause in the
previous scrool underline mode was set.
