when you want to set a sensible minimum width regardless of which font you
are using, and at what particular size.
align::
- Align text on the +center+ (default), +right+ or +left+ of the block, when
+ Align text on the +center+, +right+ or +left+ (default) of the block, when
the minimum width of the latter, specified by the +min_width+ key, is not
reached.
name and instance::
sasprintf(&(ctx->block.color), "%.*s", len, val);
}
if (strcasecmp(ctx->last_map_key, "align") == 0) {
- if (len == strlen("left") && !strncmp((const char *)val, "left", strlen("left"))) {
- ctx->block.align = ALIGN_LEFT;
+ if (len == strlen("center") && !strncmp((const char *)val, "center", strlen("center"))) {
+ ctx->block.align = ALIGN_CENTER;
} else if (len == strlen("right") && !strncmp((const char *)val, "right", strlen("right"))) {
ctx->block.align = ALIGN_RIGHT;
} else {
- ctx->block.align = ALIGN_CENTER;
+ ctx->block.align = ALIGN_LEFT;
}
} else if (strcasecmp(ctx->last_map_key, "min_width") == 0) {
i3String *text = i3string_from_utf8_with_length((const char *)val, len);