From 412bf73673a5d3b20d6eecfef17a5128474fd8cb Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Sun, 14 Jun 2009 11:03:01 +0200 Subject: [PATCH] Add new option weechat.look.hotlist_names_merged_buffers --- doc/en/autogen/user/weechat_options.txt | 5 +++++ doc/fr/autogen/user/weechat_options.txt | 5 +++++ po/cs.po | 5 ++++- po/de.po | 5 ++++- po/es.po | 5 ++++- po/fr.po | 9 +++++++-- po/hu.po | 5 ++++- po/pl.po | 5 ++++- po/ru.po | 5 ++++- po/weechat.pot | 5 ++++- src/core/wee-config.c | 6 ++++++ src/core/wee-config.h | 1 + src/gui/gui-bar-item.c | 3 ++- 13 files changed, 54 insertions(+), 10 deletions(-) diff --git a/doc/en/autogen/user/weechat_options.txt b/doc/en/autogen/user/weechat_options.txt index 6c774d852..e343ac759 100644 --- a/doc/en/autogen/user/weechat_options.txt +++ b/doc/en/autogen/user/weechat_options.txt @@ -413,6 +413,11 @@ ** type: integer ** values: 1 .. 15 (default value: 12) +* *weechat.look.hotlist_names_merged_buffers* +** description: if set, force display of names in hotlist for merged buffers +** type: boolean +** values: on, off (default value: off) + * *weechat.look.hotlist_short_names* ** description: if set, uses short names to display buffer names in hotlist (start after first '.' in name) ** type: boolean diff --git a/doc/fr/autogen/user/weechat_options.txt b/doc/fr/autogen/user/weechat_options.txt index 8b1c641de..a423901c4 100644 --- a/doc/fr/autogen/user/weechat_options.txt +++ b/doc/fr/autogen/user/weechat_options.txt @@ -413,6 +413,11 @@ ** type: entier ** valeurs: 1 .. 15 (valeur par défaut: 12) +* *weechat.look.hotlist_names_merged_buffers* +** description: si défini, force l'affichage des noms dans la hotlist pour les tampons mélangés +** type: booléen +** valeurs: on, off (valeur par défaut: off) + * *weechat.look.hotlist_short_names* ** description: si défini, utilie des noms courts pour afficher les noms de tampons dans la hotlist (commence après le premier '.' dans le nom) ** type: booléen diff --git a/po/cs.po b/po/cs.po index 41888fb43..1c78e9eba 100644 --- a/po/cs.po +++ b/po/cs.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: Jiri Golembiovsky \n" "Language-Team: weechat-dev \n" @@ -1370,6 +1370,9 @@ msgstr "" "úroveň pro zobrazování jmen v hotlistu (kombinace: 1=připojení/odpojení " "2=zpráva, 4=soukromé, 8=zvýraznění, příklad: 12=soukromé+zvýraznění)" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/de.po b/po/de.po index df48dfe9e..6d4687d21 100644 --- a/po/de.po +++ b/po/de.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: Thomas Schuetz \n" "Language-Team: weechat-dev \n" @@ -1392,6 +1392,9 @@ msgstr "" "Level für Namensanzeige in der Hotlist (Kombination von: 1=join/part, " "2=Nachricht, 4=Query, 8=Highlight, z.B. 12=Query+Highlight)" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/es.po b/po/es.po index a37b05bd9..4fb09a87d 100644 --- a/po/es.po +++ b/po/es.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: Roberto González Cardenete \n" "Language-Team: weechat-dev \n" @@ -1369,6 +1369,9 @@ msgstr "" "nivel para mostrar mensajes en la hotlist (combinación de: 1=join/part, " "2=mensaje, 4=privado, 8=resaltado, por ejemplo: 12=privado + resaltado)" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/fr.po b/po/fr.po index 78c1ecb0b..8fedd11fd 100644 --- a/po/fr.po +++ b/po/fr.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" -"PO-Revision-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" +"PO-Revision-Date: 2009-06-14 11:01+0200\n" "Last-Translator: FlashCode \n" "Language-Team: weechat-dev \n" "MIME-Version: 1.0\n" @@ -1544,6 +1544,11 @@ msgstr "" "1=join/part, 2=message, 4=privé, 8=highlight, par exemple: 12=privé" "+highlight)" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" +"si défini, force l'affichage des noms dans la hotlist pour les tampons " +"mélangés" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/hu.po b/po/hu.po index 0ed9e8eb7..e71f71466 100644 --- a/po/hu.po +++ b/po/hu.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: Andras Voroskoi \n" "Language-Team: weechat-dev \n" @@ -1401,6 +1401,9 @@ msgid "" "2=message, 4=private, 8=highlight, for example: 12=private+highlight)" msgstr "" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/pl.po b/po/pl.po index d55dd9b0f..d0ff86ff1 100644 --- a/po/pl.po +++ b/po/pl.po @@ -9,7 +9,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: \n" "Language-Team: Polish\n" @@ -1232,6 +1232,9 @@ msgid "" "2=message, 4=private, 8=highlight, for example: 12=private+highlight)" msgstr "" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/ru.po b/po/ru.po index 3ba86d7aa..61530797e 100644 --- a/po/ru.po +++ b/po/ru.po @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.0-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: 2009-05-11 13:02+0200\n" "Last-Translator: Pavel Shevchuk \n" "Language-Team: weechat-dev \n" @@ -1401,6 +1401,9 @@ msgstr "" "уровень отображения имён в хотлисте (сочетание: 1=вход/выход, 2=сообщение, " "4=личное сообщение, 8=подсветка, например: 12=личные+подсветка)" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/po/weechat.pot b/po/weechat.pot index 0d44d8177..fb24a0e21 100644 --- a/po/weechat.pot +++ b/po/weechat.pot @@ -7,7 +7,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2009-06-14 10:45+0200\n" +"POT-Creation-Date: 2009-06-14 11:01+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -1200,6 +1200,9 @@ msgid "" "2=message, 4=private, 8=highlight, for example: 12=private+highlight)" msgstr "" +msgid "if set, force display of names in hotlist for merged buffers" +msgstr "" + msgid "" "if set, uses short names to display buffer names in hotlist (start after " "first '.' in name)" diff --git a/src/core/wee-config.c b/src/core/wee-config.c index d1c4d3e12..e853fada5 100644 --- a/src/core/wee-config.c +++ b/src/core/wee-config.c @@ -80,6 +80,7 @@ struct t_config_option *config_look_highlight; struct t_config_option *config_look_hotlist_names_count; struct t_config_option *config_look_hotlist_names_length; struct t_config_option *config_look_hotlist_names_level; +struct t_config_option *config_look_hotlist_names_merged_buffers; struct t_config_option *config_look_hotlist_short_names; struct t_config_option *config_look_hotlist_sort; struct t_config_option *config_look_item_time_format; @@ -1281,6 +1282,11 @@ config_weechat_init_options () "of: 1=join/part, 2=message, 4=private, 8=highlight, " "for example: 12=private+highlight)"), NULL, 1, 15, "12", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL); + config_look_hotlist_names_merged_buffers = config_file_new_option ( + weechat_config_file, ptr_section, + "hotlist_names_merged_buffers", "boolean", + N_("if set, force display of names in hotlist for merged buffers"), + NULL, 0, 0, "off", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL); config_look_hotlist_short_names = config_file_new_option ( weechat_config_file, ptr_section, "hotlist_short_names", "boolean", diff --git a/src/core/wee-config.h b/src/core/wee-config.h index 12b359204..d6bbb85be 100644 --- a/src/core/wee-config.h +++ b/src/core/wee-config.h @@ -95,6 +95,7 @@ extern struct t_config_option *config_look_highlight; extern struct t_config_option *config_look_hotlist_names_count; extern struct t_config_option *config_look_hotlist_names_length; extern struct t_config_option *config_look_hotlist_names_level; +extern struct t_config_option *config_look_hotlist_names_merged_buffers; extern struct t_config_option *config_look_hotlist_short_names; extern struct t_config_option *config_look_hotlist_sort; extern struct t_config_option *config_look_item_time_format; diff --git a/src/gui/gui-bar-item.c b/src/gui/gui-bar-item.c index 9471c315d..d50a20de4 100644 --- a/src/gui/gui-bar-item.c +++ b/src/gui/gui-bar-item.c @@ -997,7 +997,8 @@ gui_bar_item_default_hotlist (void *data, struct t_gui_bar_item *item, sprintf (buf + strlen (buf), "%d", ptr_hotlist->buffer->number); - if ((gui_buffer_count_merged_buffers (ptr_hotlist->buffer->number) > 1) + if ((CONFIG_BOOLEAN(config_look_hotlist_names_merged_buffers) + && (gui_buffer_count_merged_buffers (ptr_hotlist->buffer->number) > 1)) || (display_name && (CONFIG_INTEGER(config_look_hotlist_names_count) != 0) && (names_count < CONFIG_INTEGER(config_look_hotlist_names_count))))