mateweather-prefs

mateweather-prefs

Synopsis

#define             MATECONF_TEMP_UNIT
#define             MATECONF_SPEED_UNIT
#define             MATECONF_PRESSURE_UNIT
#define             MATECONF_DISTANCE_UNIT
                    MateWeatherPrefs;
void                mateweather_prefs_load                 (MateWeatherPrefs *prefs,
                                                         MateWeatherMateConf *ctx);
const char *        mateweather_prefs_temp_enum_to_string  (TempUnit temp);
const char *        mateweather_prefs_speed_enum_to_string (SpeedUnit speed);
const char *        mateweather_prefs_pressure_enum_to_string
                                                        (PressureUnit pressure);
const char *        mateweather_prefs_distance_enum_to_string
                                                        (DistanceUnit distance);
TempUnit            mateweather_prefs_parse_temperature    (const char *str,
                                                         gboolean *is_default);
SpeedUnit           mateweather_prefs_parse_speed          (const char *str,
                                                         gboolean *is_default);
const char *        mateweather_prefs_get_temp_display_name
                                                        (TempUnit temp);
const char *        mateweather_prefs_get_speed_display_name
                                                        (SpeedUnit speed);
const char *        mateweather_prefs_get_pressure_display_name
                                                        (PressureUnit pressure);
const char *        mateweather_prefs_get_distance_display_name
                                                        (DistanceUnit distance);

Description

Details

MATECONF_TEMP_UNIT

#define MATECONF_TEMP_UNIT     "temperature_unit"


MATECONF_SPEED_UNIT

#define MATECONF_SPEED_UNIT    "speed_unit"


MATECONF_PRESSURE_UNIT

#define MATECONF_PRESSURE_UNIT "pressure_unit"


MATECONF_DISTANCE_UNIT

#define MATECONF_DISTANCE_UNIT "distance_unit"


MateWeatherPrefs

typedef struct {
    WeatherLocation *location;
    gint update_interval;  /* in seconds */
    gboolean update_enabled;
    gboolean detailed;
    gboolean radar_enabled;
    gboolean use_custom_radar_url;
    gchar *radar;

    TempUnit     temperature_unit;
    gboolean     use_temperature_default;
    SpeedUnit    speed_unit;
    gboolean     use_speed_default;
    PressureUnit pressure_unit;
    gboolean     use_pressure_default;
    DistanceUnit distance_unit;
    gboolean     use_distance_default;
} MateWeatherPrefs;


mateweather_prefs_load ()

void                mateweather_prefs_load                 (MateWeatherPrefs *prefs,
                                                         MateWeatherMateConf *ctx);

prefs :

ctx :


mateweather_prefs_temp_enum_to_string ()

const char *        mateweather_prefs_temp_enum_to_string  (TempUnit temp);

temp :

Returns :


mateweather_prefs_speed_enum_to_string ()

const char *        mateweather_prefs_speed_enum_to_string (SpeedUnit speed);

speed :

Returns :


mateweather_prefs_pressure_enum_to_string ()

const char *        mateweather_prefs_pressure_enum_to_string
                                                        (PressureUnit pressure);

pressure :

Returns :


mateweather_prefs_distance_enum_to_string ()

const char *        mateweather_prefs_distance_enum_to_string
                                                        (DistanceUnit distance);

distance :

Returns :


mateweather_prefs_parse_temperature ()

TempUnit            mateweather_prefs_parse_temperature    (const char *str,
                                                         gboolean *is_default);

str :

is_default :

Returns :


mateweather_prefs_parse_speed ()

SpeedUnit           mateweather_prefs_parse_speed          (const char *str,
                                                         gboolean *is_default);

str :

is_default :

Returns :


mateweather_prefs_get_temp_display_name ()

const char *        mateweather_prefs_get_temp_display_name
                                                        (TempUnit temp);

temp :

Returns :


mateweather_prefs_get_speed_display_name ()

const char *        mateweather_prefs_get_speed_display_name
                                                        (SpeedUnit speed);

speed :

Returns :


mateweather_prefs_get_pressure_display_name ()

const char *        mateweather_prefs_get_pressure_display_name
                                                        (PressureUnit pressure);

pressure :

Returns :


mateweather_prefs_get_distance_display_name ()

const char *        mateweather_prefs_get_distance_display_name
                                                        (DistanceUnit distance);

distance :

Returns :