1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-29 06:16:40 +02:00

Add null values for options, new syntax for /set, reintroduce temporary IRC server feature, improve IRC server options, new functions in API

This commit is contained in:
Sebastien Helleu
2009-01-02 23:05:23 +01:00
parent e9b7d2bc46
commit e7e2da5a9c
60 changed files with 4555 additions and 2881 deletions
+2 -1
View File
@@ -358,7 +358,7 @@ den Server dazu bringen, seine Konfigurationsdatei neu zu laden
den Server dazu bringen, sich selbst neu zu starten
</programlisting>
<command>/server [list [servername]] | [listfull [servername]] | [add servername hostname[/port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | [rename servername newservername] | [del servername] | [deloutq] | [switch]</command>
<command>/server [list [servername]] | [listfull [servername]] | [add servername hostname[/port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | [rename servername newservername] | [keep servername] | [del servername] | [deloutq] | [switch]</command>
<programlisting>
Auflisten, Hinzufügen oder Entfernen von Servern
@@ -373,6 +373,7 @@ servername: server name, for internal and display use
ssl: use SSL protocol
copy: duplicate a server
rename: rename a server
keep: keep server in config file (for temporary servers only)
del: delete a server
deloutq: delete messages out queue for all servers (all messages WeeChat is currently sending)
switch: switch active server (when one buffer is used for all servers, default key: alt-s on server buffer)
+3 -3
View File
@@ -24,11 +24,11 @@ Examples:
/logger disable
set level to 3 for all IRC buffers:
/set logger.level.irc = 3
/set logger.level.irc 3
disable logging for main WeeChat buffer:
/set logger.level.core.weechat = 0
/set logger.level.core.weechat 0
use a directory per IRC server and a file per channel inside:
/set logger.mask.irc = $server/$channel.weechatlog
/set logger.mask.irc "$server/$channel.weechatlog"
Log levels used by IRC plugin:
1: user message, notice, private
+9 -2
View File
@@ -242,12 +242,19 @@ file: configuration file to save
Without argument, all files (WeeChat and plugins) are saved.
</programlisting>
<command>/set [Option [ = Wert]]</command>
<command>/set [option [value]]</command>
<programlisting>
Konfigurationsparameter setzen
option: name of an option
value: value for option
value: new value for option
New value can be, according to variable type:
boolean: on, off ou toggle
integer: number, ++number ou --number string : any string ("" for empty string)
color : color name, ++number ou --number
For all types, you can use null to remove option value (undefined value). This works only for some special plugin variables.
</programlisting>
<command>/unset [option]</command>
+4 -4
View File
@@ -62,8 +62,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
festzulegen, benutzen Sie den <command>/set</command>" Befehl.
Zum Beispiel:
<screen>
/set charset.default.decode = ISO-8859-15
/set charset.default.encode = ISO-8859-15
/set charset.default.decode ISO-8859-15
/set charset.default.encode ISO-8859-15
</screen>
Wenn der Zeichensatz zum Dekodieren nicht gesetzt ist (z.B. beim
ersten Start des Plugins), wird es automatisch auf den
@@ -102,7 +102,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<!-- TRANSLATION NEEDED -->
To set charset for all IRC channels (and privates) of an IRC server,
use following command:
<screen>/set charset.decode.irc.freenode = ISO-8859-15</screen>
<screen>/set charset.decode.irc.freenode ISO-8859-15</screen>
</para>
</listitem>
<listitem>
@@ -141,7 +141,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
Setze die globalen Dekodier-Einstellungen, z.B.:
<screen>/set charset.default.decode = ISO-8859-15</screen>
<screen>/set charset.default.decode ISO-8859-15</screen>
</para>
</listitem>
</itemizedlist>
+5 -5
View File
@@ -118,25 +118,25 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
set level 3 for IRC channel #weechat:
<screen>/set logger.level.irc.freenode.#weechat = 3</screen>
<screen>/set logger.level.irc.freenode.#weechat 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 3 for freenode server buffer:
<screen>/set logger.level.irc.server.freenode = 3</screen>
<screen>/set logger.level.irc.server.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 3 for all channels on server freenode:
<screen>/set logger.level.irc.freenode = 3</screen>
<screen>/set logger.level.irc.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 2 for all IRC buffers:
<screen>/set logger.level.irc = 2</screen>
<screen>/set logger.level.irc 2</screen>
</para>
</listitem>
</itemizedlist>
@@ -156,7 +156,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<para>
For example if you want one directory by IRC server and one file by
channel inside:
<screen>/set logger.mask.irc = "irc/$server/$channel.weechatlog"</screen>
<screen>/set logger.mask.irc "irc/$server/$channel.weechatlog"</screen>
You'll have following files:
<screen>
~/.weechat/
+1 -1
View File
@@ -23,7 +23,7 @@
# 1. run WeeChat and load this script, with following command:
# /perl load ~/src/weechat/doc/docgen.pl
# 2. change path to build in your doc/ directory:
# /set plugins.var.perl.docgen.path = "~/src/weechat/doc"
# /set plugins.var.perl.docgen.path "~/src/weechat/doc"
# 3. run docgen command:
# /docgen
# XML files should be in ~/src/weechat/doc/xx/autogen/ (where xx is language)
+2 -1
View File
@@ -358,7 +358,7 @@ tell the server to reload its config file
tell the server to restart itself
</programlisting>
<command>/server [list [servername]] | [listfull [servername]] | [add servername hostname[/port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | [rename servername newservername] | [del servername] | [deloutq] | [switch]</command>
<command>/server [list [servername]] | [listfull [servername]] | [add servername hostname[/port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | [rename servername newservername] | [keep servername] | [del servername] | [deloutq] | [switch]</command>
<programlisting>
list, add or remove servers
@@ -373,6 +373,7 @@ servername: server name, for internal and display use
ssl: use SSL protocol
copy: duplicate a server
rename: rename a server
keep: keep server in config file (for temporary servers only)
del: delete a server
deloutq: delete messages out queue for all servers (all messages WeeChat is currently sending)
switch: switch active server (when one buffer is used for all servers, default key: alt-s on server buffer)
+3 -3
View File
@@ -24,11 +24,11 @@ Examples:
/logger disable
set level to 3 for all IRC buffers:
/set logger.level.irc = 3
/set logger.level.irc 3
disable logging for main WeeChat buffer:
/set logger.level.core.weechat = 0
/set logger.level.core.weechat 0
use a directory per IRC server and a file per channel inside:
/set logger.mask.irc = $server/$channel.weechatlog
/set logger.mask.irc "$server/$channel.weechatlog"
Log levels used by IRC plugin:
1: user message, notice, private
+9 -2
View File
@@ -242,12 +242,19 @@ file: configuration file to save
Without argument, all files (WeeChat and plugins) are saved.
</programlisting>
<command>/set [option [ = value]]</command>
<command>/set [option [value]]</command>
<programlisting>
set config options
option: name of an option
value: value for option
value: new value for option
New value can be, according to variable type:
boolean: on, off ou toggle
integer: number, ++number ou --number string : any string ("" for empty string)
color : color name, ++number ou --number
For all types, you can use null to remove option value (undefined value). This works only for some special plugin variables.
</programlisting>
<command>/unset [option]</command>
+302 -1
View File
@@ -2944,6 +2944,7 @@ struct t_config_option *weechat_config_new_option (
int max,
const chat *default_value,
const char *value,
int null_value_allowed,
int (*callback_check_value)(void *data,
struct t_config_option *option,
const char *value),
@@ -3029,6 +3030,12 @@ struct t_config_option *weechat_config_new_option (
<option>value</option>: value for option
</para>
</listitem>
<listitem>
<para>
<option>null_value_allowed</option>: 1 if null (undefined value)
is allowed for option, otherwise 0
</para>
</listitem>
<listitem>
<para>
<option>callback_check_value</option>: callback called to check
@@ -3159,6 +3166,7 @@ struct t_config_option *option1 =
0, 0, /* min, max */
"on", /* default */
"on", /* value */
0, /* null value allowed */
NULL, NULL, /* check callback */
NULL, NULL, /* change callback */
NULL, NULL); /* delete callback */
@@ -3171,6 +3179,7 @@ struct t_config_option *option2 =
0, 100, /* min, max */
"15", /* default */
"15", /* value */
0, /* null value allowed */
NULL, NULL, /* check callback */
NULL, NULL, /* change callback */
NULL, NULL); /* delete callback */
@@ -3183,6 +3192,7 @@ struct t_config_option *option3 =
0, 0, /* min, max */
"bottom", /* default */
"bottom", /* value */
0, /* null value allowed */
NULL, NULL, /* check callback */
NULL, NULL, /* change callback */
NULL, NULL); /* delete callback */
@@ -3195,6 +3205,7 @@ struct t_config_option *option4 =
0, 0, /* min, max */
"test", /* default */
"test", /* value */
1, /* null value allowed */
NULL, NULL, /* check callback */
NULL, NULL, /* change callback */
NULL, NULL); /* delete callback */
@@ -3207,6 +3218,7 @@ struct t_config_option *option5 =
0, 0, /* min, max */
"lightblue", /* default */
"lightblue", /* value */
0, /* null value allowed */
NULL, NULL, /* check callback */
NULL, NULL, /* change callback */
NULL, NULL); /* delete callback */
@@ -3487,6 +3499,66 @@ switch (weechat_config_option_set (option, "new_value", 1))
</para>
</section>
<section id="secPluginCApi_weechat_config_option_set_null">
<title>weechat_config_option_set_null</title>
<para>
Prototype:
<programlisting>
int weechat_config_option_set_null (
struct t_config_option *option,
int run_callback);
</programlisting>
</para>
<para>
Set null (undefined value) for an option.
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
<listitem>
<para>
<option>run_callback</option>: 1 for calling change callback if
option is changed (if it was not null), 0 otherwise
</para>
</listitem>
</itemizedlist>
</para>
<note>
<para>
You can set value to null only if option allows null value
(see <xref linkend="secPluginCApi_weechat_config_new_option" />).
</para>
</note>
<para>
Return value: WEECHAT_CONFIG_OPTION_SET_OK_CHANGED if option value has
been reset, WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE if value was not
changed, WEECHAT_CONFIG_OPTION_SET_ERROR if an error occured.
</para>
<para>
Example:
<screen>
switch (weechat_config_option_set_null (option, 1))
{
case WEECHAT_CONFIG_OPTION_SET_OK_CHANGED:
/* .... */
break;
case WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE:
/* .... */
break;
case WEECHAT_CONFIG_OPTION_SET_ERROR:
/* .... */
break;
}
</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_option_unset">
<title>weechat_config_option_unset</title>
@@ -3677,6 +3749,9 @@ void *weechat_config_option_get_pointer (
</listitem>
</itemizedlist>
</para>
<para>
Return value: pointer to property asked.
</para>
<para>
Example:
<screen>
@@ -3685,6 +3760,43 @@ char *description = weechat_config_option_get_pointer (option, "description");
</para>
</section>
<section id="secPluginCApi_weechat_config_option_is_null">
<title>weechat_config_option_is_null</title>
<para>
Prototype:
<programlisting>
int weechat_config_option_is_null (struct t_config_option *option);
</programlisting>
</para>
<para>
Check if an option is null (undefined value).
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Example:
<screen>
if (weechat_config_option_is_null (option))
{
/* value is null */
}
else
{
/* value is not null */
}
</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_boolean">
<title>weechat_config_boolean</title>
@@ -3725,6 +3837,46 @@ else
</para>
</section>
<section id="secPluginCApi_weechat_config_boolean_default">
<title>weechat_config_boolean_default</title>
<para>
Prototype:
<programlisting>
int weechat_config_boolean_default (struct t_config_option *option);
</programlisting>
</para>
<para>
Get default boolean value of option.
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Return value: default boolean value of option (0 or 1).
</para>
<para>
Example:
<screen>
if (weechat_config_boolean_default (option))
{
/* true */
}
else
{
/* false */
}
</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_integer">
<title>weechat_config_integer</title>
@@ -3752,7 +3904,38 @@ int weechat_config_integer (struct t_config_option *option);
</para>
<para>
Example:
<screen>int value = weechat_config_boolean (option);</screen>
<screen>int value = weechat_config_integer (option);</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_integer_default">
<title>weechat_config_integer_default</title>
<para>
Prototype:
<programlisting>
int weechat_config_integer_default (struct t_config_option *option);
</programlisting>
</para>
<para>
Get default integer value of option.
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Return value: default integer value of option.
</para>
<para>
Example:
<screen>int value = weechat_config_integer (option);</screen>
</para>
</section>
@@ -3793,6 +3976,37 @@ const char *weechat_config_string (struct t_config_option *option);
<para>
Prototype:
<programlisting>
const char *weechat_config_string_default (struct t_config_option *option);
</programlisting>
</para>
<para>
Get default string value of option.
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Return value: default string value of option.
</para>
<para>
Example:
<screen>char *value = weechat_config_string_default (option);</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_color">
<title>weechat_config_color</title>
<para>
Prototype:
<programlisting>
const char *weechat_config_color (struct t_config_option *option);
</programlisting>
</para>
@@ -3818,6 +4032,85 @@ const char *weechat_config_color (struct t_config_option *option);
</para>
</section>
<section id="secPluginCApi_weechat_config_color_default">
<title>weechat_config_color_default</title>
<para>
Prototype:
<programlisting>
const char *weechat_config_color_default (struct t_config_option *option);
</programlisting>
</para>
<para>
Get default color value of option.
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Return value: default color value of option (string with name of color).
</para>
<para>
Example:
<screen>char *color = weechat_config_color_default (option);</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_write_option">
<title>weechat_config_write_option</title>
<para>
Prototype:
<programlisting>
void weechat_config_write_option (
struct t_config_file *config_file,
struct t_config_option *option);
</programlisting>
</para>
<para>
Write a line in a configuration file with option and its value (this
function should be called only in "write" or "write_default" callbacks
for a section).
</para>
<para>
Arguments:
<itemizedlist>
<listitem>
<para>
<option>config_file</option>: configuration file pointer
</para>
</listitem>
<listitem>
<para>
<option>option</option>: option pointer
</para>
</listitem>
</itemizedlist>
</para>
<para>
Example:
<screen>
int
my_section_write_cb (void *data, struct t_config_file *config_file,
const char *section_name)
{
weechat_config_write_line (config_file, "my_section", NULL);
weechat_config_write_option (config_file, option);
return WEECHAT_RC_OK;
}
</screen>
</para>
</section>
<section id="secPluginCApi_weechat_config_write_line">
<title>weechat_config_write_line</title>
@@ -3854,6 +4147,12 @@ void weechat_config_write_line (
</listitem>
</itemizedlist>
</para>
<note>
<para>
If value is NULL, then line with section name is written
(for example: "[section]").
</para>
</note>
<para>
Example:
<screen>
@@ -3861,6 +4160,8 @@ int
my_section_write_cb (void *data, struct t_config_file *config_file,
const char *section_name)
{
weechat_config_write_line (config_file, "my_section", NULL);
weechat_config_write_line (config_file, "option", "%s;%d",
"value", 123);
+4 -4
View File
@@ -63,8 +63,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<command>/set</command>.
For example:
<screen>
/set charset.default.decode = ISO-8859-15
/set charset.default.encode = ISO-8859-15
/set charset.default.decode ISO-8859-15
/set charset.default.encode ISO-8859-15
</screen>
If global decode charset is not set (for example during first
load of Charset plugin), it will be automatically set to terminal
@@ -99,7 +99,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<para>
To set charset for all IRC channels (and privates) of an IRC server,
use following command:
<screen>/set charset.decode.irc.freenode = ISO-8859-15</screen>
<screen>/set charset.decode.irc.freenode ISO-8859-15</screen>
</para>
</listitem>
<listitem>
@@ -145,7 +145,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
setup global decode value, for example:
<screen>/set charset.default.decode = ISO-8859-15</screen>
<screen>/set charset.default.decode ISO-8859-15</screen>
</para>
</listitem>
</itemizedlist>
+5 -5
View File
@@ -118,25 +118,25 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
set level 3 for IRC channel #weechat:
<screen>/set logger.level.irc.freenode.#weechat = 3</screen>
<screen>/set logger.level.irc.freenode.#weechat 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 3 for freenode server buffer:
<screen>/set logger.level.irc.server.freenode = 3</screen>
<screen>/set logger.level.irc.server.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 3 for all channels on server freenode:
<screen>/set logger.level.irc.freenode = 3</screen>
<screen>/set logger.level.irc.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
set level 2 for all IRC buffers:
<screen>/set logger.level.irc = 2</screen>
<screen>/set logger.level.irc 2</screen>
</para>
</listitem>
</itemizedlist>
@@ -156,7 +156,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<para>
For example if you want one directory by IRC server and one file by
channel inside:
<screen>/set logger.mask.irc = "irc/$server/$channel.weechatlog"</screen>
<screen>/set logger.mask.irc "irc/$server/$channel.weechatlog"</screen>
You'll have following files:
<screen>
~/.weechat/
+69 -35
View File
@@ -3,17 +3,17 @@ WeeChat quick start guide (english version)
1. Launch weechat
Run "weechat-curses" from your shell.
A recommended terminal emulator for X (but not mandatory) is rxvt-unicode
(it has good UTF-8 support, and no problem with default keyboard bindings).
Run "weechat-curses" from your shell.
2. Online help / options
WeeChat has help for all commands, just issue /help
To get help on a command, issue /help command
To set options, use /set config.section.option = value
To set options, use /set config.section.option value
(where config is configuration name ("weechat" for core, or a plugin
name), "section" the section of this configuration and "option" the
option name).
@@ -24,12 +24,14 @@ WeeChat quick start guide (english version)
You can use /set option with partial name and wildcard "*" at beginning or
end to display all options containg letters.
For example:
/set => display all options (WeeChat and plugins)
/set weechat.* => display WeeChat options
/set irc.* => display IRC plugin options
/set => display all options (WeeChat and plugins)
/set weechat.* => display WeeChat options
/set irc.* => display IRC plugin options
You can display help for an option with /help, for example:
/help weechat.look.highlight
/help weechat.look.highlight
All settings are saved when WeeChat ends (or with "/save" command to force
write of options).
@@ -51,10 +53,12 @@ WeeChat quick start guide (english version)
4. Create an IRC server
You can add an IRC server with /server command, for example:
/server add oftc irc.oftc.org 6667
/server add oftc irc.oftc.org 6667
As usual, help is available if you're lost:
/help server
/help server
5. Set custom IRC server options
@@ -62,30 +66,44 @@ WeeChat quick start guide (english version)
don't specify a specific value for a server option.
These default options are "irc.server_default.*".
For each server option, WeeChat uses its value if it is defined (not
"null"). Otherwise WeeChat uses default value (irc.server_default.xxx).
For example there's default nicks (based on your un*x login), and you can
override them for oftc server with following command:
/set irc.server.oftc.nicks = "mynick1,mynick2,mynick3,mynick4,mynick5"
/set irc.server.oftc.nicks "mynick1,mynick2,mynick3,mynick4,mynick5"
To set username and realname:
/set irc.server.oftc.username = "My user name"
/set irc.server.oftc.realname = "My real name"
/set irc.server.oftc.username "My user name"
/set irc.server.oftc.realname "My real name"
To enable auto-connect to server at startup:
/set irc.server.oftc.autoconnect = on
/set irc.server.oftc.autoconnect on
To run a command after connection to server, for example to identify
with nickserv:
/set irc.server.oftc.command = "/msg nickserv identify xxxxxx"
/set irc.server.oftc.command "/msg nickserv identify xxxxxx"
Note: many commmands can be separated by ';' (semi-colon)
To auto-join some channels when connecting to server:
/set irc.server.oftc.autojoin = "#channel1,#channel2"
/set irc.server.oftc.autojoin "#channel1,#channel2"
To remove value of a server option, and use default value instead,
for example to use default nicks (irc.server_default.nicks):
/set irc.server.oftc.nicks null
Other options:
You can setup other options with following command:
/set irc.server.oftc.xxx = value
where "xxx" is option name - you can see all possible options with:
/set irc.server_default.*
You can setup other options with following command ("xxx" is option
name):
/set irc.server.oftc.xxx value
6. Connect to IRC server and auto-join channels
@@ -98,11 +116,17 @@ WeeChat quick start guide (english version)
7. Join/part IRC channels
Join a channel:
/join #channel
/join #channel
Part a channel:
/part [quit message]
/part [quit message]
Close server or channel buffer:
/close [quit message]
/close [quit message]
(/close is an alias on /buffer close)
8. Buffer/window management
@@ -115,13 +139,16 @@ WeeChat quick start guide (english version)
with many buffers at same time.
Commands to manage buffers and windows:
/buffer
/window
/buffer
/window
(I'll not repeat here that you can get help with /help on these commands)
For example, to split verticaly screen into a small window (1/3 width),
and a large (2/3), use command:
/window splitv 33
/window splitv 33
9. Key bindings
@@ -140,11 +167,16 @@ WeeChat quick start guide (english version)
A useful key is meta-k (alt-k) to find key codes.
For example, to bind meta-y (alt-y) to command "/buffer close":
/key (press meta-k) (press meta-y) /buffer close
/key (press meta-k) (press meta-y) /buffer close
You'll have a command line like:
/key meta-y /buffer close
/key meta-y /buffer close
To remove key:
/key unbind meta-y
/key unbind meta-y
10. Plugins/scripts
@@ -153,24 +185,26 @@ WeeChat quick start guide (english version)
Plugins are automatically loaded when found.
Some plugins let you use scripts in WeeChat (in many languages like Perl,
Python, Ruby and Lua). These plugins must be loaded with /plugin command
and they provide commands like /perl, used to load scripts.
Python, Ruby, Lua and Tcl). These plugins must be loaded with /plugin
command and they provide commands like /perl, used to load scripts.
Many external plugins/scripts (from contributors) are available for
WeeChat, please look at:
http://weechat.flashtux.org/plugins.php
http://weechat.flashtux.org/plugins.php
Please look at WeeChat documentation to load/unload plugins or scripts.
11. More documentation
You can now use WeeChat and read FAQ/documentation for any other question:
http://weechat.flashtux.org/faq.php
http://weechat.flashtux.org/doc.php
http://weechat.flashtux.org/faq.php
http://weechat.flashtux.org/doc.php
Enjoy WeeChat!
--
(c) 2006-2008, written by FlashCode <flashcode@flashtux.org>
Last edited on 2008-11-12.
(c) 2006-2009, written by FlashCode <flashcode@flashtux.org>
Last edited on 2009-01-02.
This document is part of WeeChat and is distributed under GPL 3 licence.
+2 -1
View File
@@ -358,7 +358,7 @@ demander au serveur de recharger son fichier de configuration
demander au serveur de redémarrer
</programlisting>
<command>/server [list [nom_serveur]] | [listfull [nom_serveur]] | [add nom_serveur nom[/port] [-temp] [-auto | -noauto] [-ipv6] [-ssl]] | [copy nom_serveur nouveau_nom_serveur] | [rename nom_serveur nouveau_nom_serveur] | [del nom_serveur] | [deloutq] | [switch]</command>
<command>/server [list [nom_serveur]] | [listfull [nom_serveur]] | [add nom_serveur nom[/port] [-temp] [-auto | -noauto] [-ipv6] [-ssl]] | [copy nom_serveur nouveau_nom_serveur] | [rename nom_serveur nouveau_nom_serveur] | [keep nom_serveur] | [del nom_serveur] | [deloutq] | [switch]</command>
<programlisting>
liste, ajoute ou retire des serveurs
@@ -373,6 +373,7 @@ nom_serveur: nom du serveur, pour usage interne et affichage
ssl: utiliser le protocole SSL
copy: dupliquer un serveur
rename: renommer un serveur
keep: garder le serveur dans le fichier de configuration (pour les serveurs temporaires seulement)
del: supprimer un serveur
deloutq: supprimer la file d'attente des messages sortants pour tous les serveurs (tous les messages que WeeChat est actuellement en train d'envoyer)
switch: changer le serveur actif (quand un tampon est utilisé pour tous les serveurs, touche par défaut: alt-s sur le tampon serveur)
+3 -3
View File
@@ -23,11 +23,11 @@ Exemples :
désactiver l'enregistrement pour le tampon courant :
/logger disable
définir le niveau à 3 pour les tampons IRC :
/set logger.level.irc = 3
/set logger.level.irc 3
désactiver l'enregistrement pour le tampon principal de WeeChat :
/set logger.level.core.weechat = 0
/set logger.level.core.weechat 0
utiliser un répertoire par serveur IRC et un fichier par canal dedans :
/set logger.mask.irc = $server/$channel.weechatlog
/set logger.mask.irc "$server/$channel.weechatlog"
Niveaux de log utilisés par l'extension IRC :
1: message d'utilisateur, notice, privé
+10 -2
View File
@@ -240,12 +240,20 @@ fichier: fichier de configuration à sauvegarder
Sans paramètre, tous les fichiers (WeeChat et extensions) sont sauvegardés.
</programlisting>
<command>/set [option [ = valeur]]</command>
<command>/set [option [valeur]]</command>
<programlisting>
modifier des options de configuration
option: nom d'une option
valeur: valeur pour l'option
valeur: nouvelle valeur pour l'option
La nouvelle valeur peut être, selon le type de l'option :
booléen: on, off ou toggle
entier : nombre, ++nombre ou --nombre
chaîne : toute chaîne ("" pour une chaîne vide)
couleur: nom de couleur, ++nombre ou --nombre
Pour tous les types, vous pouvez utiliser null pour supprimer la valeur de l'option (valeur non définie). Cela ne fonctionne qu'avec certaines options spéciales des extensions.
</programlisting>
<command>/unset [option]</command>
+5 -5
View File
@@ -66,11 +66,11 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
Pour modifier les jeux de caractères de décodage et d'encodage
globaux, utilisez la commande <command>/setp</command>".
globaux, utilisez la commande <command>/set</command>".
Par exemple :
<screen>
/set charset.default.decode = ISO-8859-15
/set charset.default.encode = ISO-8859-15
/set charset.default.decode ISO-8859-15
/set charset.default.encode ISO-8859-15
</screen>
Si le jeu de caractères de décodage global n'est pas renseigné
(par exemple pendant le premier chargement de Charset), il sera
@@ -108,7 +108,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
Pour modifier le jeu de caractères pour tous les canaux IRC (et
conversations privées) d'un serveur IRC, utilisez la commande
suivante :
<screen>/set charset.decode.irc.freenode = ISO-8859-15</screen>
<screen>/set charset.decode.irc.freenode ISO-8859-15</screen>
</para>
</listitem>
<listitem>
@@ -158,7 +158,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
affectez la valeur pour le décodage global, par exemple :
<screen>/set charset.default.decode = ISO-8859-15</screen>
<screen>/set charset.default.decode ISO-8859-15</screen>
</para>
</listitem>
</itemizedlist>
+5 -5
View File
@@ -119,25 +119,25 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<listitem>
<para>
afecter le niveau 3 pour le canal IRC #weechat :
<screen>/set logger.level.irc.freenode.#weechat = 3</screen>
<screen>/set logger.level.irc.freenode.#weechat 3</screen>
</para>
</listitem>
<listitem>
<para>
affecter le niveau 3 pour le tampon serveur freenode :
<screen>/set logger.level.irc.server.freenode = 3</screen>
<screen>/set logger.level.irc.server.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
affecter le niveau 3 pour tous les canaux sur le serveur freenode :
<screen>/set logger.level.irc.freenode = 3</screen>
<screen>/set logger.level.irc.freenode 3</screen>
</para>
</listitem>
<listitem>
<para>
affecter le niveau 2 pour tous les tampons IRC :
<screen>/set logger.level.irc = 2</screen>
<screen>/set logger.level.irc 2</screen>
</para>
</listitem>
</itemizedlist>
@@ -158,7 +158,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
<para>
Par exemple, si vous voulez un répertoire par serveur IRC et un fichier
par canal dedans :
<screen>/set logger.mask.irc = "irc/$server/$channel.weechatlog"</screen>
<screen>/set logger.mask.irc "irc/$server/$channel.weechatlog"</screen>
Vous obtiendrez les fichiers suivants :
<screen>
~/.weechat/
+69 -35
View File
@@ -3,18 +3,18 @@ Guide de démarrage rapide WeeChat (version française)
1. Démarrer weechat
Lancer "weechat-curses" depuis votre shell.
Un émulateur de terminal recommandé pour X (mais pas obligatoire) est
rxvt-unicode (il a un bon support UTF-8, et aucun problème avec les
touches par défaut).
Lancer "weechat-curses" depuis votre shell.
2. Aide en ligne / options
WeeChat dispose d'aide pour toutes les commandes, tapez simplement /help
Pour avoir de l'aide sur une commande, tapez /help commande
Pour modifier des options, utilisez /set config.section.option = valeur
Pour modifier des options, utilisez /set config.section.option valeur
(où "config" est le nom de la configuration ("weechat" pour le coeur, ou
un nom d'extension), "section" la section de cette configuration et
"option" le nom de l'option).
@@ -26,12 +26,13 @@ Guide de démarrage rapide WeeChat (version française)
joker "*" au début ou à la fin pour afficher toutes les options contenant
ces lettres.
Par exemple :
/set => affiche toutes les options (WeeChat et extensions)
/set weechat.* => affiche les options WeeChat
/set irc.* => affiche les options de l'extension IRC
/set => affiche toutes les options (WeeChat et extensions)
/set weechat.* => affiche les options WeeChat
/set irc.* => affiche les options de l'extension IRC
Vous pouvez afficher de l'aide sur une option avec /help, par exemple :
/help weechat.look.highlight
/help weechat.look.highlight
Toutes les options sont sauvées quand WeeChat quitte (ou avec la commande
"/save" pour forcer une écriture des options).
@@ -55,10 +56,12 @@ Guide de démarrage rapide WeeChat (version française)
4. Créer un serveur IRC
Vous pouvez ajouter un serveur IRC par la commande /server, par exemple :
/server add oftc irc.oftc.org 6667
/server add oftc irc.oftc.org 6667
Comme d'habitude, de l'aide est disponible si vous êtes perdus :
/help server
/help server
5. Définir les options du serveur IRC
@@ -66,31 +69,46 @@ Guide de démarrage rapide WeeChat (version française)
spécifiez pas de valeur spécifique pour une option de serveur.
Ces options par défaut sont "irc.server_default.*".
Pour chaque option d'un serveur, WeeChat utilise sa valeur si elle est
définie (non "null"). Sinon WeeChat utilise la valeur par défaut
(irc.server_default.xxx).
Par exemple il y a des pseudos par défaut (basés sur votre login un*x), et
vous pouvez les écraser pour le serveur oftc avec la commande suivante :
/set irc.server.oftc.nicks = "pseudo1,pseudo2,pseudo3,pseudo4,pseudo5"
/set irc.server.oftc.nicks "pseudo1,pseudo2,pseudo3,pseudo4,pseudo5"
Pour modifier le nom d'utilisateur et nom réel :
/set irc.server.oftc.username = "Mon nom d'utilisateur"
/set irc.server.oftc.realname = "Mon nom réel"
/set irc.server.oftc.username "Mon nom d'utilisateur"
/set irc.server.oftc.realname "Mon nom réel"
Pour activer la connexion automatique au serveur lors du démarrage :
/set irc.server.oftc.autoconnect = on
/set irc.server.oftc.autoconnect on
Pour lancer une commande après connexion au serveur, par exemple pour
s'identifier auprès de nickserv :
/set irc.server.oftc.command = "/msg nickserv identify xxxxxx"
/set irc.server.oftc.command "/msg nickserv identify xxxxxx"
NB: plusieurs commandes peuvent être séparées par ';' (point-virgule)
Pour rejoindre automatiquement des canaux lors de la connexion au serveur :
/set irc.server.oftc.autojoin = "#canal1,#canal2"
/set irc.server.oftc.autojoin "#canal1,#canal2"
Pour supprimer la valeur d'une option du serveur et utiliser sa valeur par
défaut à la place, par exemple pour utiliser les pseudos par défaut
(irc.server_default.nicks) :
/set irc.server.oftc.nicks null
Autres options :
Vous pouvez modifier les autres options avec la commande suivante :
/set irc.server.oftc.xxx = valeur
où "xxx" est le nom d'une option - vous pouvez vois les options possibles
avec :
/set irc.server_default.*
Vous pouvez modifier les autres options avec la commande suivante ("xxx"
est le nom d'une option) :
/set irc.server.oftc.xxx valeur
6. Se connecter au serveur IRC et rejoindre les canaux
@@ -103,11 +121,17 @@ Guide de démarrage rapide WeeChat (version française)
7. Joindre/quitter les canaux IRC
Joindre un canal :
/join #channel
/join #channel
Quitter un canal :
/part [message de fin]
/part [message de fin]
Quitter un canal et fermer le tampon :
/close [message de fin]
/close [message de fin]
(/close est un alias sur /buffer close)
8. Gérer les tampons/fenêtres
@@ -120,14 +144,17 @@ Guide de démarrage rapide WeeChat (version française)
alors plusieurs fenêtres avec plusieurs tampons en même temps.
Commandes pour gérer les tampons et les fenêtres :
/buffer
/window
/buffer
/window
(je ne répéterai pas que vous pouvez avoir de l'aide sur ces commandes
avec /help)
Par exemple, pour découper verticalement l'écran en une petite fenêtre
(1/3 de la largeur) et une large (2/3), utilisez la commande :
/window splitv 33
/window splitv 33
9. Raccourcis clavier
@@ -147,11 +174,16 @@ Guide de démarrage rapide WeeChat (version française)
Une touche utile est meta-k (alt-k) pour trouver le code des touches.
Par exemple, pour associer meta-y (alt-y) à la commande "/buffer close" :
/key (pressez meta-k) (pressez meta-y) /buffer close
/key (pressez meta-k) (pressez meta-y) /buffer close
Vous aurez une ligne de commande qui ressemble à ceci :
/key meta-y /buffer close
/key meta-y /buffer close
Pour enlever la touche :
/key unbind meta-y
/key unbind meta-y
10. Extensions/scripts
@@ -160,13 +192,14 @@ Guide de démarrage rapide WeeChat (version française)
Les extensions sont automatiquement chargées lorsqu'elles sont trouvées.
Des extensions permettent d'utiliser des scripts dans WeeChat (dans
différent langages comme Perl, Python, Ruby et Lua). Ces extensions
différent langages comme Perl, Python, Ruby, Lua et Tcl). Ces extensions
doivent être chargées avec la commande /plugin et elles fournissent des
commandes telles que /perl, utilisées pour charger les scripts.
Plusieurs extensions/scripts (de contributeurs) sont disponibles pour
WeeChat, voir ici :
http://weechat.flashtux.org/plugins.php
http://weechat.flashtux.org/plugins.php
Merci de regarder la documentation WeeChat pour charger/décharger des
extensions ou des scripts.
@@ -175,12 +208,13 @@ Guide de démarrage rapide WeeChat (version française)
Vous pouvez maintenant utiliser WeeChat et lire la FAQ/documentation pour
toute autre question :
http://weechat.flashtux.org/faq.php
http://weechat.flashtux.org/doc.php
http://weechat.flashtux.org/faq.php
http://weechat.flashtux.org/doc.php
Bon WeeChat !
--
(c) 2006-2008, écrit par FlashCode <flashcode@flashtux.org>
Dernière édition le 12/11/2008.
(c) 2006-2009, écrit par FlashCode <flashcode@flashtux.org>
Dernière édition le 02/01/2009.
Ce document fait partie de WeeChat et est distribué sous license GPL 3.
+129 -88
View File
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2008-09-17 16:19+0200\n"
"Last-Translator: Jiri Golembiovsky <golemj@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -321,6 +321,10 @@ msgstr "hodnoty"
msgid "default value"
msgstr "výchozí hodnota"
#, fuzzy
msgid "(undefined)"
msgstr "výchozí hodnota"
msgid "current value"
msgstr "aktuální hodnota"
@@ -1074,15 +1078,23 @@ msgstr ""
msgid "set config options"
msgstr "nastaví konfigurační možnosti"
msgid "[option [ = value]]"
#, fuzzy
msgid "[option [value]]"
msgstr "[možnost [ = hodnota]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
"možnost: jméno volby\n"
"hodnota: hodnota volby"
msgid "unset/reset config options"
msgstr "odnastavit/resetovat konfigurační možnosti"
@@ -1680,7 +1692,7 @@ msgid "(default options)"
msgstr "(výchozí volby)"
#, fuzzy, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%s konfigurační soubor \"%s\" nenalezen\n"
#, fuzzy, c-format
@@ -1695,10 +1707,6 @@ msgstr "%s %s, řádek %d: nevalidní syntaxe, chybí \"]\"\n"
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%s %s, řádek %d: neznámý identifikátor sekce (\"%s\")\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%s %s, řádek %d: nevalidní syntax, chybí \"=\"\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr "%s %s, řádek %d: neznámý identifikátor sekce (\"%s\")\n"
@@ -1715,58 +1723,6 @@ msgstr "%s %s, řádek %d: nevalidní volba \"%s\"\n"
msgid "Reloading configuration file %s"
msgstr "Ukládám konfiguraci na disk\n"
msgid " . type: boolean\n"
msgstr " . typ: boolean\n"
#, fuzzy
msgid " . values: \"on\" or \"off\"\n"
msgstr " . hodnoty: 'on' or 'off'\n"
#, fuzzy, c-format
msgid " . default value: \"%s\"\n"
msgstr " . výchozí hodnota: '%s'\n"
msgid " . type: string\n"
msgstr " . typ: řetězec\n"
msgid " . values: "
msgstr " . hodnoty: "
msgid " . type: integer\n"
msgstr " . typ: celočíselný\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . hodnoty: mezi %d a %d\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . výchozí hodnota: %d\n"
msgid " . values: any string\n"
msgstr " . hodnoty: typ řetězec (jakýkoliv řetězec)\n"
msgid " . type: char\n"
msgstr " . typ: znak\n"
msgid " . values: any char\n"
msgstr " . hodnoty: jakýkolív znak\n"
#, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . hodnoty: jakýkoliv řetězec (limit: %d znaků)\n"
msgid " . type: color\n"
msgstr " . typ: barva\n"
#, fuzzy
msgid " . values: color (depends on GUI used)\n"
msgstr " . hodnoty: mezi %d a %d\n"
#, c-format
msgid " . description: %s\n"
msgstr " . popis: %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2417,7 +2373,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s chybí argument pro volbu \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "Server %s%s%s vytvořen\n"
#, fuzzy, c-format
@@ -2527,18 +2483,6 @@ msgstr "Server s '%s':\n"
msgid "No server found with \"%s\""
msgstr "Žádný server s '%s' nenalezen.\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s server \"%s\" nenalezen pro příkaz \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s server \"%s\" pro příkaz \"%s\" již existuje\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Server %s%s%s byl přejmenován na %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr "%s server \"%s\" již existuje, nemohu jej vytvořít!\n"
@@ -2547,10 +2491,34 @@ msgstr "%s server \"%s\" již existuje, nemohu jej vytvořít!\n"
msgid "%s%s: unable to create server"
msgstr "%s nemohu vytvořit server\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgstr "Server %s%s%s vytvořen\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s server \"%s\" nenalezen pro příkaz \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s server \"%s\" pro příkaz \"%s\" již existuje\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "Server %s%s%s byl zkopírován do %s%s\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Server %s%s%s byl přejmenován na %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "Server %s%s%s vytvořen\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "Server %s%s%s vytvořen\n"
#, fuzzy, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3108,7 +3076,8 @@ msgstr "vypíše, přídá nebo odebere servery"
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[list [jméno_serveru]] | [listfull [jméno_serveru]] | [add jméno_serveru "
"jméno_hosta [-port port] [-temp] [-auto | -noauto] [-ipv6] [-ssl] [-pwd "
@@ -3132,6 +3101,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3364,14 +3334,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%s špatné parametry pro příkaz \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nedostatek paměti pro infobar zprávu\n"
#, fuzzy, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr "%s volba nastavení \"%s\" nenalezena\n"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3449,6 +3411,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "automaticky znovu přijít na kanál po vykopnutí"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nedostatek paměti pro infobar zprávu\n"
#, fuzzy, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr "%s nedostatek paměti pro infobar zprávu\n"
@@ -3574,7 +3540,7 @@ msgid "IRC debug messages"
msgstr "vypsat debug zprávy"
#, fuzzy, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%sServer: %s%s %s[%s%s%s]\n"
msgid "connected"
@@ -3583,6 +3549,9 @@ msgstr "připojen"
msgid "not connected"
msgstr "nepřipojen"
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr "na"
@@ -4170,11 +4139,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -5136,6 +5105,78 @@ msgstr "%s DCC: nemohu nastavit 'neblokovaci' volbu na soket\n"
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s chybí argument pro volbu \"%s\"\n"
#~ msgid " . type: boolean\n"
#~ msgstr " . typ: boolean\n"
#, fuzzy
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . hodnoty: 'on' or 'off'\n"
#, fuzzy
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . výchozí hodnota: '%s'\n"
#~ msgid " . type: string\n"
#~ msgstr " . typ: řetězec\n"
#~ msgid " . values: "
#~ msgstr " . hodnoty: "
#~ msgid " . type: integer\n"
#~ msgstr " . typ: celočíselný\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . hodnoty: mezi %d a %d\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . výchozí hodnota: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . hodnoty: typ řetězec (jakýkoliv řetězec)\n"
#~ msgid " . type: char\n"
#~ msgstr " . typ: znak\n"
#~ msgid " . values: any char\n"
#~ msgstr " . hodnoty: jakýkolív znak\n"
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . hodnoty: jakýkoliv řetězec (limit: %d znaků)\n"
#~ msgid " . type: color\n"
#~ msgstr " . typ: barva\n"
#, fuzzy
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . hodnoty: mezi %d a %d\n"
#~ msgid " . description: %s\n"
#~ msgstr " . popis: %s\n"
#, fuzzy
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%s %s, řádek %d: nevalidní syntax, chybí \"=\"\n"
#, fuzzy
#~ msgid "value not defined"
#~ msgstr "Žádné pole nejsou definovány"
#, fuzzy
#~ msgid "hidden"
#~ msgstr "(skrytý)"
#, fuzzy
#~ msgid ""
#~ "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
#~ msgstr "%s volba nastavení \"%s\" nenalezena\n"
#~ msgid ""
#~ "option: name of an option\n"
#~ " value: value for option"
#~ msgstr ""
#~ "možnost: jméno volby\n"
#~ "hodnota: hodnota volby"
#~ msgid "display nicklist (on buffers with nicklist enabled)"
#~ msgstr ""
#~ "zobrazit okno se seznamem přezdívek (pro buffery s povoleným seznamem "
+125 -88
View File
@@ -9,7 +9,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2007-09-06 12:44+0200\n"
"Last-Translator: Thomas Schuetz <i18n@internet-villa.de>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -345,6 +345,10 @@ msgstr " . Werte: "
msgid "default value"
msgstr " . Standardwert: %d\n"
#, fuzzy
msgid "(undefined)"
msgstr " . Standardwert: %d\n"
msgid "current value"
msgstr ""
@@ -1100,12 +1104,22 @@ msgstr ""
msgid "set config options"
msgstr "Konfigurationsparameter setzen"
msgid "[option [ = value]]"
#, fuzzy
msgid "[option [value]]"
msgstr "[Option [ = Wert]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
#, fuzzy
@@ -1695,7 +1709,7 @@ msgid "(default options)"
msgstr ""
#, fuzzy, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%s Konfigurationsdatei \"%s\" nicht gefunden.\n"
#, fuzzy, c-format
@@ -1710,10 +1724,6 @@ msgstr "%s %s, Zeile %d: Syntaxfehler, \"]\" erwartet\n"
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%s %s, Zeile %d: unbekannte Sektion \"%s\"\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%s %s, Zeile %d: Syntaxfehler, \"=\" erwartet\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr "%s %s, Zeile %d: unbekannte Sektion \"%s\"\n"
@@ -1730,60 +1740,6 @@ msgstr "%s %s, Zeile %d: ungültige Option \"%s\"\n"
msgid "Reloading configuration file %s"
msgstr "Konfiguration wird gespeichert\n"
msgid " . type: boolean\n"
msgstr " . Typ: Boolean\n"
#, fuzzy
msgid " . values: \"on\" or \"off\"\n"
msgstr " . Werte ('on' oder 'off')\n"
#, fuzzy, c-format
msgid " . default value: \"%s\"\n"
msgstr " . Standardwert: '%s'\n"
msgid " . type: string\n"
msgstr " . Typ: Zeichenfolge\n"
msgid " . values: "
msgstr " . Werte: "
msgid " . type: integer\n"
msgstr " . Typ: Ganzzahl\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . Werte: zwischen %d und %d\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . Standardwert: %d\n"
msgid " . values: any string\n"
msgstr " . Werte: eine beliebige Zeichenfolge\n"
#, fuzzy
msgid " . type: char\n"
msgstr " . Typ: Farbe\n"
#, fuzzy
msgid " . values: any char\n"
msgstr " . Werte: eine beliebige Zeichenfolge\n"
#, fuzzy, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . Werte: eine beliebige Zeichenfolge\n"
msgid " . type: color\n"
msgstr " . Typ: Farbe\n"
#, fuzzy
msgid " . values: color (depends on GUI used)\n"
msgstr " . Werte: zwischen %d und %d\n"
#, c-format
msgid " . description: %s\n"
msgstr " . Beschreibung: %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2427,7 +2383,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s fehlende Argumente für die \"--dir\"-Option\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "Server %s%s%s angelegt\n"
#, fuzzy, c-format
@@ -2537,18 +2493,6 @@ msgstr "Server '%s' nicht gefunden.\n"
msgid "No server found with \"%s\""
msgstr "Server '%s' nicht gefunden.\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s Server \"%s\" nicht gefunden für den \"%s\"-Befehl\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s Server \"%s\" nicht gefunden für den \"%s\"-Befehl\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Server %s%s%s wurde gelöscht\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr ""
@@ -2559,10 +2503,34 @@ msgstr ""
msgid "%s%s: unable to create server"
msgstr "%s kann den Server nicht anlegen\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgstr "Server %s%s%s angelegt\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s Server \"%s\" nicht gefunden für den \"%s\"-Befehl\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s Server \"%s\" nicht gefunden für den \"%s\"-Befehl\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "Server %s%s%s wurde gelöscht\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Server %s%s%s wurde gelöscht\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "Server %s%s%s angelegt\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "Server %s%s%s angelegt\n"
#, fuzzy, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3111,7 +3079,8 @@ msgstr "Auflisten, Hinzufügen oder Entfernen von Servern"
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[Servername] | [Servername Hostname Port [-auto | -noauto] [-ipv6] [-ssl] [-"
"pwd Passwort] [-nicks Nick1 Nick2 Nick3] [-username Benutzername] [-realname "
@@ -3131,6 +3100,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3345,14 +3315,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%s fehlerhafte Argumente für der \"%s\"-Befehl\n"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nicht genügend Speicher für Infobar-Nachricht\n"
#, fuzzy, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr "%s Konfigurationsoption \"%s\" nicht gefunden\n"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3431,6 +3393,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "Channels nach Kick automatisch wieder betreten, falls möglich"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nicht genügend Speicher für Infobar-Nachricht\n"
#, fuzzy, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr "%s nicht genügend Speicher für Infobar-Nachricht\n"
@@ -3557,7 +3523,7 @@ msgid "IRC debug messages"
msgstr "Debugging-Nachricht ausgeben"
#, fuzzy, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%sServer: %s%s %s[%s%s%s]\n"
msgid "connected"
@@ -3566,6 +3532,9 @@ msgstr "verbunden"
msgid "not connected"
msgstr "nicht verbunden"
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr "an"
@@ -4146,11 +4115,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -5099,6 +5068,74 @@ msgstr "%s DCC: kann die 'nonblock'-Option für den Socket nicht festlegen\n"
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s fehlende Argumente für die \"--dir\"-Option\n"
#~ msgid " . type: boolean\n"
#~ msgstr " . Typ: Boolean\n"
#, fuzzy
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . Werte ('on' oder 'off')\n"
#, fuzzy
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . Standardwert: '%s'\n"
#~ msgid " . type: string\n"
#~ msgstr " . Typ: Zeichenfolge\n"
#~ msgid " . values: "
#~ msgstr " . Werte: "
#~ msgid " . type: integer\n"
#~ msgstr " . Typ: Ganzzahl\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . Werte: zwischen %d und %d\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . Standardwert: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . Werte: eine beliebige Zeichenfolge\n"
#, fuzzy
#~ msgid " . type: char\n"
#~ msgstr " . Typ: Farbe\n"
#, fuzzy
#~ msgid " . values: any char\n"
#~ msgstr " . Werte: eine beliebige Zeichenfolge\n"
#, fuzzy
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . Werte: eine beliebige Zeichenfolge\n"
#~ msgid " . type: color\n"
#~ msgstr " . Typ: Farbe\n"
#, fuzzy
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . Werte: zwischen %d und %d\n"
#~ msgid " . description: %s\n"
#~ msgstr " . Beschreibung: %s\n"
#, fuzzy
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%s %s, Zeile %d: Syntaxfehler, \"=\" erwartet\n"
#, fuzzy
#~ msgid "value not defined"
#~ msgstr "Keine Aliases definiert.\n"
#, fuzzy
#~ msgid "hidden"
#~ msgstr "(versteckt)"
#, fuzzy
#~ msgid ""
#~ "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
#~ msgstr "%s Konfigurationsoption \"%s\" nicht gefunden\n"
#, fuzzy
#~ msgid "display nicklist (on buffers with nicklist enabled)"
#~ msgstr "Nicklisten-Fenster in Channelfenstern anzeigen"
+128 -91
View File
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2007-09-19 12:09+0200\n"
"Last-Translator: Roberto González Cardenete <robert.glez@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -341,6 +341,10 @@ msgstr " . valores: "
msgid "default value"
msgstr " . valor por defecto: %d\n"
#, fuzzy
msgid "(undefined)"
msgstr " . valor por defecto: %d\n"
msgid "current value"
msgstr ""
@@ -1081,12 +1085,22 @@ msgstr ""
msgid "set config options"
msgstr "poner opciones de configuración"
msgid "[option [ = value]]"
#, fuzzy
msgid "[option [value]]"
msgstr "[opción [ = valor]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
#, fuzzy
@@ -1343,8 +1357,8 @@ msgstr "la cadena mostrada tras la finalización de los nombres de usuario"
#, fuzzy
msgid "use a marker (line or char) on buffers to show first unread line"
msgstr ""
"usar un marcador en los servidores/canales para mostrar la primera línea "
"sin leer"
"usar un marcador en los servidores/canales para mostrar la primera línea sin "
"leer"
#, fuzzy
msgid "save configuration file on exit"
@@ -1680,7 +1694,7 @@ msgid "(default options)"
msgstr ""
#, fuzzy, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%s fichero de configuración \"%s\" no encontrado.\n"
#, fuzzy, c-format
@@ -1695,10 +1709,6 @@ msgstr "%s %s, línea %d: sintaxis inválida, falta \"]\"\n"
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%s %s, línea %d: identificador de sección desconocido (\"%s\")\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%s %s, línea %d: sintaxis inválida, falta \"=\"\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr "%s %s, línea %d: identificador de sección desconocido (\"%s\")\n"
@@ -1715,60 +1725,6 @@ msgstr "%s %s, línea %d: opción \"%s\" inválida\n"
msgid "Reloading configuration file %s"
msgstr "Guardar configuración a disco\n"
msgid " . type: boolean\n"
msgstr " . tipo: booleano\n"
#, fuzzy
msgid " . values: \"on\" or \"off\"\n"
msgstr " . valores: 'on' u 'off'\n"
#, fuzzy, c-format
msgid " . default value: \"%s\"\n"
msgstr " . valor por defecto: '%s'\n"
msgid " . type: string\n"
msgstr " . tipo: cadena\n"
msgid " . values: "
msgstr " . valores: "
msgid " . type: integer\n"
msgstr " . tipo: entero\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . valores: entre %d y %d\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . valor por defecto: %d\n"
msgid " . values: any string\n"
msgstr " . valores: cualquier cadena\n"
#, fuzzy
msgid " . type: char\n"
msgstr " . tipo: color\n"
#, fuzzy
msgid " . values: any char\n"
msgstr " . valores: cualquier cadena\n"
#, fuzzy, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . valores: cualquier cadena\n"
msgid " . type: color\n"
msgstr " . tipo: color\n"
#, fuzzy
msgid " . values: color (depends on GUI used)\n"
msgstr " . valores: entre %d y %d\n"
#, c-format
msgid " . description: %s\n"
msgstr " . descripción: %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2401,7 +2357,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s falta un argumento para la opción --dir\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "Servidor %s%s%s creado\n"
#, fuzzy, c-format
@@ -2511,18 +2467,6 @@ msgstr "Servidor '%s' no encontrado.\n"
msgid "No server found with \"%s\""
msgstr "Servidor '%s' no encontrado.\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s servidor \"%s\" no encontrado para el comando \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s servidor \"%s\" no encontrado para el comando \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "El servidor %s%s%s ha sido borrado\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr "%s el servidor \"%s\" ya existe, ¡no se puede crear!\n"
@@ -2531,10 +2475,34 @@ msgstr "%s el servidor \"%s\" ya existe, ¡no se puede crear!\n"
msgid "%s%s: unable to create server"
msgstr "%s no es posible crear el servidor\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgstr "Servidor %s%s%s creado\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s servidor \"%s\" no encontrado para el comando \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s servidor \"%s\" no encontrado para el comando \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "El servidor %s%s%s ha sido borrado\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "El servidor %s%s%s ha sido borrado\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "Servidor %s%s%s creado\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "Servidor %s%s%s creado\n"
#, fuzzy, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3096,7 +3064,8 @@ msgstr "lista, añde o elimina servidores"
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[nombre_de_servidor] | [nombre_de_servidor nombre/IP puerto [-auto | -"
"noauto] [-ipv6] [-ssl] [-pwd contraseña] [-nicks alias1 alias2 alias3] [-"
@@ -3117,6 +3086,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3336,15 +3306,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%s argumentos incorrectos para el comando \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr ""
"No hay suficiente memoria para el mensaje de la barra de información\n"
#, fuzzy, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr "%s opción de configuración \"%s\" no encontrada\n"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3421,6 +3382,11 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "unirse de nuevo automáticamente a los canales cuando sea expulsado"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr ""
"No hay suficiente memoria para el mensaje de la barra de información\n"
#, fuzzy, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr ""
@@ -3548,7 +3514,7 @@ msgid "IRC debug messages"
msgstr "imprime mensajes de depuración"
#, fuzzy, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%sServidor:%s%s %s[%s%s%s]\n"
msgid "connected"
@@ -3557,6 +3523,9 @@ msgstr "conectado"
msgid "not connected"
msgstr "no conectado"
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr "activo"
@@ -4142,11 +4111,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -5101,6 +5070,74 @@ msgstr "%s no es posible crear el servidor\n"
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s falta un argumento para la opción --dir\n"
#~ msgid " . type: boolean\n"
#~ msgstr " . tipo: booleano\n"
#, fuzzy
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . valores: 'on' u 'off'\n"
#, fuzzy
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . valor por defecto: '%s'\n"
#~ msgid " . type: string\n"
#~ msgstr " . tipo: cadena\n"
#~ msgid " . values: "
#~ msgstr " . valores: "
#~ msgid " . type: integer\n"
#~ msgstr " . tipo: entero\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . valores: entre %d y %d\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . valor por defecto: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . valores: cualquier cadena\n"
#, fuzzy
#~ msgid " . type: char\n"
#~ msgstr " . tipo: color\n"
#, fuzzy
#~ msgid " . values: any char\n"
#~ msgstr " . valores: cualquier cadena\n"
#, fuzzy
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . valores: cualquier cadena\n"
#~ msgid " . type: color\n"
#~ msgstr " . tipo: color\n"
#, fuzzy
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . valores: entre %d y %d\n"
#~ msgid " . description: %s\n"
#~ msgstr " . descripción: %s\n"
#, fuzzy
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%s %s, línea %d: sintaxis inválida, falta \"=\"\n"
#, fuzzy
#~ msgid "value not defined"
#~ msgstr "Ningún alias definido.\n"
#, fuzzy
#~ msgid "hidden"
#~ msgstr "(oculto)"
#, fuzzy
#~ msgid ""
#~ "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
#~ msgstr "%s opción de configuración \"%s\" no encontrada\n"
#, fuzzy
#~ msgid "display nicklist (on buffers with nicklist enabled)"
#~ msgstr "mostrar ventana de usuarios (para las ventanas de canal)"
+126 -97
View File
@@ -6,8 +6,8 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"PO-Revision-Date: 2008-12-19 18:37+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2009-01-02 18:38+0100\n"
"Last-Translator: FlashCode <flashcode@flashtux.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
"MIME-Version: 1.0\n"
@@ -325,6 +325,9 @@ msgstr "valeurs"
msgid "default value"
msgstr "valeur par défaut"
msgid "(undefined)"
msgstr "(non défini)"
msgid "current value"
msgstr "valeur courante"
@@ -1174,15 +1177,34 @@ msgstr ""
msgid "set config options"
msgstr "modifier des options de configuration"
msgid "[option [ = value]]"
msgstr "[option [ = valeur]]"
msgid "[option [value]]"
msgstr "[option [valeur]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
"option: nom d'une option\n"
"valeur: valeur pour l'option"
"valeur: nouvelle valeur pour l'option\n"
"\n"
"La nouvelle valeur peut être, selon le type de l'option :\n"
" booléen: on, off ou toggle\n"
" entier : nombre, ++nombre ou --nombre\n"
" chaîne : toute chaîne (\"\" pour une chaîne vide)\n"
" couleur: nom de couleur, ++nombre ou --nombre\n"
"\n"
"Pour tous les types, vous pouvez utiliser null pour supprimer la valeur de "
"l'option (valeur non définie). Cela ne fonctionne qu'avec certaines options "
"spéciales des extensions."
msgid "unset/reset config options"
msgstr "supprimer/réinitialiser des options de configuration"
@@ -1767,8 +1789,8 @@ msgid "(default options)"
msgstr "(options par défaut)"
#, c-format
msgid "%sWarning: config file \"%s\" not found"
msgstr "%sAttention: fichier de configuration \"%s\" non trouvé."
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%sAttention: fichier de configuration \"%s\" non trouvé"
#, c-format
msgid "Reading configuration file %s"
@@ -1782,10 +1804,6 @@ msgstr "%sAttention: %s, ligne %d: syntaxe invalide, il manque \"]\""
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%sAttention: %s, ligne %d: section inconnue (\"%s\")"
#, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%sAttention: %s, ligne %d: syntaxe invalide, il manque \"=\""
#, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr ""
@@ -1803,56 +1821,6 @@ msgstr "%sAttention: %s, ligne %d: valeur invalide pour l'option \"%s\""
msgid "Reloading configuration file %s"
msgstr "Rechargement du fichier de configuration %s"
msgid " . type: boolean\n"
msgstr " . type: booléen\n"
msgid " . values: \"on\" or \"off\"\n"
msgstr " . valeurs: \"on\" ou \"off\"\n"
#, c-format
msgid " . default value: \"%s\"\n"
msgstr " . valeur par défaut: \"%s\"\n"
msgid " . type: string\n"
msgstr " . type: chaîne\n"
msgid " . values: "
msgstr " . valeurs: "
msgid " . type: integer\n"
msgstr " . type: entier\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . valeurs: entre %d et %d\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . valeur par défaut: %d\n"
msgid " . values: any string\n"
msgstr " . valeurs: toute chaîne\n"
msgid " . type: char\n"
msgstr " . type: caractère\n"
msgid " . values: any char\n"
msgstr " . valeurs: tout caractère\n"
#, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . valeurs: toute chaîne (limite: %d caractères)\n"
msgid " . type: color\n"
msgstr " . type: couleur\n"
msgid " . values: color (depends on GUI used)\n"
msgstr " . valeurs: couleur (dépend de l'interface utilisée)\n"
#, c-format
msgid " . description: %s\n"
msgstr " . description: %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2508,8 +2476,8 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s%s: paramètre manquant pour l'option \"%s\""
#, c-format
msgid "%s: server %s%s%s created"
msgstr "%s: serveur %s%s%s créé"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "%s: serveur %s%s%s créé (serveur temporaire, NON SAUVE !)"
#, c-format
msgid "%s%s: unable to create server \"%s\""
@@ -2617,18 +2585,6 @@ msgstr "Serveurs avec \"%s\":"
msgid "No server found with \"%s\""
msgstr "Pas de serveur trouvé avec \"%s\""
#, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s%s: le serveur \"%s\" n'existe pas pour la commande \"%s\""
#, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s%s: le serveur \"%s\" existe déjà pour la commande \"%s\""
#, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "%s: le serveur %s%s%s a été renommé en %s%s"
#, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr "%s%s: le serveur \"%s\" existe déjà, impossible de le créer !"
@@ -2637,10 +2593,34 @@ msgstr "%s%s: le serveur \"%s\" existe déjà, impossible de le créer !"
msgid "%s%s: unable to create server"
msgstr "%s%s: impossible de créer le serveur"
#, c-format
msgid "%s: server %s%s%s created"
msgstr "%s: serveur %s%s%s créé"
#, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s%s: le serveur \"%s\" n'existe pas pour la commande \"%s\""
#, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s%s: le serveur \"%s\" existe déjà pour la commande \"%s\""
#, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "%s: le serveur %s%s%s a été copié vers %s%s"
#, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "%s: le serveur %s%s%s a été renommé en %s%s"
#, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "%s%s: le serveur \"%s\" n'est pas temporaire"
#, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "%s: le serveur %s%s%s n'est plus temporaire"
#, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3212,12 +3192,13 @@ msgstr "liste, ajoute ou retire des serveurs"
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[list [nom_serveur]] | [listfull [nom_serveur]] | [add nom_serveur nom[/"
"port] [-temp] [-auto | -noauto] [-ipv6] [-ssl]] | [copy nom_serveur "
"nouveau_nom_serveur] | [rename nom_serveur nouveau_nom_serveur] | [del "
"nom_serveur] | [deloutq] | [switch]"
"nouveau_nom_serveur] | [rename nom_serveur nouveau_nom_serveur] | [keep "
"nom_serveur] | [del nom_serveur] | [deloutq] | [switch]"
msgid ""
" list: list servers (no parameter implies this list)\n"
@@ -3232,6 +3213,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3262,6 +3244,8 @@ msgstr ""
" ssl: utiliser le protocole SSL\n"
" copy: dupliquer un serveur\n"
" rename: renommer un serveur\n"
" keep: garder le serveur dans le fichier de configuration (pour les "
"serveurs temporaires seulement)\n"
" del: supprimer un serveur\n"
" deloutq: supprimer la file d'attente des messages sortants pour tous les "
"serveurs (tous les messages que WeeChat est actuellement en train "
@@ -3465,16 +3449,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%sirc: pas assez de paramètres pour la commande \"%s\""
#, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s%s: erreur de création du serveur \"%s\""
#, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr ""
"%s%s: erreur de création de l'option \"%s\" pour le serveur \"%s\" (server "
"non trouvé)"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3550,6 +3524,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "rejoindre automatiquement les canaux quand mis dehors"
#, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s%s: erreur de création du serveur \"%s\""
#, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr "%s%s: erreur de création de l'option serveur \"%s\""
@@ -3676,8 +3654,8 @@ msgid "IRC debug messages"
msgstr "Messages de debug IRC"
#, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgstr "%sServeur: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%sServeur: %s%s %s[%s%s%s]%s%s"
msgid "connected"
msgstr "connecté"
@@ -3685,6 +3663,9 @@ msgstr "connecté"
msgid "not connected"
msgstr "non connecté"
msgid " (temporary)"
msgstr " (temporaire)"
msgid "on"
msgstr "activé"
@@ -4277,11 +4258,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -4307,11 +4288,11 @@ msgstr ""
" désactiver l'enregistrement pour le tampon courant :\n"
" /logger disable\n"
" définir le niveau à 3 pour les tampons IRC :\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" désactiver l'enregistrement pour le tampon principal de WeeChat :\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" utiliser un répertoire par serveur IRC et un fichier par canal dedans :\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Niveaux de log utilisés par l'extension IRC :\n"
" 1: message d'utilisateur, notice, privé\n"
@@ -5250,3 +5231,51 @@ msgstr "%s%s: impossible de positionner l'option \"nonblock\" pour la socket"
#, c-format
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s%s: délai d'attente dépassé pour \"%s\" avec %s"
#~ msgid " . type: boolean\n"
#~ msgstr " . type: booléen\n"
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . valeurs: \"on\" ou \"off\"\n"
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . valeur par défaut: \"%s\"\n"
#~ msgid " . type: string\n"
#~ msgstr " . type: chaîne\n"
#~ msgid " . values: "
#~ msgstr " . valeurs: "
#~ msgid " . type: integer\n"
#~ msgstr " . type: entier\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . valeurs: entre %d et %d\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . valeur par défaut: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . valeurs: toute chaîne\n"
#~ msgid " . type: char\n"
#~ msgstr " . type: caractère\n"
#~ msgid " . values: any char\n"
#~ msgstr " . valeurs: tout caractère\n"
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . valeurs: toute chaîne (limite: %d caractères)\n"
#~ msgid " . type: color\n"
#~ msgstr " . type: couleur\n"
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . valeurs: couleur (dépend de l'interface utilisée)\n"
#~ msgid " . description: %s\n"
#~ msgstr " . description: %s\n"
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%sAttention: %s, ligne %d: syntaxe invalide, il manque \"=\""
+122 -86
View File
@@ -12,7 +12,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2007-10-10 18:07+0200\n"
"Last-Translator: Andras Voroskoi <voroskoi@frugalware.org>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -346,6 +346,10 @@ msgstr " . értékek: "
msgid "default value"
msgstr " . alapérték: %d\n"
#, fuzzy
msgid "(undefined)"
msgstr " . alapérték: %d\n"
msgid "current value"
msgstr ""
@@ -1115,12 +1119,22 @@ msgstr ""
msgid "set config options"
msgstr "konfigurációs paraméterek beállítása"
msgid "[option [ = value]]"
#, fuzzy
msgid "[option [value]]"
msgstr "[opció [ = érték]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
#, fuzzy
@@ -1708,7 +1722,7 @@ msgid "(default options)"
msgstr ""
#, fuzzy, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%s a \"%s\" beállítófájl nem található.\n"
#, fuzzy, c-format
@@ -1723,10 +1737,6 @@ msgstr "%s %s, %d. sor: érvénytelen szintaxis, hiányzó \"]\"\n"
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%s %s, %d. sor: ismeretlen csoportazonosító (\"%s\")\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%s %s, %d. sor: érvénytelen szintaxis, hiányzó \"=\"\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr "%s %s, %d. sor: ismeretlen csoportazonosító (\"%s\")\n"
@@ -1743,58 +1753,6 @@ msgstr "%s %s, %d. sor: érvénytelen opció: \"%s\"\n"
msgid "Reloading configuration file %s"
msgstr "Beállítások mentése a lemezre\n"
msgid " . type: boolean\n"
msgstr " . típus: logikai\n"
#, fuzzy
msgid " . values: \"on\" or \"off\"\n"
msgstr " . értékek: 'on' vagy 'off'\n"
#, fuzzy, c-format
msgid " . default value: \"%s\"\n"
msgstr " . alapérték: '%s'\n"
msgid " . type: string\n"
msgstr " . típus: szöveg\n"
msgid " . values: "
msgstr " . értékek: "
msgid " . type: integer\n"
msgstr " . típus: szám\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . értékek: %d és %d között\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . alapérték: %d\n"
msgid " . values: any string\n"
msgstr " . érték: bármilyen szöveg\n"
msgid " . type: char\n"
msgstr " . típus: karakter\n"
msgid " . values: any char\n"
msgstr " . érték: bármilyen karakter\n"
#, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . érték: bármilyen szöveg (korlát: %d karakter)\n"
msgid " . type: color\n"
msgstr " . típus: szín\n"
#, fuzzy
msgid " . values: color (depends on GUI used)\n"
msgstr " . értékek: %d és %d között\n"
#, c-format
msgid " . description: %s\n"
msgstr " . leírás : %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2432,7 +2390,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s hiányzó argumentum a(z) \"%s\" opciónak\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "A %s%s%s szerver létrehozva\n"
#, fuzzy, c-format
@@ -2540,18 +2498,6 @@ msgstr "A(z) '%s' szerverek listája:\n"
msgid "No server found with \"%s\""
msgstr "Nem található '%s' szerver.\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s a \"%s\" szerver nem található a \"%s\" parancshoz\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s a \"%s\" szerver már létezik a(z) \"%s\" parancshoz\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "A %s%s%s szerver mostantól: %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr "%s a \"%s\" szerver már létezik, nem hozhatja létre!\n"
@@ -2560,10 +2506,34 @@ msgstr "%s a \"%s\" szerver már létezik, nem hozhatja létre!\n"
msgid "%s%s: unable to create server"
msgstr "%s nem sikerült a szervert létrehozni\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgstr "A %s%s%s szerver létrehozva\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s a \"%s\" szerver nem található a \"%s\" parancshoz\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s a \"%s\" szerver már létezik a(z) \"%s\" parancshoz\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "A %s%s%s szerver másolva lett %s%s néven\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "A %s%s%s szerver mostantól: %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "A %s%s%s szerver létrehozva\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "A %s%s%s szerver létrehozva\n"
#, fuzzy, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3126,7 +3096,8 @@ msgstr "szerverek listázása, hozzáadása vagy eltávolítása"
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[list [szervernév]] | [listfull [szervernév]] | [add szervernév gépnév [-"
"port port] [-temp] [-auto | -noauto] [-ipv6] [-ssl] [-pwd jelszó] [-nicks "
@@ -3148,6 +3119,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3382,14 +3354,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%s rossz argumentum a \"%s\" parancsnak\n"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nincs elég memória az információs pult üzenethez\n"
#, fuzzy, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr "%s a \"%s\" opció nem található\n"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3466,6 +3430,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "automatikus visszalépés a szobába kirúgáskor"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s nincs elég memória az információs pult üzenethez\n"
#, fuzzy, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr "%s nincs elég memória az információs pult üzenethez\n"
@@ -3583,7 +3551,7 @@ msgid "IRC debug messages"
msgstr "hibakereső üzenetek megjelenítése"
#, fuzzy, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%s Szerver: %s%s %s[%s%s%s]\n"
msgid "connected"
@@ -3592,6 +3560,9 @@ msgstr "csatlakozva"
msgid "not connected"
msgstr "nincs csatlakozva"
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr "be"
@@ -4173,11 +4144,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -5121,6 +5092,71 @@ msgstr "%s DCC: nem sikerült 'nonblock' opciót beállítani a csatornán\n"
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s hiányzó argumentum a(z) \"%s\" opciónak\n"
#~ msgid " . type: boolean\n"
#~ msgstr " . típus: logikai\n"
#, fuzzy
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . értékek: 'on' vagy 'off'\n"
#, fuzzy
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . alapérték: '%s'\n"
#~ msgid " . type: string\n"
#~ msgstr " . típus: szöveg\n"
#~ msgid " . values: "
#~ msgstr " . értékek: "
#~ msgid " . type: integer\n"
#~ msgstr " . típus: szám\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . értékek: %d és %d között\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . alapérték: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . érték: bármilyen szöveg\n"
#~ msgid " . type: char\n"
#~ msgstr " . típus: karakter\n"
#~ msgid " . values: any char\n"
#~ msgstr " . érték: bármilyen karakter\n"
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . érték: bármilyen szöveg (korlát: %d karakter)\n"
#~ msgid " . type: color\n"
#~ msgstr " . típus: szín\n"
#, fuzzy
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . értékek: %d és %d között\n"
#~ msgid " . description: %s\n"
#~ msgstr " . leírás : %s\n"
#, fuzzy
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%s %s, %d. sor: érvénytelen szintaxis, hiányzó \"=\"\n"
#, fuzzy
#~ msgid "value not defined"
#~ msgstr "Nincs aliasz definiálva.\n"
#, fuzzy
#~ msgid "hidden"
#~ msgstr "(rejtett)"
#, fuzzy
#~ msgid ""
#~ "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
#~ msgstr "%s a \"%s\" opció nem található\n"
#, fuzzy
#~ msgid "display nicklist (on buffers with nicklist enabled)"
#~ msgstr "névlista ablak mutatása (szobaablakban)"
+122 -86
View File
@@ -6,7 +6,7 @@ msgid ""
msgstr ""
"Project-Id-Version: WeeChat 0.2.7-dev\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\n"
"PO-Revision-Date: 2007-09-06 12:44+0200\n"
"Last-Translator: Pavel Shevchuk <stlwrt@gmail.com>\n"
"Language-Team: weechat-dev <weechat-dev@nongnu.org>\n"
@@ -342,6 +342,10 @@ msgstr " . значения: "
msgid "default value"
msgstr " . значение по умолчанию: %d\n"
#, fuzzy
msgid "(undefined)"
msgstr " . значение по умолчанию: %d\n"
msgid "current value"
msgstr ""
@@ -1111,12 +1115,22 @@ msgstr ""
msgid "set config options"
msgstr "настроить параметры конфигурации"
msgid "[option [ = value]]"
#, fuzzy
msgid "[option [value]]"
msgstr "[параметр [ = значение]]"
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
#, fuzzy
@@ -1709,7 +1723,7 @@ msgid "(default options)"
msgstr ""
#, fuzzy, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr "%s конфигурационынй файл \"%s\" не найден.\n"
#, fuzzy, c-format
@@ -1724,10 +1738,6 @@ msgstr "%s %s, строка %d: некорректный синтаксис, н
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr "%s %s, строка %d: неизвестный идентификатор секции (\"%s\")\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr "%s %s, строка %d: некорректный синтаксис, утерян \"=\"\n"
#, fuzzy, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr "%s %s, строка %d: неизвестный идентификатор секции (\"%s\")\n"
@@ -1744,58 +1754,6 @@ msgstr "%s %s, строка %d: некорректный параметр \"%s\"
msgid "Reloading configuration file %s"
msgstr "Сохраняю конфигурацию\n"
msgid " . type: boolean\n"
msgstr " . тип: булевый\n"
#, fuzzy
msgid " . values: \"on\" or \"off\"\n"
msgstr " . значения: 'on' или 'off'\n"
#, fuzzy, c-format
msgid " . default value: \"%s\"\n"
msgstr " . значение по умолчанию: '%s'\n"
msgid " . type: string\n"
msgstr " . тип: строка\n"
msgid " . values: "
msgstr " . значения: "
msgid " . type: integer\n"
msgstr " . тип: целочисленный\n"
#, c-format
msgid " . values: between %d and %d\n"
msgstr " . значения: от %d до %d\n"
#, c-format
msgid " . default value: %d\n"
msgstr " . значение по умолчанию: %d\n"
msgid " . values: any string\n"
msgstr " . значения: любая строка\n"
msgid " . type: char\n"
msgstr " . тип: символ\n"
msgid " . values: any char\n"
msgstr " . значения: любой символ\n"
#, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr " . значения: любая строка (ограничение: %d символов)\n"
msgid " . type: color\n"
msgstr " . тип: цвет\n"
#, fuzzy
msgid " . values: color (depends on GUI used)\n"
msgstr " . значения: от %d до %d\n"
#, c-format
msgid " . description: %s\n"
msgstr " . описание: %s\n"
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2436,7 +2394,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr "%s нет аргумента для параметра \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr "Сервер %s%s%s создан\n"
#, fuzzy, c-format
@@ -2545,18 +2503,6 @@ msgstr "Серверы с '%s':\n"
msgid "No server found with \"%s\""
msgstr "Серверы с '%s' не найдены.\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s сервер \"%s\" не найден для команды \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s сервер \"%s\" уже существует для команды \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Сервер %s%s%s переименован в %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr "%s сервер \"%s\" уже существует, не могу создать его!\n"
@@ -2565,10 +2511,34 @@ msgstr "%s сервер \"%s\" уже существует, не могу соз
msgid "%s%s: unable to create server"
msgstr "%s не могу создать сервер\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s created"
msgstr "Сервер %s%s%s создан\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr "%s сервер \"%s\" не найден для команды \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr "%s сервер \"%s\" уже существует для команды \"%s\"\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr "Сервер %s%s%s скопирован в %s%s\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr "Сервер %s%s%s переименован в %s%s\n"
#, fuzzy, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr "Сервер %s%s%s создан\n"
#, fuzzy, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr "Сервер %s%s%s создан\n"
#, fuzzy, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -3126,7 +3096,8 @@ msgstr "перечислить, добавить или удалить серв
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
"[list [сервер]] | [listfull [сервер]] | [add сервер адрес [-port порт] [-"
"temp] [-auto | -noauto] [-ipv6] [-ssl] [-pwd пароль] [-nicks ник1 ник2 ник3] "
@@ -3148,6 +3119,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -3375,14 +3347,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr "%s некорректные аргументы команды \"%s\"\n"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s недостаточно памяти для сообщения в строке информации\n"
#, fuzzy, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr "%s параметр конфигурации \"%s\" не найден\n"
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -3459,6 +3423,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr "автоматически перезаходить на каналы после кика"
#, fuzzy, c-format
msgid "%s%s: error creating server \"%s\""
msgstr "%s недостаточно памяти для сообщения в строке информации\n"
#, fuzzy, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr "%s недостаточно памяти для сообщения в строке информации\n"
@@ -3576,7 +3544,7 @@ msgid "IRC debug messages"
msgstr "выводить отладочные сообщения"
#, fuzzy, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr "%sСервер: %s%s %s[%s%s%s]\n"
msgid "connected"
@@ -3585,6 +3553,9 @@ msgstr "подключен"
msgid "not connected"
msgstr "отключен"
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr "вкл."
@@ -4160,11 +4131,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
@@ -5102,6 +5073,71 @@ msgstr "%s DCC: не могу установить неблокирующий р
msgid "%s%s: timeout for \"%s\" with %s"
msgstr "%s нет аргумента для параметра \"%s\"\n"
#~ msgid " . type: boolean\n"
#~ msgstr " . тип: булевый\n"
#, fuzzy
#~ msgid " . values: \"on\" or \"off\"\n"
#~ msgstr " . значения: 'on' или 'off'\n"
#, fuzzy
#~ msgid " . default value: \"%s\"\n"
#~ msgstr " . значение по умолчанию: '%s'\n"
#~ msgid " . type: string\n"
#~ msgstr " . тип: строка\n"
#~ msgid " . values: "
#~ msgstr " . значения: "
#~ msgid " . type: integer\n"
#~ msgstr " . тип: целочисленный\n"
#~ msgid " . values: between %d and %d\n"
#~ msgstr " . значения: от %d до %d\n"
#~ msgid " . default value: %d\n"
#~ msgstr " . значение по умолчанию: %d\n"
#~ msgid " . values: any string\n"
#~ msgstr " . значения: любая строка\n"
#~ msgid " . type: char\n"
#~ msgstr " . тип: символ\n"
#~ msgid " . values: any char\n"
#~ msgstr " . значения: любой символ\n"
#~ msgid " . values: any string (limit: %d chars)\n"
#~ msgstr " . значения: любая строка (ограничение: %d символов)\n"
#~ msgid " . type: color\n"
#~ msgstr " . тип: цвет\n"
#, fuzzy
#~ msgid " . values: color (depends on GUI used)\n"
#~ msgstr " . значения: от %d до %d\n"
#~ msgid " . description: %s\n"
#~ msgstr " . описание: %s\n"
#, fuzzy
#~ msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
#~ msgstr "%s %s, строка %d: некорректный синтаксис, утерян \"=\"\n"
#, fuzzy
#~ msgid "value not defined"
#~ msgstr "Сокращения не заданы.\n"
#, fuzzy
#~ msgid "hidden"
#~ msgstr "(скрытый)"
#, fuzzy
#~ msgid ""
#~ "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
#~ msgstr "%s параметр конфигурации \"%s\" не найден\n"
#, fuzzy
#~ msgid "display nicklist (on buffers with nicklist enabled)"
#~ msgstr "показывать список ников (в окнах каналов)"
+55 -84
View File
@@ -7,7 +7,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: flashcode@flashtux.org\n"
"POT-Creation-Date: 2008-12-19 18:36+0100\n"
"POT-Creation-Date: 2009-01-02 22:40+0100\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"
@@ -304,6 +304,9 @@ msgstr ""
msgid "default value"
msgstr ""
msgid "(undefined)"
msgstr ""
msgid "current value"
msgstr ""
@@ -957,12 +960,21 @@ msgstr ""
msgid "set config options"
msgstr ""
msgid "[option [ = value]]"
msgid "[option [value]]"
msgstr ""
msgid ""
"option: name of an option\n"
" value: value for option"
" value: new value for option\n"
"\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number string : any string (\"\" for empty "
"string)\n"
" color : color name, ++number ou --number\n"
"\n"
"For all types, you can use null to remove option value (undefined value). "
"This works only for some special plugin variables."
msgstr ""
msgid "unset/reset config options"
@@ -1430,7 +1442,7 @@ msgid "(default options)"
msgstr ""
#, c-format
msgid "%sWarning: config file \"%s\" not found"
msgid "%sWarning: configuration file \"%s\" not found"
msgstr ""
#, c-format
@@ -1445,10 +1457,6 @@ msgstr ""
msgid "%sWarning: %s, line %d: unknown section identifier (\"%s\")"
msgstr ""
#, c-format
msgid "%sWarning: %s, line %d: invalid syntax, missing \"=\""
msgstr ""
#, c-format
msgid "%sWarning: %s, line %d: option \"%s\" unknown for section \"%s\""
msgstr ""
@@ -1465,56 +1473,6 @@ msgstr ""
msgid "Reloading configuration file %s"
msgstr ""
msgid " . type: boolean\n"
msgstr ""
msgid " . values: \"on\" or \"off\"\n"
msgstr ""
#, c-format
msgid " . default value: \"%s\"\n"
msgstr ""
msgid " . type: string\n"
msgstr ""
msgid " . values: "
msgstr ""
msgid " . type: integer\n"
msgstr ""
#, c-format
msgid " . values: between %d and %d\n"
msgstr ""
#, c-format
msgid " . default value: %d\n"
msgstr ""
msgid " . values: any string\n"
msgstr ""
msgid " . type: char\n"
msgstr ""
msgid " . values: any char\n"
msgstr ""
#, c-format
msgid " . values: any string (limit: %d chars)\n"
msgstr ""
msgid " . type: color\n"
msgstr ""
msgid " . values: color (depends on GUI used)\n"
msgstr ""
#, c-format
msgid " . description: %s\n"
msgstr ""
#, c-format
msgid "System clock skew detected (%+ld seconds), reinitializing all timers"
msgstr ""
@@ -2101,7 +2059,7 @@ msgid "%s%s: missing argument for \"%s\" option"
msgstr ""
#, c-format
msgid "%s: server %s%s%s created"
msgid "%s: server %s%s%s created (temporary server, NOT SAVED!)"
msgstr ""
#, c-format
@@ -2207,18 +2165,6 @@ msgstr ""
msgid "No server found with \"%s\""
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr ""
#, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" already exists, can't create it!"
msgstr ""
@@ -2227,10 +2173,34 @@ msgstr ""
msgid "%s%s: unable to create server"
msgstr ""
#, c-format
msgid "%s: server %s%s%s created"
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" not found for \"%s\" command"
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" already exists for \"%s\" command"
msgstr ""
#, c-format
msgid "%s: server %s%s%s has been copied to %s%s"
msgstr ""
#, c-format
msgid "%s: server %s%s%s has been renamed to %s%s"
msgstr ""
#, c-format
msgid "%s%s: server \"%s\" is not a temporary server"
msgstr ""
#, c-format
msgid "%s: server %s%s%s is not temporary any more"
msgstr ""
#, c-format
msgid ""
"%s%s: you can not delete server \"%s\" because you are connected to. Try \"/"
@@ -2689,7 +2659,8 @@ msgstr ""
msgid ""
"[list [servername]] | [listfull [servername]] | [add servername hostname[/"
"port] [-auto | -noauto] [-ipv6] [-ssl]] | [copy servername newservername] | "
"[rename servername newservername] | [del servername] | [deloutq] | [switch]"
"[rename servername newservername] | [keep servername] | [del servername] | "
"[deloutq] | [switch]"
msgstr ""
msgid ""
@@ -2705,6 +2676,7 @@ msgid ""
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all servers (all messages WeeChat "
"is currently sending)\n"
@@ -2878,14 +2850,6 @@ msgstr ""
msgid "%sirc: too few arguments for \"%s\" command"
msgstr ""
#, c-format
msgid "%s%s: error creating server \"%s\""
msgstr ""
#, c-format
msgid "%s%s: error creating option \"%s\" for server \"%s\" (server not found)"
msgstr ""
#, c-format
msgid ""
"%s%s: warning: server \"%s\" not found in configuration file, not deleted in "
@@ -2949,6 +2913,10 @@ msgstr ""
msgid "automatically rejoin channels when kicked"
msgstr ""
#, c-format
msgid "%s%s: error creating server \"%s\""
msgstr ""
#, c-format
msgid "%s%s: error creating server option \"%s\""
msgstr ""
@@ -3052,7 +3020,7 @@ msgid "IRC debug messages"
msgstr ""
#, c-format
msgid "%sServer: %s%s %s[%s%s%s]"
msgid "%sServer: %s%s %s[%s%s%s]%s%s"
msgstr ""
msgid "connected"
@@ -3061,6 +3029,9 @@ msgstr ""
msgid "not connected"
msgstr ""
msgid " (temporary)"
msgstr ""
msgid "on"
msgstr ""
@@ -3619,11 +3590,11 @@ msgid ""
" /logger disable\n"
"\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n"
"\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
+230 -123
View File
@@ -1352,15 +1352,33 @@ command_help (void *data, struct t_gui_buffer *buffer,
_("type"), _("boolean"));
gui_chat_printf (NULL, " %s: on, off",
_("values"));
gui_chat_printf (NULL, " %s: %s",
_("default value"),
(CONFIG_BOOLEAN_DEFAULT(ptr_option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
gui_chat_printf (NULL, " %s: %s%s",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(CONFIG_BOOLEAN(ptr_option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
if (ptr_option->default_value)
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
(CONFIG_BOOLEAN_DEFAULT(ptr_option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
_("(undefined)"));
}
if (ptr_option->value)
{
gui_chat_printf (NULL, " %s: %s%s",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(CONFIG_BOOLEAN(ptr_option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("current value"),
_("(undefined)"));
}
break;
case CONFIG_OPTION_TYPE_INTEGER:
if (ptr_option->string_values)
@@ -1390,15 +1408,34 @@ command_help (void *data, struct t_gui_buffer *buffer,
_("type"), _("string"));
gui_chat_printf (NULL, " %s: %s",
_("values"), string);
gui_chat_printf (NULL, " %s: \"%s\"",
_("default value"),
ptr_option->string_values[CONFIG_INTEGER_DEFAULT(ptr_option)]);
gui_chat_printf (NULL,
" %s: \"%s%s%s\"",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
ptr_option->string_values[CONFIG_INTEGER(ptr_option)],
GUI_COLOR(GUI_COLOR_CHAT));
if (ptr_option->default_value)
{
gui_chat_printf (NULL, " %s: \"%s\"",
_("default value"),
ptr_option->string_values[CONFIG_INTEGER_DEFAULT(ptr_option)]);
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
_("(undefined)"));
}
if (ptr_option->value)
{
gui_chat_printf (NULL,
" %s: \"%s%s%s\"",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
ptr_option->string_values[CONFIG_INTEGER(ptr_option)],
GUI_COLOR(GUI_COLOR_CHAT));
}
else
{
gui_chat_printf (NULL,
" %s: %s",
_("current value"),
_("(undefined)"));
}
free (string);
}
}
@@ -1409,13 +1446,31 @@ command_help (void *data, struct t_gui_buffer *buffer,
gui_chat_printf (NULL, " %s: %d .. %d",
_("values"),
ptr_option->min, ptr_option->max);
gui_chat_printf (NULL, " %s: %d",
_("default value"),
CONFIG_INTEGER_DEFAULT(ptr_option));
gui_chat_printf (NULL, " %s: %s%d",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_INTEGER(ptr_option));
if (ptr_option->default_value)
{
gui_chat_printf (NULL, " %s: %d",
_("default value"),
CONFIG_INTEGER_DEFAULT(ptr_option));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
_("(undefined)"));
}
if (ptr_option->value)
{
gui_chat_printf (NULL, " %s: %s%d",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_INTEGER(ptr_option));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("current value"),
_("(undefined)"));
}
}
break;
case CONFIG_OPTION_TYPE_STRING:
@@ -1442,27 +1497,63 @@ command_help (void *data, struct t_gui_buffer *buffer,
ptr_option->max);
break;
}
gui_chat_printf (NULL, " %s: \"%s\"",
_("default value"),
CONFIG_STRING_DEFAULT(ptr_option));
gui_chat_printf (NULL, " %s: \"%s%s%s\"",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_STRING(ptr_option),
GUI_COLOR(GUI_COLOR_CHAT));
if (ptr_option->default_value)
{
gui_chat_printf (NULL, " %s: \"%s\"",
_("default value"),
CONFIG_STRING_DEFAULT(ptr_option));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
_("(undefined)"));
}
if (ptr_option->value)
{
gui_chat_printf (NULL, " %s: \"%s%s%s\"",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_STRING(ptr_option),
GUI_COLOR(GUI_COLOR_CHAT));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("current value"),
_("(undefined)"));
}
break;
case CONFIG_OPTION_TYPE_COLOR:
gui_chat_printf (NULL, " %s: %s",
_("type"), _("color"));
gui_chat_printf (NULL, " %s: %s",
_("values"), _("a color name"));
gui_chat_printf (NULL, " %s: %s",
_("default value"),
gui_color_get_name (CONFIG_COLOR_DEFAULT(ptr_option)));
gui_chat_printf (NULL, " %s: %s%s",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
gui_color_get_name (CONFIG_COLOR(ptr_option)));
if (ptr_option->default_value)
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
gui_color_get_name (CONFIG_COLOR_DEFAULT(ptr_option)));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("default value"),
_("(undefined)"));
}
if (ptr_option->value)
{
gui_chat_printf (NULL, " %s: %s%s",
_("current value"),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
gui_color_get_name (CONFIG_COLOR(ptr_option)));
}
else
{
gui_chat_printf (NULL, " %s: %s",
_("current value"),
_("(undefined)"));
}
break;
case CONFIG_NUM_OPTION_TYPES:
break;
@@ -2634,23 +2725,12 @@ command_set_display_option (struct t_config_option *option,
const char *message)
{
const char *color_name;
switch (option->type)
if (option->value)
{
case CONFIG_OPTION_TYPE_BOOLEAN:
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%s",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(CONFIG_BOOLEAN(option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
break;
case CONFIG_OPTION_TYPE_INTEGER:
if (option->string_values)
{
switch (option->type)
{
case CONFIG_OPTION_TYPE_BOOLEAN:
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%s",
(message) ? message : " ",
option->config_file->name,
@@ -2658,45 +2738,67 @@ command_set_display_option (struct t_config_option *option,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
option->string_values[CONFIG_INTEGER(option)]);
}
else
{
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%d",
(CONFIG_BOOLEAN(option) == CONFIG_BOOLEAN_TRUE) ?
"on" : "off");
break;
case CONFIG_OPTION_TYPE_INTEGER:
if (option->string_values)
{
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%s",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
option->string_values[CONFIG_INTEGER(option)]);
}
else
{
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%d",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_INTEGER(option));
}
break;
case CONFIG_OPTION_TYPE_STRING:
gui_chat_printf (NULL, "%s%s.%s.%s%s = \"%s%s%s\"",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
CONFIG_INTEGER(option));
}
break;
case CONFIG_OPTION_TYPE_STRING:
gui_chat_printf (NULL, "%s%s.%s.%s%s = \"%s%s%s\"",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(option->value) ? CONFIG_STRING(option) : "",
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS));
break;
case CONFIG_OPTION_TYPE_COLOR:
color_name = gui_color_get_name (CONFIG_COLOR(option));
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%s",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(color_name) ? color_name : _("(unknown)"));
break;
case CONFIG_NUM_OPTION_TYPES:
/* make C compiler happy */
break;
CONFIG_STRING(option),
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS));
break;
case CONFIG_OPTION_TYPE_COLOR:
color_name = gui_color_get_name (CONFIG_COLOR(option));
gui_chat_printf (NULL, "%s%s.%s.%s%s = %s%s",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name,
GUI_COLOR(GUI_COLOR_CHAT_DELIMITERS),
GUI_COLOR(GUI_COLOR_CHAT_HOST),
(color_name) ? color_name : _("(unknown)"));
break;
case CONFIG_NUM_OPTION_TYPES:
/* make C compiler happy */
break;
}
}
else
{
gui_chat_printf (NULL, "%s%s.%s.%s",
(message) ? message : " ",
option->config_file->name,
option->section->name,
option->name);
}
}
@@ -2823,38 +2925,35 @@ command_set (void *data, struct t_gui_buffer *buffer,
}
/* set option value */
if ((argc >= 4) && (string_strcasecmp (argv[2], "=") == 0))
value =(string_strcasecmp (argv_eol[2], WEECHAT_CONFIG_OPTION_NULL) == 0) ?
NULL : string_remove_quotes (argv_eol[2], "'\"");
rc = config_file_option_set_with_string (argv[1], value);
if (value)
free (value);
switch (rc)
{
value = string_remove_quotes (argv_eol[3], "'\"");
rc = config_file_option_set_with_string (argv[1],
(value) ? value : argv_eol[3]);
if (value)
free (value);
switch (rc)
{
case WEECHAT_CONFIG_OPTION_SET_ERROR:
gui_chat_printf (NULL,
_("%sError: failed to set option \"%s\""),
gui_chat_prefix[GUI_CHAT_PREFIX_ERROR],
argv[1]);
return WEECHAT_RC_ERROR;
case WEECHAT_CONFIG_OPTION_SET_OPTION_NOT_FOUND:
gui_chat_printf (NULL,
_("%sError: configuration option \"%s\" not "
"found"),
gui_chat_prefix[GUI_CHAT_PREFIX_ERROR],
argv[1]);
return WEECHAT_RC_ERROR;
default:
config_file_search_with_string (argv[1], NULL, NULL,
&ptr_option, NULL);
if (ptr_option)
command_set_display_option (ptr_option,
_("Option changed: "));
else
gui_chat_printf (NULL, _("Option changed"));
break;
}
case WEECHAT_CONFIG_OPTION_SET_ERROR:
gui_chat_printf (NULL,
_("%sError: failed to set option \"%s\""),
gui_chat_prefix[GUI_CHAT_PREFIX_ERROR],
argv[1]);
return WEECHAT_RC_ERROR;
case WEECHAT_CONFIG_OPTION_SET_OPTION_NOT_FOUND:
gui_chat_printf (NULL,
_("%sError: configuration option \"%s\" not "
"found"),
gui_chat_prefix[GUI_CHAT_PREFIX_ERROR],
argv[1]);
return WEECHAT_RC_ERROR;
default:
config_file_search_with_string (argv[1], NULL, NULL,
&ptr_option, NULL);
if (ptr_option)
command_set_display_option (ptr_option,
_("Option changed: "));
else
gui_chat_printf (NULL, _("Option changed"));
break;
}
return WEECHAT_RC_OK;
@@ -3659,10 +3758,18 @@ command_init ()
&command_save, NULL);
hook_command (NULL, "set",
N_("set config options"),
N_("[option [ = value]]"),
N_("[option [value]]"),
N_("option: name of an option\n"
" value: value for option"),
"%o = %v",
" value: new value for option\n\n"
"New value can be, according to variable type:\n"
" boolean: on, off ou toggle\n"
" integer: number, ++number ou --number"
" string : any string (\"\" for empty string)\n"
" color : color name, ++number ou --number\n\n"
"For all types, you can use null to remove "
"option value (undefined value). This works only "
"for some special plugin variables."),
"%o %v",
&command_set, NULL);
hook_command (NULL, "unset",
N_("unset/reset config options"),
+791 -511
View File
File diff suppressed because it is too large Load Diff
+12 -2
View File
@@ -119,6 +119,7 @@ struct t_config_option
int min, max; /* min and max for value */
void *default_value; /* default value */
void *value; /* value */
int null_value_allowed; /* null value allowed ? */
int (*callback_check_value) /* called to check value before */
(void *data, /* assiging new value */
struct t_config_option *option,
@@ -189,6 +190,7 @@ extern struct t_config_option *config_file_new_option (struct t_config_file *con
int min, int max,
const char *default_value,
const char *value,
int null_value_allowed,
int (*callback_check_value)(void *data,
struct t_config_option *option,
const char *value),
@@ -219,18 +221,27 @@ extern int config_file_option_reset (struct t_config_option *option,
int run_callback);
extern int config_file_option_set (struct t_config_option *option,
const char *value, int run_callback);
extern int config_file_option_set_null (struct t_config_option *option,
int run_callback);
extern int config_file_option_unset (struct t_config_option *option);
extern void config_file_option_rename (struct t_config_option *option,
const char *new_name);
extern void *config_file_option_get_pointer (struct t_config_option *option,
const char *property);
extern int config_file_option_is_null (struct t_config_option *option);
extern int config_file_option_default_is_null (struct t_config_option *option);
extern int config_file_option_set_with_string (const char *option_name, const char *value);
extern int config_file_option_unset_with_string (const char *option_name);
extern int config_file_option_boolean (struct t_config_option *option);
extern int config_file_option_boolean_default (struct t_config_option *option);
extern int config_file_option_integer (struct t_config_option *option);
extern int config_file_option_integer_default (struct t_config_option *option);
extern const char *config_file_option_string (struct t_config_option *option);
extern const char *config_file_option_string_default (struct t_config_option *option);
extern const char *config_file_option_color (struct t_config_option *option);
extern const char *config_file_option_color_default (struct t_config_option *option);
extern void config_file_write_option (struct t_config_file *config_file,
struct t_config_option *option);
extern void config_file_write_line (struct t_config_file *config_file,
const char *option_name, const char *value, ...);
extern int config_file_write (struct t_config_file *config_files);
@@ -245,7 +256,6 @@ extern void config_file_free_all ();
extern void config_file_free_all_plugin (struct t_weechat_plugin *plugin);
extern int config_file_add_to_infolist (struct t_infolist *infolist,
const char *option_name);
extern void config_file_print_stdout (struct t_config_file *config_file);
extern void config_file_print_log ();
#endif /* wee-config-file.h */
+148 -148
View File
@@ -524,7 +524,7 @@ config_weechat_debug_create_option (void *data,
config_file, section,
option_name, "integer",
_("debug level for plugin (\"core\" for WeeChat core)"),
NULL, 0, 32, "0", value, NULL, NULL,
NULL, 0, 32, "0", value, 0, NULL, NULL,
&config_weechat_debug_change, NULL,
NULL, NULL);
rc = (ptr_option) ?
@@ -578,13 +578,13 @@ config_weechat_debug_set (const char *plugin_name, const char *value)
}
/*
* config_weechat_proxy_read: read proxy option in config file
* config_weechat_proxy_read_cb: read proxy option in config file
*/
int
config_weechat_proxy_read (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
config_weechat_proxy_read_cb (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
{
char *pos_option, *proxy_name;
struct t_proxy *ptr_temp_proxy;
@@ -647,13 +647,13 @@ config_weechat_proxy_read (void *data, struct t_config_file *config_file,
}
/*
* config_weechat_bar_read: read bar option in config file
* config_weechat_bar_read_cb: read bar option in config file
*/
int
config_weechat_bar_read (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
config_weechat_bar_read_cb (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
{
char *pos_option, *bar_name;
struct t_gui_bar *ptr_temp_bar;
@@ -716,13 +716,13 @@ config_weechat_bar_read (void *data, struct t_config_file *config_file,
}
/*
* config_weechat_layout_read: read layout option in config file
* config_weechat_layout_read_cb: read layout option in config file
*/
int
config_weechat_layout_read (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
config_weechat_layout_read_cb (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
{
int argc;
char **argv, *error1, *error2, *error3, *error4;
@@ -817,12 +817,12 @@ config_weechat_layout_write_tree (struct t_config_file *config_file,
}
/*
* config_weechat_layout_write: write layout section in configuration file
* config_weechat_layout_write_cb: write layout section in configuration file
*/
void
config_weechat_layout_write (void *data, struct t_config_file *config_file,
const char *section_name)
config_weechat_layout_write_cb (void *data, struct t_config_file *config_file,
const char *section_name)
{
struct t_gui_layout_buffer *ptr_layout_buffer;
@@ -845,14 +845,14 @@ config_weechat_layout_write (void *data, struct t_config_file *config_file,
}
/*
* config_weechat_filter_read: read filter option from config file
* config_weechat_filter_read_cb: read filter option from config file
*/
int
config_weechat_filter_read (void *data,
struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
config_weechat_filter_read_cb (void *data,
struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
{
char **argv, **argv_eol;
int argc;
@@ -881,12 +881,12 @@ config_weechat_filter_read (void *data,
}
/*
* config_weechat_filter_write: write filter section in configuration file
* config_weechat_filter_write_cb: write filter section in configuration file
*/
void
config_weechat_filter_write (void *data, struct t_config_file *config_file,
const char *section_name)
config_weechat_filter_write_cb (void *data, struct t_config_file *config_file,
const char *section_name)
{
struct t_gui_filter *ptr_filter;
@@ -909,13 +909,13 @@ config_weechat_filter_write (void *data, struct t_config_file *config_file,
}
/*
* config_weechat_key_read: read key option in config file
* config_weechat_key_read_cb: read key option in config file
*/
int
config_weechat_key_read (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
config_weechat_key_read_cb (void *data, struct t_config_file *config_file,
struct t_config_section *section,
const char *option_name, const char *value)
{
/* make C compiler happy */
(void) data;
@@ -940,12 +940,12 @@ config_weechat_key_read (void *data, struct t_config_file *config_file,
}
/*
* config_weechat_key_write: write key section in configuration file
* config_weechat_key_write_cb: write key section in configuration file
*/
void
config_weechat_key_write (void *data, struct t_config_file *config_file,
const char *section_name)
config_weechat_key_write_cb (void *data, struct t_config_file *config_file,
const char *section_name)
{
struct t_gui_key *ptr_key;
char *expanded_name;
@@ -1013,27 +1013,27 @@ config_weechat_init ()
weechat_config_file, ptr_section,
"command_after_plugins", "string",
N_("command executed when WeeChat starts, after loading plugins"),
NULL, 0, 0, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_startup_command_before_plugins = config_file_new_option (
weechat_config_file, ptr_section,
"command_before_plugins", "string",
N_("command executed when WeeChat starts, before loading plugins"),
NULL, 0, 0, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_startup_display_logo = config_file_new_option (
weechat_config_file, ptr_section,
"display_logo", "boolean",
N_("display WeeChat logo at startup"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_startup_display_version = config_file_new_option (
weechat_config_file, ptr_section,
"display_version", "boolean",
N_("display WeeChat version at startup"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_startup_weechat_slogan = config_file_new_option (
weechat_config_file, ptr_section,
"weechat_slogan", "string",
N_("WeeChat slogan (if empty, slogan is not used)"),
NULL, 0, 0, _("the geekiest chat client!"), NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, _("the geekiest chat client!"), NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* look */
ptr_section = config_file_new_section (weechat_config_file, "look",
@@ -1052,18 +1052,18 @@ config_weechat_init ()
N_("default notify level for buffers (used to tell WeeChat if buffer "
"must be displayed in hotlist or not, according to importance "
"of message)"),
"none|highlight|message|all", 0, 0, "all", NULL,
"none|highlight|message|all", 0, 0, "all", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
config_look_buffer_time_format = config_file_new_option (
weechat_config_file, ptr_section,
"buffer_time_format", "string",
N_("time format for buffers"),
NULL, 0, 0, "%H:%M:%S", NULL, NULL, NULL, &config_change_buffer_time_format, NULL, NULL, NULL);
NULL, 0, 0, "%H:%M:%S", NULL, 0, NULL, NULL, &config_change_buffer_time_format, NULL, NULL, NULL);
config_look_color_nicks_number = config_file_new_option (
weechat_config_file, ptr_section,
"color_nicks_number", "integer",
N_("number of colors to use for nicks colors"),
NULL, 1, 10, "10", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 1, 10, "10", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_color_real_white = config_file_new_option (
weechat_config_file, ptr_section,
"color_real_white", "boolean",
@@ -1072,47 +1072,47 @@ config_weechat_init ()
"white background, you should turn on this option to "
"see real white instead of default term foreground "
"color)"),
NULL, 0, 0, "off", NULL, NULL, NULL, &config_change_color, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_look_day_change = config_file_new_option (
weechat_config_file, ptr_section,
"day_change", "boolean",
N_("display special message when day changes"),
NULL, 0, 0, "on", NULL, NULL, NULL, &config_change_day_change, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, &config_change_day_change, NULL, NULL, NULL);
config_look_day_change_time_format = config_file_new_option (
weechat_config_file, ptr_section,
"day_change_time_format", "string",
N_("time format for date displayed when day changed"),
NULL, 0, 0, "%a, %d %b %Y", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "%a, %d %b %Y", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_highlight = config_file_new_option (
weechat_config_file, ptr_section,
"highlight", "string",
N_("comma separated list of words to highlight (case insensitive "
"comparison, words may begin or end with \"*\" for partial match)"),
NULL, 0, 0, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_hotlist_names_count = config_file_new_option (
weechat_config_file, ptr_section,
"hotlist_names_count", "integer",
N_("max number of names in hotlist (0 = no name "
"displayed, only buffer numbers)"),
NULL, 0, 32, "3", NULL, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
NULL, 0, 32, "3", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
config_look_hotlist_names_length = config_file_new_option (
weechat_config_file, ptr_section,
"hotlist_names_length", "integer",
N_("max length of names in hotlist (0 = no limit)"),
NULL, 0, 32, "0", NULL, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
NULL, 0, 32, "0", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
config_look_hotlist_names_level = config_file_new_option (
weechat_config_file, ptr_section,
"hotlist_names_level", "integer",
N_("level for displaying names in hotlist (combination "
"of: 1=join/part, 2=message, 4=private, 8=highlight, "
"for example: 12=private+highlight)"),
NULL, 1, 15, "12", NULL, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
NULL, 1, 15, "12", 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",
N_("if set, uses short names to display buffer names in hotlist (start "
"after first '.' in name)"),
NULL, 0, 0, "on", NULL, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
config_look_hotlist_sort = config_file_new_option (
weechat_config_file, ptr_section,
"hotlist_sort", "integer",
@@ -1121,102 +1121,102 @@ config_weechat_init ()
"number_asc, number_desc)"),
"group_time_asc|group_time_desc|group_number_asc|"
"group_number_desc|number_asc|number_desc",
0, 0, "group_time_asc", NULL, NULL, NULL, &config_change_hotlist, NULL, NULL, NULL);
0, 0, "group_time_asc", NULL, 0, NULL, NULL, &config_change_hotlist, NULL, NULL, NULL);
config_look_item_time_format = config_file_new_option (
weechat_config_file, ptr_section,
"item_time_format", "string",
N_("time format for \"time\" bar item"),
NULL, 0, 0, "%H:%M", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "%H:%M", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_nickmode = config_file_new_option (
weechat_config_file, ptr_section,
"nickmode", "boolean",
N_("display nick mode ((half)op/voice) before each nick"),
NULL, 0, 0, "on", NULL, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
config_look_nickmode_empty = config_file_new_option (
weechat_config_file, ptr_section,
"nickmode_empty", "boolean",
N_("display space if nick mode is not (half)op/voice"),
NULL, 0, 0, "off", NULL, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
config_look_paste_max_lines = config_file_new_option (
weechat_config_file, ptr_section,
"paste_max_lines", "integer",
N_("max number of lines for paste without asking user "
"(0 = disable this feature)"),
NULL, 0, INT_MAX, "3", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "3", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_prefix[GUI_CHAT_PREFIX_ERROR] = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_error", "string",
N_("prefix for error messages"),
NULL, 0, 0, "=!=", NULL, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
NULL, 0, 0, "=!=", NULL, 0, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
config_look_prefix[GUI_CHAT_PREFIX_NETWORK] = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_network", "string",
N_("prefix for network messages"),
NULL, 0, 0, "--", NULL, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
NULL, 0, 0, "--", NULL, 0, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
config_look_prefix[GUI_CHAT_PREFIX_ACTION] = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_action", "string",
N_("prefix for action messages"),
NULL, 0, 0, " *", NULL, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
NULL, 0, 0, " *", NULL, 0, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
config_look_prefix[GUI_CHAT_PREFIX_JOIN] = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_join", "string",
N_("prefix for join messages"),
NULL, 0, 0, "-->", NULL, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
NULL, 0, 0, "-->", NULL, 0, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
config_look_prefix[GUI_CHAT_PREFIX_QUIT] = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_quit", "string",
N_("prefix for quit messages"),
NULL, 0, 0, "<--", NULL, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
NULL, 0, 0, "<--", NULL, 0, NULL, NULL, &config_change_prefix, NULL, NULL, NULL);
config_look_prefix_align = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_align", "integer",
N_("prefix alignment (none, left, right (default))"),
"none|left|right", 0, 0, "right", NULL, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
"none|left|right", 0, 0, "right", NULL, 0, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
config_look_prefix_align_max = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_align_max", "integer",
N_("max size for prefix (0 = no max size)"),
NULL, 0, 64, "0", NULL, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
NULL, 0, 64, "0", NULL, 0, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
config_look_prefix_suffix = config_file_new_option (
weechat_config_file, ptr_section,
"prefix_suffix", "string",
N_("string displayed after prefix"),
NULL, 0, 0, "|", NULL, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
NULL, 0, 0, "|", NULL, 0, NULL, NULL, &config_change_buffers, NULL, NULL, NULL);
config_look_read_marker = config_file_new_option (
weechat_config_file, ptr_section,
"read_marker", "integer",
N_("use a marker (line or char) on buffers to show first unread line"),
"none|line|dotted-line|char",
0, 0, "dotted-line", NULL, NULL, NULL, &config_change_read_marker, NULL, NULL, NULL);
0, 0, "dotted-line", NULL, 0, NULL, NULL, &config_change_read_marker, NULL, NULL, NULL);
config_look_save_config_on_exit = config_file_new_option (
weechat_config_file, ptr_section,
"save_config_on_exit", "boolean",
N_("save configuration file on exit"),
NULL, 0, 0, "on", NULL, NULL, NULL, &config_change_save_config_on_exit, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, &config_change_save_config_on_exit, NULL, NULL, NULL);
config_look_save_layout_on_exit = config_file_new_option (
weechat_config_file, ptr_section,
"save_layout_on_exit", "integer",
N_("save layout on exit (buffers, windows, or both)"),
"none|buffers|windows|all", 0, 0, "all", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
"none|buffers|windows|all", 0, 0, "all", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_scroll_amount = config_file_new_option (
weechat_config_file, ptr_section,
"scroll_amount", "integer",
N_("how many lines to scroll by with scroll_up and "
"scroll_down"),
NULL, 1, INT_MAX, "3", NULL, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
NULL, 1, INT_MAX, "3", NULL, 0, NULL, NULL, &config_change_buffer_content, NULL, NULL, NULL);
config_look_scroll_page_percent = config_file_new_option (
weechat_config_file, ptr_section,
"scroll_page_percent", "integer",
N_("percent of screen to scroll when scrolling one page up or down "
"(for example 100 means one page, 50 half-page)"),
NULL, 1, 100, "100", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 1, 100, "100", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_look_set_title = config_file_new_option (
weechat_config_file, ptr_section,
"set_title", "boolean",
N_("set title for window (terminal for Curses GUI) with "
"name and version"),
NULL, 0, 0, "on", NULL, NULL, NULL, &config_change_title, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, &config_change_title, NULL, NULL, NULL);
/* colors */
ptr_section = config_file_new_section (weechat_config_file, "color",
@@ -1234,343 +1234,343 @@ config_weechat_init ()
weechat_config_file, ptr_section,
"separator", "color",
N_("background color for window separators (when splitted)"),
NULL, GUI_COLOR_SEPARATOR, 0, "blue", NULL,
NULL, GUI_COLOR_SEPARATOR, 0, "blue", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* bar colors */
config_color_bar_more = config_file_new_option (
weechat_config_file, ptr_section,
"bar_more", "color",
N_("text color for '+' when scrolling bars"),
NULL, -1, 0, "lightmagenta", NULL,
NULL, -1, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* chat window */
config_color_chat = config_file_new_option (
weechat_config_file, ptr_section,
"chat", "color",
N_("text color for chat"),
NULL, GUI_COLOR_CHAT, 0, "default", NULL,
NULL, GUI_COLOR_CHAT, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_bg = config_file_new_option (
weechat_config_file, ptr_section,
"chat_bg", "color",
N_("background color for chat"),
NULL, -1, 0, "default", NULL,
NULL, -1, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_time = config_file_new_option (
weechat_config_file, ptr_section,
"chat_time", "color",
N_("text color for time in chat window"),
NULL, GUI_COLOR_CHAT_TIME, 0, "default", NULL,
NULL, GUI_COLOR_CHAT_TIME, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_time_delimiters = config_file_new_option (
weechat_config_file, ptr_section,
"chat_time_delimiters", "color",
N_("text color for time delimiters"),
NULL, GUI_COLOR_CHAT_TIME_DELIMITERS, 0, "brown", NULL,
NULL, GUI_COLOR_CHAT_TIME_DELIMITERS, 0, "brown", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix[GUI_CHAT_PREFIX_ERROR] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_error", "color",
N_("text color for error prefix"),
NULL, GUI_COLOR_CHAT_PREFIX_ERROR, 0, "yellow", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_ERROR, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix[GUI_CHAT_PREFIX_NETWORK] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_network", "color",
N_("text color for network prefix"),
NULL, GUI_COLOR_CHAT_PREFIX_NETWORK, 0, "magenta", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_NETWORK, 0, "magenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix[GUI_CHAT_PREFIX_ACTION] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_action", "color",
N_("text color for action prefix"),
NULL, GUI_COLOR_CHAT_PREFIX_ACTION, 0, "white", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_ACTION, 0, "white", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix[GUI_CHAT_PREFIX_JOIN] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_join", "color",
N_("text color for join prefix"),
NULL, GUI_COLOR_CHAT_PREFIX_JOIN, 0, "lightgreen", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_JOIN, 0, "lightgreen", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix[GUI_CHAT_PREFIX_QUIT] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_quit", "color",
N_("text color for quit prefix"),
NULL, GUI_COLOR_CHAT_PREFIX_QUIT, 0, "lightred", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_QUIT, 0, "lightred", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix_more = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_more", "color",
N_("text color for '+' when prefix is too long"),
NULL, GUI_COLOR_CHAT_PREFIX_MORE, 0, "lightmagenta", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_MORE, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_prefix_suffix = config_file_new_option (
weechat_config_file, ptr_section,
"chat_prefix_suffix", "color",
N_("text color for suffix (after prefix)"),
NULL, GUI_COLOR_CHAT_PREFIX_SUFFIX, 0, "green", NULL,
NULL, GUI_COLOR_CHAT_PREFIX_SUFFIX, 0, "green", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_buffer = config_file_new_option (
weechat_config_file, ptr_section,
"chat_buffer", "color",
N_("text color for buffer names"),
NULL, GUI_COLOR_CHAT_BUFFER, 0, "white", NULL,
NULL, GUI_COLOR_CHAT_BUFFER, 0, "white", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_server = config_file_new_option (
weechat_config_file, ptr_section,
"chat_server", "color",
N_("text color for server names"),
NULL, GUI_COLOR_CHAT_SERVER, 0, "brown", NULL,
NULL, GUI_COLOR_CHAT_SERVER, 0, "brown", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_channel = config_file_new_option (
weechat_config_file, ptr_section,
"chat_channel", "color",
N_("text color for channel names"),
NULL, GUI_COLOR_CHAT_CHANNEL, 0, "white", NULL,
NULL, GUI_COLOR_CHAT_CHANNEL, 0, "white", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick", "color",
N_("text color for nicks in chat window"),
NULL, GUI_COLOR_CHAT_NICK, 0, "lightcyan", NULL,
NULL, GUI_COLOR_CHAT_NICK, 0, "lightcyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_self = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_self", "color",
N_("text color for local nick in chat window"),
NULL, GUI_COLOR_CHAT_NICK_SELF, 0, "white", NULL,
NULL, GUI_COLOR_CHAT_NICK_SELF, 0, "white", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_other = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_other", "color",
N_("text color for other nick in private buffer"),
NULL, GUI_COLOR_CHAT_NICK_OTHER, 0, "cyan", NULL,
NULL, GUI_COLOR_CHAT_NICK_OTHER, 0, "cyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[0] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color01", "color",
N_("text color #1 for nick"),
NULL, GUI_COLOR_CHAT_NICK1, 0, "cyan", NULL,
NULL, GUI_COLOR_CHAT_NICK1, 0, "cyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[1] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color02", "color",
N_("text color #2 for nick"),
NULL, GUI_COLOR_CHAT_NICK2, 0, "magenta", NULL,
NULL, GUI_COLOR_CHAT_NICK2, 0, "magenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[2] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color03", "color",
N_("text color #3 for nick"),
NULL, GUI_COLOR_CHAT_NICK3, 0, "green", NULL,
NULL, GUI_COLOR_CHAT_NICK3, 0, "green", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[3] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color04", "color",
N_("text color #4 for nick"),
NULL, GUI_COLOR_CHAT_NICK4, 0, "brown", NULL,
NULL, GUI_COLOR_CHAT_NICK4, 0, "brown", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[4] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color05", "color",
N_("text color #5 for nick"),
NULL, GUI_COLOR_CHAT_NICK5, 0, "lightblue", NULL,
NULL, GUI_COLOR_CHAT_NICK5, 0, "lightblue", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[5] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color06", "color",
N_("text color #6 for nick"),
NULL, GUI_COLOR_CHAT_NICK6, 0, "default", NULL,
NULL, GUI_COLOR_CHAT_NICK6, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[6] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color07", "color",
N_("text color #7 for nick"),
NULL, GUI_COLOR_CHAT_NICK7, 0, "lightcyan", NULL,
NULL, GUI_COLOR_CHAT_NICK7, 0, "lightcyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[7] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color08", "color",
N_("text color #8 for nick"),
NULL, GUI_COLOR_CHAT_NICK8, 0, "lightmagenta", NULL,
NULL, GUI_COLOR_CHAT_NICK8, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[8] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color09", "color",
N_("text color #9 for nick"),
NULL, GUI_COLOR_CHAT_NICK9, 0, "lightgreen", NULL,
NULL, GUI_COLOR_CHAT_NICK9, 0, "lightgreen", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_nick_colors[9] = config_file_new_option (
weechat_config_file, ptr_section,
"chat_nick_color10", "color",
N_("text color #10 for nick"),
NULL, GUI_COLOR_CHAT_NICK10, 0, "blue", NULL,
NULL, GUI_COLOR_CHAT_NICK10, 0, "blue", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_host = config_file_new_option (
weechat_config_file, ptr_section,
"chat_host", "color",
N_("text color for hostnames"),
NULL, GUI_COLOR_CHAT_HOST, 0, "cyan", NULL,
NULL, GUI_COLOR_CHAT_HOST, 0, "cyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_delimiters = config_file_new_option (
weechat_config_file, ptr_section,
"chat_delimiters", "color",
N_("text color for delimiters"),
NULL, GUI_COLOR_CHAT_DELIMITERS, 0, "green", NULL,
NULL, GUI_COLOR_CHAT_DELIMITERS, 0, "green", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_highlight = config_file_new_option (
weechat_config_file, ptr_section,
"chat_highlight", "color",
N_("text color for highlighted prefix"),
NULL, GUI_COLOR_CHAT_HIGHLIGHT, 0, "yellow", NULL,
NULL, GUI_COLOR_CHAT_HIGHLIGHT, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_highlight_bg = config_file_new_option (
weechat_config_file, ptr_section,
"chat_highlight_bg", "color",
N_("background color for highlighted prefix"),
NULL, -1, 0, "magenta", NULL,
NULL, -1, 0, "magenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_read_marker = config_file_new_option (
weechat_config_file, ptr_section,
"chat_read_marker", "color",
N_("text color for unread data marker"),
NULL, GUI_COLOR_CHAT_READ_MARKER, 0, "magenta", NULL,
NULL, GUI_COLOR_CHAT_READ_MARKER, 0, "magenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_read_marker_bg = config_file_new_option (
weechat_config_file, ptr_section,
"chat_read_marker_bg", "color",
N_("background color for unread data marker"),
NULL, -1, 0, "default", NULL,
NULL, -1, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_text_found = config_file_new_option (
weechat_config_file, ptr_section,
"chat_text_found", "color",
N_("text color for marker on lines where text sought is found"),
NULL, GUI_COLOR_CHAT_TEXT_FOUND, 0, "yellow", NULL,
NULL, GUI_COLOR_CHAT_TEXT_FOUND, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_chat_text_found_bg = config_file_new_option (
weechat_config_file, ptr_section,
"chat_text_found_bg", "color",
N_("background color for marker on lines where text sought is found"),
NULL, -1, 0, "lightmagenta", NULL,
NULL, -1, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* status window */
config_color_status_number = config_file_new_option (
weechat_config_file, ptr_section,
"status_number", "color",
N_("text color for current buffer number in status bar"),
NULL, -1, 0, "yellow", NULL,
NULL, -1, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_name = config_file_new_option (
weechat_config_file, ptr_section,
"status_name", "color",
N_("text color for current buffer name in status bar"),
NULL, -1, 0, "white", NULL,
NULL, -1, 0, "white", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_data_msg = config_file_new_option (
weechat_config_file, ptr_section,
"status_data_msg", "color",
N_("text color for buffer with new messages (status bar)"),
NULL, -1, 0, "yellow", NULL,
NULL, -1, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_data_private = config_file_new_option (
weechat_config_file, ptr_section,
"status_data_private", "color",
N_("text color for buffer with private message (status bar)"),
NULL, -1, 0, "lightgreen", NULL,
NULL, -1, 0, "lightgreen", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_data_highlight = config_file_new_option (
weechat_config_file, ptr_section,
"status_data_highlight", "color",
N_("text color for buffer with highlight (status bar)"),
NULL, -1, 0, "lightmagenta", NULL,
NULL, -1, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_data_other = config_file_new_option (
weechat_config_file, ptr_section,
"status_data_other", "color",
N_("text color for buffer with new data (not messages) "
"(status bar)"),
NULL, -1, 0, "default", NULL,
NULL, -1, 0, "default", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_status_more = config_file_new_option (
weechat_config_file, ptr_section,
"status_more", "color",
N_("text color for buffer with new data (status bar)"),
NULL, -1, 0, "yellow", NULL,
NULL, -1, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* input window */
config_color_input_nick = config_file_new_option (
weechat_config_file, ptr_section,
"input_nick", "color",
N_("text color for nick name in input line"),
NULL, -1, 0, "lightcyan", NULL,
NULL, -1, 0, "lightcyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_input_text_not_found = config_file_new_option (
weechat_config_file, ptr_section,
"input_text_not_found", "color",
N_("text color for unsucessful text search in input line"),
NULL, -1, 0, "red", NULL,
NULL, -1, 0, "red", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_input_actions = config_file_new_option (
weechat_config_file, ptr_section,
"input_actions", "color",
N_("text color for actions in input line"),
NULL, -1, 0, "lightgreen", NULL,
NULL, -1, 0, "lightgreen", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* nicklist window */
config_color_nicklist_group = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_group", "color",
N_("text color for groups in nicklist"),
NULL, -1, 0, "green", NULL,
NULL, -1, 0, "green", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_away = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_away", "color",
N_("text color for away nicknames"),
NULL, -1, 0, "cyan", NULL,
NULL, -1, 0, "cyan", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_prefix1 = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_prefix1", "color",
N_("text color for prefix #1 in nicklist"),
NULL, -1, 0, "lightgreen", NULL,
NULL, -1, 0, "lightgreen", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_prefix2 = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_prefix2", "color",
N_("text color for prefix #2 in nicklist"),
NULL, -1, 0, "lightmagenta", NULL,
NULL, -1, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_prefix3 = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_prefix3", "color",
N_("text color for prefix #3 in nicklist"),
NULL, -1, 0, "yellow", NULL,
NULL, -1, 0, "yellow", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_prefix4 = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_prefix4", "color",
N_("text color for prefix #4 in nicklist"),
NULL, -1, 0, "blue", NULL,
NULL, -1, 0, "blue", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_prefix5 = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_prefix5", "color",
N_("text color for prefix #5 in nicklist"),
NULL, -1, 0, "brown", NULL,
NULL, -1, 0, "brown", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_more = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_more", "color",
N_("text color for '+' when scrolling nicks in nicklist"),
NULL, -1, 0, "lightmagenta", NULL,
NULL, -1, 0, "lightmagenta", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
config_color_nicklist_separator = config_file_new_option (
weechat_config_file, ptr_section,
"nicklist_separator", "color",
N_("text color for nicklist separator"),
NULL, -1, 0, "blue", NULL,
NULL, -1, 0, "blue", NULL, 0,
NULL, NULL, &config_change_color, NULL, NULL, NULL);
/* completion */
@@ -1588,45 +1588,45 @@ config_weechat_init ()
weechat_config_file, ptr_section,
"nick_completor", "string",
N_("string inserted after nick completion"),
NULL, 0, 0, ":", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, ":", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_nick_first_only = config_file_new_option (
weechat_config_file, ptr_section,
"nick_first_only", "boolean",
N_("complete only with first nick found"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_nick_ignore_chars = config_file_new_option (
weechat_config_file, ptr_section,
"nick_ignore_chars", "string",
N_("chars ignored for nick completion"),
NULL, 0, 0, "[]-^", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "[]-^", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_partial_completion_alert = config_file_new_option (
weechat_config_file, ptr_section,
"partial_completion_alert", "boolean",
N_("alert user when a partial completion occurs"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_partial_completion_nick = config_file_new_option (
weechat_config_file, ptr_section,
"partial_completion_nick", "boolean",
N_("partially complete nicks (stop when many nicks found begin with "
"same letters)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_partial_completion_command = config_file_new_option (
weechat_config_file, ptr_section,
"partial_completion_command", "boolean",
N_("partially complete command names (stop when many commands found "
"begin with same letters)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_partial_completion_command_arg = config_file_new_option (
weechat_config_file, ptr_section,
"partial_completion_command_arg", "boolean",
N_("partially complete command arguments (stop when many arguments "
"found begin with same prefix)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_completion_partial_completion_count = config_file_new_option (
weechat_config_file, ptr_section,
"partial_completion_count", "boolean",
N_("display count for each partial completion in bar item"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* history */
ptr_section = config_file_new_section (weechat_config_file, "history",
@@ -1644,24 +1644,24 @@ config_weechat_init ()
"max_lines", "integer",
N_("maximum number of lines in history per buffer "
"(0 = unlimited)"),
NULL, 0, INT_MAX, "4096", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "4096", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_history_max_commands = config_file_new_option (
weechat_config_file, ptr_section,
"max_commands", "integer",
N_("maximum number of user commands in history (0 = "
"unlimited)"),
NULL, 0, INT_MAX, "100", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "100", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_history_display_default = config_file_new_option (
weechat_config_file, ptr_section,
"display_default", "integer",
N_("maximum number of commands to display by default in "
"history listing (0 = unlimited)"),
NULL, 0, INT_MAX, "5", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "5", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* proxies */
ptr_section = config_file_new_section (weechat_config_file, "proxy",
0, 0,
&config_weechat_proxy_read, NULL,
&config_weechat_proxy_read_cb, NULL,
NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL);
if (!ptr_section)
@@ -1690,13 +1690,13 @@ config_weechat_init ()
"at startup, \"*\" means all plugins found (names may "
"be partial, for example \"perl\" is ok for "
"\"perl.so\")"),
NULL, 0, 0, "*", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "*", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_plugin_debug = config_file_new_option (
weechat_config_file, ptr_section,
"debug", "boolean",
N_("enable debug messages by default in all plugins (option disabled "
"by default, which is highly recommended)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_plugin_extension = config_file_new_option (
weechat_config_file, ptr_section,
"extension", "string",
@@ -1708,23 +1708,23 @@ config_weechat_init ()
#else
".so",
#endif
NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_plugin_path = config_file_new_option (
weechat_config_file, ptr_section,
"path", "string",
N_("path for searching plugins ('%h' will be replaced by "
"WeeChat home, ~/.weechat by default)"),
NULL, 0, 0, "%h/plugins", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "%h/plugins", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
config_plugin_save_config_on_unload = config_file_new_option (
weechat_config_file, ptr_section,
"save_config_on_unload", "boolean",
N_("save configuration files when unloading plugins"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* bars */
ptr_section = config_file_new_section (weechat_config_file, "bar",
0, 0,
&config_weechat_bar_read, NULL,
&config_weechat_bar_read_cb, NULL,
NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL);
if (!ptr_section)
@@ -1738,8 +1738,8 @@ config_weechat_init ()
/* layout */
ptr_section = config_file_new_section (weechat_config_file, "layout",
0, 0,
&config_weechat_layout_read, NULL,
&config_weechat_layout_write, NULL,
&config_weechat_layout_read_cb, NULL,
&config_weechat_layout_write_cb, NULL,
NULL, NULL, NULL, NULL, NULL, NULL);
if (!ptr_section)
{
@@ -1750,9 +1750,9 @@ config_weechat_init ()
/* filters */
ptr_section = config_file_new_section (weechat_config_file, "filter",
0, 0,
&config_weechat_filter_read, NULL,
&config_weechat_filter_write, NULL,
&config_weechat_filter_write, NULL,
&config_weechat_filter_read_cb, NULL,
&config_weechat_filter_write_cb, NULL,
&config_weechat_filter_write_cb, NULL,
NULL, NULL, NULL, NULL);
if (!ptr_section)
{
@@ -1763,9 +1763,9 @@ config_weechat_init ()
/* keys */
ptr_section = config_file_new_section (weechat_config_file, "key",
0, 0,
&config_weechat_key_read, NULL,
&config_weechat_key_write, NULL,
&config_weechat_key_write, NULL,
&config_weechat_key_read_cb, NULL,
&config_weechat_key_write_cb, NULL,
&config_weechat_key_write_cb, NULL,
NULL, NULL, NULL, NULL);
if (!ptr_section)
{
+6 -6
View File
@@ -264,7 +264,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "integer",
N_("proxy type (http (default), socks4, socks5)"),
"http|socks4|socks5", 0, 0, value, NULL,
"http|socks4|socks5", 0, 0, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_OPTION_IPV6:
@@ -272,7 +272,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "boolean",
N_("connect to proxy using ipv6"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_OPTION_ADDRESS:
@@ -280,7 +280,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "string",
N_("proxy server address (IP or hostname)"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_OPTION_PORT:
@@ -288,7 +288,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "integer",
N_("port for connecting to proxy server"),
NULL, 0, 65535, value, NULL,
NULL, 0, 65535, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_OPTION_USERNAME:
@@ -296,7 +296,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "string",
N_("username for proxy server"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_OPTION_PASSWORD:
@@ -304,7 +304,7 @@ proxy_create_option (const char *proxy_name, int index_option,
weechat_config_file, weechat_config_section_proxy,
option_name, "string",
N_("password for proxy server"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
break;
case PROXY_NUM_OPTIONS:
+14 -14
View File
@@ -1300,7 +1300,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "boolean",
N_("true if bar is hidden, false if it is displayed"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_hidden, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_PRIORITY:
@@ -1308,7 +1308,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "integer",
N_("bar priority (high number means bar displayed first)"),
NULL, 0, INT_MAX, value, NULL,
NULL, 0, INT_MAX, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_priority, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_TYPE:
@@ -1316,7 +1316,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "integer",
N_("bar type (root, window, window_active, window_inactive)"),
"root|window|window_active|window_inactive", 0, 0, value, NULL,
"root|window|window_active|window_inactive", 0, 0, value, NULL, 0,
&gui_bar_config_check_type, NULL, NULL, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_CONDITIONS:
@@ -1325,7 +1325,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
option_name, "string",
N_("condition(s) for displaying bar (for bars of type "
"\"window\")"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_conditions, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_POSITION:
@@ -1333,7 +1333,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "integer",
N_("bar position (bottom, top, left, right)"),
"bottom|top|left|right", 0, 0, value, NULL,
"bottom|top|left|right", 0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_position, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_FILLING_TOP_BOTTOM:
@@ -1344,7 +1344,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
"right) or \"vertical\" (from top to bottom)) when bar "
"position is top or bottom"),
"horizontal|vertical|columns_horizontal|columns_vertical",
0, 0, value, NULL,
0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_filling, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_FILLING_LEFT_RIGHT:
@@ -1355,7 +1355,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
"right) or \"vertical\" (from top to bottom)) when bar "
"position is left or right"),
"horizontal|vertical|columns_horizontal|columns_vertical",
0, 0, value, NULL,
0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_filling, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_SIZE:
@@ -1363,7 +1363,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "integer",
N_("bar size in chars (0 = auto size)"),
NULL, 0, INT_MAX, value, NULL,
NULL, 0, INT_MAX, value, NULL, 0,
&gui_bar_config_check_size, NULL,
&gui_bar_config_change_size, NULL,
NULL, NULL);
@@ -1373,7 +1373,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "integer",
N_("max bar size in chars (0 = no limit)"),
NULL, 0, INT_MAX, value, NULL,
NULL, 0, INT_MAX, value, NULL, 0,
NULL, NULL,
&gui_bar_config_change_size_max, NULL,
NULL, NULL);
@@ -1383,7 +1383,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "color",
N_("default text color for bar"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL,
&gui_bar_config_change_color, NULL,
NULL, NULL);
@@ -1393,7 +1393,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "color",
N_("default delimiter color for bar"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL,
&gui_bar_config_change_color, NULL,
NULL, NULL);
@@ -1403,7 +1403,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "color",
N_("default background color for bar"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL,
&gui_bar_config_change_color, NULL,
NULL, NULL);
@@ -1413,7 +1413,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "boolean",
N_("separator line between bar and other bars/windows"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_separator, NULL, NULL, NULL);
break;
case GUI_BAR_OPTION_ITEMS:
@@ -1421,7 +1421,7 @@ gui_bar_create_option (const char *bar_name, int index_option, const char *value
weechat_config_file, weechat_config_section_bar,
option_name, "string",
N_("items of bar"),
NULL, 0, 0, value, NULL,
NULL, 0, 0, value, NULL, 0,
NULL, NULL, &gui_bar_config_change_items, NULL, NULL, NULL);
break;
case GUI_BAR_NUM_OPTIONS:
+96 -44
View File
@@ -760,66 +760,101 @@ gui_completion_list_add_option_value (struct t_gui_completion *completion)
0, WEECHAT_LIST_POS_SORT);
gui_completion_list_add (completion, "toggle",
0, WEECHAT_LIST_POS_END);
if (CONFIG_BOOLEAN(option_found) == CONFIG_BOOLEAN_TRUE)
gui_completion_list_add (completion, "on",
0, WEECHAT_LIST_POS_BEGINNING);
if (option_found->value)
{
if (CONFIG_BOOLEAN(option_found) == CONFIG_BOOLEAN_TRUE)
gui_completion_list_add (completion, "on",
0, WEECHAT_LIST_POS_BEGINNING);
else
gui_completion_list_add (completion, "off",
0, WEECHAT_LIST_POS_BEGINNING);
}
else
gui_completion_list_add (completion, "off",
{
gui_completion_list_add (completion,
WEECHAT_CONFIG_OPTION_NULL,
0, WEECHAT_LIST_POS_BEGINNING);
}
break;
case CONFIG_OPTION_TYPE_INTEGER:
length = 64;
value_string = malloc (length);
if (value_string)
if (option_found->string_values)
{
if (option_found->string_values)
for (i = 0; option_found->string_values[i]; i++)
{
for (i = 0; option_found->string_values[i]; i++)
{
gui_completion_list_add (completion,
option_found->string_values[i],
0, WEECHAT_LIST_POS_SORT);
}
gui_completion_list_add (completion, "++1",
0, WEECHAT_LIST_POS_END);
gui_completion_list_add (completion, "--1",
0, WEECHAT_LIST_POS_END);
snprintf (value_string, length,
"%s",
option_found->string_values[CONFIG_INTEGER(option_found)]);
gui_completion_list_add (completion,
option_found->string_values[i],
0, WEECHAT_LIST_POS_SORT);
}
gui_completion_list_add (completion, "++1",
0, WEECHAT_LIST_POS_END);
gui_completion_list_add (completion, "--1",
0, WEECHAT_LIST_POS_END);
if (option_found->value)
{
gui_completion_list_add (completion,
option_found->string_values[CONFIG_INTEGER(option_found)],
0, WEECHAT_LIST_POS_BEGINNING);
}
else
{
if (CONFIG_INTEGER(option_found) > option_found->min)
gui_completion_list_add (completion, "--1",
0, WEECHAT_LIST_POS_BEGINNING);
if (CONFIG_INTEGER(option_found) < option_found->max)
gui_completion_list_add (completion, "++1",
0, WEECHAT_LIST_POS_BEGINNING);
snprintf (value_string, length,
"%d", CONFIG_INTEGER(option_found));
gui_completion_list_add (completion,
WEECHAT_CONFIG_OPTION_NULL,
0, WEECHAT_LIST_POS_BEGINNING);
}
}
else
{
if (option_found->value && CONFIG_INTEGER(option_found) > option_found->min)
gui_completion_list_add (completion, "--1",
0, WEECHAT_LIST_POS_BEGINNING);
if (option_found->value && CONFIG_INTEGER(option_found) < option_found->max)
gui_completion_list_add (completion, "++1",
0, WEECHAT_LIST_POS_BEGINNING);
if (option_found->value)
{
value_string = malloc (64);
if (value_string)
{
snprintf (value_string, length,
"%d", CONFIG_INTEGER(option_found));
gui_completion_list_add (completion,
value_string,
0, WEECHAT_LIST_POS_BEGINNING);
free (value_string);
}
}
else
{
gui_completion_list_add (completion,
WEECHAT_CONFIG_OPTION_NULL,
0, WEECHAT_LIST_POS_BEGINNING);
}
gui_completion_list_add (completion,
value_string,
0, WEECHAT_LIST_POS_BEGINNING);
free (value_string);
}
break;
case CONFIG_OPTION_TYPE_STRING:
gui_completion_list_add (completion,
"\"\"",
0, WEECHAT_LIST_POS_BEGINNING);
length = strlen (CONFIG_STRING(option_found)) + 2 + 1;
value_string = malloc (length);
if (value_string)
if (option_found->value)
{
length = strlen (CONFIG_STRING(option_found)) + 2 + 1;
value_string = malloc (length);
if (value_string)
{
snprintf (value_string, length,
"\"%s\"",
CONFIG_STRING(option_found));
gui_completion_list_add (completion,
value_string,
0, WEECHAT_LIST_POS_BEGINNING);
free (value_string);
}
}
else
{
snprintf (value_string, length,
"\"%s\"",
CONFIG_STRING(option_found));
gui_completion_list_add (completion,
value_string,
WEECHAT_CONFIG_OPTION_NULL,
0, WEECHAT_LIST_POS_BEGINNING);
free (value_string);
}
break;
case CONFIG_OPTION_TYPE_COLOR:
@@ -836,17 +871,34 @@ gui_completion_list_add_option_value (struct t_gui_completion *completion)
0, WEECHAT_LIST_POS_END);
gui_completion_list_add (completion, "--1",
0, WEECHAT_LIST_POS_END);
color_name = gui_color_get_name (CONFIG_INTEGER(option_found));
if (color_name)
if (option_found->value)
{
color_name = gui_color_get_name (CONFIG_INTEGER(option_found));
if (color_name)
{
gui_completion_list_add (completion,
color_name,
0, WEECHAT_LIST_POS_BEGINNING);
}
}
else
{
gui_completion_list_add (completion,
color_name,
WEECHAT_CONFIG_OPTION_NULL,
0, WEECHAT_LIST_POS_BEGINNING);
}
break;
case CONFIG_NUM_OPTION_TYPES:
break;
}
if (option_found->value
&& option_found->null_value_allowed)
{
gui_completion_list_add (completion,
WEECHAT_CONFIG_OPTION_NULL,
0,
WEECHAT_LIST_POS_END);
}
}
}
}
+4 -2
View File
@@ -631,7 +631,8 @@ alias_config_create_option (void *data, struct t_config_file *config_file,
weechat_config_new_option (
config_file, section,
option_name, "string", NULL,
NULL, 0, 0, "", value, NULL, NULL,
NULL, 0, 0, "", value, 0,
NULL, NULL,
&alias_config_change_cb, NULL,
&alias_config_delete_cb, NULL);
@@ -750,7 +751,8 @@ alias_command_cb (void *data, struct t_gui_buffer *buffer, int argc,
weechat_config_new_option (
alias_config_file, alias_config_section_cmd,
alias_name, "string", NULL,
NULL, 0, 0, "", argv_eol[2], NULL, NULL,
NULL, 0, 0, "", argv_eol[2], 0,
NULL, NULL,
&alias_config_change_cb, NULL,
&alias_config_delete_cb, NULL);
+7 -6
View File
@@ -191,7 +191,8 @@ weechat_aspell_config_dict_create_option (void *data,
config_file, section,
option_name, "string",
_("comma separated list of dictionaries to use on this buffer"),
NULL, 0, 0, "", value, NULL, NULL,
NULL, 0, 0, "", value, 0,
NULL, NULL,
&weechat_aspell_config_dict_change, NULL,
NULL, NULL);
rc = (ptr_option) ?
@@ -272,7 +273,7 @@ weechat_aspell_config_init ()
weechat_aspell_config_file, ptr_section,
"color", "color",
N_("color used for mispelled words"),
NULL, 0, 0, "lightred", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "lightred", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* check */
ptr_section = weechat_config_new_section (weechat_aspell_config_file, "check",
@@ -293,7 +294,7 @@ weechat_aspell_config_init ()
"enabled (spell checking is disabled for all other commands)"),
NULL, 0, 0,
"ame,amsg,away,command,cycle,kick,kickban,me,msg,notice,part,query,"
"quit,topic", NULL,
"quit,topic", NULL, 0,
NULL, NULL, &weechat_aspell_config_change_commands, NULL, NULL, NULL);
weechat_aspell_config_check_default_dict = weechat_config_new_option (
weechat_aspell_config_file, ptr_section,
@@ -301,19 +302,19 @@ weechat_aspell_config_init ()
N_("default dictionary (or comma separated list of dictionaries) to "
"use when buffer has no dictionary defined (leave blank to disable "
"aspell on buffers for which you didn't explicitely enabled it)"),
NULL, 0, 0, "", NULL,
NULL, 0, 0, "", NULL, 0,
NULL, NULL, &weechat_aspell_config_change_default_dict, NULL, NULL, NULL);
weechat_aspell_config_check_word_min_length = weechat_config_new_option (
weechat_aspell_config_file, ptr_section,
"word_min_length", "integer",
N_("minimum length for a word to be spell checked (use 0 to check all "
"words)"),
NULL, 0, INT_MAX, "2", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "2", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
weechat_aspell_config_check_during_search = weechat_config_new_option (
weechat_aspell_config_file, ptr_section,
"during_search", "boolean",
N_("check words during text search in buffer"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* dict */
ptr_section = weechat_config_new_section (weechat_aspell_config_file, "dict",
+4 -3
View File
@@ -109,7 +109,8 @@ charset_config_create_option (void *data, struct t_config_file *config_file,
ptr_option = weechat_config_new_option (
config_file, section,
option_name, "string", NULL,
NULL, 0, 0, "", value, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", value, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
rc = (ptr_option) ?
WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE : WEECHAT_CONFIG_OPTION_SET_ERROR;
}
@@ -163,13 +164,13 @@ charset_config_init ()
(charset_terminal && charset_internal
&& (strcasecmp (charset_terminal,
charset_internal) != 0)) ?
charset_terminal : "iso-8859-1", NULL,
charset_terminal : "iso-8859-1", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
charset_default_encode = weechat_config_new_option (
charset_config_file, ptr_section,
"encode", "string",
N_("global encoding charset"),
NULL, 0, 0, "", NULL,
NULL, 0, 0, "", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (charset_config_file, "decode",
+155 -228
View File
@@ -530,10 +530,8 @@ int
irc_command_connect (void *data, struct t_gui_buffer *buffer, int argc,
char **argv, char **argv_eol)
{
struct t_irc_server server_tmp;
int i, nb_connect, connect_ok, all_servers, no_join, port, ipv6, ssl;
int default_ipv6, default_ssl;
char *error, value[16];
char *name, *error;
long number;
IRC_GET_SERVER(buffer);
@@ -606,65 +604,21 @@ irc_command_connect (void *data, struct t_gui_buffer *buffer, int argc,
}
else
{
irc_server_init (&server_tmp);
default_ipv6 = server_tmp.ipv6;
default_ssl = server_tmp.ssl;
server_tmp.name = irc_server_get_name_without_port (argv[i]);
server_tmp.addresses = strdup (argv[i]);
server_tmp.ipv6 = ipv6;
server_tmp.ssl = ssl;
ptr_server = irc_server_new (server_tmp.name,
server_tmp.autoconnect,
server_tmp.autoreconnect,
server_tmp.autoreconnect_delay,
server_tmp.proxy,
server_tmp.addresses,
server_tmp.ipv6,
server_tmp.ssl,
server_tmp.password,
server_tmp.nicks,
server_tmp.username,
server_tmp.realname,
server_tmp.local_hostname,
server_tmp.command,
1, /* command_delay */
server_tmp.autojoin,
1); /* autorejoin */
name = irc_server_get_name_without_port (argv[i]);
ptr_server = irc_server_alloc ((name) ? name : argv[i]);
if (name)
free (name);
if (ptr_server)
{
ptr_server->temp_server = 1;
weechat_config_option_set (ptr_server->options[IRC_SERVER_OPTION_ADDRESSES],
argv[i], 1);
weechat_printf (NULL,
_("%s: server %s%s%s created"),
_("%s: server %s%s%s created (temporary server, NOT SAVED!)"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
server_tmp.name,
ptr_server->name,
IRC_COLOR_CHAT);
/* create server options */
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_ADDRESSES,
server_tmp.addresses);
if (default_ipv6 != server_tmp.ipv6)
{
snprintf (value, sizeof (value),
"%s",
(server_tmp.ipv6) ? "on" : "off");
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_IPV6,
value);
}
if (default_ssl != server_tmp.ssl)
{
snprintf (value, sizeof (value),
"%s",
(server_tmp.ssl) ? "on" : "off");
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_SSL,
value);
}
if (!irc_command_connect_one_server (ptr_server, 0))
connect_ok = 0;
}
@@ -2776,12 +2730,9 @@ int
irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
char **argv, char **argv_eol)
{
int i, detailed_list, one_server_found, length;
int default_autoconnect, default_ipv6, default_ssl;
struct t_irc_server server_tmp, *ptr_server2, *server_found, *new_server;
char *server_name, *mask, value[16], charset_modifier[256];
struct t_infolist *infolist;
struct t_config_option *ptr_option;
int i, detailed_list, one_server_found;
struct t_irc_server *ptr_server2, *server_found, *new_server;
char *server_name, charset_modifier[256];
IRC_GET_SERVER_CHANNEL(buffer);
@@ -2852,6 +2803,124 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
return WEECHAT_RC_OK;
}
if (weechat_strcasecmp (argv[1], "add") == 0)
{
if (argc < 4)
{
IRC_COMMAND_TOO_FEW_ARGUMENTS(NULL, "server add");
}
if (irc_server_search (argv[2]))
{
weechat_printf (NULL,
_("%s%s: server \"%s\" already exists, "
"can't create it!"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[2]);
return WEECHAT_RC_ERROR;
}
new_server = irc_server_alloc (argv[2]);
if (!new_server)
{
weechat_printf (NULL,
_("%s%s: unable to create server"),
weechat_prefix ("error"), IRC_PLUGIN_NAME);
return WEECHAT_RC_ERROR;
}
weechat_config_option_set (new_server->options[IRC_SERVER_OPTION_ADDRESSES],
argv[3], 1);
/* parse arguments */
for (i = 4; i < argc; i++)
{
if (argv[i][0] == '-')
{
if (weechat_strcasecmp (argv[i], "-auto") == 0)
{
weechat_config_option_set (new_server->options[IRC_SERVER_OPTION_AUTOCONNECT],
"on", 1);
}
if (weechat_strcasecmp (argv[i], "-noauto") == 0)
{
weechat_config_option_set (new_server->options[IRC_SERVER_OPTION_AUTOCONNECT],
"off", 1);
}
if (weechat_strcasecmp (argv[i], "-ipv6") == 0)
{
weechat_config_option_set (new_server->options[IRC_SERVER_OPTION_IPV6],
"on", 1);
}
if (weechat_strcasecmp (argv[i], "-ssl") == 0)
{
weechat_config_option_set (new_server->options[IRC_SERVER_OPTION_SSL],
"on", 1);
}
}
}
weechat_printf (NULL,
_("%s: server %s%s%s created"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
new_server->name,
IRC_COLOR_CHAT);
if (IRC_SERVER_OPTION_BOOLEAN(new_server, IRC_SERVER_OPTION_AUTOCONNECT))
irc_server_connect (new_server, 0);
return WEECHAT_RC_OK;
}
if (weechat_strcasecmp (argv[1], "copy") == 0)
{
if (argc < 4)
{
IRC_COMMAND_TOO_FEW_ARGUMENTS(NULL, "server copy");
}
/* look for server by name */
server_found = irc_server_search (argv[2]);
if (!server_found)
{
weechat_printf (NULL,
_("%s%s: server \"%s\" not found for "
"\"%s\" command"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[2], "server copy");
return WEECHAT_RC_ERROR;
}
/* check if target name already exists */
if (irc_server_search (argv[3]))
{
weechat_printf (NULL,
_("%s%s: server \"%s\" already exists for "
"\"%s\" command"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[3], "server copy");
return WEECHAT_RC_ERROR;
}
/* copy server */
new_server = irc_server_copy (server_found, argv[3]);
if (new_server)
{
weechat_printf (NULL,
_("%s: server %s%s%s has been copied to "
"%s%s"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
argv[2],
IRC_COLOR_CHAT,
IRC_COLOR_CHAT_SERVER,
argv[3]);
return WEECHAT_RC_OK;
}
return WEECHAT_RC_ERROR;
}
if (weechat_strcasecmp (argv[1], "rename") == 0)
{
if (argc < 4)
@@ -2900,129 +2969,11 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
return WEECHAT_RC_ERROR;
}
if (weechat_strcasecmp (argv[1], "add") == 0)
if (weechat_strcasecmp (argv[1], "keep") == 0)
{
if (argc < 4)
if (argc < 3)
{
IRC_COMMAND_TOO_FEW_ARGUMENTS(NULL, "server add");
}
if (irc_server_search (argv[2]))
{
weechat_printf (NULL,
_("%s%s: server \"%s\" already exists, "
"can't create it!"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[2]);
return WEECHAT_RC_ERROR;
}
/* init server struct */
irc_server_init (&server_tmp);
default_autoconnect = server_tmp.autoconnect;
default_ipv6 = server_tmp.ipv6;
default_ssl = server_tmp.ssl;
server_tmp.name = strdup (argv[2]);
server_tmp.addresses = strdup (argv[3]);
/* parse arguments */
for (i = 4; i < argc; i++)
{
if (argv[i][0] == '-')
{
if (weechat_strcasecmp (argv[i], "-auto") == 0)
server_tmp.autoconnect = 1;
if (weechat_strcasecmp (argv[i], "-noauto") == 0)
server_tmp.autoconnect = 0;
if (weechat_strcasecmp (argv[i], "-ipv6") == 0)
server_tmp.ipv6 = 1;
if (weechat_strcasecmp (argv[i], "-ssl") == 0)
server_tmp.ssl = 1;
}
}
/* create new server */
new_server = irc_server_new (server_tmp.name,
server_tmp.autoconnect,
server_tmp.autoreconnect,
server_tmp.autoreconnect_delay,
server_tmp.proxy,
server_tmp.addresses,
server_tmp.ipv6,
server_tmp.ssl,
server_tmp.password,
server_tmp.nicks,
server_tmp.username,
server_tmp.realname,
server_tmp.local_hostname,
server_tmp.command,
1, /* command_delay */
server_tmp.autojoin,
1); /* autorejoin */
if (new_server)
{
weechat_printf (NULL,
_("%s: server %s%s%s created"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
server_tmp.name,
IRC_COLOR_CHAT);
/* create server options */
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_ADDRESSES,
server_tmp.addresses);
if (default_autoconnect != server_tmp.autoconnect)
{
snprintf (value, sizeof (value),
"%s",
(server_tmp.autoconnect) ? "on" : "off");
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_AUTOCONNECT,
value);
}
if (default_ipv6 != server_tmp.ipv6)
{
snprintf (value, sizeof (value),
"%s",
(server_tmp.ipv6) ? "on" : "off");
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_IPV6,
value);
}
if (default_ssl != server_tmp.ssl)
{
snprintf (value, sizeof (value),
"%s",
(server_tmp.ssl) ? "on" : "off");
irc_server_new_option (&server_tmp,
IRC_CONFIG_SERVER_SSL,
value);
}
}
else
{
weechat_printf (NULL,
_("%s%s: unable to create server"),
weechat_prefix ("error"), IRC_PLUGIN_NAME);
irc_server_free_data (&server_tmp);
return WEECHAT_RC_ERROR;
}
if (new_server->autoconnect)
irc_server_connect (new_server, 0);
irc_server_free_data (&server_tmp);
return WEECHAT_RC_OK;
}
if (weechat_strcasecmp (argv[1], "copy") == 0)
{
if (argc < 4)
{
IRC_COMMAND_TOO_FEW_ARGUMENTS(NULL, "server copy");
IRC_COMMAND_TOO_FEW_ARGUMENTS(NULL, "server keep");
}
/* look for server by name */
@@ -3033,38 +2984,31 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
_("%s%s: server \"%s\" not found for "
"\"%s\" command"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[2], "server copy");
argv[2], "server keep");
return WEECHAT_RC_ERROR;
}
/* check if target name already exists */
if (irc_server_search (argv[3]))
/* check that is it temporary server */
if (!server_found->temp_server)
{
weechat_printf (NULL,
_("%s%s: server \"%s\" already exists for "
"\"%s\" command"),
_("%s%s: server \"%s\" is not a temporary server"),
weechat_prefix ("error"), IRC_PLUGIN_NAME,
argv[3], "server copy");
argv[2], "server keep");
return WEECHAT_RC_ERROR;
}
/* duplicate server */
new_server = irc_server_duplicate (server_found, argv[3]);
if (new_server)
{
weechat_printf (NULL,
_("%s: server %s%s%s has been copied to "
"%s%s"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
argv[2],
IRC_COLOR_CHAT,
IRC_COLOR_CHAT_SERVER,
argv[3]);
return WEECHAT_RC_OK;
}
/* remove temporary flag on server */
server_found->temp_server = 0;
return WEECHAT_RC_ERROR;
weechat_printf (NULL,
_("%s: server %s%s%s is not temporary any more"),
IRC_PLUGIN_NAME,
IRC_COLOR_CHAT_SERVER,
argv[2],
IRC_COLOR_CHAT);
return WEECHAT_RC_OK;
}
if (weechat_strcasecmp (argv[1], "del") == 0)
@@ -3097,27 +3041,7 @@ irc_command_server (void *data, struct t_gui_buffer *buffer, int argc,
}
server_name = strdup (server_found->name);
/* remove all options (server will be removed when last option is removed) */
length = 32 + strlen (server_found->name) + 1;
mask = malloc (length);
if (mask)
{
snprintf (mask, length, "irc.server.%s.*", server_found->name);
infolist = weechat_infolist_get ("option", NULL, mask);
free (mask);
while (weechat_infolist_next (infolist))
{
weechat_config_search_with_string (weechat_infolist_string (infolist,
"full_name"),
NULL, NULL, &ptr_option,
NULL);
if (ptr_option)
weechat_config_option_unset (ptr_option);
}
weechat_infolist_free (infolist);
}
irc_server_free (server_found);
weechat_printf (NULL,
_("%s: Server %s%s%s has been deleted"),
IRC_PLUGIN_NAME,
@@ -4114,7 +4038,8 @@ irc_command_init ()
"[-auto | -noauto] [-ipv6] [-ssl]] | "
"[copy servername newservername] | "
"[rename servername newservername] | "
"[del servername] | [deloutq] | [switch]"),
"[keep servername] | [del servername] | "
"[deloutq] | [switch]"),
N_(" list: list servers (no parameter implies "
"this list)\n"
" listfull: list servers with detailed info for "
@@ -4132,6 +4057,8 @@ irc_command_init ()
" ssl: use SSL protocol\n"
" copy: duplicate a server\n"
" rename: rename a server\n"
" keep: keep server in config file (for "
"temporary servers only)\n"
" del: delete a server\n"
" deloutq: delete messages out queue for all "
"servers (all messages WeeChat is currently "
@@ -4150,7 +4077,7 @@ irc_command_init ()
" /server del freenode\n"
" /server deloutq\n"
" /server switch"),
"add|copy|rename|del|deloutq|list|listfull|switch "
"add|copy|rename|keep|del|deloutq|list|listfull|switch "
"%(irc_servers) %(irc_servers)",
&irc_command_server, NULL);
weechat_hook_command ("servlist",
File diff suppressed because it is too large Load Diff
+4 -29
View File
@@ -26,29 +26,6 @@
#define IRC_CONFIG_DISPLAY_AWAY_LOCAL 1
#define IRC_CONFIG_DISPLAY_AWAY_CHANNEL 2
enum t_irc_config_server_option
{
IRC_CONFIG_SERVER_AUTOCONNECT = 0,
IRC_CONFIG_SERVER_AUTORECONNECT,
IRC_CONFIG_SERVER_AUTORECONNECT_DELAY,
IRC_CONFIG_SERVER_PROXY,
IRC_CONFIG_SERVER_ADDRESSES,
IRC_CONFIG_SERVER_IPV6,
IRC_CONFIG_SERVER_SSL,
IRC_CONFIG_SERVER_PASSWORD,
IRC_CONFIG_SERVER_NICKS,
IRC_CONFIG_SERVER_USERNAME,
IRC_CONFIG_SERVER_REALNAME,
IRC_CONFIG_SERVER_LOCAL_HOSTNAME,
IRC_CONFIG_SERVER_COMMAND,
IRC_CONFIG_SERVER_COMMAND_DELAY,
IRC_CONFIG_SERVER_AUTOJOIN,
IRC_CONFIG_SERVER_AUTOREJOIN,
IRC_CONFIG_SERVER_NOTIFY_LEVELS,
/* number of server options */
IRC_CONFIG_NUM_SERVER_OPTIONS,
};
#define IRC_CONFIG_SERVER_DEFAULT_AUTOCONNECT 0
#define IRC_CONFIG_SERVER_DEFAULT_AUTORECONNECT 1
#define IRC_CONFIG_SERVER_DEFAULT_AUTORECONNECT_DELAY 30
@@ -58,7 +35,6 @@ enum t_irc_config_server_option
#define IRC_CONFIG_SERVER_DEFAULT_AUTOREJOIN 0
extern char *irc_config_server_option_string[];
extern struct t_config_file *irc_config_file;
extern struct t_config_section *irc_config_section_server_default;
extern struct t_config_section *irc_config_section_server;
@@ -96,7 +72,6 @@ extern struct t_config_option *irc_config_network_send_unknown_commands;
extern struct t_config_option *irc_config_server_default[];
extern int irc_config_search_server_option (const char *option_name);
extern void irc_config_server_change_cb (void *data,
struct t_config_option *option);
extern void irc_config_server_delete_cb (void *data,
@@ -105,14 +80,14 @@ struct t_config_option *irc_config_server_new_option (struct t_config_file *conf
struct t_config_section *section,
int index_option,
const char *option_name,
const char *default_value,
const char *value,
int null_value_allowed,
void *callback_change,
void *callback_change_data,
void *callback_delete,
void *callback_delete_data);
void *callback_change_data);
extern int irc_config_init ();
extern int irc_config_read ();
extern int irc_config_write ();
extern int irc_config_write (int write_temp_servers);
extern void irc_config_free ();
#endif /* irc-config.h */
+144 -53
View File
@@ -152,11 +152,11 @@ irc_display_server (struct t_irc_server *server, int with_detail)
{
char *string;
int num_channels, num_pv;
if (with_detail)
{
weechat_printf (NULL, "");
weechat_printf (NULL, _("%sServer: %s%s %s[%s%s%s]"),
weechat_printf (NULL, _("%sServer: %s%s %s[%s%s%s]%s%s"),
IRC_COLOR_CHAT,
IRC_COLOR_CHAT_SERVER,
server->name,
@@ -164,61 +164,150 @@ irc_display_server (struct t_irc_server *server, int with_detail)
IRC_COLOR_CHAT,
(server->is_connected) ?
_("connected") : _("not connected"),
IRC_COLOR_CHAT_DELIMITERS);
IRC_COLOR_CHAT_DELIMITERS,
IRC_COLOR_CHAT,
(server->temp_server) ? _(" (temporary)") : "");
weechat_printf (NULL, " autoconnect . . . . : %s",
(server->autoconnect) ? _("on") : _("off"));
weechat_printf (NULL, " autoreconnect . . . : %s",
(server->autoreconnect) ? _("on") : _("off"));
weechat_printf (NULL, " autoreconnect_delay : %d %s",
server->autoreconnect_delay,
NG_("second", "seconds", server->autoreconnect_delay));
weechat_printf (NULL, " addresses . . . . . : %s",
(server->addresses && server->addresses[0]) ?
server->addresses : "");
weechat_printf (NULL, " ipv6 . . . . . . . : %s",
(server->ipv6) ? _("on") : _("off"));
weechat_printf (NULL, " ssl . . . . . . . . : %s",
(server->ssl) ? _("on") : _("off"));
weechat_printf (NULL, " password . . . . . : %s",
(server->password && server->password[0]) ?
_("(hidden)") : "");
weechat_printf (NULL, " nicks . . . . . . . : %s",
(server->nicks && server->nicks[0]) ?
server->nicks : "");
weechat_printf (NULL, " username . . . . . : %s",
(server->username && server->username[0]) ?
server->username : "");
weechat_printf (NULL, " realname . . . . . : %s",
(server->realname && server->realname[0]) ?
server->realname : "");
weechat_printf (NULL, " local_hostname . . : %s",
(server->local_hostname && server->local_hostname[0]) ?
server->local_hostname : "");
if (server->command && server->command[0])
string = strdup (server->command);
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_ADDRESSES]))
weechat_printf (NULL, " addresses. . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_ADDRESSES));
else
string = NULL;
if (string)
weechat_printf (NULL, " addresses. . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_ADDRESSES]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_PROXY]))
weechat_printf (NULL, " proxy. . . . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_PROXY));
else
weechat_printf (NULL, " proxy. . . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_PROXY]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_IPV6]))
weechat_printf (NULL, " ipv6 . . . . . . . . : (%s)",
(IRC_SERVER_OPTION_BOOLEAN(server, IRC_SERVER_OPTION_IPV6)) ?
_("on") : _("off"));
else
weechat_printf (NULL, " ipv6 . . . . . . . . : %s%s",
IRC_COLOR_CHAT_HOST,
weechat_config_boolean (server->options[IRC_SERVER_OPTION_IPV6]) ?
_("on") : _("off"));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_SSL]))
weechat_printf (NULL, " ssl. . . . . . . . . : (%s)",
(IRC_SERVER_OPTION_BOOLEAN(server, IRC_SERVER_OPTION_SSL)) ?
_("on") : _("off"));
else
weechat_printf (NULL, " ssl. . . . . . . . . : %s%s",
IRC_COLOR_CHAT_HOST,
weechat_config_boolean (server->options[IRC_SERVER_OPTION_SSL]) ?
_("on") : _("off"));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_PASSWORD]))
weechat_printf (NULL, " password . . . . . . : %s",
_("(hidden)"));
else
weechat_printf (NULL, " password . . . . . . : %s%s",
IRC_COLOR_CHAT_HOST,
_("(hidden)"));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_AUTOCONNECT]))
weechat_printf (NULL, " autoconnect. . . . . : (%s)",
(IRC_SERVER_OPTION_BOOLEAN(server, IRC_SERVER_OPTION_AUTOCONNECT)) ?
_("on") : _("off"));
else
weechat_printf (NULL, " autoconnect. . . . . : %s%s",
IRC_COLOR_CHAT_HOST,
weechat_config_boolean (server->options[IRC_SERVER_OPTION_AUTOCONNECT]) ?
_("on") : _("off"));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_AUTORECONNECT]))
weechat_printf (NULL, " autoreconnect. . . . : (%s)",
(IRC_SERVER_OPTION_BOOLEAN(server, IRC_SERVER_OPTION_AUTORECONNECT)) ?
_("on") : _("off"));
else
weechat_printf (NULL, " autoreconnect. . . . : %s%s",
IRC_COLOR_CHAT_HOST,
weechat_config_boolean (server->options[IRC_SERVER_OPTION_AUTORECONNECT]) ?
_("on") : _("off"));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_AUTORECONNECT_DELAY]))
weechat_printf (NULL, " autoreconnect_delay. : (%d %s)",
IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_AUTORECONNECT_DELAY),
NG_("second", "seconds", IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_AUTORECONNECT_DELAY)));
else
weechat_printf (NULL, " autoreconnect_delay. : %s%d %s",
IRC_COLOR_CHAT_HOST,
weechat_config_integer (server->options[IRC_SERVER_OPTION_AUTORECONNECT_DELAY]),
NG_("second", "seconds", weechat_config_integer (server->options[IRC_SERVER_OPTION_AUTORECONNECT_DELAY])));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_NICKS]))
weechat_printf (NULL, " nicks. . . . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_NICKS));
else
weechat_printf (NULL, " nicks. . . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_NICKS]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_USERNAME]))
weechat_printf (NULL, " username . . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_USERNAME));
else
weechat_printf (NULL, " username . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_USERNAME]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_REALNAME]))
weechat_printf (NULL, " realname . . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_REALNAME));
else
weechat_printf (NULL, " realname . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_REALNAME]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_LOCAL_HOSTNAME]))
weechat_printf (NULL, " local_hostname . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_LOCAL_HOSTNAME));
else
weechat_printf (NULL, " local_hostname . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_LOCAL_HOSTNAME]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_COMMAND]))
{
if (weechat_config_boolean (irc_config_look_hide_nickserv_pwd))
string = strdup (IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_COMMAND));
if (string && weechat_config_boolean (irc_config_look_hide_nickserv_pwd))
irc_display_hide_password (string, 1);
weechat_printf (NULL, " command . . . . . . : %s",
string);
free (string);
weechat_printf (NULL, " command. . . . . . . : ('%s')",
(string) ? string : IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_COMMAND));
if (string)
free (string);
}
else
{
weechat_printf (NULL, " command . . . . . . : %s",
(server->command && server->command[0]) ?
server->command : "");
string = strdup (weechat_config_string (server->options[IRC_SERVER_OPTION_COMMAND]));
if (string && weechat_config_boolean (irc_config_look_hide_nickserv_pwd))
irc_display_hide_password (string, 1);
weechat_printf (NULL, " command. . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
(string) ? string : weechat_config_string (server->options[IRC_SERVER_OPTION_COMMAND]));
if (string)
free (string);
}
weechat_printf (NULL, " command_delay . . . : %d %s",
server->command_delay,
NG_("second", "seconds", server->command_delay));
weechat_printf (NULL, " autojoin . . . . . : %s",
(server->autojoin && server->autojoin[0]) ?
server->autojoin : "");
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_COMMAND_DELAY]))
weechat_printf (NULL, " command_delay. . . . : (%d %s)",
IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_COMMAND_DELAY),
NG_("second", "seconds", IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_COMMAND_DELAY)));
else
weechat_printf (NULL, " command_delay. . . . : %s%d %s",
IRC_COLOR_CHAT_HOST,
weechat_config_integer (server->options[IRC_SERVER_OPTION_COMMAND_DELAY]),
NG_("second", "seconds", weechat_config_integer (server->options[IRC_SERVER_OPTION_COMMAND_DELAY])));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_AUTOJOIN]))
weechat_printf (NULL, " autojoin . . . . . . : ('%s')",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_AUTOJOIN));
else
weechat_printf (NULL, " autojoin . . . . . . : %s'%s'",
IRC_COLOR_CHAT_HOST,
weechat_config_string (server->options[IRC_SERVER_OPTION_AUTOJOIN]));
if (weechat_config_option_is_null (server->options[IRC_SERVER_OPTION_AUTOREJOIN]))
weechat_printf (NULL, " autorejoin . . . . . : (%s)",
(IRC_SERVER_OPTION_BOOLEAN(server, IRC_SERVER_OPTION_AUTOREJOIN)) ?
_("on") : _("off"));
else
weechat_printf (NULL, " autorejoin . . . . . : %s%s",
IRC_COLOR_CHAT_HOST,
weechat_config_boolean (server->options[IRC_SERVER_OPTION_AUTOREJOIN]) ?
_("on") : _("off"));
}
else
{
@@ -226,7 +315,7 @@ irc_display_server (struct t_irc_server *server, int with_detail)
{
num_channels = irc_server_get_channel_count (server);
num_pv = irc_server_get_pv_count (server);
weechat_printf (NULL, " %s %s%s %s[%s%s%s]%s, %d %s, %d pv",
weechat_printf (NULL, " %s %s%s %s[%s%s%s]%s%s, %d %s, %d pv",
(server->is_connected) ? "*" : " ",
IRC_COLOR_CHAT_SERVER,
server->name,
@@ -236,16 +325,18 @@ irc_display_server (struct t_irc_server *server, int with_detail)
_("connected") : _("not connected"),
IRC_COLOR_CHAT_DELIMITERS,
IRC_COLOR_CHAT,
(server->temp_server) ? _(" (temporary)") : "",
num_channels,
NG_("channel", "channels", num_channels),
num_pv);
}
else
{
weechat_printf (NULL, " %s %s%s",
(server->is_connected) ? "*" : " ",
weechat_printf (NULL, " %s%s%s%s",
IRC_COLOR_CHAT_SERVER,
server->name);
server->name,
IRC_COLOR_CHAT,
(server->temp_server) ? _(" (temporary)") : "");
}
}
}
+10 -6
View File
@@ -456,7 +456,7 @@ irc_protocol_cmd_kick (struct t_irc_server *server, const char *command,
/* my nick was kicked => free all nicks, channel is not active any
more */
irc_nick_free_all (ptr_channel);
if (server->autorejoin)
if (IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_AUTOREJOIN))
irc_command_join_server (server, ptr_channel->name);
}
else
@@ -1589,7 +1589,8 @@ irc_protocol_cmd_privmsg (struct t_irc_server *server, const char *command,
weechat_infolist_new_var_string (item, "local_nick", server->nick);
weechat_infolist_new_var_string (item, "filename", pos_file);
weechat_infolist_new_var_string (item, "size", pos_size);
weechat_infolist_new_var_string (item, "proxy", server->proxy);
weechat_infolist_new_var_string (item, "proxy",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_PROXY));
weechat_infolist_new_var_string (item, "address", pos_addr);
weechat_infolist_new_var_integer (item, "port", atoi (pos_port));
weechat_hook_signal_send ("xfer_add",
@@ -1922,7 +1923,8 @@ irc_protocol_cmd_privmsg (struct t_irc_server *server, const char *command,
weechat_infolist_new_var_string (item, "type", "chat_recv");
weechat_infolist_new_var_string (item, "remote_nick", nick);
weechat_infolist_new_var_string (item, "local_nick", server->nick);
weechat_infolist_new_var_string (item, "proxy", server->proxy);
weechat_infolist_new_var_string (item, "proxy",
IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_PROXY));
weechat_infolist_new_var_string (item, "address", pos_addr);
weechat_infolist_new_var_integer (item, "port", atoi (pos_port));
weechat_hook_signal_send ("xfer_add",
@@ -2382,6 +2384,7 @@ irc_protocol_cmd_001 (struct t_irc_server *server, const char *command,
{
char **commands, **ptr_cmd, *vars_replaced;
char *away_msg;
const char *ptr_command;
/* 001 message looks like:
:server 001 mynick :Welcome to the dancer-ircd Network
@@ -2416,10 +2419,11 @@ irc_protocol_cmd_001 (struct t_irc_server *server, const char *command,
WEECHAT_HOOK_SIGNAL_STRING, server->name);
/* execute command when connected */
if (server->command && server->command[0])
ptr_command = IRC_SERVER_OPTION_STRING(server, IRC_SERVER_OPTION_COMMAND);
if (ptr_command && ptr_command[0])
{
/* splitting command on ';' which can be escaped with '\;' */
commands = weechat_string_split_command (server->command, ';');
commands = weechat_string_split_command (ptr_command, ';');
if (commands)
{
for (ptr_cmd = commands; *ptr_cmd; ptr_cmd++)
@@ -2434,7 +2438,7 @@ irc_protocol_cmd_001 (struct t_irc_server *server, const char *command,
weechat_string_free_splitted_command (commands);
}
if (server->command_delay > 0)
if (IRC_SERVER_OPTION_INTEGER(server, IRC_SERVER_OPTION_COMMAND_DELAY) > 0)
server->command_time = time (NULL) + 1;
else
irc_server_autojoin_channels (server);
File diff suppressed because it is too large Load Diff
+52 -27
View File
@@ -31,6 +31,49 @@
#define NI_MAXHOST 256
#endif
enum t_irc_server_option
{
IRC_SERVER_OPTION_ADDRESSES = 0,
IRC_SERVER_OPTION_PROXY,
IRC_SERVER_OPTION_IPV6,
IRC_SERVER_OPTION_SSL,
IRC_SERVER_OPTION_PASSWORD,
IRC_SERVER_OPTION_AUTOCONNECT,
IRC_SERVER_OPTION_AUTORECONNECT,
IRC_SERVER_OPTION_AUTORECONNECT_DELAY,
IRC_SERVER_OPTION_NICKS,
IRC_SERVER_OPTION_USERNAME,
IRC_SERVER_OPTION_REALNAME,
IRC_SERVER_OPTION_LOCAL_HOSTNAME,
IRC_SERVER_OPTION_COMMAND,
IRC_SERVER_OPTION_COMMAND_DELAY,
IRC_SERVER_OPTION_AUTOJOIN,
IRC_SERVER_OPTION_AUTOREJOIN,
/* number of server options */
IRC_SERVER_NUM_OPTIONS,
};
#define IRC_SERVER_OPTION_BOOLEAN(__server, __index) \
((!weechat_config_option_is_null (__server->options[__index])) ? \
weechat_config_boolean(__server->options[__index]) : \
((!weechat_config_option_is_null (irc_config_server_default[__index])) ? \
weechat_config_boolean(irc_config_server_default[__index]) \
: weechat_config_boolean_default(irc_config_server_default[__index])))
#define IRC_SERVER_OPTION_INTEGER(__server, __index) \
((!weechat_config_option_is_null (__server->options[__index])) ? \
weechat_config_integer(__server->options[__index]) : \
((!weechat_config_option_is_null (irc_config_server_default[__index])) ? \
weechat_config_integer(irc_config_server_default[__index]) \
: weechat_config_integer_default(irc_config_server_default[__index])))
#define IRC_SERVER_OPTION_STRING(__server, __index) \
((!weechat_config_option_is_null (__server->options[__index])) ? \
weechat_config_string(__server->options[__index]) : \
((!weechat_config_option_is_null (irc_config_server_default[__index])) ? \
weechat_config_string(irc_config_server_default[__index]) \
: weechat_config_string_default(irc_config_server_default[__index])))
#define IRC_SERVER_DEFAULT_PORT 6667
#define IRC_SERVER_DEFAULT_PREFIXES_LIST "@%+~&!-"
#define IRC_SERVER_DEFAULT_NICKS "weechat1,weechat2,weechat3," \
@@ -59,25 +102,12 @@ struct t_irc_outqueue
struct t_irc_server
{
/* user choices */
char *name; /* internal name of server */
int autoconnect; /* = 1 if auto connect at startup */
int autoreconnect; /* = 1 if auto reco when disconnected */
int autoreconnect_delay; /* delay before trying again reconnect */
char *proxy; /* proxy used for this server (optional) */
char *addresses; /* server addresses (IP/name with port) */
int ipv6; /* use IPv6 protocol */
int ssl; /* SSL protocol */
char *password; /* password for server */
char *nicks; /* nicknames as one string */
char *username; /* user name */
char *realname; /* real name */
char *local_hostname; /* custom local hostname */
char *command; /* command to run once connected */
int command_delay; /* delay after execution of command */
char *autojoin; /* channels to automatically join */
int autorejoin; /* auto rejoin channels when kicked */
char *name; /* internal name of server */
struct t_config_option *options[IRC_SERVER_NUM_OPTIONS];
/* internal vars */
int temp_server; /* temporary server (not saved) */
int reloading_from_config; /* 1 if reloading from config file */
int reloaded_from_config; /* 1 if reloaded from config file */
int addresses_count; /* number of addresses */
char **addresses_array; /* exploded addresses */
@@ -138,21 +168,16 @@ extern const int gnutls_cert_type_prio[];
extern const int gnutls_prot_prio[];
#endif
extern struct t_irc_message *irc_recv_msgq, *irc_msgq_last_msg;
extern char *irc_server_option_string[];
extern char *irc_server_option_default[];
extern int irc_server_valid (struct t_irc_server *server);
extern int irc_server_search_option (const char *option_name);
extern char *irc_server_get_name_without_port (const char *name);
extern void irc_server_new_option (struct t_irc_server *server,
int index_option,
const char *value);
extern void irc_server_set_addresses (struct t_irc_server *server,
const char *addresses);
extern void irc_server_set_nicks (struct t_irc_server *server, const char *nicks);
extern void irc_server_set_with_option (struct t_irc_server *server,
int index_option,
struct t_config_option *option);
extern void irc_server_set_nick (struct t_irc_server *server, const char *nick);
extern void irc_server_init (struct t_irc_server *server);
extern struct t_irc_server *irc_server_alloc (const char *name);
extern int irc_server_alloc_with_url (const char *irc_url);
extern void irc_server_free_all ();
@@ -172,8 +197,8 @@ extern struct t_irc_server *irc_server_new (const char *name, int autoconnect,
int command_delay,
const char *autojoin,
int autorejoin);
extern struct t_irc_server *irc_server_duplicate (struct t_irc_server *server,
const char *new_name);
extern struct t_irc_server *irc_server_copy (struct t_irc_server *server,
const char *new_name);
extern int irc_server_rename (struct t_irc_server *server, const char *new_name);
extern void irc_server_send_signal (struct t_irc_server *server,
const char *signal, const char *command,
+2
View File
@@ -184,6 +184,8 @@ irc_upgrade_read_cb (int object_id,
irc_upgrade_current_server = irc_server_search (weechat_infolist_string (infolist, "name"));
if (irc_upgrade_current_server)
{
irc_upgrade_current_server->temp_server =
weechat_infolist_integer (infolist, "temp_server");
irc_upgrade_current_server->buffer = NULL;
buffer_name = weechat_infolist_string (infolist, "buffer_name");
if (buffer_name && buffer_name[0])
+6 -2
View File
@@ -193,12 +193,16 @@ weechat_plugin_end (struct t_weechat_plugin *plugin)
if (irc_hook_timer_check_away)
weechat_unhook (irc_hook_timer_check_away);
irc_config_write ();
if (irc_signal_upgrade_received)
{
irc_config_write (1);
irc_upgrade_save ();
}
else
{
irc_config_write (0);
irc_server_disconnect_all ();
}
irc_server_free_all ();
+9 -9
View File
@@ -148,7 +148,7 @@ logger_config_level_create_option (void *data,
option_name, "integer",
_("logging level for this buffer (0 = logging disabled, "
"1 = a few messages (most important) .. 9 = all messages)"),
NULL, 0, 9, "9", value, NULL, NULL,
NULL, 0, 9, "9", value, 0, NULL, NULL,
&logger_config_level_change, NULL,
NULL, NULL);
rc = (ptr_option) ?
@@ -275,7 +275,7 @@ logger_config_mask_create_option (void *data,
option_name, "string",
_("file mask for log file; local buffer variables are "
"permitted"),
NULL, 0, 0, "", value, NULL, NULL,
NULL, 0, 0, "", value, 0, NULL, NULL,
&logger_config_mask_change, NULL,
NULL, NULL);
rc = (ptr_option) ?
@@ -339,7 +339,7 @@ logger_config_init ()
"backlog", "integer",
N_("maximum number of lines to display from log file when creating "
"new buffer (0 = no backlog)"),
NULL, 0, INT_MAX, "20", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "20", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* file */
ptr_section = weechat_config_new_section (logger_config_file, "file",
@@ -358,19 +358,19 @@ logger_config_init ()
"auto_log", "boolean",
N_("automatically save content of buffers to files (unless a buffer "
"disables log)"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
logger_config_file_name_lower_case = weechat_config_new_option (
logger_config_file, ptr_section,
"name_lower_case", "boolean",
N_("use only lower case for log filenames"),
NULL, 0, 0, "on", NULL, NULL, NULL,
NULL, 0, 0, "on", NULL, 0, NULL, NULL,
&logger_config_change_file_option_restart_log, NULL, NULL, NULL);
logger_config_file_path = weechat_config_new_option (
logger_config_file, ptr_section,
"path", "string",
N_("path for WeeChat log files ('%h' will be replaced by WeeChat "
"home, ~/.weechat by default)"),
NULL, 0, 0, "%h/logs/", NULL, NULL, NULL,
NULL, 0, 0, "%h/logs/", NULL, 0, NULL, NULL,
&logger_config_change_file_option_restart_log, NULL, NULL, NULL);
logger_config_file_mask = weechat_config_new_option (
logger_config_file, ptr_section,
@@ -378,20 +378,20 @@ logger_config_init ()
N_("default file name mask for log files (format is 'directory/to/file' "
"or 'file', without first '/' because 'path' option is used to "
"build complete path to file); local buffer variables are permitted"),
NULL, 0, 0, "$plugin.$name.weechatlog", NULL, NULL, NULL,
NULL, 0, 0, "$plugin.$name.weechatlog", NULL, 0, NULL, NULL,
&logger_config_change_file_option_restart_log, NULL, NULL, NULL);
logger_config_file_info_lines = weechat_config_new_option (
logger_config_file, ptr_section,
"info_lines", "boolean",
N_("write information line in log file when log starts or ends for a "
"buffer"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
logger_config_file_time_format = weechat_config_new_option (
logger_config_file, ptr_section,
"time_format", "string",
N_("timestamp used in log files (see man strftime for date/time "
"specifiers)"),
NULL, 0, 0, "%Y-%m-%d %H:%M:%S", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "%Y-%m-%d %H:%M:%S", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
/* level */
ptr_section = weechat_config_new_section (logger_config_file, "level",
+3 -3
View File
@@ -987,11 +987,11 @@ weechat_plugin_init (struct t_weechat_plugin *plugin, int argc, char *argv[])
" disable logging for current buffer:\n"
" /logger disable\n\n"
" set level to 3 for all IRC buffers:\n"
" /set logger.level.irc = 3\n"
" /set logger.level.irc 3\n"
" disable logging for main WeeChat buffer:\n"
" /set logger.level.core.weechat = 0\n"
" /set logger.level.core.weechat 0\n"
" use a directory per IRC server and a file per channel inside:\n"
" /set logger.mask.irc = $server/$channel.weechatlog\n\n"
" /set logger.mask.irc \"$server/$channel.weechatlog\"\n\n"
"Log levels used by IRC plugin:\n"
" 1: user message, notice, private\n"
" 2: nick change\n"
+1 -1
View File
@@ -263,7 +263,7 @@ notify_config_create_option (void *data, struct t_config_file *config_file,
config_file, section,
option_name, "integer", NULL,
"none|highlight|message|all",
0, 0, "", value, NULL, NULL, NULL, NULL, NULL, NULL);
0, 0, "", value, 0, NULL, NULL, NULL, NULL, NULL, NULL);
rc = (ptr_option) ?
WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE : WEECHAT_CONFIG_OPTION_SET_ERROR;
}
+2 -2
View File
@@ -96,7 +96,7 @@ plugin_config_set_internal (const char *option, const char *value)
ptr_option = config_file_new_option (
plugin_config_file, plugin_config_section_var,
option, "string", NULL,
NULL, 0, 0, "", value, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", value, 0, NULL, NULL, NULL, NULL, NULL, NULL);
rc = (ptr_option) ? WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE : WEECHAT_CONFIG_OPTION_SET_ERROR;
}
@@ -164,7 +164,7 @@ plugin_config_create_option (void *data, struct t_config_file *config_file,
ptr_option = config_file_new_option (
config_file, section,
option_name, "string", NULL,
NULL, 0, 0, "", value, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", value, 0, NULL, NULL, NULL, NULL, NULL, NULL);
return (ptr_option) ?
WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE : WEECHAT_CONFIG_OPTION_SET_ERROR;
+7
View File
@@ -397,13 +397,20 @@ plugin_load (const char *filename)
new_plugin->config_string_to_boolean = &config_file_string_to_boolean;
new_plugin->config_option_reset = &config_file_option_reset;
new_plugin->config_option_set = &config_file_option_set;
new_plugin->config_option_set_null = &config_file_option_set_null;
new_plugin->config_option_unset = &config_file_option_unset;
new_plugin->config_option_rename = &config_file_option_rename;
new_plugin->config_option_get_pointer = &config_file_option_get_pointer;
new_plugin->config_option_is_null = &config_file_option_is_null;
new_plugin->config_boolean = &config_file_option_boolean;
new_plugin->config_boolean_default = &config_file_option_boolean_default;
new_plugin->config_integer = &config_file_option_integer;
new_plugin->config_integer_default = &config_file_option_integer_default;
new_plugin->config_string = &config_file_option_string;
new_plugin->config_string_default = &config_file_option_string_default;
new_plugin->config_color = &config_file_option_color;
new_plugin->config_color_default = &config_file_option_color_default;
new_plugin->config_write_option = &config_file_write_option;
new_plugin->config_write_line = &config_file_write_line;
new_plugin->config_write = &config_file_write;
new_plugin->config_read = &config_file_read;
+10 -10
View File
@@ -106,7 +106,7 @@ relay_config_init ()
relay_config_file, ptr_section,
"auto_open_buffer", "boolean",
N_("auto open relay buffer when a new client is connecting"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (relay_config_file, "color",
0, 0,
@@ -123,49 +123,49 @@ relay_config_init ()
relay_config_file, ptr_section,
"text", "color",
N_("text color"),
NULL, 0, 0, "default", NULL,
NULL, 0, 0, "default", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_text_bg = weechat_config_new_option (
relay_config_file, ptr_section,
"text_bg", "color",
N_("background color"),
NULL, 0, 0, "default", NULL,
NULL, 0, 0, "default", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_text_selected = weechat_config_new_option (
relay_config_file, ptr_section,
"text_selected", "color",
N_("text color of selected client line"),
NULL, 0, 0, "white", NULL,
NULL, 0, 0, "white", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_status[RELAY_STATUS_CONNECTING] = weechat_config_new_option (
relay_config_file, ptr_section,
"status_connecting", "color",
N_("text color for \"connecting\" status"),
NULL, 0, 0, "yellow", NULL,
NULL, 0, 0, "yellow", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_status[RELAY_STATUS_WAITING_AUTH] = weechat_config_new_option (
relay_config_file, ptr_section,
"status_waiting_auth", "color",
N_("text color for \"waiting authentication\" status"),
NULL, 0, 0, "brown", NULL,
NULL, 0, 0, "brown", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_status[RELAY_STATUS_CONNECTED] = weechat_config_new_option (
relay_config_file, ptr_section,
"status_active", "color",
N_("text color for \"connected\" status"),
NULL, 0, 0, "lightblue", NULL,
NULL, 0, 0, "lightblue", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_status[RELAY_STATUS_AUTH_FAILED] = weechat_config_new_option (
relay_config_file, ptr_section,
"status_auth_failed", "color",
N_("text color for \"authentication failed\" status"),
NULL, 0, 0, "lightred", NULL,
NULL, 0, 0, "lightred", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
relay_config_color_status[RELAY_STATUS_DISCONNECTED] = weechat_config_new_option (
relay_config_file, ptr_section,
"status_disconnected", "color",
N_("text color for \"disconnected\" status"),
NULL, 0, 0, "lightred", NULL,
NULL, 0, 0, "lightred", NULL, 0,
NULL, NULL, &relay_config_refresh_cb, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (relay_config_file, "network",
@@ -185,7 +185,7 @@ relay_config_init ()
N_("port number (or range of ports) that relay plugin listens on "
"(syntax: a single port, ie. 5000 or a port "
"range, ie. 5000-5015)"),
NULL, 0, 0, "22373-22400", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "22373-22400", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
return 1;
}
+176 -17
View File
@@ -1461,7 +1461,7 @@ weechat_lua_api_config_new_option (lua_State *L)
const char *string_values, *default_value, *value;
const char *function_check_value, *function_change, *function_delete;
char *result;
int n, min, max;
int n, min, max, null_value_allowed;
/* make C compiler happy */
(void) L;
@@ -1482,28 +1482,30 @@ weechat_lua_api_config_new_option (lua_State *L)
max = 0;
default_value = NULL;
value = NULL;
null_value_allowed = 0;
function_check_value = NULL;
function_change = NULL;
function_delete = NULL;
n = lua_gettop (lua_current_interpreter);
if (n < 13)
if (n < 14)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_new_option");
LUA_RETURN_EMPTY;
}
config_file = lua_tostring (lua_current_interpreter, -13);
section = lua_tostring (lua_current_interpreter, -12);
name = lua_tostring (lua_current_interpreter, -11);
type = lua_tostring (lua_current_interpreter, -10);
description = lua_tostring (lua_current_interpreter, -9);
string_values = lua_tostring (lua_current_interpreter, -8);
min = lua_tonumber (lua_current_interpreter, -7);
max = lua_tonumber (lua_current_interpreter, -6);
default_value = lua_tostring (lua_current_interpreter, -5);
value = lua_tostring (lua_current_interpreter, -4);
config_file = lua_tostring (lua_current_interpreter, -14);
section = lua_tostring (lua_current_interpreter, -13);
name = lua_tostring (lua_current_interpreter, -12);
type = lua_tostring (lua_current_interpreter, -11);
description = lua_tostring (lua_current_interpreter, -10);
string_values = lua_tostring (lua_current_interpreter, -9);
min = lua_tonumber (lua_current_interpreter, -8);
max = lua_tonumber (lua_current_interpreter, -7);
default_value = lua_tostring (lua_current_interpreter, -6);
value = lua_tostring (lua_current_interpreter, -5);
null_value_allowed = lua_tonumber (lua_current_interpreter, -4);
function_check_value = lua_tostring (lua_current_interpreter, -3);
function_change = lua_tostring (lua_current_interpreter, -2);
function_delete = lua_tostring (lua_current_interpreter, -1);
@@ -1520,6 +1522,7 @@ weechat_lua_api_config_new_option (lua_State *L)
max,
default_value,
value,
null_value_allowed,
&weechat_lua_api_config_option_check_value_cb,
function_check_value,
&weechat_lua_api_config_option_change_cb,
@@ -1664,7 +1667,7 @@ weechat_lua_api_config_option_set (lua_State *L)
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set");
LUA_RETURN_INT(0);
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = NULL;
@@ -1676,7 +1679,7 @@ weechat_lua_api_config_option_set (lua_State *L)
if (n < 3)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
LUA_RETURN_INT(0);
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = lua_tostring (lua_current_interpreter, -3);
@@ -1690,6 +1693,46 @@ weechat_lua_api_config_option_set (lua_State *L)
LUA_RETURN_INT(rc);
}
/*
* weechat_lua_api_config_option_set_null: set null (undefined) value for
* option
*/
static int
weechat_lua_api_config_option_set_null (lua_State *L)
{
const char *option;
int n, run_callback, rc;
/* make C compiler happy */
(void) L;
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set_null");
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = NULL;
run_callback = 0;
n = lua_gettop (lua_current_interpreter);
if (n < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = lua_tostring (lua_current_interpreter, -2);
run_callback = lua_tonumber (lua_current_interpreter, -1);
rc = weechat_config_option_set_null (script_str2ptr (option),
run_callback);
LUA_RETURN_INT(rc);
}
/*
* weechat_lua_api_config_option_unset: unset an option
*/
@@ -1706,7 +1749,7 @@ weechat_lua_api_config_option_unset (lua_State *L)
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_unset");
LUA_RETURN_INT(0);
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
option = NULL;
@@ -1716,7 +1759,7 @@ weechat_lua_api_config_option_unset (lua_State *L)
if (n < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_unset");
LUA_RETURN_INT(0);
LUA_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
option = lua_tostring (lua_current_interpreter, -1);
@@ -1741,7 +1784,7 @@ weechat_lua_api_config_option_rename (lua_State *L)
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_rename");;
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_rename");
LUA_RETURN_ERROR;
}
@@ -1765,6 +1808,79 @@ weechat_lua_api_config_option_rename (lua_State *L)
LUA_RETURN_OK;
}
/*
* weechat_lua_api_config_option_is_null: return 1 if value of option is null
*/
static int
weechat_lua_api_config_option_is_null (lua_State *L)
{
const char *option;
int n, value;
/* make C compiler happy */
(void) L;
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_is_null");
LUA_RETURN_INT(1);
}
option = NULL;
n = lua_gettop (lua_current_interpreter);
if (n < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_is_null");
LUA_RETURN_INT(1);
}
option = lua_tostring (lua_current_interpreter, -1);
value = weechat_config_option_is_null (script_str2ptr (option));
LUA_RETURN_INT(value);
}
/*
* weechat_lua_api_config_option_default_is_null: return 1 if default value of
* option is null
*/
static int
weechat_lua_api_config_option_default_is_null (lua_State *L)
{
const char *option;
int n, value;
/* make C compiler happy */
(void) L;
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_default_is_null");
LUA_RETURN_INT(1);
}
option = NULL;
n = lua_gettop (lua_current_interpreter);
if (n < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_default_is_null");
LUA_RETURN_INT(1);
}
option = lua_tostring (lua_current_interpreter, -1);
value = weechat_config_option_default_is_null (script_str2ptr (option));
LUA_RETURN_INT(value);
}
/*
* weechat_lua_api_config_boolean: return boolean value of option
*/
@@ -1909,6 +2025,45 @@ weechat_lua_api_config_color (lua_State *L)
LUA_RETURN_STRING(result);
}
/*
* weechat_lua_api_config_write_option: write an option in configuration file
*/
static int
weechat_lua_api_config_write_option (lua_State *L)
{
const char *config_file, *option;
int n;
/* make C compiler happy */
(void) L;
if (!lua_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_write_option");
LUA_RETURN_ERROR;
}
config_file = NULL;
option = NULL;
n = lua_gettop (lua_current_interpreter);
if (n < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_write_option");
LUA_RETURN_ERROR;
}
config_file = lua_tostring (lua_current_interpreter, -2);
option = lua_tostring (lua_current_interpreter, -1);
weechat_config_write_option (script_str2ptr (config_file),
script_str2ptr (option));
LUA_RETURN_OK;
}
/*
* weechat_lua_api_config_write_line: write a line in configuration file
*/
@@ -5880,12 +6035,16 @@ const struct luaL_reg weechat_lua_api_funcs[] = {
{ "config_string_to_boolean", &weechat_lua_api_config_string_to_boolean },
{ "config_option_reset", &weechat_lua_api_config_option_reset },
{ "config_option_set", &weechat_lua_api_config_option_set },
{ "config_option_set_null", &weechat_lua_api_config_option_set_null },
{ "config_option_unset", &weechat_lua_api_config_option_unset },
{ "config_option_rename", &weechat_lua_api_config_option_rename },
{ "config_option_is_null", &weechat_lua_api_config_option_is_null },
{ "config_option_default_is_null", &weechat_lua_api_config_option_default_is_null },
{ "config_boolean", &weechat_lua_api_config_boolean },
{ "config_integer", &weechat_lua_api_config_integer },
{ "config_string", &weechat_lua_api_config_string },
{ "config_color", &weechat_lua_api_config_color },
{ "config_write_option", &weechat_lua_api_config_write_option },
{ "config_write_line", &weechat_lua_api_config_write_line },
{ "config_write", &weechat_lua_api_config_write },
{ "config_read", &weechat_lua_api_config_read },
+136 -8
View File
@@ -1260,7 +1260,7 @@ static XS (XS_weechat_api_config_new_option)
PERL_RETURN_EMPTY;
}
if (items < 13)
if (items < 14)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_new_option");
PERL_RETURN_EMPTY;
@@ -1274,9 +1274,9 @@ static XS (XS_weechat_api_config_new_option)
string_values = SvPV (ST (5), PL_na);
default_value = SvPV (ST (8), PL_na);
value = SvPV (ST (9), PL_na);
function_check_value = SvPV (ST (10), PL_na);
function_change = SvPV (ST (11), PL_na);
function_delete = SvPV (ST (12), PL_na);
function_check_value = SvPV (ST (11), PL_na);
function_change = SvPV (ST (12), PL_na);
function_delete = SvPV (ST (13), PL_na);
result = script_ptr2str (script_api_config_new_option (weechat_perl_plugin,
perl_current_script,
script_str2ptr (config_file),
@@ -1289,6 +1289,7 @@ static XS (XS_weechat_api_config_new_option)
SvIV (ST (7)), /* max */
default_value,
value,
SvIV (ST (10)), /* null_value_allowed */
&weechat_perl_api_config_option_check_value_cb,
function_check_value,
&weechat_perl_api_config_option_change_cb,
@@ -1410,13 +1411,13 @@ static XS (XS_weechat_api_config_option_set)
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set");
PERL_RETURN_INT(0);
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (items < 3)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
PERL_RETURN_INT(0);
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = SvPV (ST (0), PL_na);
@@ -1428,6 +1429,38 @@ static XS (XS_weechat_api_config_option_set)
PERL_RETURN_INT(rc);
}
/*
* weechat::config_option_set_null: set null (undefined) value for option
*/
static XS (XS_weechat_api_config_option_set_null)
{
int rc;
char *option;
dXSARGS;
/* make C compiler happy */
(void) cv;
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set_null");
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (items < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = SvPV (ST (0), PL_na);
rc = weechat_config_option_set_null (script_str2ptr (option),
SvIV (ST (1))); /* run_callback */
PERL_RETURN_INT(rc);
}
/*
* weechat::config_option_unset: unset an option
*/
@@ -1444,13 +1477,13 @@ static XS (XS_weechat_api_config_option_unset)
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_unset");
PERL_RETURN_INT(0);
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
if (items < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_unset");
PERL_RETURN_INT(0);
PERL_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
option = SvPV (ST (0), PL_na);
@@ -1491,6 +1524,65 @@ static XS (XS_weechat_api_config_option_rename)
PERL_RETURN_OK;
}
/*
* weechat::config_option_is_null: return 1 if value of option is null
*/
static XS (XS_weechat_api_config_option_is_null)
{
int value;
dXSARGS;
/* make C compiler happy */
(void) cv;
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_is_null");
PERL_RETURN_INT(1);
}
if (items < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_is_null");
PERL_RETURN_INT(1);
}
value = weechat_config_option_is_null (script_str2ptr (SvPV (ST (0), PL_na))); /* option */
PERL_RETURN_INT(value);
}
/*
* weechat::config_option_default_is_null: return 1 if default value of option
* is null
*/
static XS (XS_weechat_api_config_option_default_is_null)
{
int value;
dXSARGS;
/* make C compiler happy */
(void) cv;
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_default_is_null");
PERL_RETURN_INT(1);
}
if (items < 1)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_default_is_null");
PERL_RETURN_INT(1);
}
value = weechat_config_option_default_is_null (script_str2ptr (SvPV (ST (0), PL_na))); /* option */
PERL_RETURN_INT(value);
}
/*
* weechat::config_boolean: return boolean value of option
*/
@@ -1607,6 +1699,38 @@ static XS (XS_weechat_api_config_color)
PERL_RETURN_STRING(result);
}
/*
* weechat::config_write_option: write an option in configuration file
*/
static XS (XS_weechat_api_config_write_option)
{
char *config_file, *option;
dXSARGS;
/* make C compiler happy */
(void) cv;
if (!perl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_write_option");
PERL_RETURN_ERROR;
}
if (items < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_write_option");
PERL_RETURN_ERROR;
}
config_file = SvPV (ST (0), PL_na);
option = SvPV (ST (1), PL_na);
weechat_config_write_option (script_str2ptr (config_file),
script_str2ptr (option));
PERL_RETURN_OK;
}
/*
* weechat::config_write_line: write a line in configuration file
*/
@@ -4624,12 +4748,16 @@ weechat_perl_api_init (pTHX)
newXS ("weechat::config_string_to_boolean", XS_weechat_api_config_string_to_boolean, "weechat");
newXS ("weechat::config_option_reset", XS_weechat_api_config_option_reset, "weechat");
newXS ("weechat::config_option_set", XS_weechat_api_config_option_set, "weechat");
newXS ("weechat::config_option_set_null", XS_weechat_api_config_option_set_null, "weechat");
newXS ("weechat::config_option_unset", XS_weechat_api_config_option_unset, "weechat");
newXS ("weechat::config_option_rename", XS_weechat_api_config_option_rename, "weechat");
newXS ("weechat::config_option_is_null", XS_weechat_api_config_option_is_null, "weechat");
newXS ("weechat::config_option_default_is_null", XS_weechat_api_config_option_default_is_null, "weechat");
newXS ("weechat::config_boolean", XS_weechat_api_config_boolean, "weechat");
newXS ("weechat::config_integer", XS_weechat_api_config_integer, "weechat");
newXS ("weechat::config_string", XS_weechat_api_config_string, "weechat");
newXS ("weechat::config_color", XS_weechat_api_config_color, "weechat");
newXS ("weechat::config_write_option", XS_weechat_api_config_write_option, "weechat");
newXS ("weechat::config_write_line", XS_weechat_api_config_write_line, "weechat");
newXS ("weechat::config_write", XS_weechat_api_config_write, "weechat");
newXS ("weechat::config_read", XS_weechat_api_config_read, "weechat");
+147 -8
View File
@@ -1316,7 +1316,7 @@ weechat_python_api_config_new_option (PyObject *self, PyObject *args)
char *config_file, *section, *name, *type, *description, *string_values;
char *default_value, *value, *result;
char *function_check_value, *function_change, *function_delete;
int min, max;
int min, max, null_value_allowed;
PyObject *object;
/* make C compiler happy */
@@ -1340,10 +1340,11 @@ weechat_python_api_config_new_option (PyObject *self, PyObject *args)
function_change = NULL;
function_delete = NULL;
if (!PyArg_ParseTuple (args, "ssssssiisssss", &config_file, &section, &name,
if (!PyArg_ParseTuple (args, "ssssssiississs", &config_file, &section, &name,
&type, &description, &string_values, &min, &max,
&default_value, &value, &function_check_value,
&function_change, &function_delete))
&default_value, &value, &null_value_allowed,
&function_check_value, &function_change,
&function_delete))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_new_option");
PYTHON_RETURN_EMPTY;
@@ -1361,6 +1362,7 @@ weechat_python_api_config_new_option (PyObject *self, PyObject *args)
max,
default_value,
value,
null_value_allowed,
&weechat_python_api_config_option_check_value_cb,
function_check_value,
&weechat_python_api_config_option_change_cb,
@@ -1489,7 +1491,7 @@ weechat_python_api_config_option_set (PyObject *self, PyObject *args)
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set");
PYTHON_RETURN_INT(0);
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = NULL;
@@ -1499,7 +1501,7 @@ weechat_python_api_config_option_set (PyObject *self, PyObject *args)
if (!PyArg_ParseTuple (args, "ssi", &option, &new_value, &run_callback))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
PYTHON_RETURN_INT(0);
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
rc = weechat_config_option_set (script_str2ptr (option),
@@ -1509,6 +1511,41 @@ weechat_python_api_config_option_set (PyObject *self, PyObject *args)
PYTHON_RETURN_INT(rc);
}
/*
* weechat_python_api_config_option_set_null: set null (undefined) value for
* option
*/
static PyObject *
weechat_python_api_config_option_set_null (PyObject *self, PyObject *args)
{
char *option;
int run_callback, rc;
/* make C compiler happy */
(void) self;
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set_null");
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = NULL;
run_callback = 0;
if (!PyArg_ParseTuple (args, "si", &option, &run_callback))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
rc = weechat_config_option_set_null (script_str2ptr (option),
run_callback);
PYTHON_RETURN_INT(rc);
}
/*
* weechat_python_api_config_option_unset: unset an option
*/
@@ -1525,7 +1562,7 @@ weechat_python_api_config_option_unset (PyObject *self, PyObject *args)
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_unset");
PYTHON_RETURN_INT(0);
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
option = NULL;
@@ -1533,7 +1570,7 @@ weechat_python_api_config_option_unset (PyObject *self, PyObject *args)
if (!PyArg_ParseTuple (args, "s", &option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_unset");
PYTHON_RETURN_INT(0);
PYTHON_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
rc = weechat_config_option_unset (script_str2ptr (option));
@@ -1574,6 +1611,71 @@ weechat_python_api_config_option_rename (PyObject *self, PyObject *args)
PYTHON_RETURN_OK;
}
/*
* weechat_python_api_config_option_is_null: return 1 if value of option is null
*/
static PyObject *
weechat_python_api_config_option_is_null (PyObject *self, PyObject *args)
{
char *option;
int value;
/* make C compiler happy */
(void) self;
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_is_null");
PYTHON_RETURN_INT(1);
}
option = NULL;
if (!PyArg_ParseTuple (args, "s", &option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_is_null");
PYTHON_RETURN_INT(1);
}
value = weechat_config_option_is_null (script_str2ptr (option));
PYTHON_RETURN_INT(value);
}
/*
* weechat_python_api_config_option_default_is_null: return 1 if default value
* of option is null
*/
static PyObject *
weechat_python_api_config_option_default_is_null (PyObject *self, PyObject *args)
{
char *option;
int value;
/* make C compiler happy */
(void) self;
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_default_is_null");
PYTHON_RETURN_INT(1);
}
option = NULL;
if (!PyArg_ParseTuple (args, "s", &option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_default_is_null");
PYTHON_RETURN_INT(1);
}
value = weechat_config_option_default_is_null (script_str2ptr (option));
PYTHON_RETURN_INT(value);
}
/*
* weechat_python_api_config_boolean: return boolean value of option
*/
@@ -1702,6 +1804,39 @@ weechat_python_api_config_color (PyObject *self, PyObject *args)
PYTHON_RETURN_STRING(result);
}
/*
* weechat_python_api_config_write_option: write an option in configuration file
*/
static PyObject *
weechat_python_api_config_write_option (PyObject *self, PyObject *args)
{
char *config_file, *option;
/* make C compiler happy */
(void) self;
if (!python_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_write_option");
PYTHON_RETURN_ERROR;
}
config_file = NULL;
option = NULL;
if (!PyArg_ParseTuple (args, "ss", &config_file, &option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_write_option");
PYTHON_RETURN_ERROR;
}
weechat_config_write_option (script_str2ptr (config_file),
script_str2ptr (option));
PYTHON_RETURN_OK;
}
/*
* weechat_python_api_config_write_line: write a line in configuration file
*/
@@ -4911,12 +5046,16 @@ PyMethodDef weechat_python_funcs[] =
{ "config_string_to_boolean", &weechat_python_api_config_string_to_boolean, METH_VARARGS, "" },
{ "config_option_reset", &weechat_python_api_config_option_reset, METH_VARARGS, "" },
{ "config_option_set", &weechat_python_api_config_option_set, METH_VARARGS, "" },
{ "config_option_set_null", &weechat_python_api_config_option_set_null, METH_VARARGS, "" },
{ "config_option_unset", &weechat_python_api_config_option_unset, METH_VARARGS, "" },
{ "config_option_rename", &weechat_python_api_config_option_rename, METH_VARARGS, "" },
{ "config_option_is_null", &weechat_python_api_config_option_is_null, METH_VARARGS, "" },
{ "config_option_default_is_null", &weechat_python_api_config_option_default_is_null, METH_VARARGS, "" },
{ "config_boolean", &weechat_python_api_config_boolean, METH_VARARGS, "" },
{ "config_integer", &weechat_python_api_config_integer, METH_VARARGS, "" },
{ "config_string", &weechat_python_api_config_string, METH_VARARGS, "" },
{ "config_color", &weechat_python_api_config_color, METH_VARARGS, "" },
{ "config_write_option", &weechat_python_api_config_write_option, METH_VARARGS, "" },
{ "config_write_line", &weechat_python_api_config_write_line, METH_VARARGS, "" },
{ "config_write", &weechat_python_api_config_write, METH_VARARGS, "" },
{ "config_read", &weechat_python_api_config_read, METH_VARARGS, "" },
+170 -8
View File
@@ -1477,7 +1477,7 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
VALUE section, VALUE name, VALUE type,
VALUE description, VALUE string_values,
VALUE min, VALUE max, VALUE default_value,
VALUE value,
VALUE value, VALUE null_value_allowed,
VALUE function_check_value,
VALUE function_change,
VALUE function_delete)
@@ -1485,7 +1485,7 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
char *c_config_file, *c_section, *c_name, *c_type, *c_description;
char *c_string_values, *c_default_value, *c_value, *result;
char *c_function_check_value, *c_function_change, *c_function_delete;
int c_min, c_max;
int c_min, c_max, c_null_value_allowed;
VALUE return_value;
/* make C compiler happy */
@@ -1507,13 +1507,14 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
c_max = 0;
c_default_value = NULL;
c_value = NULL;
c_null_value_allowed = 0;
c_function_check_value = NULL;
c_function_change = NULL;
c_function_delete = NULL;
if (NIL_P (config_file) || NIL_P (section) || NIL_P (name) || NIL_P (type)
|| NIL_P (description) || NIL_P (string_values)
|| NIL_P (default_value) || NIL_P (value)
|| NIL_P (default_value) || NIL_P (value) || NIL_P (null_value_allowed)
|| NIL_P (function_check_value) || NIL_P (function_change)
|| NIL_P (function_delete))
{
@@ -1531,6 +1532,7 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
Check_Type (max, T_FIXNUM);
Check_Type (default_value, T_STRING);
Check_Type (value, T_STRING);
Check_Type (null_value_allowed, T_FIXNUM);
Check_Type (function_check_value, T_STRING);
Check_Type (function_change, T_STRING);
Check_Type (function_delete, T_STRING);
@@ -1545,6 +1547,7 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
c_max = FIX2INT (max);
c_default_value = STR2CSTR (default_value);
c_value = STR2CSTR (value);
c_null_value_allowed = FIX2INT (null_value_allowed);
c_function_check_value = STR2CSTR (function_check_value);
c_function_change = STR2CSTR (function_change);
c_function_delete = STR2CSTR (function_delete);
@@ -1561,6 +1564,7 @@ weechat_ruby_api_config_new_option (VALUE class, VALUE config_file,
c_max,
c_default_value,
c_value,
c_null_value_allowed,
&weechat_ruby_api_config_option_check_value_cb,
c_function_check_value,
&weechat_ruby_api_config_option_change_cb,
@@ -1710,7 +1714,7 @@ weechat_ruby_api_config_option_set (VALUE class, VALUE option, VALUE new_value,
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set");
RUBY_RETURN_INT(0);
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
c_option = NULL;
@@ -1720,7 +1724,7 @@ weechat_ruby_api_config_option_set (VALUE class, VALUE option, VALUE new_value,
if (NIL_P (option) || NIL_P (new_value) || NIL_P (run_callback))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
RUBY_RETURN_INT(0);
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
Check_Type (option, T_STRING);
@@ -1738,6 +1742,48 @@ weechat_ruby_api_config_option_set (VALUE class, VALUE option, VALUE new_value,
RUBY_RETURN_INT(rc);
}
/*
* weechat_ruby_api_config_option_set_null: set null (undefined) value for
* option
*/
static VALUE
weechat_ruby_api_config_option_set_null (VALUE class, VALUE option,
VALUE run_callback)
{
char *c_option;
int c_run_callback, rc;
/* make C compiler happy */
(void) class;
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set_null");
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
c_option = NULL;
c_run_callback = 0;
if (NIL_P (option) || NIL_P (run_callback))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
Check_Type (option, T_STRING);
Check_Type (run_callback, T_FIXNUM);
c_option = STR2CSTR (option);
c_run_callback = FIX2INT (run_callback);
rc = weechat_config_option_set_null (script_str2ptr (c_option),
c_run_callback);
RUBY_RETURN_INT(rc);
}
/*
* weechat_ruby_api_config_option_unset: unset an option
*/
@@ -1754,7 +1800,7 @@ weechat_ruby_api_config_option_unset (VALUE class, VALUE option)
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_unset");
RUBY_RETURN_INT(0);
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
c_option = NULL;
@@ -1762,7 +1808,7 @@ weechat_ruby_api_config_option_unset (VALUE class, VALUE option)
if (NIL_P (option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_unset");
RUBY_RETURN_INT(0);
RUBY_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
Check_Type (option, T_STRING);
@@ -1814,6 +1860,78 @@ weechat_ruby_api_config_option_rename (VALUE class, VALUE option,
RUBY_RETURN_OK;
}
/*
* weechat_ruby_api_config_option_is_null: return 1 if value of option is null
*/
static VALUE
weechat_ruby_api_config_option_is_null (VALUE class, VALUE option)
{
char *c_option;
int value;
/* make C compiler happy */
(void) class;
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_is_null");
RUBY_RETURN_INT(1);
}
c_option = NULL;
if (NIL_P (option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_is_null");
RUBY_RETURN_INT(1);
}
Check_Type (option, T_STRING);
c_option = STR2CSTR (option);
value = weechat_config_option_is_null (script_str2ptr (c_option));
RUBY_RETURN_INT(value);
}
/*
* weechat_ruby_api_config_option_default_is_null: return 1 if value of option is null
*/
static VALUE
weechat_ruby_api_config_option_default_is_null (VALUE class, VALUE option)
{
char *c_option;
int value;
/* make C compiler happy */
(void) class;
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_default_is_null");
RUBY_RETURN_INT(1);
}
c_option = NULL;
if (NIL_P (option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_default_is_null");
RUBY_RETURN_INT(1);
}
Check_Type (option, T_STRING);
c_option = STR2CSTR (option);
value = weechat_config_option_default_is_null (script_str2ptr (c_option));
RUBY_RETURN_INT(value);
}
/*
* weechat_ruby_api_config_boolean: return boolean value of option
*/
@@ -1958,6 +2076,46 @@ weechat_ruby_api_config_color (VALUE class, VALUE option)
RUBY_RETURN_STRING(result);
}
/*
* weechat_ruby_api_config_write_option: write an option in configuration file
*/
static VALUE
weechat_ruby_api_config_write_option (VALUE class, VALUE config_file,
VALUE option)
{
char *c_config_file, *c_option;
/* make C compiler happy */
(void) class;
if (!ruby_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_write_option");
RUBY_RETURN_ERROR;
}
c_config_file = NULL;
c_option = NULL;
if (NIL_P (config_file) || NIL_P (option))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_write_option");
RUBY_RETURN_ERROR;
}
Check_Type (config_file, T_STRING);
Check_Type (option, T_STRING);
c_config_file = STR2CSTR (config_file);
c_option = STR2CSTR (option);
weechat_config_write_option (script_str2ptr (c_config_file),
script_str2ptr (c_option));
RUBY_RETURN_OK;
}
/*
* weechat_ruby_api_config_write_line: write a line in configuration file
*/
@@ -5636,17 +5794,21 @@ weechat_ruby_api_init (VALUE ruby_mWeechat)
rb_define_module_function (ruby_mWeechat, "config_new", &weechat_ruby_api_config_new, 2);
rb_define_module_function (ruby_mWeechat, "config_new_section", &weechat_ruby_api_config_new_section, 9);
rb_define_module_function (ruby_mWeechat, "config_search_section", &weechat_ruby_api_config_search_section, 2);
rb_define_module_function (ruby_mWeechat, "config_new_option", &weechat_ruby_api_config_new_option, 13);
rb_define_module_function (ruby_mWeechat, "config_new_option", &weechat_ruby_api_config_new_option, 14);
rb_define_module_function (ruby_mWeechat, "config_search_option", &weechat_ruby_api_config_search_option, 3);
rb_define_module_function (ruby_mWeechat, "config_string_to_boolean", &weechat_ruby_api_config_string_to_boolean, 1);
rb_define_module_function (ruby_mWeechat, "config_option_reset", &weechat_ruby_api_config_option_reset, 2);
rb_define_module_function (ruby_mWeechat, "config_option_set", &weechat_ruby_api_config_option_set, 3);
rb_define_module_function (ruby_mWeechat, "config_option_set_null", &weechat_ruby_api_config_option_set_null, 2);
rb_define_module_function (ruby_mWeechat, "config_option_unset", &weechat_ruby_api_config_option_unset, 1);
rb_define_module_function (ruby_mWeechat, "config_option_rename", &weechat_ruby_api_config_option_rename, 2);
rb_define_module_function (ruby_mWeechat, "config_option_is_null", &weechat_ruby_api_config_option_is_null, 1);
rb_define_module_function (ruby_mWeechat, "config_option_default_is_null", &weechat_ruby_api_config_option_default_is_null, 1);
rb_define_module_function (ruby_mWeechat, "config_boolean", &weechat_ruby_api_config_boolean, 1);
rb_define_module_function (ruby_mWeechat, "config_integer", &weechat_ruby_api_config_integer, 1);
rb_define_module_function (ruby_mWeechat, "config_string", &weechat_ruby_api_config_string, 1);
rb_define_module_function (ruby_mWeechat, "config_color", &weechat_ruby_api_config_color, 1);
rb_define_module_function (ruby_mWeechat, "config_write_option", &weechat_ruby_api_config_write_option, 2);
rb_define_module_function (ruby_mWeechat, "config_write_line", &weechat_ruby_api_config_write_line, 3);
rb_define_module_function (ruby_mWeechat, "config_write", &weechat_ruby_api_config_write, 1);
rb_define_module_function (ruby_mWeechat, "config_read", &weechat_ruby_api_config_read, 1);
+2
View File
@@ -347,6 +347,7 @@ script_api_config_new_option (struct t_weechat_plugin *weechat_plugin,
int min, int max,
const char *default_value,
const char *value,
int null_value_allowed,
void (*callback_check_value)(void *data,
struct t_config_option *option,
const char *value),
@@ -416,6 +417,7 @@ script_api_config_new_option (struct t_weechat_plugin *weechat_plugin,
new_option = weechat_config_new_option (config_file, section, name, type,
description, string_values, min,
max, default_value, value,
null_value_allowed,
callback1, new_script_callback1,
callback2, new_script_callback2,
callback3, new_script_callback3);
+1
View File
@@ -68,6 +68,7 @@ extern struct t_config_option *script_api_config_new_option (struct t_weechat_pl
int min, int max,
const char *default_value,
const char *value,
int null_value_allowed,
void (*callback_check_value)(void *data,
struct t_config_option *option,
const char *value),
+165 -18
View File
@@ -1458,10 +1458,6 @@ weechat_tcl_api_config_option_delete_cb (void *data,
}
}
/*
* weechat_tcl_api_config_new_option: create a new option in section
*/
@@ -1474,7 +1470,7 @@ weechat_tcl_api_config_new_option (ClientData clientData, Tcl_Interp *interp,
char *result, *config_file, *section, *name, *type;
char *description, *string_values, *default_value, *value;
char *function_check_value, *function_change, *function_delete;
int i,min,max;
int i, min, max, null_value_allowed;
/* make C compiler happy */
(void) clientData;
@@ -1485,14 +1481,15 @@ weechat_tcl_api_config_new_option (ClientData clientData, Tcl_Interp *interp,
TCL_RETURN_EMPTY;
}
if (objc < 14)
if (objc < 15)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_new_option");
TCL_RETURN_EMPTY;
}
if ((Tcl_GetIntFromObj (interp, objv[7], &min) != TCL_OK)
|| (Tcl_GetIntFromObj (interp, objv[8], &max) != TCL_OK))
|| (Tcl_GetIntFromObj (interp, objv[8], &max) != TCL_OK)
|| (Tcl_GetIntFromObj (interp, objv[11], &null_value_allowed) != TCL_OK))
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_new_option");
TCL_RETURN_EMPTY;
@@ -1506,9 +1503,9 @@ weechat_tcl_api_config_new_option (ClientData clientData, Tcl_Interp *interp,
string_values = Tcl_GetStringFromObj (objv[6], &i);
default_value = Tcl_GetStringFromObj (objv[9], &i);
value = Tcl_GetStringFromObj (objv[10], &i);
function_check_value = Tcl_GetStringFromObj (objv[11], &i);
function_change = Tcl_GetStringFromObj (objv[12], &i);
function_delete = Tcl_GetStringFromObj (objv[13], &i);
function_check_value = Tcl_GetStringFromObj (objv[12], &i);
function_change = Tcl_GetStringFromObj (objv[13], &i);
function_delete = Tcl_GetStringFromObj (objv[14], &i);
result = script_ptr2str (script_api_config_new_option (weechat_tcl_plugin,
tcl_current_script,
@@ -1522,6 +1519,7 @@ weechat_tcl_api_config_new_option (ClientData clientData, Tcl_Interp *interp,
max,
default_value,
value,
null_value_allowed,
&weechat_tcl_api_config_option_check_value_cb,
function_check_value,
&weechat_tcl_api_config_option_change_cb,
@@ -1653,7 +1651,7 @@ weechat_tcl_api_config_option_set (ClientData clientData, Tcl_Interp *interp,
Tcl_Obj* objp;
int rc;
char *option, *new_value;
int i,run_cb;
int i, run_callback;
/* make C compiler happy */
(void) clientData;
@@ -1661,26 +1659,67 @@ weechat_tcl_api_config_option_set (ClientData clientData, Tcl_Interp *interp,
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set");
TCL_RETURN_INT(0);
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (objc < 4)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
TCL_RETURN_INT(0);
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (Tcl_GetIntFromObj (interp, objv[3], &run_cb) != TCL_OK)
if (Tcl_GetIntFromObj (interp, objv[3], &run_callback) != TCL_OK)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set");
TCL_RETURN_INT(0);
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = Tcl_GetStringFromObj (objv[1], &i);
new_value = Tcl_GetStringFromObj (objv[2], &i);
rc = weechat_config_option_set (script_str2ptr (option),
new_value,
run_cb); /* run_callback */
run_callback);
TCL_RETURN_INT(rc);
}
/*
* weechat_tcl_api_config_option_set_null: set null (undefined)value for option
*/
static int
weechat_tcl_api_config_option_set_null (ClientData clientData, Tcl_Interp *interp,
int objc, Tcl_Obj *CONST objv[])
{
Tcl_Obj* objp;
int rc;
char *option;
int i, run_callback;
/* make C compiler happy */
(void) clientData;
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_set_null");
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (objc < 3)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
if (Tcl_GetIntFromObj (interp, objv[2], &run_callback) != TCL_OK)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_set_null");
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_SET_ERROR);
}
option = Tcl_GetStringFromObj (objv[1], &i);
rc = weechat_config_option_set_null (script_str2ptr (option),
run_callback);
TCL_RETURN_INT(rc);
}
@@ -1704,13 +1743,13 @@ weechat_tcl_api_config_option_unset (ClientData clientData, Tcl_Interp *interp,
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_unset");
TCL_RETURN_INT(0);
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
if (objc < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_unset");
TCL_RETURN_INT(0);
TCL_RETURN_INT(WEECHAT_CONFIG_OPTION_UNSET_ERROR);
}
option = Tcl_GetStringFromObj (objv[1], &i);
@@ -1748,12 +1787,77 @@ weechat_tcl_api_config_option_rename (ClientData clientData, Tcl_Interp *interp,
option = Tcl_GetStringFromObj (objv[1], &i);
new_name = Tcl_GetStringFromObj (objv[2], &i);
weechat_config_option_rename (script_str2ptr (option),
new_name);
TCL_RETURN_OK;
}
/*
* weechat_tcl_api_config_option_is_null: return 1 if value of option is null
*/
static int
weechat_tcl_api_config_option_is_null (ClientData clientData, Tcl_Interp *interp,
int objc, Tcl_Obj *CONST objv[])
{
Tcl_Obj* objp;
int result, i;
/* make C compiler happy */
(void) clientData;
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_is_null");
TCL_RETURN_INT(1);
}
if (objc < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_is_null");
TCL_RETURN_INT(1);
}
result = weechat_config_option_is_null (script_str2ptr (Tcl_GetStringFromObj (objv[1], &i))); /* option */
TCL_RETURN_INT(result);
}
/*
* weechat_tcl_api_config_option_default_is_null: return 1 if default value of
* option is null
*/
static int
weechat_tcl_api_config_option_default_is_null (ClientData clientData,
Tcl_Interp *interp,
int objc, Tcl_Obj *CONST objv[])
{
Tcl_Obj* objp;
int result, i;
/* make C compiler happy */
(void) clientData;
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_option_default_is_null");
TCL_RETURN_INT(1);
}
if (objc < 2)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_option_default_is_null");
TCL_RETURN_INT(1);
}
result = weechat_config_option_default_is_null (script_str2ptr (Tcl_GetStringFromObj (objv[1], &i))); /* option */
TCL_RETURN_INT(result);
}
/*
* weechat_tcl_api_config_boolean: return boolean value of option
*/
@@ -1880,6 +1984,41 @@ weechat_tcl_api_config_color (ClientData clientData, Tcl_Interp *interp,
TCL_RETURN_STRING(result);
}
/*
* weechat_tcl_api_config_write_option: write an option in configuration file
*/
static int
weechat_tcl_api_config_write_option (ClientData clientData, Tcl_Interp *interp,
int objc, Tcl_Obj *CONST objv[])
{
Tcl_Obj *objp;
char *config_file, *option;
int i;
/* make C compiler happy */
(void) clientData;
if (!tcl_current_script)
{
WEECHAT_SCRIPT_MSG_NOT_INITIALIZED("config_write_option");
TCL_RETURN_ERROR;
}
if (objc < 3)
{
WEECHAT_SCRIPT_MSG_WRONG_ARGUMENTS("config_write_option");
TCL_RETURN_ERROR;
}
config_file = Tcl_GetStringFromObj (objv[1], &i);
option = Tcl_GetStringFromObj (objv[2], &i);
weechat_config_write_option (script_str2ptr (config_file),
script_str2ptr (option));
TCL_RETURN_OK;
}
/*
* weechat_tcl_api_config_write_line: write a line in configuration file
*/
@@ -5324,10 +5463,16 @@ void weechat_tcl_api_init (Tcl_Interp *interp) {
weechat_tcl_api_config_option_reset, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_set",
weechat_tcl_api_config_option_set, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_set_null",
weechat_tcl_api_config_option_set_null, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_unset",
weechat_tcl_api_config_option_unset, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_rename",
weechat_tcl_api_config_option_rename, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_is_null",
weechat_tcl_api_config_option_is_null, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_option_default_is_null",
weechat_tcl_api_config_option_default_is_null, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_boolean",
weechat_tcl_api_config_boolean, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_integer",
@@ -5336,6 +5481,8 @@ void weechat_tcl_api_init (Tcl_Interp *interp) {
weechat_tcl_api_config_string, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_color",
weechat_tcl_api_config_color, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_write_option",
weechat_tcl_api_config_write_option, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_write_line",
weechat_tcl_api_config_write_line, (ClientData)NULL, (Tcl_CmdDeleteProc*)NULL);
Tcl_CreateObjCommand (interp,"weechat::config_write",
+32
View File
@@ -60,6 +60,9 @@ struct t_weelist;
#define WEECHAT_CONFIG_WRITE_ERROR -1
#define WEECHAT_CONFIG_WRITE_MEMORY_ERROR -2
/* null value for option */
#define WEECHAT_CONFIG_OPTION_NULL "null"
/* return codes for config option set */
#define WEECHAT_CONFIG_OPTION_SET_OK_CHANGED 2
#define WEECHAT_CONFIG_OPTION_SET_OK_SAME_VALUE 1
@@ -254,6 +257,7 @@ struct t_weechat_plugin
int max,
const char *default_value,
const char *value,
int null_value_allowed,
int (*callback_check_value)(void *data,
struct t_config_option *option,
const char *value),
@@ -282,15 +286,25 @@ struct t_weechat_plugin
int run_callback);
int (*config_option_set) (struct t_config_option *option,
const char *value, int run_callback);
int (*config_option_set_null) (struct t_config_option *option,
int run_callback);
int (*config_option_unset) (struct t_config_option *option);
void (*config_option_rename) (struct t_config_option *option,
const char *new_name);
void *(*config_option_get_pointer) (struct t_config_option *option,
const char *property);
int (*config_option_is_null) (struct t_config_option *option);
int (*config_option_default_is_null) (struct t_config_option *option);
int (*config_boolean) (struct t_config_option *option);
int (*config_boolean_default) (struct t_config_option *option);
int (*config_integer) (struct t_config_option *option);
int (*config_integer_default) (struct t_config_option *option);
const char *(*config_string) (struct t_config_option *option);
const char *(*config_string_default) (struct t_config_option *option);
const char *(*config_color) (struct t_config_option *option);
const char *(*config_color_default) (struct t_config_option *option);
void (*config_write_option) (struct t_config_file *config_file,
struct t_config_option *option);
void (*config_write_line) (struct t_config_file *config_file,
const char *option_name,
const char *value, ...);
@@ -761,6 +775,7 @@ extern int weechat_plugin_end (struct t_weechat_plugin *plugin);
#define weechat_config_new_option(__config, __section, __name, __type, \
__desc, __string_values, __min, \
__max, __default, __value, \
__null_value_allowed, \
__callback_check, \
__callback_check_data, \
__callback_change, \
@@ -770,6 +785,7 @@ extern int weechat_plugin_end (struct t_weechat_plugin *plugin);
weechat_plugin->config_new_option(__config, __section, __name, \
__type, __desc, __string_values, \
__min, __max, __default, __value, \
__null_value_allowed, \
__callback_check, \
__callback_check_data, \
__callback_change, \
@@ -797,20 +813,36 @@ extern int weechat_plugin_end (struct t_weechat_plugin *plugin);
#define weechat_config_option_set(__option, __value, __run_callback) \
weechat_plugin->config_option_set(__option, __value, \
__run_callback)
#define weechat_config_option_set_null(__option, __run_callback) \
weechat_plugin->config_option_set_null(__option, __run_callback)
#define weechat_config_option_unset(__option) \
weechat_plugin->config_option_unset(__option)
#define weechat_config_option_rename(__option, __new_name) \
weechat_plugin->config_option_rename(__option, __new_name)
#define weechat_config_option_get_pointer(__option, __property) \
weechat_plugin->config_option_get_pointer(__option, __property)
#define weechat_config_option_is_null(__option) \
weechat_plugin->config_option_is_null(__option)
#define weechat_config_option_default_is_null(__option) \
weechat_plugin->config_option_default_is_null(__option)
#define weechat_config_boolean(__option) \
weechat_plugin->config_boolean(__option)
#define weechat_config_boolean_default(__option) \
weechat_plugin->config_boolean_default(__option)
#define weechat_config_integer(__option) \
weechat_plugin->config_integer(__option)
#define weechat_config_integer_default(__option) \
weechat_plugin->config_integer_default(__option)
#define weechat_config_string(__option) \
weechat_plugin->config_string(__option)
#define weechat_config_string_default(__option) \
weechat_plugin->config_string_default(__option)
#define weechat_config_color(__option) \
weechat_plugin->config_color(__option)
#define weechat_config_color_default(__option) \
weechat_plugin->config_color_default(__option)
#define weechat_config_write_option(__config, __option) \
weechat_plugin->config_write_option(__config, __option)
#define weechat_config_write_line(__config, __option, __value...) \
weechat_plugin->config_write_line(__config, __option, ##__value)
#define weechat_config_write(__config) \
+25 -25
View File
@@ -124,12 +124,12 @@ xfer_config_init ()
"auto_open_buffer", "boolean",
N_("auto open xfer buffer when a new xfer is added "
"to list"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_look_progress_bar_size = weechat_config_new_option (
xfer_config_file, ptr_section,
"progress_bar_size", "integer",
N_("size of progress bar, in chars (if 0, progress bar is disabled)"),
NULL, 0, XFER_CONFIG_PROGRESS_BAR_MAX_SIZE, "20", NULL,
NULL, 0, XFER_CONFIG_PROGRESS_BAR_MAX_SIZE, "20", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (xfer_config_file, "color",
@@ -147,55 +147,55 @@ xfer_config_init ()
xfer_config_file, ptr_section,
"text", "color",
N_("text color"),
NULL, 0, 0, "default", NULL,
NULL, 0, 0, "default", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_text_bg = weechat_config_new_option (
xfer_config_file, ptr_section,
"text_bg", "color",
N_("background color"),
NULL, 0, 0, "default", NULL,
NULL, 0, 0, "default", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_text_selected = weechat_config_new_option (
xfer_config_file, ptr_section,
"text_selected", "color",
N_("text color of selected xfer line"),
NULL, 0, 0, "white", NULL,
NULL, 0, 0, "white", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_WAITING] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_waiting", "color",
N_("text color for \"waiting\" status"),
NULL, 0, 0, "lightcyan", NULL,
NULL, 0, 0, "lightcyan", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_CONNECTING] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_connecting", "color",
N_("text color for \"connecting\" status"),
NULL, 0, 0, "yellow", NULL,
NULL, 0, 0, "yellow", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_ACTIVE] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_active", "color",
N_("text color for \"active\" status"),
NULL, 0, 0, "lightblue", NULL,
NULL, 0, 0, "lightblue", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_DONE] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_done", "color",
N_("text color for \"done\" status"),
NULL, 0, 0, "lightgreen", NULL,
NULL, 0, 0, "lightgreen", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_FAILED] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_failed", "color",
N_("text color for \"failed\" status"),
NULL, 0, 0, "lightred", NULL,
NULL, 0, 0, "lightred", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
xfer_config_color_status[XFER_STATUS_ABORTED] = weechat_config_new_option (
xfer_config_file, ptr_section,
"status_aborted", "color",
N_("text color for \"aborted\" status"),
NULL, 0, 0, "lightred", NULL,
NULL, 0, 0, "lightred", NULL, 0,
NULL, NULL, &xfer_config_refresh_cb, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (xfer_config_file, "network",
@@ -213,37 +213,37 @@ xfer_config_init ()
xfer_config_file, ptr_section,
"timeout", "integer",
N_("timeout for xfer request (in seconds)"),
NULL, 5, INT_MAX, "300", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 5, INT_MAX, "300", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_network_blocksize = weechat_config_new_option (
xfer_config_file, ptr_section,
"blocksize", "integer",
N_("block size for sending packets, in bytes"),
NULL, XFER_BLOCKSIZE_MIN, XFER_BLOCKSIZE_MAX, "65536", NULL,
NULL, XFER_BLOCKSIZE_MIN, XFER_BLOCKSIZE_MAX, "65536", NULL, 0,
NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_network_fast_send = weechat_config_new_option (
xfer_config_file, ptr_section,
"fast_send", "boolean",
N_("does not wait for ACK when sending file"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_network_port_range = weechat_config_new_option (
xfer_config_file, ptr_section,
"port_range", "string",
N_("restricts outgoing files/chats to use only ports in the given "
"range (useful for NAT) (syntax: a single port, ie. 5000 or a port "
"range, ie. 5000-5015, empty value means any port)"),
NULL, 0, 0, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_network_own_ip = weechat_config_new_option (
xfer_config_file, ptr_section,
"own_ip", "string",
N_("IP or DNS address used for sending files/chats "
"(if empty, local interface IP is used)"),
NULL, 0, 0, "", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_network_speed_limit = weechat_config_new_option (
xfer_config_file, ptr_section,
"speed_limit", "integer",
N_("speed limit for sending files, in kilo-bytes by second (0 means "
"no limit)"),
NULL, 0, INT_MAX, "0", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, INT_MAX, "0", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
ptr_section = weechat_config_new_section (xfer_config_file, "file",
0, 0,
@@ -260,44 +260,44 @@ xfer_config_init ()
xfer_config_file, ptr_section,
"download_path", "string",
N_("path for writing incoming files"),
NULL, 0, 0, "%h/xfer", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "%h/xfer", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_upload_path = weechat_config_new_option (
xfer_config_file, ptr_section,
"upload_path", "string",
N_("path for reading files when sending (when no path is "
"specified by user)"),
NULL, 0, 0, "~", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "~", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_use_nick_in_filename = weechat_config_new_option (
xfer_config_file, ptr_section,
"use_nick_in_filename", "boolean",
N_("use remote nick as prefix in local filename when receiving a file"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_convert_spaces = weechat_config_new_option (
xfer_config_file, ptr_section,
"convert_spaces", "boolean",
N_("convert spaces to underscores when sending files"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_auto_rename = weechat_config_new_option (
xfer_config_file, ptr_section,
"auto_rename", "boolean",
N_("rename incoming files if already exists (add '.1', '.2', ...)"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_auto_resume = weechat_config_new_option (
xfer_config_file, ptr_section,
"auto_resume", "boolean",
N_("automatically resume file transfer if connection with remote host "
"is lost"),
NULL, 0, 0, "on", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "on", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_auto_accept_files = weechat_config_new_option (
xfer_config_file, ptr_section,
"auto_accept_files", "boolean",
N_("automatically accept incoming files (use carefully!)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
xfer_config_file_auto_accept_chats = weechat_config_new_option (
xfer_config_file, ptr_section,
"auto_accept_chats", "boolean",
N_("automatically accept chat requests (use carefully!)"),
NULL, 0, 0, "off", NULL, NULL, NULL, NULL, NULL, NULL, NULL);
NULL, 0, 0, "off", NULL, 0, NULL, NULL, NULL, NULL, NULL, NULL);
return 1;
}