aboutsummaryrefslogtreecommitdiffstats
path: root/epy.py
diff options
context:
space:
mode:
Diffstat (limited to 'epy.py')
-rw-r--r--epy.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/epy.py b/epy.py
index 96efaeb..1466dd3 100644
--- a/epy.py
+++ b/epy.py
@@ -874,7 +874,11 @@ def reader(stdscr, ebook, index, width, y, pctg, sect):
stdscr.clear()
stdscr.refresh()
- pad.refresh(y, 0, 0, x, rows-1, x+width)
+ # try except to be more flexible on terminal resize
+ try:
+ pad.refresh(y, 0, 0, x, rows-1, x+width)
+ except curses.error:
+ pass
if sect != "":
y = toc_secid.get(sect, 0)