aboutsummaryrefslogtreecommitdiff
path: root/style.c
diff options
context:
space:
mode:
authorThomas Adam <thomas@xteddy.org>2021-03-11 08:01:29 +0000
committerThomas Adam <thomas@xteddy.org>2021-03-11 08:01:29 +0000
commit12cfd0d22b630ead9c6d739b13c3409485ea551c (patch)
treeee2535b2b0e0075078cae6a2eb0bf5171d11078d /style.c
parent541872bc5754a8f4daa84f23043c356f7ac4f663 (diff)
parentee0df1b8f8a9099fbd67a73c9fb20b89c64d6106 (diff)
downloadrtmux-12cfd0d22b630ead9c6d739b13c3409485ea551c.tar.gz
rtmux-12cfd0d22b630ead9c6d739b13c3409485ea551c.tar.bz2
rtmux-12cfd0d22b630ead9c6d739b13c3409485ea551c.zip
Merge branch 'obsd-master' into master
Diffstat (limited to 'style.c')
-rw-r--r--style.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/style.c b/style.c
index 08614f9c..24b09882 100644
--- a/style.c
+++ b/style.c
@@ -139,6 +139,8 @@ style_parse(struct style *sy, const struct grid_cell *base, const char *in)
sy->align = STYLE_ALIGN_CENTRE;
else if (strcasecmp(tmp + 6, "right") == 0)
sy->align = STYLE_ALIGN_RIGHT;
+ else if (strcasecmp(tmp + 6, "absolute-centre") == 0)
+ sy->align = STYLE_ALIGN_ABSOLUTE_CENTRE;
else
goto error;
} else if (end > 5 && strncasecmp(tmp, "fill=", 5) == 0) {
@@ -227,6 +229,8 @@ style_tostring(struct style *sy)
tmp = "centre";
else if (sy->align == STYLE_ALIGN_RIGHT)
tmp = "right";
+ else if (sy->align == STYLE_ALIGN_ABSOLUTE_CENTRE)
+ tmp = "absolute-centre";
off += xsnprintf(s + off, sizeof s - off, "%salign=%s", comma,
tmp);
comma = ",";