irc: add option irc.look.display_pv_warning_address (closes #892)

If the address of remote nick changes in a private buffer, a warning is
displayed.
v2.8-utf8proc
Sébastien Helleu 2019-10-11 20:26:34 +02:00
parent 1dda5ffd02
commit 876a0a1609
26 changed files with 238 additions and 14 deletions

View File

@ -27,6 +27,7 @@ New features::
* core: add support of modifiers in evaluation of expressions with "modifier:name,data,string"
* api: add modifier "color_encode_ansi" (issue #528)
* api: add modifier "eval_path_home"
* irc: add option irc.look.display_pv_warning_address to display a warning in private buffer if the remote nick address has changed (issue #892)
* irc: add server option "ssl_password" (issue #115, issue #1416)
* irc: add "user" in output of irc_message_parse (issue #136)
* irc: add options irc.color.message_kick and irc.color.reason_kick (issue #683, issue #684)

View File

@ -75,6 +75,20 @@ This new server option has three possible values:
_irc.network.channel_encode_ to _off_ (so this was the default behavior
in previous versions)
[[v2.7_irc_pv_warning_address]]
=== Warning when nick address changes in private buffer
A new option _irc.look.display_pv_warning_address_ has been added to display
a warning in a private buffer if the address of remote nick has changed.
The warning is enabled by default and can be disabled with this command:
----
/set irc.look.display_pv_warning_address off
----
See issue #892 for more information.
[[v2.7_xfer_file_receive_suffix]]
=== Suffix for files received via DCC

View File

@ -224,6 +224,12 @@
** Werte: on, off
** Standardwert: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** Beschreibung: pass:none[display a warning in private buffer if the address of remote nick has changed]
** Typ: boolesch
** Werte: on, off
** Standardwert: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** Beschreibung: pass:none[durch Kommata getrennte Liste von Wörtern die in Channel-Buffern als Highlight erscheinen sollen (zwischen Groß- und Kleinschreibung wird nicht unterschieden. Um zwischen Groß- und Kleinschreibung zu unterscheiden muss zu Beginn "(?-i)" genutzt werden; des Weiteren können folgende Variablen genutzt werden: $nick, $channel und $server). Wird ein Buffer geöffnet, dann werden die angegeben Wörter dem Buffer-Merkmal "highlight_words" hinzugefügt. Dies bedeutet, dass diese Einstellung keinen direkten Einfluss auf schon geöffnete Buffer hat. Eine leere Zeichenkette deaktiviert ein Highlight für den Nick. Beispiel: "$nick", "(?-i)$nick"]
** Typ: Zeichenkette

View File

@ -224,6 +224,12 @@
** values: on, off
** default value: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** description: pass:none[display a warning in private buffer if the address of remote nick has changed]
** type: boolean
** values: on, off
** default value: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** description: pass:none[comma separated list of words to highlight in channel buffers (case insensitive, use "(?-i)" at beginning of words to make them case sensitive; special variables $nick, $channel and $server are replaced by their value), these words are added to buffer property "highlight_words" only when buffer is created (it does not affect current buffers), an empty string disables default highlight on nick, examples: "$nick", "(?-i)$nick"]
** type: string

View File

@ -224,6 +224,12 @@
** valeurs: on, off
** valeur par défaut: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** description: pass:none[afficher un avertissement dans le tampon privé si l'adresse du pseudo distant a changé]
** type: booléen
** valeurs: on, off
** valeur par défaut: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** description: pass:none[liste de mots pour le highlight dans les tampons de type "canal", séparés par des virgules (insensible à la casse, utilisez "(?-i)" au début des mots pour les rendre sensibles à la casse ; les variables spéciales $nick, $channel et $server sont remplacées par leurs valeurs), ces mots sont ajoutés à la propriété du tampon "highlight_words" seulement lorsque le tampon est créé (cela n'affecte pas les tampons courants), une chaîne vide désactive le highlight par défaut sur le pseudo, exemples : "$nick", "(?-i)$nick"]
** type: chaîne

View File

@ -224,6 +224,12 @@
** valori: on, off
** valore predefinito: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** descrizione: pass:none[display a warning in private buffer if the address of remote nick has changed]
** tipo: bool
** valori: on, off
** valore predefinito: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** descrizione: pass:none[comma separated list of words to highlight in channel buffers (case insensitive, use "(?-i)" at beginning of words to make them case sensitive; special variables $nick, $channel and $server are replaced by their value), these words are added to buffer property "highlight_words" only when buffer is created (it does not affect current buffers), an empty string disables default highlight on nick, examples: "$nick", "(?-i)$nick"]
** tipo: stringa

View File

@ -224,6 +224,12 @@
** 値: on, off
** デフォルト値: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** 説明: pass:none[display a warning in private buffer if the address of remote nick has changed]
** タイプ: ブール
** 値: on, off
** デフォルト値: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** 説明: pass:none[現在のバッファでハイライトする単語のコンマ区切りリスト (大文字小文字を区別しない、"(?-i)" を単語の最初につければ大文字小文字を区別する; 特殊変数 $nick、$channel、$server はそれぞれの値に置換される)、これらの単語は、バッファの作成時にバッファプロパティ "highlight_words" に追加される (既存のバッファには影響なし)、空文字列はニックネームに関するデフォルトのハイライトを無効にする、例: "$nick", "(?-i)$nick"]
** タイプ: 文字列

View File

@ -224,6 +224,12 @@
** wartości: on, off
** domyślna wartość: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** opis: pass:none[display a warning in private buffer if the address of remote nick has changed]
** typ: bool
** wartości: on, off
** domyślna wartość: `+on+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** opis: pass:none[oddzielona przecinkami lista słów do podświetleń w buforach kanałów (wielkość liter nie ma znaczenia, użyj "(?-i)" na początku słów, dla których wielkość liter ma znaczenie; zmienne specjalne $nick, $channel i $server są zastępowane odpowiednimi wartościami), słowa te są dodawane do zmiennej lokalnej bufora "highlight_words" tylko kiedy bufor jest tworzony (nie ma wpływu na obecne bufory), pusty ciąg wyłącza domyślne podświetlenia nicka, przykłady: "$nick", "(?-i)$nick"]
** typ: ciąg

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:31+0200\n"
"Last-Translator: Ondřej Súkup <mimi.vx@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6139,6 +6139,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: nemohu přidělit nový kanál"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s se zpet na serveru"
@ -8294,6 +8298,10 @@ msgstr ""
"zobrazit v soukromém okně zprávu po tom co se uživatel vráti (po odpojení od "
"serveru)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -24,7 +24,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-10-06 15:51+0200\n"
"Last-Translator: Nils Görs <weechatter@arcor.de>\n"
"Language-Team: German <kde-i18n-de@kde.org>\n"
@ -7584,6 +7584,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: Neuer Channel konnte nicht alloziert werden"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s hat sich wieder am Server angemeldet"
@ -9952,6 +9956,10 @@ msgstr ""
"es wird bei einer privaten Unterhaltung eine Mitteilung ausgegeben falls der "
"User wieder zurück ist (falls der User sich beim Server abgemeldet hat)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -22,7 +22,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:31+0200\n"
"Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6354,6 +6354,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: no se pudo crear un nuevo canal"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s ha regresado al servidor"
@ -8552,6 +8556,10 @@ msgstr ""
"mostrar un mensaje en privado cuando el usuario esta de vuelta (después de "
"salir del servidor)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
#, fuzzy
msgid ""
"comma separated list of words to highlight in channel buffers (case "

View File

@ -21,8 +21,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"PO-Revision-Date: 2019-10-09 21:39+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-10-11 20:23+0200\n"
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"Language: fr\n"
@ -7423,6 +7423,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s : impossible d'allouer un nouveau canal"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr "%sAttention : l'adresse du pseudo distant a changé"
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s est de retour sur le serveur"
@ -9736,6 +9740,12 @@ msgstr ""
"afficher un message en privé lorsque l'utilisateur est de retour (après "
"avoir quitté le serveur)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
"afficher un avertissement dans le tampon privé si l'adresse du pseudo "
"distant a changé"
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:31+0200\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5665,6 +5665,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s nem sikerült új csatornát lefoglalni"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, fuzzy, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s %s(%s%s%s)%s belépett a(z) %s%s szobába\n"
@ -7722,6 +7726,10 @@ msgstr "privát beszélgetésben a másik fél távollétét csak egyszer jelezz
msgid "display a message in private when user is back (after quit on server)"
msgstr ""
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:31+0200\n"
"Last-Translator: Esteban I. Ruiz Moreno <exio4.com@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6521,6 +6521,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: impossibile allocare un nuovo canale"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s è tornato sul server"
@ -8734,6 +8738,10 @@ msgstr ""
"mostra un messaggio in privato quando l'utente è tornato (dopo l'uscita dal "
"server)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
#, fuzzy
msgid ""
"comma separated list of words to highlight in channel buffers (case "

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-09-22 18:54+0200\n"
"Last-Translator: AYANOKOUZI, Ryuunosuke <i38w7i3@yahoo.co.jp>\n"
"Language-Team: Japanese <https://github.com/l/weechat/tree/master/"
@ -7104,6 +7104,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: 新しいチャンネルの割り当てに失敗"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s がサーバに戻りました"
@ -9345,6 +9349,10 @@ msgstr ""
"ユーザが戻ったら、プライベートウィンドウにメッセージを表示 (サーバとの切断を"
"挟んで)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -22,7 +22,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-09-22 18:54+0200\n"
"Last-Translator: Krzysztof Korościk <soltys@soltys.info>\n"
"Language-Team: Polish <kde-i18n-doc@kde.org>\n"
@ -7234,6 +7234,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: nie można przydzielić nowego kanału"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s jest z powrotem na serwerze"
@ -9509,6 +9513,10 @@ msgstr ""
msgid "display a message in private when user is back (after quit on server)"
msgstr "pokaż prywatną wiadomość, kiedy użytkownik wróci na serwer"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-09-22 18:54+0200\n"
"Last-Translator: Vasco Almeida <vascomalmeida@sapo.pt>\n"
"Language-Team: Portuguese <>\n"
@ -6891,6 +6891,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s%s: não é possível alocar novo canal"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s%s %s(%s%s%s)%s voltou ao servidor"
@ -9161,6 +9165,10 @@ msgstr ""
"mostrar um mensagem em privado quando o utilizador voltar (depois de sair do "
"servidor)"
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:32+0200\n"
"Last-Translator: Eduardo Elias <camponez@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -6312,6 +6312,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr ""
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr ""
@ -8154,6 +8158,10 @@ msgstr ""
msgid "display a message in private when user is back (after quit on server)"
msgstr ""
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:32+0200\n"
"Last-Translator: Aleksey V Zapparov AKA ixti <ixti@member.fsf.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5703,6 +5703,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr "%s не могу расположить новый канал"
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, fuzzy, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr "%s%s %s(%s%s%s)%s зашёл на канал %s%s\n"
@ -7753,6 +7757,10 @@ msgstr "отображать уведомление об отсутствии е
msgid "display a message in private when user is back (after quit on server)"
msgstr ""
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -20,7 +20,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2019-05-13 21:32+0200\n"
"Last-Translator: Hasan Kiran <sunder67@hotmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5230,6 +5230,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr ""
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr ""
@ -6996,6 +7000,10 @@ msgstr ""
msgid "display a message in private when user is back (after quit on server)"
msgstr ""
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2019-10-09 21:37+0200\n"
"POT-Creation-Date: 2019-10-11 13:59+0200\n"
"PO-Revision-Date: 2014-08-16 10:27+0200\n"
"Last-Translator: Sébastien Helleu <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@ -5171,6 +5171,10 @@ msgstr ""
msgid "%s%s: cannot allocate new channel"
msgstr ""
#, c-format
msgid "%sWarning: the address of remote nick has changed"
msgstr ""
#, c-format
msgid "%s%s%s %s(%s%s%s)%s is back on server"
msgstr ""
@ -6864,6 +6868,10 @@ msgstr ""
msgid "display a message in private when user is back (after quit on server)"
msgstr ""
msgid ""
"display a warning in private buffer if the address of remote nick has changed"
msgstr ""
msgid ""
"comma separated list of words to highlight in channel buffers (case "
"insensitive, use \"(?-i)\" at beginning of words to make them case "

View File

@ -569,11 +569,57 @@ irc_channel_set_buffer_title (struct t_irc_channel *channel)
void
irc_channel_set_topic (struct t_irc_channel *channel, const char *topic)
{
int display_warning;
/*
* display a warning in the private buffer if the address of remote
* nick has changed (that means you may talk to someone else!)
*/
display_warning = (
(channel->type == IRC_CHANNEL_TYPE_PRIVATE)
&& weechat_config_boolean (irc_config_look_display_pv_warning_address)
&& channel->topic && channel->topic[0]
&& topic && topic[0]
&& (strcmp (channel->topic, topic) != 0));
if (channel->topic)
free (channel->topic);
channel->topic = (topic) ? strdup (topic) : NULL;
irc_channel_set_buffer_title (channel);
if (display_warning)
{
weechat_printf_date_tags (
channel->buffer,
0,
"no_log,warning_nick_address",
_("%sWarning: the address of remote nick has changed"),
weechat_prefix ("error"));
}
}
/*
* Sets topic of all private buffers with a nick.
*/
void
irc_channel_set_topic_private_buffers (struct t_irc_server *server,
struct t_irc_nick *nick,
const char *nickname,
const char *topic)
{
struct t_irc_channel *ptr_channel;
for (ptr_channel = server->channels; ptr_channel;
ptr_channel = ptr_channel->next_channel)
{
if ((ptr_channel->type == IRC_CHANNEL_TYPE_PRIVATE)
&& (irc_server_strcasecmp (server, ptr_channel->name, (nick) ? nick->name : nickname) == 0))
{
irc_channel_set_topic (ptr_channel, topic);
}
}
}
/*

View File

@ -103,6 +103,10 @@ extern void irc_channel_add_nicklist_groups (struct t_irc_server *server,
extern void irc_channel_set_buffer_title (struct t_irc_channel *channel);
extern void irc_channel_set_topic (struct t_irc_channel *channel,
const char *topic);
extern void irc_channel_set_topic_private_buffers (struct t_irc_server *server,
struct t_irc_nick *nick,
const char *nickname,
const char *topic);
extern void irc_channel_set_modes (struct t_irc_channel *channel,
const char *modes);
extern void irc_channel_free (struct t_irc_server *server,

View File

@ -70,6 +70,7 @@ struct t_config_option *irc_config_look_display_join_message;
struct t_config_option *irc_config_look_display_old_topic;
struct t_config_option *irc_config_look_display_pv_away_once;
struct t_config_option *irc_config_look_display_pv_back;
struct t_config_option *irc_config_look_display_pv_warning_address;
struct t_config_option *irc_config_look_highlight_channel;
struct t_config_option *irc_config_look_highlight_pv;
struct t_config_option *irc_config_look_highlight_server;
@ -2825,6 +2826,13 @@ irc_config_init ()
"server)"),
NULL, 0, 0, "on", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
irc_config_look_display_pv_warning_address = weechat_config_new_option (
irc_config_file, ptr_section,
"display_pv_warning_address", "boolean",
N_("display a warning in private buffer if the address of remote nick "
"has changed"),
NULL, 0, 0, "on", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
irc_config_look_highlight_channel = weechat_config_new_option (
irc_config_file, ptr_section,
"highlight_channel", "string",

View File

@ -110,6 +110,7 @@ extern struct t_config_option *irc_config_look_display_join_message;
extern struct t_config_option *irc_config_look_display_old_topic;
extern struct t_config_option *irc_config_look_display_pv_away_once;
extern struct t_config_option *irc_config_look_display_pv_back;
extern struct t_config_option *irc_config_look_display_pv_warning_address;
extern struct t_config_option *irc_config_look_highlight_channel;
extern struct t_config_option *irc_config_look_highlight_pv;
extern struct t_config_option *irc_config_look_highlight_server;

View File

@ -1244,7 +1244,11 @@ IRC_PROTOCOL_CALLBACK(join)
/* display message in private if private has flag "has_quit_server" */
if (!local_join)
{
irc_channel_display_nick_back_in_pv (server, ptr_nick, nick);
irc_channel_set_topic_private_buffers (server, ptr_nick, nick,
address);
}
}
if (local_join)
@ -1717,7 +1721,11 @@ IRC_PROTOCOL_CALLBACK(nick)
}
if (!local_nick)
{
irc_channel_display_nick_back_in_pv (server, ptr_nick_found, new_nick);
irc_channel_set_topic_private_buffers (server, ptr_nick_found,
new_nick, address);
}
return WEECHAT_RC_OK;
}