summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAiden Gall <aiden@aidengall.xyz>2024-04-05 15:09:59 +0100
committerAiden Gall <aiden@aidengall.xyz>2024-04-05 15:09:59 +0100
commit9d8cc9f05e1cd2bb2d324bb57c38dba3236141b7 (patch)
treec70ee7fd3924ee48c3512988f585072aa01c0766
parentc7ed1f4f4b40b2267fb97d879d0a2525b7e5cd66 (diff)
parentd63b9eb90245926b531bd54b1d591adb96613e70 (diff)
merge upstream
-rw-r--r--config.mk2
-rw-r--r--st.c10
-rw-r--r--x.c6
3 files changed, 10 insertions, 8 deletions
diff --git a/config.mk b/config.mk
index 7153a4a..72297ef 100644
--- a/config.mk
+++ b/config.mk
@@ -1,5 +1,5 @@
# st version
-VERSION = 0.9.1
+VERSION = 0.9.2
# Customize below to fit your system
diff --git a/st.c b/st.c
index a426827..8ded428 100644
--- a/st.c
+++ b/st.c
@@ -110,8 +110,8 @@ enum escape_state {
typedef struct {
Glyph attr; /* current char attributes */
- int x; /* terminal column */
- int y; /* terminal row */
+ int x;
+ int y;
char state;
} TCursor;
@@ -2402,16 +2402,12 @@ tstrsequence(uchar c)
void
tcontrolcode(uchar ascii)
{
- size_t i;
-
switch (ascii) {
case '\t': /* HT */
tputtab(1);
return;
case '\b': /* BS */
- for (i = 1; term.c.x && term.line[term.c.y][term.c.x - i].u == 0; ++i)
- ;
- tmoveto(term.c.x - i, term.c.y);
+ tmoveto(term.c.x-1, term.c.y);
return;
case '\r': /* CR */
tmoveto(0, term.c.y);
diff --git a/x.c b/x.c
index d2ad828..e524c0a 100644
--- a/x.c
+++ b/x.c
@@ -1643,6 +1643,9 @@ xseticontitle(char *p)
XTextProperty prop;
DEFAULT(p, opt_title);
+ if (p[0] == '\0')
+ p = opt_title;
+
if (Xutf8TextListToTextProperty(xw.dpy, &p, 1, XUTF8StringStyle,
&prop) != Success)
return;
@@ -1657,6 +1660,9 @@ xsettitle(char *p)
XTextProperty prop;
DEFAULT(p, opt_title);
+ if (p[0] == '\0')
+ p = opt_title;
+
if (Xutf8TextListToTextProperty(xw.dpy, &p, 1, XUTF8StringStyle,
&prop) != Success)
return;