diff options
-rw-r--r-- | config.def.h | 2 | ||||
-rw-r--r-- | x.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/config.def.h b/config.def.h index 1969a54..2f6107e 100644 --- a/config.def.h +++ b/config.def.h @@ -17,6 +17,8 @@ static char *font2[] = { static int borderperc = 2; +static int center_text = 0; + /* * What program is execed by st depends of these precedence rules: * 1: program passed with -e @@ -768,8 +768,8 @@ cresize(int width, int height) col = MAX(1, col); row = MAX(1, row); - win.hborderpx = (win.w - col * win.cw) / 2; - win.vborderpx = (win.h - row * win.ch) / 2; + win.hborderpx = center_text ? (win.w - col * win.cw) / 2 : 0; // (win.w - col * win.cw) / 2 + win.vborderpx = center_text ? (win.h - row * win.ch) / 2 : 0; // (win.h - row * win.ch) / 2 tresize(col, row); xresize(col, row); |