core: do not change the chat prefix size when a filtered line is added (closes #1092)

v2.8-utf8proc
Sébastien Helleu 2017-10-29 07:17:30 +01:00
parent 6b817015e3
commit 84013b82df
2 changed files with 14 additions and 7 deletions

View File

@ -40,6 +40,7 @@ Improvements::
Bug fixes::
* core: do not change the chat prefix size when a filtered line is added (issue #1092)
* core: fix display of nicks in nicklist when they are in a group with sub-groups (issue #1079)
* core, plugins: check return code of strftime function
* core: fix cast of time_t (to "long long" instead of "long") (issue #1051)

View File

@ -945,13 +945,19 @@ gui_line_add_to_list (struct t_gui_lines *lines,
line->next_line = NULL;
lines->last_line = line;
/* adjust "prefix_max_length" if this prefix length is > max */
gui_line_get_prefix_for_display (line, NULL, &prefix_length, NULL,
&prefix_is_nick);
if (prefix_is_nick)
prefix_length += config_length_nick_prefix_suffix;
if (prefix_length > lines->prefix_max_length)
lines->prefix_max_length = prefix_length;
/*
* adjust "prefix_max_length" if this prefix length is > max
* (only if the line is displayed
*/
if (line->data->displayed)
{
gui_line_get_prefix_for_display (line, NULL, &prefix_length, NULL,
&prefix_is_nick);
if (prefix_is_nick)
prefix_length += config_length_nick_prefix_suffix;
if (prefix_length > lines->prefix_max_length)
lines->prefix_max_length = prefix_length;
}
/* adjust "lines_hidden" if the line is hidden */
if (!line->data->displayed)