aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOmar Sandoval <osandov@osandov.com>2015-04-09 18:22:31 -0700
committerRoberto E. Vargas Caballero <k0ga@shike2.com>2015-04-10 23:43:05 +0200
commitecac5ee35ef006001b280461ed3f9812d855250c (patch)
treee799690df73cc5e13cc35981300e4cc7f03ff9f4
parent93b54cfcc437c9bac9af3ceb2d9ba19c442de1ff (diff)
downloadst-ecac5ee35ef006001b280461ed3f9812d855250c.tar.gz
st-ecac5ee35ef006001b280461ed3f9812d855250c.zip
Make DECSCUSR thickness configurable
-rw-r--r--config.def.h5
-rw-r--r--st.c10
2 files changed, 10 insertions, 5 deletions
diff --git a/config.def.h b/config.def.h
index 56bae2d..5e7caaf 100644
--- a/config.def.h
+++ b/config.def.h
@@ -42,6 +42,11 @@ static unsigned int actionfps = 30;
42static unsigned int blinktimeout = 800; 42static unsigned int blinktimeout = 800;
43 43
44/* 44/*
45 * thickness of underline and bar cursors
46 */
47static unsigned int cursorthickness = 2;
48
49/*
45 * bell volume. It must be a value between -100 and 100. Use 0 for disabling 50 * bell volume. It must be a value between -100 and 100. Use 0 for disabling
46 * it 51 * it
47 */ 52 */
diff --git a/st.c b/st.c
index a7064b1..b2bcfe9 100644
--- a/st.c
+++ b/st.c
@@ -3591,15 +3591,15 @@ xdrawcursor(void) {
3591 case 4: /* Steady Underline */ 3591 case 4: /* Steady Underline */
3592 XftDrawRect(xw.draw, &dc.col[defaultcs], 3592 XftDrawRect(xw.draw, &dc.col[defaultcs],
3593 borderpx + curx * xw.cw, 3593 borderpx + curx * xw.cw,
3594 borderpx + (term.c.y + 1) * xw.ch - 1, 3594 borderpx + (term.c.y + 1) * xw.ch - cursorthickness,
3595 xw.cw, 1); 3595 xw.cw, cursorthickness);
3596 break; 3596 break;
3597 case 5: /* Blinking bar */ 3597 case 5: /* Blinking bar */
3598 case 6: /* Steady bar */ 3598 case 6: /* Steady bar */
3599 XftDrawRect(xw.draw, &dc.col[defaultcs], 3599 XftDrawRect(xw.draw, &dc.col[defaultcs],
3600 borderpx + curx * xw.cw, 3600 borderpx + curx * xw.cw,
3601 borderpx + term.c.y * xw.ch, 3601 borderpx + term.c.y * xw.ch,
3602 1, xw.ch); 3602 cursorthickness, xw.ch);
3603 break; 3603 break;
3604 } 3604 }
3605 } else { 3605 } else {