1 #ifndef _FS2_REGISTRY_HEADER_FILE
2 #define _FS2_REGISTRY_HEADER_FILE
4 // ------------------------------------------------------------------------------------------------------------
5 // REGISTRY DEFINES/VARS
9 extern char *Osreg_company_name;
10 extern char *Osreg_class_name;
11 extern char *Osreg_app_name;
12 extern char *Osreg_title;
15 // ------------------------------------------------------------------------------------------------------------
20 // initialize the registry. setup default keys to use
21 void os_init_registry_stuff(char *company, char *app, char *version);
23 // Removes a value from to the INI file. Passing
24 // name=NULL will delete the section.
25 void os_config_remove( char *section, char *name );
27 // Writes a string to the registry
28 void os_config_write_string( char *section, char *name, char *value );
30 // same as previous function except we don't use the application name to build up the keyname
31 void os_config_write_string2( char *section, char *name, char *value );
33 // Writes an unsigned int to the INI file.
34 void os_config_write_uint( char *section, char *name, unsigned int value );
36 // Reads a string from the INI file. If default is passed,
37 // and the string isn't found, returns ptr to default otherwise
38 // returns NULL; Copy the return value somewhere before
39 // calling os_read_string again, because it might reuse the
41 char * os_config_read_string( char *section, char *name, char *default_value=NULL );
43 // same as previous function except we don't use the application name to build up the keyname
44 char * os_config_read_string2( char *section, char *name, char *default_value=NULL );
46 // Reads a string from the INI file. Default_value must
47 // be passed, and if 'name' isn't found, then returns default_value
48 unsigned int os_config_read_uint( char *section, char *name, unsigned int default_value );
50 // uses Ex versions of Windows registry functions
51 char * os_config_read_string_ex( char *keyname, char *name, char *default_value );