summaryrefslogtreecommitdiff
path: root/libs/clearlooks-newer
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2015-10-04 14:51:05 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2015-10-04 14:51:05 -0400
commit4dc63966f0872efe768dad61eb9b8785d06b92d1 (patch)
treee54104d57d6c2da7840979181368151fd0819c96 /libs/clearlooks-newer
parent297e80e020da94a56984b20782584bb1dd96ea34 (diff)
globally remove all trailing whitespace from ardour code base.
Paul Davis was responsible for introducing almost all of this.
Diffstat (limited to 'libs/clearlooks-newer')
-rw-r--r--libs/clearlooks-newer/cairo-support.c120
-rw-r--r--libs/clearlooks-newer/clearlooks_draw.c60
-rw-r--r--libs/clearlooks-newer/clearlooks_draw_glossy.c40
-rw-r--r--libs/clearlooks-newer/clearlooks_draw_gummy.c40
-rw-r--r--libs/clearlooks-newer/clearlooks_draw_inverted.c22
-rw-r--r--libs/clearlooks-newer/clearlooks_rc_style.c6
-rw-r--r--libs/clearlooks-newer/clearlooks_style.c20
-rw-r--r--libs/clearlooks-newer/clearlooks_theme_main.c2
-rw-r--r--libs/clearlooks-newer/clearlooks_types.h8
-rw-r--r--libs/clearlooks-newer/general-support.h2
-rw-r--r--libs/clearlooks-newer/widget-information.c76
-rw-r--r--libs/clearlooks-newer/widget-information.h38
12 files changed, 217 insertions, 217 deletions
diff --git a/libs/clearlooks-newer/cairo-support.c b/libs/clearlooks-newer/cairo-support.c
index fa195776a2..4b82bb5758 100644
--- a/libs/clearlooks-newer/cairo-support.c
+++ b/libs/clearlooks-newer/cairo-support.c
@@ -4,16 +4,16 @@
/***********************************************
* ge_hsb_from_color -
- *
+ *
* Get HSB values from RGB values.
*
* Modified from Smooth but originated in GTK+
***********************************************/
void
-ge_hsb_from_color (const CairoColor *color,
- gdouble *hue,
+ge_hsb_from_color (const CairoColor *color,
+ gdouble *hue,
gdouble *saturation,
- gdouble *brightness)
+ gdouble *brightness)
{
gdouble min, max, delta;
gdouble red, green, blue;
@@ -21,7 +21,7 @@ ge_hsb_from_color (const CairoColor *color,
red = color->r;
green = color->g;
blue = color->b;
-
+
if (red > green)
{
max = MAX(red, blue);
@@ -32,7 +32,7 @@ ge_hsb_from_color (const CairoColor *color,
max = MAX(green, blue);
min = MIN(red, blue);
}
-
+
*brightness = (max + min) / 2;
if (fabs(max - min) < 0.0001)
@@ -46,34 +46,34 @@ ge_hsb_from_color (const CairoColor *color,
*saturation = (max - min) / (max + min);
else
*saturation = (max - min) / (2 - max - min);
-
+
delta = max -min;
-
+
if (red == max)
*hue = (green - blue) / delta;
else if (green == max)
*hue = 2 + (blue - red) / delta;
else if (blue == max)
*hue = 4 + (red - green) / delta;
-
+
*hue *= 60;
if (*hue < 0.0)
*hue += 360;
}
}
-
+
/***********************************************
* ge_color_from_hsb -
- *
+ *
* Get RGB values from HSB values.
*
* Modified from Smooth but originated in GTK+
***********************************************/
#define MODULA(number, divisor) (((gint)number % divisor) + (number - (gint)number))
void
-ge_color_from_hsb (gdouble hue,
+ge_color_from_hsb (gdouble hue,
gdouble saturation,
- gdouble brightness,
+ gdouble brightness,
CairoColor *color)
{
gint i;
@@ -81,31 +81,31 @@ ge_color_from_hsb (gdouble hue,
gdouble m1, m2, m3;
if (!color) return;
-
+
if (brightness <= 0.5)
m2 = brightness * (1 + saturation);
else
m2 = brightness + saturation - brightness * saturation;
-
+
m1 = 2 * brightness - m2;
-
+
hue_shift[0] = hue + 120;
hue_shift[1] = hue;
hue_shift[2] = hue - 120;
-
+
color_shift[0] = color_shift[1] = color_shift[2] = brightness;
-
+
i = (saturation == 0)?3:0;
-
+
for (; i < 3; i++)
{
m3 = hue_shift[i];
-
+
if (m3 > 360)
m3 = MODULA(m3, 360);
else if (m3 < 0)
m3 = 360 - MODULA(ABS(m3), 360);
-
+
if (m3 < 60)
color_shift[i] = m1 + (m2 - m1) * m3 / 60;
else if (m3 < 180)
@@ -115,7 +115,7 @@ ge_color_from_hsb (gdouble hue,
else
color_shift[i] = m1;
}
-
+
color->r = color_shift[0];
color->g = color_shift[1];
color->b = color_shift[2];
@@ -155,7 +155,7 @@ ge_cairo_color_to_gtk (const CairoColor *cc, GdkColor *c)
c->blue = b;
}
-void
+void
ge_gtk_style_to_cairo_color_cube (GtkStyle * style, CairoColorCube *cube)
{
int i;
@@ -163,7 +163,7 @@ ge_gtk_style_to_cairo_color_cube (GtkStyle * style, CairoColorCube *cube)
g_return_if_fail (style && cube);
for (i = 0; i < 5; i++)
- {
+ {
ge_gdk_color_to_cairo (&style->bg[i], &cube->bg[i]);
ge_gdk_color_to_cairo (&style->fg[i], &cube->fg[i]);
@@ -189,17 +189,17 @@ ge_shade_color(const CairoColor *base, gdouble shade_ratio, CairoColor *composit
gdouble hue = 0;
gdouble saturation = 0;
gdouble brightness = 0;
-
+
g_return_if_fail (base && composite);
ge_hsb_from_color (base, &hue, &saturation, &brightness);
-
+
brightness = MIN(brightness*shade_ratio, 1.0);
brightness = MAX(brightness, 0.0);
-
+
saturation = MIN(saturation*shade_ratio, 1.0);
saturation = MAX(saturation, 0.0);
-
+
ge_color_from_hsb (hue, saturation, brightness, composite);
composite->a = base->a;
}
@@ -210,7 +210,7 @@ ge_saturate_color (const CairoColor *base, gdouble saturate_level, CairoColor *c
gdouble hue = 0;
gdouble saturation = 0;
gdouble brightness = 0;
-
+
g_return_if_fail (base && composite);
ge_hsb_from_color (base, &hue, &saturation, &brightness);
@@ -223,7 +223,7 @@ ge_saturate_color (const CairoColor *base, gdouble saturate_level, CairoColor *c
}
void
-ge_mix_color (const CairoColor *color1, const CairoColor *color2,
+ge_mix_color (const CairoColor *color1, const CairoColor *color2,
gdouble mix_factor, CairoColor *composite)
{
g_return_if_fail (color1 && color2 && composite);
@@ -234,7 +234,7 @@ ge_mix_color (const CairoColor *color1, const CairoColor *color2,
composite->a = 1.0;
}
-cairo_t *
+cairo_t *
ge_gdk_drawable_to_cairo (GdkDrawable *window, GdkRectangle *area)
{
cairo_t *cr;
@@ -246,7 +246,7 @@ ge_gdk_drawable_to_cairo (GdkDrawable *window, GdkRectangle *area)
cairo_set_line_cap (cr, CAIRO_LINE_CAP_SQUARE);
cairo_set_line_join (cr, CAIRO_LINE_JOIN_MITER);
- if (area)
+ if (area)
{
cairo_rectangle (cr, area->x, area->y, area->width, area->height);
cairo_clip_preserve (cr);
@@ -256,7 +256,7 @@ ge_gdk_drawable_to_cairo (GdkDrawable *window, GdkRectangle *area)
return cr;
}
-void
+void
ge_cairo_set_color (cairo_t *cr, const CairoColor *color)
{
g_return_if_fail (cr && color);
@@ -275,9 +275,9 @@ ge_cairo_set_gdk_color_with_alpha (cairo_t *cr, const GdkColor *color, gdouble a
alpha);
}
-void
-ge_cairo_pattern_add_color_stop_color (cairo_pattern_t *pattern,
- gfloat offset,
+void
+ge_cairo_pattern_add_color_stop_color (cairo_pattern_t *pattern,
+ gfloat offset,
const CairoColor *color)
{
g_return_if_fail (pattern && color);
@@ -286,9 +286,9 @@ ge_cairo_pattern_add_color_stop_color (cairo_pattern_t *pattern,
}
void
-ge_cairo_pattern_add_color_stop_shade(cairo_pattern_t *pattern,
- gdouble offset,
- const CairoColor *color,
+ge_cairo_pattern_add_color_stop_shade(cairo_pattern_t *pattern,
+ gdouble offset,
+ const CairoColor *color,
gdouble shade)
{
CairoColor shaded;
@@ -408,16 +408,16 @@ ge_cairo_stroke_rectangle (cairo_t *cr, double x, double y, double w, double h)
/***********************************************
* ge_cairo_simple_border -
- *
+ *
* A simple routine to draw thin squared
* borders with a topleft and bottomright color.
- *
+ *
* It originated in Smooth-Engine.
***********************************************/
void
ge_cairo_simple_border (cairo_t *cr,
const CairoColor * tl, const CairoColor * br,
- gint x, gint y, gint width, gint height,
+ gint x, gint y, gint width, gint height,
gboolean topleft_overlap)
{
gboolean solid_color;
@@ -445,7 +445,7 @@ ge_cairo_simple_border (cairo_t *cr,
cairo_stroke (cr);
}
-
+
ge_cairo_set_color(cr, tl);
cairo_move_to(cr, x + 0.5, y + height - 0.5);
@@ -485,7 +485,7 @@ void ge_cairo_polygon (cairo_t *cr,
for (i = 1; i < npoints; i++)
{
if (!((points[i].x == points[i + 1].x) &&
- (points[i].y == points[i + 1].y)))
+ (points[i].y == points[i + 1].y)))
{
cairo_line_to(cr, points[i].x, points[i].y);
}
@@ -508,7 +508,7 @@ void ge_cairo_line (cairo_t *cr,
gint y1,
gint x2,
gint y2)
-{
+{
cairo_save(cr);
ge_cairo_set_color(cr, color);
@@ -578,11 +578,11 @@ ge_cairo_exchange_axis (cairo_t *cr,
/***********************************************
* ge_cairo_pattern_fill -
- *
+ *
* Fill an area with some pattern
* Scaling or tiling if needed
***********************************************/
-void
+void
ge_cairo_pattern_fill(cairo_t *canvas,
CairoPattern *pattern,
gint x,
@@ -653,7 +653,7 @@ ge_cairo_pattern_fill(cairo_t *canvas,
/***********************************************
* ge_cairo_color_pattern -
- *
+ *
* Create A Solid Color Pattern
***********************************************/
CairoPattern*
@@ -668,9 +668,9 @@ ge_cairo_color_pattern(CairoColor *base)
result->scale = GE_DIRECTION_NONE;
result->translate = GE_DIRECTION_NONE;
- result->handle = cairo_pattern_create_rgba(base->r,
- base->g,
- base->b,
+ result->handle = cairo_pattern_create_rgba(base->r,
+ base->g,
+ base->b,
base->a);
result->operator = CAIRO_OPERATOR_SOURCE;
@@ -680,7 +680,7 @@ ge_cairo_color_pattern(CairoColor *base)
/***********************************************
* ge_cairo_pixbuf_pattern -
- *
+ *
* Create A Tiled Pixbuf Pattern
***********************************************/
CairoPattern*
@@ -723,7 +723,7 @@ ge_cairo_pixbuf_pattern(GdkPixbuf *pixbuf)
/***********************************************
* ge_cairo_pixmap_pattern -
- *
+ *
* Create A Tiled Pixmap Pattern
***********************************************/
CairoPattern*
@@ -736,8 +736,8 @@ ge_cairo_pixmap_pattern(GdkPixmap *pixmap)
gdk_drawable_get_size (GDK_DRAWABLE (pixmap), &width, &height);
- pixbuf = gdk_pixbuf_get_from_drawable(NULL, GDK_DRAWABLE (pixmap),
- gdk_drawable_get_colormap(GDK_DRAWABLE (pixmap)),
+ pixbuf = gdk_pixbuf_get_from_drawable(NULL, GDK_DRAWABLE (pixmap),
+ gdk_drawable_get_colormap(GDK_DRAWABLE (pixmap)),
0, 0, 0, 0, width, height);
result = ge_cairo_pixbuf_pattern(pixbuf);
@@ -748,17 +748,17 @@ ge_cairo_pixmap_pattern(GdkPixmap *pixmap)
}
/***********************************************
- * ge_cairo_linear_shade_gradient_pattern -
- *
+ * ge_cairo_linear_shade_gradient_pattern -
+ *
* Create A Linear Shade Gradient Pattern
* Aka Smooth Shade Gradient, from/to gradient
* With End points defined as shades of the
* base color
***********************************************/
CairoPattern *
-ge_cairo_linear_shade_gradient_pattern(CairoColor *base,
- gdouble shade1,
- gdouble shade2,
+ge_cairo_linear_shade_gradient_pattern(CairoColor *base,
+ gdouble shade1,
+ gdouble shade2,
gboolean vertical)
{
CairoPattern * result = g_new0(CairoPattern, 1);
diff --git a/libs/clearlooks-newer/clearlooks_draw.c b/libs/clearlooks-newer/clearlooks_draw.c
index fa0b3e078b..29803a2d71 100644
--- a/libs/clearlooks-newer/clearlooks_draw.c
+++ b/libs/clearlooks-newer/clearlooks_draw.c
@@ -42,9 +42,9 @@ typedef void (*menubar_draw_proto) (cairo_t *cr,
int x, int y, int width, int height);
static void
-clearlooks_draw_inset (cairo_t *cr,
- const CairoColor *bg_color,
- double x, double y, double w, double h,
+clearlooks_draw_inset (cairo_t *cr,
+ const CairoColor *bg_color,
+ double x, double y, double w, double h,
double radius, uint8 corners)
{
CairoColor shadow;
@@ -100,7 +100,7 @@ clearlooks_draw_inset (cairo_t *cr,
static void
clearlooks_draw_shadow (cairo_t *cr, const ClearlooksColors *colors, gfloat radius, int width, int height)
{
- CairoColor shadow;
+ CairoColor shadow;
ge_shade_color (&colors->shade[6], 0.92, &shadow);
cairo_set_line_width (cr, 1.0);
@@ -119,7 +119,7 @@ clearlooks_draw_top_left_highlight (cairo_t *cr, const CairoColor *color,
const WidgetParameters *params,
int width, int height, gdouble radius)
{
- CairoColor hilight;
+ CairoColor hilight;
double light_top = params->ythickness-1,
light_bottom = height - params->ythickness - 1,
@@ -223,12 +223,12 @@ clearlooks_draw_gripdots (cairo_t *cr, const ClearlooksColors *colors, int x, in
ge_shade_color (dark, 1.5, &hilight);
- for ( i = 0; i < xr; i++ )
+ for ( i = 0; i < xr; i++ )
{
for ( j = 0; j < yr; j++ )
{
xoff = x -(xr * 3 / 2) + 3 * i;
- yoff = y -(yr * 3 / 2) + 3 * j;
+ yoff = y -(yr * 3 / 2) + 3 * j;
cairo_rectangle (cr, width/2+0.5+xoff, height/2+0.5+yoff, 2, 2);
cairo_set_source_rgba (cr, hilight.r, hilight.g, hilight.b, 0.8+contrast);
@@ -353,7 +353,7 @@ clearlooks_draw_button (cairo_t *cr,
ge_cairo_set_color (cr, border_disabled);
else
if (!params->active)
- clearlooks_set_border_gradient (cr, border_normal, 1.32, 0, height);
+ clearlooks_set_border_gradient (cr, border_normal, 1.32, 0, height);
else
ge_cairo_set_color (cr, border_normal);
@@ -412,7 +412,7 @@ clearlooks_draw_entry (cairo_t *cr,
}
else
{
- CairoColor shadow;
+ CairoColor shadow;
ge_shade_color (&border, 0.925, &shadow);
cairo_set_source_rgba (cr, shadow.r, shadow.g, shadow.b, params->disabled ? 0.05 : 0.1);
@@ -430,7 +430,7 @@ clearlooks_draw_entry (cairo_t *cr,
if (params->focus || params->disabled)
ge_cairo_set_color (cr, &border);
else
- clearlooks_set_border_gradient (cr, &border, 1.32, 0, height);
+ clearlooks_set_border_gradient (cr, &border, 1.32, 0, height);
cairo_stroke (cr);
}
@@ -441,7 +441,7 @@ clearlooks_draw_spinbutton (cairo_t *cr,
int x, int y, int width, int height)
{
const CairoColor *border = &colors->shade[!params->disabled ? 5 : 3];
- CairoColor hilight;
+ CairoColor hilight;
params->style_functions->draw_button (cr, colors, params, x, y, width, height);
@@ -468,7 +468,7 @@ clearlooks_draw_spinbutton_down (cairo_t *cr,
{
cairo_pattern_t *pattern;
double radius = MIN (params->radius, MIN ((width - 4.0) / 2.0, (height - 4.0) / 2.0));
- CairoColor shadow;
+ CairoColor shadow;
ge_shade_color (&colors->bg[GTK_STATE_NORMAL], 0.8, &shadow);
cairo_translate (cr, x+1, y+1);
@@ -624,9 +624,9 @@ clearlooks_draw_slider (cairo_t *cr,
cairo_pattern_add_color_stop_rgb (pattern, 1.0, spot->r, spot->g, spot->b);
cairo_set_source (cr, pattern);
}
- else
+ else
{
- CairoColor hilight;
+ CairoColor hilight;
ge_shade_color (fill, 1.5, &hilight);
cairo_set_source_rgba (cr, hilight.r, hilight.g, hilight.b, 0.5);
}
@@ -642,7 +642,7 @@ clearlooks_draw_slider (cairo_t *cr,
if (params->prelight || params->disabled)
ge_cairo_set_color (cr, border);
else
- clearlooks_set_border_gradient (cr, border, 1.2, 0, height);
+ clearlooks_set_border_gradient (cr, border, 1.2, 0, height);
cairo_stroke (cr);
/* Draw handle lines */
@@ -1021,10 +1021,10 @@ clearlooks_draw_menubar1 (cairo_t *cr,
static menubar_draw_proto clearlooks_menubar_draw[3] =
-{
- clearlooks_draw_menubar0,
+{
+ clearlooks_draw_menubar0,
clearlooks_draw_menubar1,
- clearlooks_draw_menubar2
+ clearlooks_draw_menubar2
};
static void
@@ -1042,7 +1042,7 @@ clearlooks_draw_menubar (cairo_t *cr,
}
static void
-clearlooks_get_frame_gap_clip (int x, int y, int width, int height,
+clearlooks_get_frame_gap_clip (int x, int y, int width, int height,
const FrameParameters *frame,
ClearlooksRectangle *bevel,
ClearlooksRectangle *border)
@@ -1219,7 +1219,7 @@ clearlooks_draw_tab (cairo_t *cr,
width += 3.0;
strip_size = 2.0/width;
- if (tab->gap_side == CL_GAP_LEFT)
+ if (tab->gap_side == CL_GAP_LEFT)
cairo_translate (cr, -3.0, 0.0); /* gap at the other side */
}
@@ -1263,8 +1263,8 @@ clearlooks_draw_tab (cairo_t *cr,
ge_shade_color (fill, 0.92, &shadow);
- cairo_pattern_add_color_stop_rgba (pattern, 0.0, hilight.r, hilight.g, hilight.b, 0.4);
- cairo_pattern_add_color_stop_rgba (pattern, 1.0/height, hilight.r, hilight.g, hilight.b, 0.4);
+ cairo_pattern_add_color_stop_rgba (pattern, 0.0, hilight.r, hilight.g, hilight.b, 0.4);
+ cairo_pattern_add_color_stop_rgba (pattern, 1.0/height, hilight.r, hilight.g, hilight.b, 0.4);
cairo_pattern_add_color_stop_rgb (pattern, 1.0/height, fill->r,fill->g,fill->b);
cairo_pattern_add_color_stop_rgb (pattern, 1.0, shadow.r,shadow.g,shadow.b);
cairo_set_source (cr, pattern);
@@ -1374,7 +1374,7 @@ clearlooks_draw_list_view_header (cairo_t *cr,
{
const CairoColor *border = &colors->shade[5];
cairo_pattern_t *pattern;
- CairoColor hilight;
+ CairoColor hilight;
CairoColor shadow;
ge_shade_color (border, 1.5, &hilight);
@@ -1452,7 +1452,7 @@ clearlooks_draw_toolbar (cairo_t *cr,
ge_cairo_set_color (cr, fill);
cairo_paint (cr);
- if (!toolbar->topmost)
+ if (!toolbar->topmost)
{
/* Draw highlight */
cairo_move_to (cr, 0, 0.5);
@@ -1661,8 +1661,8 @@ clearlooks_draw_scrollbar_stepper (cairo_t *cr,
s2 = colors->bg[widget->state_type];
ge_shade_color(&s2, 1.06, &s1);
- ge_shade_color(&s2, 0.98, &s3);
- ge_shade_color(&s2, 0.94, &s4);
+ ge_shade_color(&s2, 0.98, &s3);
+ ge_shade_color(&s2, 0.94, &s4);
cairo_pattern_add_color_stop_rgb(pattern, 0, s1.r, s1.g, s1.b);
cairo_pattern_add_color_stop_rgb(pattern, 0.5, s2.r, s2.g, s2.b);
@@ -1677,7 +1677,7 @@ clearlooks_draw_scrollbar_stepper (cairo_t *cr,
cairo_translate (cr, -0.5, -0.5);
ge_cairo_rounded_rectangle (cr, 0.5, 0.5, width-1, height-1, radius, corners);
- clearlooks_set_border_gradient (cr, &border, 1.2, (scrollbar->horizontal ? 0 : width), (scrollbar->horizontal ? height: 0));
+ clearlooks_set_border_gradient (cr, &border, 1.2, (scrollbar->horizontal ? 0 : width), (scrollbar->horizontal ? height: 0));
cairo_stroke (cr);
cairo_translate (cr, 0.5, 0.5);
@@ -1763,8 +1763,8 @@ clearlooks_draw_scrollbar_slider (cairo_t *cr,
s2 = colors->bg[widget->state_type];
ge_shade_color(&s2, 1.06, &s1);
- ge_shade_color(&s2, 0.98, &s3);
- ge_shade_color(&s2, 0.94, &s4);
+ ge_shade_color(&s2, 0.98, &s3);
+ ge_shade_color(&s2, 0.94, &s4);
pattern = cairo_pattern_create_linear(1, 1, 1, height-1);
cairo_pattern_add_color_stop_rgb(pattern, 0, s1.r, s1.g, s1.b);
@@ -1777,7 +1777,7 @@ clearlooks_draw_scrollbar_slider (cairo_t *cr,
cairo_fill(cr);
cairo_pattern_destroy(pattern);
- clearlooks_set_border_gradient (cr, &border, 1.2, 0, height);
+ clearlooks_set_border_gradient (cr, &border, 1.2, 0, height);
ge_cairo_stroke_rectangle (cr, 0.5, 0.5, width-1, height-1);
cairo_move_to (cr, 1.5, height-1.5);
diff --git a/libs/clearlooks-newer/clearlooks_draw_glossy.c b/libs/clearlooks-newer/clearlooks_draw_glossy.c
index a8dd9ef7a3..164ea2b33a 100644
--- a/libs/clearlooks-newer/clearlooks_draw_glossy.c
+++ b/libs/clearlooks-newer/clearlooks_draw_glossy.c
@@ -65,9 +65,9 @@ clearlooks_draw_glossy_gradient (cairo_t *cr,
}
static void
-clearlooks_set_mixed_color (cairo_t *cr,
- const CairoColor *color1,
- const CairoColor *color2,
+clearlooks_set_mixed_color (cairo_t *cr,
+ const CairoColor *color1,
+ const CairoColor *color2,
gdouble mix_factor)
{
CairoColor composite;
@@ -77,7 +77,7 @@ clearlooks_set_mixed_color (cairo_t *cr,
}
static void
-clearlooks_glossy_draw_inset (cairo_t *cr,
+clearlooks_glossy_draw_inset (cairo_t *cr,
const CairoColor *bg_color,
double x, double y, double w, double h,
double radius, uint8 corners)
@@ -133,9 +133,9 @@ clearlooks_glossy_draw_inset (cairo_t *cr,
}
static void
-clearlooks_glossy_draw_light_inset (cairo_t *cr,
- const CairoColor *bg_color,
- double x, double y, double w, double h,
+clearlooks_glossy_draw_light_inset (cairo_t *cr,
+ const CairoColor *bg_color,
+ double x, double y, double w, double h,
double radius, uint8 corners)
{
CairoColor shadow;
@@ -189,7 +189,7 @@ clearlooks_glossy_draw_light_inset (cairo_t *cr,
}
static void
-clearlooks_glossy_draw_highlight_and_shade (cairo_t *cr,
+clearlooks_glossy_draw_highlight_and_shade (cairo_t *cr,
const CairoColor *bg_color,
const ShadowParameters *params,
int width, int height, gdouble radius)
@@ -305,8 +305,8 @@ clearlooks_glossy_draw_button (cairo_t *cr,
cairo_translate (cr, -0.5, -0.5);
}
- clearlooks_draw_glossy_gradient (cr, xoffset+1, yoffset+1,
- width-(xoffset*2)-2, height-(yoffset*2)-2,
+ clearlooks_draw_glossy_gradient (cr, xoffset+1, yoffset+1,
+ width-(xoffset*2)-2, height-(yoffset*2)-2,
&fill, params->disabled, radius, params->corners);
/* Pressed button shadow */
@@ -714,7 +714,7 @@ clearlooks_glossy_draw_tab (cairo_t *cr,
{
width += 3.0;
- if (tab->gap_side == CL_GAP_LEFT)
+ if (tab->gap_side == CL_GAP_LEFT)
cairo_translate (cr, -3.0, 0.0); /* gap at the other side */
}
@@ -1001,7 +1001,7 @@ clearlooks_glossy_draw_scrollbar_slider (cairo_t *cr,
cairo_fill (cr);
cairo_pattern_destroy (pattern);
- if (scrollbar->has_color)
+ if (scrollbar->has_color)
{
cairo_set_source_rgba (cr, hilight.r, hilight.g, hilight.b, 0.5);
ge_cairo_stroke_rectangle (cr, 1.5, 1.5, width-3, height-3);
@@ -1081,7 +1081,7 @@ clearlooks_glossy_draw_list_view_header (cairo_t *cr,
}
}
-static void
+static void
clearlooks_glossy_draw_toolbar (cairo_t *cr,
const ClearlooksColors *colors,
const WidgetParameters *widget,
@@ -1104,7 +1104,7 @@ clearlooks_glossy_draw_toolbar (cairo_t *cr,
cairo_translate (cr, x, y);
if (toolbar->style == 1) /* Enable Extra features */
- {
+ {
cairo_pattern_t *pattern;
CairoColor shade1, shade2, shade3;
@@ -1126,11 +1126,11 @@ clearlooks_glossy_draw_toolbar (cairo_t *cr,
cairo_pattern_destroy (pattern);
}
else /* Flat */
- {
+ {
ge_cairo_set_color (cr, fill);
cairo_paint (cr);
- if (!toolbar->topmost)
+ if (!toolbar->topmost)
{
/* Draw highlight */
cairo_move_to (cr, 0, 0.5);
@@ -1330,7 +1330,7 @@ clearlooks_glossy_draw_checkbox (cairo_t *cr,
int x, int y, int width, int height)
{
const CairoColor *border;
- const CairoColor *dot;
+ const CairoColor *dot;
gboolean inconsistent = FALSE;
gboolean draw_bullet = (checkbox->shadow_type == GTK_SHADOW_IN);
@@ -1356,17 +1356,17 @@ clearlooks_glossy_draw_checkbox (cairo_t *cr,
if (widget->xthickness > 2 && widget->ythickness > 2)
{
- widget->style_functions->draw_inset (cr, &widget->parentbg, 0.5, 0.5,
+ widget->style_functions->draw_inset (cr, &widget->parentbg, 0.5, 0.5,
width-1, height-1, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
/* Draw the rectangle for the checkbox itself */
- ge_cairo_rounded_rectangle (cr, 1.5, 1.5,
+ ge_cairo_rounded_rectangle (cr, 1.5, 1.5,
width-3, height-3, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
}
else
{
/* Draw the rectangle for the checkbox itself */
- ge_cairo_rounded_rectangle (cr, 0.5, 0.5,
+ ge_cairo_rounded_rectangle (cr, 0.5, 0.5,
width-1, height-1, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
}
diff --git a/libs/clearlooks-newer/clearlooks_draw_gummy.c b/libs/clearlooks-newer/clearlooks_draw_gummy.c
index ca208c2ebc..748d163468 100644
--- a/libs/clearlooks-newer/clearlooks_draw_gummy.c
+++ b/libs/clearlooks-newer/clearlooks_draw_gummy.c
@@ -77,9 +77,9 @@ clearlooks_draw_gummy_gradient (cairo_t *cr,
}
static void
-clearlooks_set_mixed_color (cairo_t *cr,
- const CairoColor *color1,
- const CairoColor *color2,
+clearlooks_set_mixed_color (cairo_t *cr,
+ const CairoColor *color1,
+ const CairoColor *color2,
gdouble mix_factor)
{
CairoColor composite;
@@ -89,7 +89,7 @@ clearlooks_set_mixed_color (cairo_t *cr,
}
static void
-clearlooks_gummy_draw_highlight_and_shade (cairo_t *cr,
+clearlooks_gummy_draw_highlight_and_shade (cairo_t *cr,
const CairoColor *bg_color,
const ShadowParameters *params,
int width, int height, gdouble radius)
@@ -147,7 +147,7 @@ clearlooks_gummy_draw_top_left_highlight (cairo_t *cr, const CairoColor *color,
const WidgetParameters *params,
int width, int height, gdouble radius)
{
- CairoColor hilight;
+ CairoColor hilight;
double light_top = params->ythickness-1,
light_bottom = height - params->ythickness - 1,
@@ -230,8 +230,8 @@ clearlooks_gummy_draw_button (cairo_t *cr,
cairo_translate (cr, -0.5, -0.5);
}
- clearlooks_draw_gummy_gradient (cr, xoffset+1, yoffset+1,
- width-(xoffset*2)-2, height-(yoffset*2)-2,
+ clearlooks_draw_gummy_gradient (cr, xoffset+1, yoffset+1,
+ width-(xoffset*2)-2, height-(yoffset*2)-2,
&fill, params->disabled, radius, params->corners);
/* Pressed button shadow */
@@ -242,7 +242,7 @@ clearlooks_gummy_draw_button (cairo_t *cr,
cairo_save (cr);
- ge_cairo_rounded_rectangle (cr, xoffset+1, yoffset+1, width-(xoffset*2)-2, height, radius,
+ ge_cairo_rounded_rectangle (cr, xoffset+1, yoffset+1, width-(xoffset*2)-2, height, radius,
params->corners & (CR_CORNER_TOPLEFT | CR_CORNER_TOPRIGHT | CR_CORNER_BOTTOMLEFT));
cairo_clip (cr);
cairo_rectangle (cr, xoffset+1, yoffset+1, width-(xoffset*2)-2, 3);
@@ -323,7 +323,7 @@ clearlooks_gummy_draw_entry (cairo_t *cr,
}
else
{
- CairoColor shadow;
+ CairoColor shadow;
ge_shade_color (&border, 0.92, &shadow);
cairo_set_source_rgba (cr, shadow.r, shadow.g, shadow.b, params->disabled ? 0.09 : 0.18);
@@ -622,13 +622,13 @@ clearlooks_gummy_draw_scale_trough (cairo_t *cr,
cairo_translate (cr, 1, 1);
if (!slider->lower && !slider->fill_level)
- clearlooks_gummy_scale_draw_gradient (cr,
+ clearlooks_gummy_scale_draw_gradient (cr,
&colors->shade[2], /* bottom */
&colors->shade[6], /* border */
0, 0, trough_width, trough_height,
slider->horizontal, TRUE);
else if (!slider->fill_level)
- clearlooks_gummy_scale_draw_gradient (cr,
+ clearlooks_gummy_scale_draw_gradient (cr,
&colors->spot[1], /* bottom */
&colors->spot[2], /* border */
0, 0, trough_width, trough_height,
@@ -640,7 +640,7 @@ clearlooks_gummy_draw_scale_trough (cairo_t *cr,
c1.a = 0.25;
c2.a = 0.25;
- clearlooks_gummy_scale_draw_gradient (cr,
+ clearlooks_gummy_scale_draw_gradient (cr,
&c1, /* bottom */
&c2, /* border */
0, 0, trough_width, trough_height,
@@ -690,7 +690,7 @@ clearlooks_gummy_draw_tab (cairo_t *cr,
{
width += 3.0;
- if (tab->gap_side == CL_GAP_LEFT)
+ if (tab->gap_side == CL_GAP_LEFT)
cairo_translate (cr, -3.0, 0.0); /* gap at the other side */
}
@@ -953,8 +953,8 @@ clearlooks_gummy_draw_scrollbar_stepper (cairo_t *cr,
fill = colors->bg[widget->state_type];
ge_shade_color(&fill, SHADE_TOP, &shade1);
- ge_shade_color(&fill, SHADE_CENTER_TOP, &shade2);
- ge_shade_color(&fill, SHADE_BOTTOM, &shade3);
+ ge_shade_color(&fill, SHADE_CENTER_TOP, &shade2);
+ ge_shade_color(&fill, SHADE_BOTTOM, &shade3);
cairo_pattern_add_color_stop_rgb(pattern, 0, shade1.r, shade1.g, shade1.b);
cairo_pattern_add_color_stop_rgb(pattern, 0.5, shade2.r, shade2.g, shade2.b);
@@ -1055,7 +1055,7 @@ clearlooks_gummy_draw_scrollbar_slider (cairo_t *cr,
cairo_fill (cr);
cairo_pattern_destroy (pattern);
- if (scrollbar->has_color)
+ if (scrollbar->has_color)
{
cairo_set_source_rgba (cr, hilight.r, hilight.g, hilight.b, 0.2);
ge_cairo_stroke_rectangle (cr, 1.5, 1.5, width-3, height-3);
@@ -1429,7 +1429,7 @@ clearlooks_gummy_draw_checkbox (cairo_t *cr,
int x, int y, int width, int height)
{
const CairoColor *border;
- const CairoColor *dot;
+ const CairoColor *dot;
gboolean inconsistent = FALSE;
gboolean draw_bullet = (checkbox->shadow_type == GTK_SHADOW_IN);
@@ -1455,17 +1455,17 @@ clearlooks_gummy_draw_checkbox (cairo_t *cr,
if (widget->xthickness > 2 && widget->ythickness > 2)
{
- widget->style_functions->draw_inset (cr, &widget->parentbg, 0.5, 0.5,
+ widget->style_functions->draw_inset (cr, &widget->parentbg, 0.5, 0.5,
width-1, height-1, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
/* Draw the rectangle for the checkbox itself */
- ge_cairo_rounded_rectangle (cr, 1.5, 1.5,
+ ge_cairo_rounded_rectangle (cr, 1.5, 1.5,
width-3, height-3, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
}
else
{
/* Draw the rectangle for the checkbox itself */
- ge_cairo_rounded_rectangle (cr, 0.5, 0.5,
+ ge_cairo_rounded_rectangle (cr, 0.5, 0.5,
width-1, height-1, (widget->radius > 0)? 1 : 0, CR_CORNER_ALL);
}
diff --git a/libs/clearlooks-newer/clearlooks_draw_inverted.c b/libs/clearlooks-newer/clearlooks_draw_inverted.c
index 017c39d714..6b8939ce51 100644
--- a/libs/clearlooks-newer/clearlooks_draw_inverted.c
+++ b/libs/clearlooks-newer/clearlooks_draw_inverted.c
@@ -35,7 +35,7 @@ clearlooks_draw_top_left_highlight (cairo_t *cr,
const WidgetParameters *params,
int width, int height, gdouble radius)
{
- CairoColor hilight;
+ CairoColor hilight;
double light_top = params->ythickness-1,
light_bottom = height - params->ythickness - 1,
@@ -173,7 +173,7 @@ clearlooks_inverted_draw_button (cairo_t *cr,
ge_cairo_set_color (cr, border_disabled);
else
if (!params->active)
- clearlooks_set_border_gradient (cr, &border_normal, 1.32, 0, height);
+ clearlooks_set_border_gradient (cr, &border_normal, 1.32, 0, height);
else
ge_cairo_set_color (cr, &border_normal);
@@ -464,7 +464,7 @@ clearlooks_inverted_draw_tab (cairo_t *cr,
width += 3.0;
strip_size = 2.0/width;
- if (tab->gap_side == CL_GAP_LEFT)
+ if (tab->gap_side == CL_GAP_LEFT)
cairo_translate (cr, -3.0, 0.0); /* gap at the other side */
}
@@ -492,8 +492,8 @@ clearlooks_inverted_draw_tab (cairo_t *cr,
ge_shade_color (fill, 0.92, &shadow);
- cairo_pattern_add_color_stop_rgba (pattern, 0.0, hilight.r, hilight.g, hilight.b, 0.4);
- cairo_pattern_add_color_stop_rgba (pattern, 1.0/height, hilight.r, hilight.g, hilight.b, 0.4);
+ cairo_pattern_add_color_stop_rgba (pattern, 0.0, hilight.r, hilight.g, hilight.b, 0.4);
+ cairo_pattern_add_color_stop_rgba (pattern, 1.0/height, hilight.r, hilight.g, hilight.b, 0.4);
cairo_pattern_add_color_stop_rgb (pattern, 1.0/height, fill->r,fill->g,fill->b);
cairo_pattern_add_color_stop_rgb (pattern, 1.0, shadow.r,shadow.g,shadow.b);
cairo_set_source (cr, pattern);
@@ -611,7 +611,7 @@ clearlooks_inverted_draw_slider (cairo_t *cr,
cairo_set_source (cr, pattern);
}
else {
- CairoColor hilight;
+ CairoColor hilight;
ge_shade_color (fill, 1.5, &hilight);
cairo_set_source_rgba (cr, hilight.r, hilight.g, hilight.b, 0.5);
}
@@ -778,8 +778,8 @@ clearlooks_inverted_draw_scrollbar_stepper (cairo_t *cr,
pattern = cairo_pattern_create_linear (0, 0, width, 0);
s1 = colors->bg[widget->state_type];
- ge_shade_color(&s1, 0.95, &s2);
- ge_shade_color(&s1, 1.05, &s3);
+ ge_shade_color(&s1, 0.95, &s2);
+ ge_shade_color(&s1, 1.05, &s3);
cairo_pattern_add_color_stop_rgb(pattern, 0, s2.r, s2.g, s2.b);
cairo_pattern_add_color_stop_rgb(pattern, 1.0, s3.r, s3.g, s3.b);
@@ -790,7 +790,7 @@ clearlooks_inverted_draw_scrollbar_stepper (cairo_t *cr,
clearlooks_draw_top_left_highlight (cr, &s1, widget, width, height, radius);
ge_cairo_rounded_rectangle (cr, 0.5, 0.5, width-1, height-1, radius, corners);
- clearlooks_set_border_gradient (cr, &border, 1.2, (scrollbar->horizontal ? 0 : width), (scrollbar->horizontal ? height: 0));
+ clearlooks_set_border_gradient (cr, &border, 1.2, (scrollbar->horizontal ? 0 : width), (scrollbar->horizontal ? height: 0));
cairo_stroke (cr);
cairo_translate (cr, 0.5, 0.5);
@@ -878,8 +878,8 @@ clearlooks_inverted_draw_scrollbar_slider (cairo_t *cr,
pattern = cairo_pattern_create_linear(1, 1, 1, height-1);
s1 = colors->bg[widget->state_type];
- ge_shade_color(&s1, 0.95, &s2);
- ge_shade_color(&s1, 1.05, &s3);
+ ge_shade_color(&s1, 0.95, &s2);
+ ge_shade_color(&s1, 1.05, &s3);
cairo_pattern_add_color_stop_rgb(pattern, 0, s2.r, s2.g, s2.b);
cairo_pattern_add_color_stop_rgb(pattern, 1.0, s3.r, s3.g, s3.b);
diff --git a/libs/clearlooks-newer/clearlooks_rc_style.c b/libs/clearlooks-newer/clearlooks_rc_style.c
index 8d6e0aa898..a4f8032e65 100644
--- a/libs/clearlooks-newer/clearlooks_rc_style.c
+++ b/libs/clearlooks-newer/clearlooks_rc_style.c
@@ -80,7 +80,7 @@ clearlooks_gtk2_rc_symbols[] =
{ "contrast", TOKEN_CONTRAST },
{ "sunkenmenubar", TOKEN_SUNKENMENU },
{ "progressbarstyle", TOKEN_PROGRESSBARSTYLE },
- { "menubarstyle", TOKEN_MENUBARSTYLE },
+ { "menubarstyle", TOKEN_MENUBARSTYLE },
{ "toolbarstyle", TOKEN_TOOLBARSTYLE },
{ "menuitemstyle", TOKEN_MENUITEMSTYLE },
{ "listviewitemstyle", TOKEN_LISTVIEWITEMSTYLE },
@@ -281,7 +281,7 @@ clearlooks_gtk2_rc_parse_style (GtkSettings *settings,
return G_TOKEN_EQUAL_SIGN;
token = g_scanner_get_next_token (scanner);
-
+
switch (token)
{
case TOKEN_CLASSIC:
@@ -333,7 +333,7 @@ static guint
clearlooks_rc_style_parse (GtkRcStyle *rc_style,
GtkSettings *settings,
GScanner *scanner)
-
+
{
static GQuark scope_id = 0;
ClearlooksRcStyle *clearlooks_style = CLEARLOOKS_RC_STYLE (rc_style);
diff --git a/libs/clearlooks-newer/clearlooks_style.c b/libs/clearlooks-newer/clearlooks_style.c
index d1ac8d5d39..59e64d5430 100644
--- a/libs/clearlooks-newer/clearlooks_style.c
+++ b/libs/clearlooks-newer/clearlooks_style.c
@@ -237,7 +237,7 @@ clearlooks_style_draw_shadow (DRAW_ARGS)
cairo_destroy (cr);
}
-static void
+static void
clearlooks_style_draw_box_gap (DRAW_ARGS,
GtkPositionType gap_side,
gint gap_x,
@@ -379,7 +379,7 @@ clearlooks_style_draw_extension (DRAW_ARGS, GtkPositionType gap_side)
cairo_destroy (cr);
}
-static void
+static void
clearlooks_style_draw_handle (DRAW_ARGS, GtkOrientation orientation)
{
ClearlooksStyle *clearlooks_style = CLEARLOOKS_STYLE (style);
@@ -643,7 +643,7 @@ clearlooks_style_draw_box (DRAW_ARGS)
clearlooks_set_widget_parameters (widget, style, state_type, &params);
- STYLE_FUNCTION(draw_progressbar_trough) (cr, colors, &params,
+ STYLE_FUNCTION(draw_progressbar_trough) (cr, colors, &params,
x, y, width, height);
}
else if (DETAIL ("trough") && widget && (GE_IS_VSCROLLBAR (widget) || GE_IS_HSCROLLBAR (widget)))
@@ -1082,7 +1082,7 @@ clearlooks_style_draw_hline (GtkStyle *style,
cairo_destroy (cr);
}
-static void
+static void
clearlooks_style_draw_shadow_gap (DRAW_ARGS,
GtkPositionType gap_side,
gint gap_x,
@@ -1170,7 +1170,7 @@ clearlooks_style_draw_tab (DRAW_ARGS)
{
ClearlooksColors *colors;
WidgetParameters params;
- ArrowParameters arrow;
+ ArrowParameters arrow;
cairo_t *cr;
ClearlooksStyle *clearlooks_style = CLEARLOOKS_STYLE (style);
@@ -1185,7 +1185,7 @@ clearlooks_style_draw_tab (DRAW_ARGS)
clearlooks_set_widget_parameters (widget, style, state_type, &params);
arrow.type = CL_ARROW_COMBO;
- arrow.direction = CL_DIRECTION_DOWN;
+ arrow.direction = CL_DIRECTION_DOWN;
STYLE_FUNCTION(draw_arrow) (cr, colors, &params, &arrow, x, y, width, height);
@@ -1451,7 +1451,7 @@ set_transparency (const GdkPixbuf *pixbuf, gdouble alpha_percent)
for (x = 0; x < width; x++) {
/* The "4" is the number of chars per pixel, in this case, RGBA,
the 3 means "skip to the alpha" */
- current = data + (y * rowstride) + (x * 4) + 3;
+ current = data + (y * rowstride) + (x * 4) + 3;
*(current) = (guchar) (*(current) * alpha_percent);
}
}
@@ -1567,7 +1567,7 @@ clearlooks_style_draw_render_icon (GtkStyle *style,
g_warning ("Using the default screen for gtk_default_render_icon()"));
}
-
+
if (size != (GtkIconSize) -1 && !gtk_icon_size_lookup_for_settings (settings, size, &width, &height)) {
g_warning (G_STRLOC ": invalid icon size '%d'", size);
return NULL;
@@ -1590,7 +1590,7 @@ clearlooks_style_draw_render_icon (GtkStyle *style,
g_object_unref (scaled);
} else if (state == GTK_STATE_PRELIGHT) {
- stated = gdk_pixbuf_copy (scaled);
+ stated = gdk_pixbuf_copy (scaled);
gdk_pixbuf_saturate_and_pixelate (scaled, stated,
1.2, FALSE);
@@ -1602,7 +1602,7 @@ clearlooks_style_draw_render_icon (GtkStyle *style,
}
else
stated = scaled;
-
+
return stated;
}
diff --git a/libs/clearlooks-newer/clearlooks_theme_main.c b/libs/clearlooks-newer/clearlooks_theme_main.c
index c042fdbac0..e4c35b413c 100644
--- a/libs/clearlooks-newer/clearlooks_theme_main.c
+++ b/libs/clearlooks-newer/clearlooks_theme_main.c
@@ -19,5 +19,5 @@ theme_exit (void)
GE_EXPORT GtkRcStyle *
theme_create_rc_style (void)
{
- return GTK_RC_STYLE (g_object_new (CLEARLOOKS_TYPE_RC_STYLE, NULL));
+ return GTK_RC_STYLE (g_object_new (CLEARLOOKS_TYPE_RC_STYLE, NULL));
}
diff --git a/libs/clearlooks-newer/clearlooks_types.h b/libs/clearlooks-newer/clearlooks_types.h
index 7caf8a3208..6559f3c16c 100644
--- a/libs/clearlooks-newer/clearlooks_types.h
+++ b/libs/clearlooks-newer/clearlooks_types.h
@@ -108,7 +108,7 @@ typedef enum
CL_WINDOW_EDGE_EAST,
CL_WINDOW_EDGE_SOUTH_WEST,
CL_WINDOW_EDGE_SOUTH,
- CL_WINDOW_EDGE_SOUTH_EAST
+ CL_WINDOW_EDGE_SOUTH_EAST
} ClearlooksWindowEdge;
typedef struct
@@ -214,7 +214,7 @@ typedef struct
typedef struct
{
ClearlooksHandleType type;
- boolean horizontal;
+ boolean horizontal;
} HandleParameters;
typedef struct
@@ -301,7 +301,7 @@ struct _ClearlooksStyleFunctions
const WidgetParameters *widget,
const OptionMenuParameters *optionmenu,
int x, int y, int width, int height);
-
+
void (*draw_inset) (cairo_t *cr,
const CairoColor *bg_color,
double x, double y, double w, double h,
@@ -415,7 +415,7 @@ struct _ClearlooksStyleFunctions
const WidgetParameters *widget,
const ArrowParameters *arrow,
int x, int y, int width, int height);
-
+
void (*draw_checkbox) (cairo_t *cr,
const ClearlooksColors *colors,
const WidgetParameters *widget,
diff --git a/libs/clearlooks-newer/general-support.h b/libs/clearlooks-newer/general-support.h
index 25999e2d31..8df8019f02 100644
--- a/libs/clearlooks-newer/general-support.h
+++ b/libs/clearlooks-newer/general-support.h
@@ -36,4 +36,4 @@
# undef GE_INTERNAL
# define GE_EXPORT __global
# define GE_INTERNAL __hidden
-#endif
+#endif
diff --git a/libs/clearlooks-newer/widget-information.c b/libs/clearlooks-newer/widget-information.c
index cbeb00e291..0b30c52b72 100644
--- a/libs/clearlooks-newer/widget-information.c
+++ b/libs/clearlooks-newer/widget-information.c
@@ -6,15 +6,15 @@
#include <string.h>
/* Widget Type Lookups/Macros
-
+
Based on/modified from functions in
Smooth-Engine.
-*/
+*/
gboolean
ge_object_is_a (const GObject * object, const gchar * type_name)
{
gboolean result = FALSE;
-
+
if ((object))
{
GType tmp = g_type_from_name (type_name);
@@ -22,15 +22,15 @@ ge_object_is_a (const GObject * object, const gchar * type_name)
if (tmp)
result = g_type_check_instance_is_a ((GTypeInstance *) object, tmp);
}
-
+
return result;
}
-
+
gboolean
ge_is_combo_box_entry (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if ((widget) && (widget->parent))
{
if (GE_IS_COMBO_BOX_ENTRY (widget->parent))
@@ -40,30 +40,30 @@ ge_is_combo_box_entry (GtkWidget * widget)
}
return result;
}
-
+
static gboolean
ge_combo_box_is_using_list (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if (GE_IS_COMBO_BOX (widget))
{
gboolean *tmp = NULL;
-
+
gtk_widget_style_get (widget, "appears-as-list", &result, NULL);
if (tmp)
result = *tmp;
}
-
+
return result;
}
-
+
gboolean
ge_is_combo_box (GtkWidget * widget, gboolean as_list)
{
gboolean result = FALSE;
-
+
if ((widget) && (widget->parent))
{
if (GE_IS_COMBO_BOX (widget->parent))
@@ -78,12 +78,12 @@ ge_is_combo_box (GtkWidget * widget, gboolean as_list)
}
return result;
}
-
+
gboolean
ge_is_combo (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if ((widget) && (widget->parent))
{
if (GE_IS_COMBO (widget->parent))
@@ -93,18 +93,18 @@ ge_is_combo (GtkWidget * widget)
}
return result;
}
-
+
gboolean
ge_is_in_combo_box (GtkWidget * widget)
{
return ((ge_is_combo (widget) || ge_is_combo_box (widget, TRUE) || ge_is_combo_box_entry (widget)));
}
-
+
gboolean
ge_is_toolbar_item (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if ((widget) && (widget->parent)) {
if ((GE_IS_BONOBO_TOOLBAR (widget->parent))
|| (GE_IS_BONOBO_DOCK_ITEM (widget->parent))
@@ -117,12 +117,12 @@ ge_is_toolbar_item (GtkWidget * widget)
}
return result;
}
-
+
gboolean
ge_is_panel_widget_item (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if ((widget) && (widget->parent))
{
if (GE_IS_PANEL_WIDGET (widget->parent))
@@ -132,12 +132,12 @@ ge_is_panel_widget_item (GtkWidget * widget)
}
return result;
}
-
-gboolean
+
+gboolean
ge_is_bonobo_dock_item (GtkWidget * widget)
{
gboolean result = FALSE;
-
+
if ((widget))
{
if (GE_IS_BONOBO_DOCK_ITEM(widget) || GE_IS_BONOBO_DOCK_ITEM (widget->parent))
@@ -146,9 +146,9 @@ ge_is_bonobo_dock_item (GtkWidget * widget)
{
GtkContainer *box = GE_IS_BOX(widget)?GTK_CONTAINER(widget):GTK_CONTAINER(widget->parent);
GList *children = NULL, *child = NULL;
-
+
children = gtk_container_get_children(box);
-
+
for (child = g_list_first(children); child; child = g_list_next(child))
{
if (GE_IS_BONOBO_DOCK_ITEM_GRIP(child->data))
@@ -156,9 +156,9 @@ ge_is_bonobo_dock_item (GtkWidget * widget)
result = TRUE;
child = NULL;
}
- }
-
- if (children)
+ }
+
+ if (children)
g_list_free(children);
}
}
@@ -185,7 +185,7 @@ static GtkWidget *
ge_find_combo_box_widget (GtkWidget * widget, gboolean as_list)
{
GtkWidget *result = NULL;
-
+
if (widget)
{
if (GE_IS_COMBO_BOX (widget))
@@ -200,12 +200,12 @@ ge_find_combo_box_widget (GtkWidget * widget, gboolean as_list)
}
return result;
}
-
+
static GtkWidget *
ge_find_combo_widget (GtkWidget * widget)
{
GtkWidget *result = NULL;
-
+
if (widget)
{
if (GE_IS_COMBO (widget))
@@ -220,10 +220,10 @@ GtkWidget*
ge_find_combo_box_widget_parent (GtkWidget * widget)
{
GtkWidget *result = NULL;
-
+
if (!result)
result = ge_find_combo_widget(widget);
-
+
if (!result)
result = ge_find_combo_box_widget(widget, TRUE);
@@ -235,11 +235,11 @@ ge_find_combo_box_widget_parent (GtkWidget * widget)
/***********************************************
* option_menu_get_props -
- *
+ *
* Find Option Menu Size and Spacing
*
* Taken from Smooth
- ***********************************************/
+ ***********************************************/
void
ge_option_menu_get_props (GtkWidget * widget,
GtkRequisition * indicator_size,
@@ -249,12 +249,12 @@ ge_option_menu_get_props (GtkWidget * widget,
GtkBorder default_spacing = { 7, 5, 2, 2 };
GtkRequisition *tmp_size = NULL;
GtkBorder *tmp_spacing = NULL;
-
+
if ((widget) && GE_IS_OPTION_MENU(widget))
gtk_widget_style_get (widget,
"indicator_size", &tmp_size,
"indicator_spacing", &tmp_spacing, NULL);
-
+
if (tmp_size)
{
*indicator_size = *tmp_size;
@@ -262,7 +262,7 @@ ge_option_menu_get_props (GtkWidget * widget,
}
else
*indicator_size = default_size;
-
+
if (tmp_spacing)
{
*indicator_spacing = *tmp_spacing;
@@ -273,7 +273,7 @@ ge_option_menu_get_props (GtkWidget * widget,
}
void
-ge_button_get_default_border (GtkWidget *widget,
+ge_button_get_default_border (GtkWidget *widget,
GtkBorder *border)
{
GtkBorder default_border = {1, 1, 1, 1};
diff --git a/libs/clearlooks-newer/widget-information.h b/libs/clearlooks-newer/widget-information.h
index 55da859d78..a6dd807a37 100644
--- a/libs/clearlooks-newer/widget-information.h
+++ b/libs/clearlooks-newer/widget-information.h
@@ -1,9 +1,9 @@
/* Object Type Lookups/Macros
-
+
Based on/modified from functions in
Smooth-Engine.
-*/
+*/
#define GE_IS_WIDGET(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkWidget"))
#define GE_IS_CONTAINER(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkContainer"))
#define GE_IS_BIN(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkBin"))
@@ -13,7 +13,7 @@
#define GE_IS_SEPARATOR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkSeparator"))
#define GE_IS_VSEPARATOR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkVSeparator"))
#define GE_IS_HSEPARATOR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHSeparator"))
-
+
#define GE_IS_HANDLE_BOX(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHandleBox"))
#define GE_IS_HANDLE_BOX_ITEM(object) ((object) && GE_IS_HANDLE_BOX(object->parent))
#define GE_IS_BONOBO_DOCK_ITEM(object) ((object) && ge_object_is_a ((GObject*)(object), "BonoboDockItem"))
@@ -27,14 +27,14 @@
#define GE_IS_COMBO_BOX(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkComboBox"))
#define GE_IS_COMBO(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkCombo"))
#define GE_IS_OPTION_MENU(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkOptionMenu"))
-
+
#define GE_IS_TOGGLE_BUTTON(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkToggleButton"))
#define GE_IS_CHECK_BUTTON(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkCheckButton"))
#define GE_IS_SPIN_BUTTON(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkSpinButton"))
-
+
#define GE_IS_STATUSBAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkStatusbar"))
#define GE_IS_PROGRESS_BAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkProgressBar"))
-
+
#define GE_IS_MENU_SHELL(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkMenuShell"))
#define GE_IS_MENU(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkMenu"))
#define GE_IS_MENU_BAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkMenuBar"))
@@ -43,19 +43,19 @@
#define GE_IS_CHECK_MENU_ITEM(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkCheckMenuItem"))
#define GE_IS_RANGE(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkRange"))
-
+
#define GE_IS_SCROLLBAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkScrollbar"))
#define GE_IS_VSCROLLBAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkVScrollbar"))
#define GE_IS_HSCROLLBAR(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHScrollbar"))
-
+
#define GE_IS_SCALE(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkScale"))
#define GE_IS_VSCALE(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkVScale"))
#define GE_IS_HSCALE(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHScale"))
-
+
#define GE_IS_PANED(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkPaned"))
#define GE_IS_VPANED(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkVPaned"))
#define GE_IS_HPANED(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHPaned"))
-
+
#define GE_IS_BOX(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkBox"))
#define GE_IS_VBOX(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkVBox"))
#define GE_IS_HBOX(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkHBox"))
@@ -65,34 +65,34 @@
#define GE_IS_ENTRY(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkEntry"))
#define GE_IS_BUTTON(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkButton"))
#define GE_IS_FIXED(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkFixed"))
-
+
#define TOGGLE_BUTTON(object) (GE_IS_TOGGLE_BUTTON(object)?(GtkToggleButton *)object:NULL)
-
+
#define GE_IS_NOTEBOOK(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkNotebook"))
#define GE_IS_CELL_RENDERER_TOGGLE(object) ((object) && ge_object_is_a ((GObject*)(object), "GtkCellRendererToggle"))
#define GE_WIDGET_HAS_DEFAULT(object) ((object) && GE_IS_WIDGET(object) && GTK_WIDGET_HAS_DEFAULT(object))
GE_INTERNAL gboolean ge_object_is_a (const GObject * object, const gchar * type_name);
-
+
GE_INTERNAL gboolean ge_is_combo_box_entry (GtkWidget * widget);
GE_INTERNAL gboolean ge_is_combo_box (GtkWidget * widget, gboolean as_list);
GE_INTERNAL gboolean ge_is_combo (GtkWidget * widget);
GE_INTERNAL gboolean ge_is_in_combo_box (GtkWidget * widget);
-
+
GE_INTERNAL gboolean ge_is_toolbar_item (GtkWidget * widget);
-
+
GE_INTERNAL gboolean ge_is_panel_widget_item (GtkWidget * widget);
-
+
GE_INTERNAL gboolean ge_is_bonobo_dock_item (GtkWidget * widget);
GE_INTERNAL GtkWidget *ge_find_combo_box_widget_parent (GtkWidget * widget);
-GE_INTERNAL void ge_option_menu_get_props (GtkWidget * widget,
- GtkRequisition * indicator_size,
+GE_INTERNAL void ge_option_menu_get_props (GtkWidget * widget,
+ GtkRequisition * indicator_size,
GtkBorder * indicator_spacing);
-GE_INTERNAL void ge_button_get_default_border (GtkWidget *widget,
+GE_INTERNAL void ge_button_get_default_border (GtkWidget *widget,
GtkBorder *border);
GE_INTERNAL gboolean ge_widget_is_ltr (GtkWidget *widget);