2
* Copyright (c) 2007 Rodney Cryderman <rcryderman@gmail.com>
4
* This library is free software; you can redistribute it and/or
5
* modify it under the terms of the GNU Lesser General Public
6
* License as published by the Free Software Foundation; either
7
* version 2 of the License, or (at your option) any later version.
9
* This library is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12
* Lesser General Public License for more details.
14
* You should have received a copy of the GNU Lesser General Public
15
* License along with this library; if not, write to the
16
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17
* Boston, MA 02111-1307, USA.
21
#ifndef DASHBOARD_UTIL_H_
22
#define DASHBOARD_UTIL_H_
24
#include <libawn/awn-applet.h>
25
#include <libawn/awn-cairo-utils.h>
26
#include <libawn/awn-title.h>
29
#include <gconf/gconf-client.h>
31
enum { DASHBOARD_FONT_TINY, DASHBOARD_FONT_SMALL, DASHBOARD_FONT_MEDIUM, DASHBOARD_FONT_LARGE };
55
}dashboard_cairo_widget;
57
void draw_pie_graph(cairo_t *cr, double x, double y, double radius, double start, double * values, AwnColor * colours, int numel);
59
void pick_awn_color(AwnColor * awncolour, const char *mess, void * arb_data, void (*notify_color_change)(void *));
61
void set_dashboard_gconf(GConfClient* p);
62
GConfClient* get_dashboard_gconf(void);
64
void set_fg_rbg(GdkColor *);
65
void set_bg_rbg(GdkColor *);
67
void get_fg_rgb_colour(rgb_colour *);
68
void get_fg_rgba_colour(rgba_colour *);
69
void get_bg_rgb_colour(rgb_colour *);
70
void get_bg_rgba_colour(rgba_colour *);
72
void use_bg_rgb_colour(cairo_t * cr);
73
void use_bg_rgba_colour(cairo_t * cr);
74
void use_fg_rgb_colour(cairo_t * cr);
75
void use_fg_rgba_colour(cairo_t * cr);
77
GtkWidget * get_cairo_widget(dashboard_cairo_widget *, int width, int height);
79
void del_cairo_widget(dashboard_cairo_widget * d);
81
float dashboard_get_font_size(int size);
83
char * dashboard_cairo_colour_to_string(AwnColor * colour);
85
GtkWidget * dashboard_build_clickable_menu_item(GtkWidget * menu, GCallback fn, char * mess, void *data);
86
GtkWidget * dashboard_build_clickable_check_menu_item(GtkWidget * menu, GCallback fn, char * mess, void *data, gboolean state);
88
void enable_suppress_hide_main(void);
89
void disable_suppress_hide_main(void);
90
gboolean get_hide_main(void);
92
gboolean toggle_boolean_menu(GtkWidget *widget, GdkEventButton *event, gboolean *p);
94
void quick_message(gchar *message, GtkWidget * mainwin);
96
/*void set_tiles_x(int x);
97
void set_tiles_y(int y);
98
int get_tiles_x(void);
99
int get_tiles_y(void);
100
float get_tile_size_x(void);
101
float get_tile_size_y(void);