Sometimes curses tears down and recreates all its windows (when the display is resized, for instance) and after doing that it repopulates the message window with data saved for use by ^P. But it was showing the oldest messages available rather than the most recent ones. There is still room for improvement. That process combines short messages but the refresh is based on the available number of lines; combining messages can result in lines at the bottom of the message window being left blank. This could be fixed by reverse-scrolling the window and inserting more messages at the top, or by combining short messages in history data instead of at refresh time. The second seems easier but won't handle changing the message window's width sensibly, and neither method handles wrapped, long lines well. A More>> prompt (possibly more than one) is issued if the refresh shows too many lines (either because long messages already took multiple lines or because the window has become narrower and ones which used to fit now need to be wrapped).
3.2 KiB
3.2 KiB