libpurple/accountopt.h

Sun, 17 Aug 2008 11:10:39 +0000

author
Will Thompson <resiak@pidgin.im>
date
Sun, 17 Aug 2008 11:10:39 +0000
changeset 24111
40399e39280d
parent 22256
267223b42a73
child 32438
dc8991868906
permissions
-rw-r--r--

Correct documentation about list account options to reflect what the key and
value of the PurpleKeyValuePair actually represent (based on what Pidgin does
with them). (Since the only protocol to use them, silc, uses the same string
for the key and the value, no harm came of me having written incorrect
documentation last time.)

5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
1 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
2 * @file accountopt.h Account Options API
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
3 * @ingroup core
20147
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 20040
diff changeset
4 */
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 20040
diff changeset
5
66f05a854eee applied changes from 8a731bbd0197fbcc91a705c2d8f528154216defa
Richard Laager <rlaager@pidgin.im>
parents: 20040
diff changeset
6 /* purple
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
7 *
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
8 * Purple is the legal property of its developers, whose names are too numerous
8046
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 6902
diff changeset
9 * to list here. Please refer to the COPYRIGHT file distributed with this
c581b20a47d6 [gaim-migrate @ 8730]
Sean Egan <seanegan@pidgin.im>
parents: 6902
diff changeset
10 * source distribution.
6902
bf0a4376750f [gaim-migrate @ 7449]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
11 *
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
12 * This program is free software; you can redistribute it and/or modify
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
13 * it under the terms of the GNU General Public License as published by
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
14 * the Free Software Foundation; either version 2 of the License, or
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
15 * (at your option) any later version.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
16 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
17 * This program is distributed in the hope that it will be useful,
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
18 * but WITHOUT ANY WARRANTY; without even the implied warranty of
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
20 * GNU General Public License for more details.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
21 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
22 * You should have received a copy of the GNU General Public License
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
23 * along with this program; if not, write to the Free Software
19859
71d37b57eff2 The FSF changed its address a while ago; our files were out of date.
John Bailey <rekkanoryo@rekkanoryo.org>
parents: 18190
diff changeset
24 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
25 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
26 #ifndef _PURPLE_ACCOUNTOPT_H_
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
27 #define _PURPLE_ACCOUNTOPT_H_
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
28
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
29 #include "prefs.h"
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
30
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
31 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
32 * An option for an account.
6902
bf0a4376750f [gaim-migrate @ 7449]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
33 *
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
34 * This is set by protocol plugins, and appears in the account settings
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
35 * dialogs.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
36 */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
37 typedef struct
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
38 {
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
39 PurplePrefType type; /**< The type of value. */
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
40
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
41 char *text; /**< The text that will appear to the user. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
42 char *pref_name; /**< The name of the associated preference. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
43
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
44 union
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
45 {
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
46 gboolean boolean; /**< The default boolean value. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
47 int integer; /**< The default integer value. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
48 char *string; /**< The default string value. */
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
49 GList *list; /**< The default list value. */
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
50
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
51 } default_value;
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
52
20040
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
53 gboolean masked; /**< Whether the value entered should be
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
54 * obscured from view (for passwords and
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
55 * similar options)
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
56 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
57 } PurpleAccountOption;
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
58
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
59 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
60 * A username split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
61 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
62 * This is used by some protocols to separate the fields of the username
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
63 * into more human-readable components.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
64 */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
65 typedef struct
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
66 {
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
67 char *text; /**< The text that will appear to the user. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
68 char *default_value; /**< The default value. */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
69 char field_sep; /**< The field separator. */
18099
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
70 gboolean reverse; /**< TRUE if the separator should be found
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
71 starting a the end of the string, FALSE
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
72 otherwise */
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
73
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
74 } PurpleAccountUserSplit;
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
75
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
76 #ifdef __cplusplus
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
77 extern "C" {
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
78 #endif
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
79
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
80 /**************************************************************************/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
81 /** @name Account Option API */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
82 /**************************************************************************/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
83 /*@{*/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
84
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
85 /**
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
86 * Creates a new account option. If you know what @a type will be in advance,
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
87 * consider using purple_account_option_bool_new(),
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
88 * purple_account_option_int_new(), purple_account_option_string_new() or
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
89 * purple_account_option_list_new() (as appropriate) instead.
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
90 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
91 * @param type The type of option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
92 * @param text The text of the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
93 * @param pref_name The account preference name for the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
94 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
95 * @return The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
96 */
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
97 PurpleAccountOption *purple_account_option_new(PurplePrefType type,
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
98 const char *text, const char *pref_name);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
99
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
100 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
101 * Creates a new boolean account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
102 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
103 * @param text The text of the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
104 * @param pref_name The account preference name for the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
105 * @param default_value The default value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
106 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
107 * @return The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
108 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
109 PurpleAccountOption *purple_account_option_bool_new(const char *text,
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
110 const char *pref_name, gboolean default_value);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
111
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
112 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
113 * Creates a new integer account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
114 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
115 * @param text The text of the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
116 * @param pref_name The account preference name for the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
117 * @param default_value The default value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
118 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
119 * @return The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
120 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
121 PurpleAccountOption *purple_account_option_int_new(const char *text,
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
122 const char *pref_name, int default_value);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
123
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
124 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
125 * Creates a new string account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
126 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
127 * @param text The text of the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
128 * @param pref_name The account preference name for the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
129 * @param default_value The default value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
130 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
131 * @return The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
132 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
133 PurpleAccountOption *purple_account_option_string_new(const char *text,
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
134 const char *pref_name, const char *default_value);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
135
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
136 /**
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
137 * Creates a new list account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
138 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
139 * The list passed will be owned by the account option, and the
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
140 * strings inside will be freed automatically.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
141 *
24111
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
142 * The list is a list of #PurpleKeyValuePair items. The key is the label that
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
143 * should be displayed to the user, and the <tt>(const char *)</tt> value is
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
144 * the internal ID that should be passed to purple_account_set_string() to
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
145 * choose that value.
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
146 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
147 * @param text The text of the option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
148 * @param pref_name The account preference name for the option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
149 * @param list The key, value list.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
150 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
151 * @return The account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
152 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
153 PurpleAccountOption *purple_account_option_list_new(const char *text,
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
154 const char *pref_name, GList *list);
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
155
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
156 /**
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
157 * Destroys an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
158 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
159 * @param option The option to destroy.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
160 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
161 void purple_account_option_destroy(PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
162
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
163 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
164 * Sets the default boolean value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
165 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
166 * @param option The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
167 * @param value The default boolean value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
168 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
169 void purple_account_option_set_default_bool(PurpleAccountOption *option,
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
170 gboolean value);
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
171
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
172 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
173 * Sets the default integer value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
174 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
175 * @param option The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
176 * @param value The default integer value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
177 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
178 void purple_account_option_set_default_int(PurpleAccountOption *option,
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
179 int value);
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
180
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
181 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
182 * Sets the default string value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
183 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
184 * @param option The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
185 * @param value The default string value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
186 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
187 void purple_account_option_set_default_string(PurpleAccountOption *option,
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
188 const char *value);
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
189
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
190 /**
20040
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
191 * Sets the masking for an account option. Setting this to %TRUE acts
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
192 * as a hint to the UI that the option's value should be obscured from
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
193 * view, like a password.
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
194 *
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
195 * @param option The account option.
20040
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
196 * @param masked The masking.
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
197 */
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
198 void
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
199 purple_account_option_set_masked(PurpleAccountOption *option, gboolean masked);
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
200
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
201 /**
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
202 * Sets the list values for an account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
203 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
204 * The list passed will be owned by the account option, and the
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
205 * strings inside will be freed automatically.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
206 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
207 * The list is in key, value pairs. The key is the ID stored and used
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
208 * internally, and the value is the label displayed.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
209 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
210 * @param option The account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
211 * @param values The default list value.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
212 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
213 void purple_account_option_set_list(PurpleAccountOption *option, GList *values);
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
214
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
215 /**
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
216 * Adds an item to a list account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
217 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
218 * @param option The account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
219 * @param key The key.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
220 * @param value The value.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
221 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
222 void purple_account_option_add_list_item(PurpleAccountOption *option,
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
223 const char *key, const char *value);
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
224
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
225 /**
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
226 * Returns the specified account option's type.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
227 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
228 * @param option The account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
229 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
230 * @return The account option's type.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
231 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
232 PurplePrefType purple_account_option_get_type(const PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
233
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
234 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
235 * Returns the text for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
236 *
13310
dff5b1615a1a [gaim-migrate @ 15675]
Richard Laager <rlaager@pidgin.im>
parents: 12172
diff changeset
237 * @param option The account option.
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
238 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
239 * @return The account option's text.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
240 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
241 const char *purple_account_option_get_text(const PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
242
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
243 /**
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
244 * Returns the name of an account option. This corresponds to the @c pref_name
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
245 * parameter supplied to purple_account_option_new() or one of the
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
246 * type-specific constructors.
5660
90787278c739 [gaim-migrate @ 6074]
Christian Hammond <chipx86@chipx86.com>
parents: 5654
diff changeset
247 *
13310
dff5b1615a1a [gaim-migrate @ 15675]
Richard Laager <rlaager@pidgin.im>
parents: 12172
diff changeset
248 * @param option The account option.
5660
90787278c739 [gaim-migrate @ 6074]
Christian Hammond <chipx86@chipx86.com>
parents: 5654
diff changeset
249 *
22256
267223b42a73 Improve some PurpleAcountOption documentation, and sanify some whitespace.
Will Thompson <resiak@pidgin.im>
parents: 20147
diff changeset
250 * @return The option's name.
5660
90787278c739 [gaim-migrate @ 6074]
Christian Hammond <chipx86@chipx86.com>
parents: 5654
diff changeset
251 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
252 const char *purple_account_option_get_setting(const PurpleAccountOption *option);
5660
90787278c739 [gaim-migrate @ 6074]
Christian Hammond <chipx86@chipx86.com>
parents: 5654
diff changeset
253
90787278c739 [gaim-migrate @ 6074]
Christian Hammond <chipx86@chipx86.com>
parents: 5654
diff changeset
254 /**
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
255 * Returns the default boolean value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
256 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
257 * @param option The account option.
6902
bf0a4376750f [gaim-migrate @ 7449]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
258 *
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
259 * @return The default boolean value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
260 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
261 gboolean purple_account_option_get_default_bool(const PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
262
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
263 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
264 * Returns the default integer value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
265 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
266 * @param option The account option.
6902
bf0a4376750f [gaim-migrate @ 7449]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
267 *
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
268 * @return The default integer value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
269 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
270 int purple_account_option_get_default_int(const PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
271
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
272 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
273 * Returns the default string value for an account option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
274 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
275 * @param option The account option.
6902
bf0a4376750f [gaim-migrate @ 7449]
Christian Hammond <chipx86@chipx86.com>
parents: 5944
diff changeset
276 *
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
277 * @return The default string value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
278 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
279 const char *purple_account_option_get_default_string(
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
280 const PurpleAccountOption *option);
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
281
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
282 /**
12172
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
283 * Returns the default string value for a list account option.
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
284 *
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
285 * @param option The account option.
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
286 *
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
287 * @return The default list string value.
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
288 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
289 const char *purple_account_option_get_default_list_value(
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
290 const PurpleAccountOption *option);
12172
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
291
717fa0ec02c4 [gaim-migrate @ 14474]
Stu Tomlinson <nosnilmot@pidgin.im>
parents: 12106
diff changeset
292 /**
20040
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
293 * Returns whether an option's value should be masked from view, like a
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
294 * password. If so, the UI might display each character of the option
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
295 * as a '*' (for example).
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
296 *
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
297 * @param option The account option.
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
298 *
20040
57572bb85e07 Explain what PurpleAccountOption.masked and its setters and getters
Will Thompson <resiak@pidgin.im>
parents: 19859
diff changeset
299 * @return %TRUE if the option's value should be obscured.
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
300 */
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
301 gboolean
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
302 purple_account_option_get_masked(const PurpleAccountOption *option);
10658
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
303
6223ea383921 [gaim-migrate @ 12190]
Richard Laager <rlaager@pidgin.im>
parents: 9713
diff changeset
304 /**
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
305 * Returns the list values for an account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
306 *
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
307 * @param option The account option.
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
308 *
24111
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
309 * @constreturn A list of #PurpleKeyValuePair, mapping the human-readable
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
310 * description of the value to the <tt>(const char *)</tt> that
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
311 * should be passed to purple_account_set_string() to set the
40399e39280d Correct documentation about list account options to reflect what the key and
Will Thompson <resiak@pidgin.im>
parents: 22256
diff changeset
312 * option.
8570
bce05cb55dbc [gaim-migrate @ 9318]
Christian Hammond <chipx86@chipx86.com>
parents: 8046
diff changeset
313 */
18190
bcf28ef7e8ff Re-fix the DBus list handling code by killing const GList* / const GSList*
Richard Laager <rlaager@pidgin.im>
parents: 18099
diff changeset
314 GList *purple_account_option_get_list(const PurpleAccountOption *option);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
315
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
316 /*@}*/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
317
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
318
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
319 /**************************************************************************/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
320 /** @name Account User Split API */
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
321 /**************************************************************************/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
322 /*@{*/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
323
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
324 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
325 * Creates a new account username split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
326 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
327 * @param text The text of the option.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
328 * @param default_value The default value.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
329 * @param sep The field separator.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
330 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
331 * @return The new user split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
332 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
333 PurpleAccountUserSplit *purple_account_user_split_new(const char *text,
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
334 const char *default_value,
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
335 char sep);
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
336
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
337 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
338 * Destroys an account username split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
339 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
340 * @param split The split to destroy.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
341 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
342 void purple_account_user_split_destroy(PurpleAccountUserSplit *split);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
343
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
344 /**
5654
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
345 * Returns the text for an account username split.
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
346 *
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
347 * @param split The account username split.
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
348 *
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
349 * @return The account username split's text.
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
350 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
351 const char *purple_account_user_split_get_text(const PurpleAccountUserSplit *split);
5654
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
352
3a0e6dba1c2f [gaim-migrate @ 6068]
Christian Hammond <chipx86@chipx86.com>
parents: 5639
diff changeset
353 /**
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
354 * Returns the default string value for an account split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
355 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
356 * @param split The account username split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
357 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
358 * @return The default string.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
359 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
360 const char *purple_account_user_split_get_default_value(
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
361 const PurpleAccountUserSplit *split);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
362
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
363 /**
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
364 * Returns the field separator for an account split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
365 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
366 * @param split The account username split.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
367 *
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
368 * @return The field separator.
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
369 */
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
370 char purple_account_user_split_get_separator(const PurpleAccountUserSplit *split);
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
371
18099
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
372 /**
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
373 * Returns the 'reverse' value for an account split.
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
374 *
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
375 * @param split The account username split.
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
376 *
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
377 * @return The 'reverse' value.
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
378 */
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
379 gboolean purple_account_user_split_get_reverse(const PurpleAccountUserSplit *split);
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
380
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
381 /**
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
382 * Sets the 'reverse' value for an account split.
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
383 *
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
384 * @param split The account username split.
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
385 * @param reverse The 'reverse' value
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
386 */
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
387 void purple_account_user_split_set_reverse(PurpleAccountUserSplit *split, gboolean reverse);
f38988d232f7 jabber can contain @ symbols and / in the resource, so we have to look for
Nathan Walp <nwalp@pidgin.im>
parents: 15884
diff changeset
388
5639
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
389 /*@}*/
5a13e6ed0a58 [gaim-migrate @ 6051]
Christian Hammond <chipx86@chipx86.com>
parents:
diff changeset
390
5944
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
391 #ifdef __cplusplus
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
392 }
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
393 #endif
f19df037ac58 [gaim-migrate @ 6385]
Christian Hammond <chipx86@chipx86.com>
parents: 5660
diff changeset
394
15884
4de1981757fc sed -ie 's/gaim/purple/g'
Sean Egan <seanegan@pidgin.im>
parents: 15435
diff changeset
395 #endif /* _PURPLE_ACCOUNTOPT_H_ */

mercurial