summaryrefslogtreecommitdiff
path: root/st.h
diff options
context:
space:
mode:
authorLuke Smith <luke@lukesmith.xyz>2020-07-08 11:15:08 -0400
committerLuke Smith <luke@lukesmith.xyz>2020-07-08 11:15:08 -0400
commitcfef7fa605c6215157c2d2485305f23280b4f6fe (patch)
treea337520766f009c5716110631eec3d12ef059325 /st.h
parent3f51ba298c70c346ed1f8257c5e180a074d6ff9b (diff)
parent6bf7545fc98cd0d42eb727d596215daac809c478 (diff)
Merge branch 'master' of https://github.com/mackarelfish/st into mackarelfish-master
Diffstat (limited to 'st.h')
-rw-r--r--st.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/st.h b/st.h
index b25b947..7b5991a 100644
--- a/st.h
+++ b/st.h
@@ -11,7 +11,8 @@
#define DIVCEIL(n, d) (((n) + ((d) - 1)) / (d))
#define DEFAULT(a, b) (a) = (a) ? (a) : (b)
#define LIMIT(x, a, b) (x) = (x) < (a) ? (a) : (x) > (b) ? (b) : (x)
-#define ATTRCMP(a, b) ((a).mode != (b).mode || (a).fg != (b).fg || \
+#define ATTRCMP(a, b) (((a).mode & (~ATTR_WRAP) & (~ATTR_LIGA)) != ((b).mode & (~ATTR_WRAP) & (~ATTR_LIGA)) || \
+ (a).fg != (b).fg || \
(a).bg != (b).bg)
#define TIMEDIFF(t1, t2) ((t1.tv_sec-t2.tv_sec)*1000 + \
(t1.tv_nsec-t2.tv_nsec)/1E6)
@@ -33,7 +34,8 @@ enum glyph_attribute {
ATTR_WRAP = 1 << 8,
ATTR_WIDE = 1 << 9,
ATTR_WDUMMY = 1 << 10,
- ATTR_BOXDRAW = 1 << 11,
+ ATTR_BOXDRAW = 1 << 11,
+ ATTR_LIGA = 1 << 12,
ATTR_BOLD_FAINT = ATTR_BOLD | ATTR_FAINT,
};