diff --git a/reporting/markslider b/reporting/markslider index 7741a23..ffd44c1 100755 --- a/reporting/markslider +++ b/reporting/markslider @@ -98,7 +98,8 @@ while true do # print slide $i NO_SLIDES=$( grep -ce "^# " "$1" ) - COLS=$(( $( tput cols ) - 3 )) + SLIDE_CHARS=$(( ${#i} + ${#NO_SLIDES} +1 )) + COLS=$(( $( tput cols ) - $SLIDE_CHARS )) [ "$cmd" = "e" ] && read -N 1 foo display_slide "$1" $i # save cursor location