From: Armaan Bhojwani Date: Sun, 31 Jan 2021 16:30:54 +0000 (-0500) Subject: Fix length of separator line X-Git-Tag: v0.3.0~10 X-Git-Url: https://git.armaanb.net/?p=lightcards.git;a=commitdiff_plain;h=623bf843fd172185d7dc2624f72817d2b1610558 Fix length of separator line --- diff --git a/lightcards/display.py b/lightcards/display.py index 6b5fce1..e9e5b26 100755 --- a/lightcards/display.py +++ b/lightcards/display.py @@ -95,8 +95,8 @@ def disp_card(stdscr, stack, headers, obj): placeholder="…"), curses.A_BOLD) # Add horizontal line - lin_width = mcols - if len(top) < mcols: + lin_width = header_width + if len(top) < header_width: lin_width = len(top) stdscr.hline(1, 0, curses.ACS_HLINE, lin_width) @@ -104,7 +104,6 @@ def disp_card(stdscr, stack, headers, obj): wrap_width = mcols if mcols > 80: wrap_width = 80 - stdscr.hline(curses.ACS_HLINE, lin_width) stdscr.addstr(2, 0, textwrap.fill(stack[obj.getIdx()][obj.getSide()], width=wrap_width)) disp_bar(stdscr, stack, headers, obj)