diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | doc/de/autogen/user/weechat_options.txt | 5 | ||||
-rw-r--r-- | doc/en/autogen/user/weechat_options.txt | 5 | ||||
-rw-r--r-- | doc/fr/autogen/user/weechat_options.txt | 5 | ||||
-rw-r--r-- | doc/it/autogen/user/weechat_options.txt | 5 | ||||
-rw-r--r-- | po/cs.po | 9 | ||||
-rw-r--r-- | po/de.po | 9 | ||||
-rw-r--r-- | po/es.po | 9 | ||||
-rw-r--r-- | po/fr.po | 11 | ||||
-rw-r--r-- | po/hu.po | 9 | ||||
-rw-r--r-- | po/it.po | 9 | ||||
-rw-r--r-- | po/pl.po | 9 | ||||
-rw-r--r-- | po/pt_BR.po | 9 | ||||
-rw-r--r-- | po/ru.po | 9 | ||||
-rw-r--r-- | po/weechat.pot | 9 | ||||
-rw-r--r-- | src/core/wee-config.c | 32 | ||||
-rw-r--r-- | src/core/wee-config.h | 1 | ||||
-rw-r--r-- | src/gui/curses/gui-curses-main.c | 3 | ||||
-rw-r--r-- | src/gui/curses/gui-curses.h | 3 | ||||
-rw-r--r-- | src/gui/gtk/CMakeLists.txt | 1 | ||||
-rw-r--r-- | src/gui/gtk/Makefile.am | 1 | ||||
-rw-r--r-- | src/gui/gtk/gui-gtk-term.c | 37 | ||||
-rw-r--r-- | src/gui/gui-main.h | 3 |
23 files changed, 180 insertions, 17 deletions
@@ -8,8 +8,8 @@ Version 0.3.6 (under dev!) -------------------------- * core: add "hdata" (direct access to WeeChat/plugin data) -* core: fix bug with new line inserted at end of each line displayed (set - eat_newline_glitch to 0 if available) +* core: add option weechat.look.eat_newline_glitch (do not add new line at end + of each line displayed) * core: add option "infolists" for command /debug * core: add horizontal scrolling for buffers with free content (command /window scroll_horiz) (task #11112) diff --git a/doc/de/autogen/user/weechat_options.txt b/doc/de/autogen/user/weechat_options.txt index 2d43e9c25..185860ffc 100644 --- a/doc/de/autogen/user/weechat_options.txt +++ b/doc/de/autogen/user/weechat_options.txt @@ -358,6 +358,11 @@ ** Typ: Zeichenkette ** Werte: beliebige Zeichenkette (Standardwert: `"%a, %d %b %Y"`) +* *weechat.look.eat_newline_glitch* +** Beschreibung: `if set, the eat_newline_glitch will be set to 0; this is used to not add new line char at end of each line, and then not break text when you copy/paste text from WeeChat to another application (this option is disabled by default because it can cause serious display bugs)` +** Typ: boolesch +** Werte: on, off (Standardwert: `off`) + * *weechat.look.highlight* ** Beschreibung: `Durch Kommata getrennte Liste der hervorzuhebenden Wörter (Groß-/Kleinschreibung wird nicht beachtet. Die Schlagwörter können mit "*", als Joker, beginnen oder enden)` ** Typ: Zeichenkette diff --git a/doc/en/autogen/user/weechat_options.txt b/doc/en/autogen/user/weechat_options.txt index 80a7344e1..4aba75e7e 100644 --- a/doc/en/autogen/user/weechat_options.txt +++ b/doc/en/autogen/user/weechat_options.txt @@ -358,6 +358,11 @@ ** type: string ** values: any string (default value: `"%a, %d %b %Y"`) +* *weechat.look.eat_newline_glitch* +** description: `if set, the eat_newline_glitch will be set to 0; this is used to not add new line char at end of each line, and then not break text when you copy/paste text from WeeChat to another application (this option is disabled by default because it can cause serious display bugs)` +** type: boolean +** values: on, off (default value: `off`) + * *weechat.look.highlight* ** description: `comma separated list of words to highlight (case insensitive comparison, words may begin or end with "*" for partial match)` ** type: string diff --git a/doc/fr/autogen/user/weechat_options.txt b/doc/fr/autogen/user/weechat_options.txt index 0ceb96695..865e7eb8b 100644 --- a/doc/fr/autogen/user/weechat_options.txt +++ b/doc/fr/autogen/user/weechat_options.txt @@ -358,6 +358,11 @@ ** type: chaîne ** valeurs: toute chaîne (valeur par défaut: `"%a, %d %b %Y"`) +* *weechat.look.eat_newline_glitch* +** description: `si activé, le eat_newline_glitch sera positionné à 0; cela est utilisé pour ne pas ajouter de nouvelle ligne à la fin de chaque ligne, et donc ne pas couper le texte quand vous copiez/collez du texte depuis WeeChat vers une autre application (cette option est désactivée par défaut car elle peut causer de sérieux problèmes d'affichages)` +** type: booléen +** valeurs: on, off (valeur par défaut: `off`) + * *weechat.look.highlight* ** description: `liste des mots pour la notification (séparés par des virgules, la comparaison ne tient pas compte de la casse, les mots peuvent commencer ou se terminer par "*" pour une comparaison partielle)` ** type: chaîne diff --git a/doc/it/autogen/user/weechat_options.txt b/doc/it/autogen/user/weechat_options.txt index 42a2f527c..6cf8fd763 100644 --- a/doc/it/autogen/user/weechat_options.txt +++ b/doc/it/autogen/user/weechat_options.txt @@ -358,6 +358,11 @@ ** tipo: stringa ** valori: qualsiasi stringa (valore predefinito: `"%a, %d %b %Y"`) +* *weechat.look.eat_newline_glitch* +** descrizione: `if set, the eat_newline_glitch will be set to 0; this is used to not add new line char at end of each line, and then not break text when you copy/paste text from WeeChat to another application (this option is disabled by default because it can cause serious display bugs)` +** tipo: bool +** valori: on, off (valore predefinito: `off`) + * *weechat.look.highlight* ** descrizione: `elenco separato da virgole di finestre da evidenziare (maiuscole/minuscole, le parole potrebbero cominciare o terminare con "*" per un riscontro parziale)` ** tipo: stringa @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:51+0200\n" "Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2087,6 +2087,13 @@ msgid "time format for date displayed when day changed" msgstr "formát času pro zobrazení dne při změně dne" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:51+0200\n" "Last-Translator: Nils G.\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2174,6 +2174,13 @@ msgstr "" "werden soll" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:51+0200\n" "Last-Translator: Elián Hanisch <lambdae2@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2114,6 +2114,13 @@ msgid "time format for date displayed when day changed" msgstr "formato para la fecha mostrada cuando el día cambió" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -21,8 +21,8 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" -"PO-Revision-Date: 2011-06-12 11:27+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" +"PO-Revision-Date: 2011-06-13 12:56+0200\n" "Last-Translator: Sebastien Helleu <flashcode@flashtux.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" "Language: French\n" @@ -2122,6 +2122,13 @@ msgid "time format for date displayed when day changed" msgstr "format de date pour la date affichée quand le jour a changé" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "si activé, le eat_newline_glitch sera positionné à 0; cela est utilisé pour ne pas ajouter de nouvelle ligne à la fin de chaque ligne, et donc ne pas couper le texte quand vous copiez/collez du texte depuis WeeChat vers une autre application (cette option est désactivée par défaut car elle peut causer de sérieux problèmes d'affichages)" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:51+0200\n" "Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -1789,6 +1789,13 @@ msgid "time format for date displayed when day changed" msgstr "új nap kezdetével megjelenő időbélyeg" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:52+0200\n" "Last-Translator: Marco Paolone <marcopaolone@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2111,6 +2111,13 @@ msgid "time format for date displayed when day changed" msgstr "formato dell'ora visualizzato al cambio di data" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" @@ -21,7 +21,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:52+0200\n" "Last-Translator: Krzysztof Koroscik <soltys@szluug.org>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2114,6 +2114,13 @@ msgid "time format for date displayed when day changed" msgstr "format czasu wyświetlanej daty przy zmianie dnia" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" diff --git a/po/pt_BR.po b/po/pt_BR.po index c54cc96f7..8ce67ddbd 100644 --- a/po/pt_BR.po +++ b/po/pt_BR.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:52+0200\n" "Last-Translator: Ivan Sichmann Freitas <ivansichfreitas@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -2115,6 +2115,13 @@ msgstr "mostra uma mensagem especial quando o dia muda" msgid "time format for date displayed when day changed" msgstr "formato de hora tempo para a data mostrada quando o dia muda" +msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + # Does it worth translating 'case insensitive'? #, fuzzy msgid "" @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: WeeChat 0.3.6-dev\n" "Report-Msgid-Bugs-To: flashcode@flashtux.org\n" -"POT-Creation-Date: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: 2011-05-15 10:52+0200\n" "Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n" "Language-Team: weechat-dev <weechat-dev@nongnu.org>\n" @@ -1798,6 +1798,13 @@ msgid "time format for date displayed when day changed" msgstr "отображение маркера даты при смене дня" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" diff --git a/po/weechat.pot b/po/weechat.pot index ecd9b246f..721d36b7f 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: 2011-06-13 11:52+0200\n" +"POT-Creation-Date: 2011-06-13 12:56+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Language-Team: LANGUAGE <LL@li.org>\n" @@ -1549,6 +1549,13 @@ msgid "time format for date displayed when day changed" msgstr "" msgid "" +"if set, the eat_newline_glitch will be set to 0; this is used to not add new " +"line char at end of each line, and then not break text when you copy/paste " +"text from WeeChat to another application (this option is disabled by default " +"because it can cause serious display bugs)" +msgstr "" + +msgid "" "comma separated list of words to highlight (case insensitive comparison, " "words may begin or end with \"*\" for partial match)" msgstr "" diff --git a/src/core/wee-config.c b/src/core/wee-config.c index 40465deab..b21fa1fea 100644 --- a/src/core/wee-config.c +++ b/src/core/wee-config.c @@ -55,6 +55,7 @@ #include "../gui/gui-keyboard.h" #include "../gui/gui-layout.h" #include "../gui/gui-line.h" +#include "../gui/gui-main.h" #include "../gui/gui-nicklist.h" #include "../gui/gui-window.h" #include "../plugins/plugin.h" @@ -85,6 +86,7 @@ struct t_config_option *config_look_command_chars; struct t_config_option *config_look_confirm_quit; struct t_config_option *config_look_day_change; struct t_config_option *config_look_day_change_time_format; +struct t_config_option *config_look_eat_newline_glitch; struct t_config_option *config_look_highlight; struct t_config_option *config_look_highlight_regex; struct t_config_option *config_look_highlight_tags; @@ -316,6 +318,26 @@ config_change_buffer_time_format (void *data, struct t_config_option *option) } /* + * config_change_eat_newline_glitch: called when eat_newline_glitch changes + */ + +void +config_change_eat_newline_glitch (void *data, struct t_config_option *option) +{ + /* make C compiler happy */ + (void) data; + (void) option; + + if (gui_ok) + { + if (CONFIG_BOOLEAN(config_look_eat_newline_glitch)) + gui_term_set_eat_newline_glitch (0); + else + gui_term_set_eat_newline_glitch (1); + } +} + +/* * config_change_highlight_regex: called when highlight_regex changes */ @@ -1598,6 +1620,16 @@ config_weechat_init_options () "day_change_time_format", "string", N_("time format for date displayed when day changed"), NULL, 0, 0, "%a, %d %b %Y", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL); + config_look_eat_newline_glitch = config_file_new_option ( + weechat_config_file, ptr_section, + "eat_newline_glitch", "boolean", + N_("if set, the eat_newline_glitch will be set to 0; this is used to " + "not add new line char at end of each line, and then not break " + "text when you copy/paste text from WeeChat to another application " + "(this option is disabled by default because it can cause serious " + "display bugs)"), + NULL, 0, 0, "off", NULL, 0, NULL, NULL, + &config_change_eat_newline_glitch, NULL, NULL, NULL); config_look_highlight = config_file_new_option ( weechat_config_file, ptr_section, "highlight", "string", diff --git a/src/core/wee-config.h b/src/core/wee-config.h index 73f6da86b..9b2e44d15 100644 --- a/src/core/wee-config.h +++ b/src/core/wee-config.h @@ -112,6 +112,7 @@ extern struct t_config_option *config_look_color_pairs_auto_reset; extern struct t_config_option *config_look_color_real_white; extern struct t_config_option *config_look_day_change; extern struct t_config_option *config_look_day_change_time_format; +extern struct t_config_option *config_look_eat_newline_glitch; extern struct t_config_option *config_look_highlight; extern struct t_config_option *config_look_highlight_regex; extern struct t_config_option *config_look_hline_char; diff --git a/src/gui/curses/gui-curses-main.c b/src/gui/curses/gui-curses-main.c index 33e1143bf..d95c3f56a 100644 --- a/src/gui/curses/gui-curses-main.c +++ b/src/gui/curses/gui-curses-main.c @@ -92,7 +92,8 @@ gui_main_init () initscr (); - gui_term_set_eat_newline_glitch (0); + if (CONFIG_BOOLEAN(config_look_eat_newline_glitch)) + gui_term_set_eat_newline_glitch (0); curs_set (1); noecho (); diff --git a/src/gui/curses/gui-curses.h b/src/gui/curses/gui-curses.h index 97b663f3b..7c5033912 100644 --- a/src/gui/curses/gui-curses.h +++ b/src/gui/curses/gui-curses.h @@ -82,9 +82,6 @@ extern void gui_chat_calculate_line_diff (struct t_gui_window *window, extern void gui_keyboard_default_bindings (); extern int gui_keyboard_read_cb (void *data, int fd); -/* terminal functions */ -extern void gui_term_set_eat_newline_glitch (int value); - /* window functions */ extern void gui_window_read_terminal_size (); extern void gui_window_redraw_buffer (struct t_gui_buffer *buffer); diff --git a/src/gui/gtk/CMakeLists.txt b/src/gui/gtk/CMakeLists.txt index 59d418361..817c3e715 100644 --- a/src/gui/gtk/CMakeLists.txt +++ b/src/gui/gtk/CMakeLists.txt @@ -25,6 +25,7 @@ gui-gtk-chat.c gui-gtk-color.c gui-gtk-keyboard.c gui-gtk-main.c +gui-gtk-term.c gui-gtk-window.c) SET(EXECUTABLE weechat-gtk) diff --git a/src/gui/gtk/Makefile.am b/src/gui/gtk/Makefile.am index a2ffef971..4bd2fa16c 100644 --- a/src/gui/gtk/Makefile.am +++ b/src/gui/gtk/Makefile.am @@ -37,6 +37,7 @@ weechat_gtk_SOURCES = gui-gtk-bar-window.c \ gui-gtk-color.c \ gui-gtk-keyboard.c \ gui-gtk-main.c \ + gui-gtk-term.c \ gui-gtk-window.c \ gui-gtk.h diff --git a/src/gui/gtk/gui-gtk-term.c b/src/gui/gtk/gui-gtk-term.c new file mode 100644 index 000000000..aa510cf87 --- /dev/null +++ b/src/gui/gtk/gui-gtk-term.c @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2011 Sebastien Helleu <flashcode@flashtux.org> + * + * This file is part of WeeChat, the extensible chat client. + * + * WeeChat is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * WeeChat is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with WeeChat. If not, see <http://www.gnu.org/licenses/>. + */ + +/* + * gui-gtk-term.c: terminal functions for Gtk GUI + */ + +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +/* + * gui_term_set_eat_newline_glitch: not used in Gtk GUI + */ + +void +gui_term_set_eat_newline_glitch (int value) +{ + /* make C compiler happy */ + (void) value; +} diff --git a/src/gui/gui-main.h b/src/gui/gui-main.h index 387134c60..887d28b8a 100644 --- a/src/gui/gui-main.h +++ b/src/gui/gui-main.h @@ -27,4 +27,7 @@ extern void gui_main_pre_init (int *argc, char **argv[]); extern void gui_main_init (); extern void gui_main_end (int clean_exit); +/* terminal functions (GUI dependent) */ +extern void gui_term_set_eat_newline_glitch (int value); + #endif /* __WEECHAT_GUI_MAIN_H */ |