File tree 1 file changed +13
-2
lines changed
1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change @@ -1410,10 +1410,21 @@ def move_screen_up(current_line_start_row):
1410
1410
if self .config .curtsies_list_above :
1411
1411
info_max_rows = max (visible_space_above , visible_space_below )
1412
1412
else :
1413
+ # Logic for determining size of completion box
1413
1414
# smallest allowed over-full completion box
1414
- minimum_possible_height = 20
1415
+ minimum_possible_height = 4
1416
+ # smallest amount of history that must be visible
1417
+ try_preserve_history_height = 40
1418
+ preferred_height = max (
1419
+ # always make infobox at least this height
1420
+ minimum_possible_height ,
1421
+
1422
+ # there's so much space that we can preserve
1423
+ # this much history and still expand the infobox
1424
+ min_height - try_preserve_history_height )
1425
+
1415
1426
info_max_rows = min (max (visible_space_below ,
1416
- minimum_possible_height ),
1427
+ preferred_height ),
1417
1428
min_height - current_line_height - 1 )
1418
1429
infobox = paint .paint_infobox (
1419
1430
info_max_rows ,
You can’t perform that action at this time.
0 commit comments