1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-28 13:56:37 +02:00

Fix display bug with prefix_align_max option (bug #23777)

This commit is contained in:
Sebastien Helleu
2008-07-06 10:02:26 +02:00
parent 1f787ddcba
commit c32f244fff
+4 -6
View File
@@ -387,12 +387,10 @@ gui_chat_get_line_align (struct t_gui_buffer *buffer, struct t_gui_line *line,
&& CONFIG_STRING(config_look_prefix_suffix)[0])
length_suffix = gui_chat_strlen_screen (CONFIG_STRING(config_look_prefix_suffix)) + 1;
}
if (CONFIG_INTEGER(config_look_prefix_align_max) > 0)
return gui_chat_time_length + 1 + CONFIG_INTEGER(config_look_prefix_align_max) +
length_suffix + 1;
else
return gui_chat_time_length + ((buffer->prefix_max_length > 0) ? 1 : 0) +
+ buffer->prefix_max_length + length_suffix + 1;
return gui_chat_time_length + ((buffer->prefix_max_length > 0) ? 1 : 0) +
+ ((buffer->prefix_max_length > CONFIG_INTEGER(config_look_prefix_align_max)) ?
CONFIG_INTEGER(config_look_prefix_align_max) : buffer->prefix_max_length)
+ length_suffix + 1;
}
/*