From f6b7a4cd8ca4821aa29ad06e01e619964eb01f5d Mon Sep 17 00:00:00 2001 From: Felix Pankratz Date: Wed, 30 Aug 2023 18:54:16 +0200 Subject: [PATCH] 3 4ths instead of 2 3rds --- hn.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hn.py b/hn.py index 15edb74..c4a6a48 100755 --- a/hn.py +++ b/hn.py @@ -57,7 +57,7 @@ class Client: # calculate length of line text = f'{prefix} ()\n' chars_available = self.cols - len(text) - max_title_len = min((chars_available//3)*2, len(story.title)) + max_title_len = min((chars_available//4)*3, len(story.title)) max_url_len = chars_available - max_title_len title = story.title[:max_title_len-1] + "…" if len(story.title) > max_title_len else story.title