Benjamin Otte [Sat, 4 Jun 2011 19:13:19 +0000 (21:13 +0200)]
widget: Update the font at the right place
Doing it unconditionally is not useful when the subclasses actually
using them can only ever do it in the style_updated signal. So do it in
the style_updated handler instead.
Matthias Clasen [Fri, 3 Jun 2011 03:26:09 +0000 (23:26 -0400)]
gail: Add back get_name for menu items
This was lost when GailItem was nuked. Not having it is leading
to problems, even though randomly poking strings out of your children
seems to be a less than perfect approach to naming...
Benjamin Otte [Thu, 2 Jun 2011 00:31:44 +0000 (02:31 +0200)]
Revert "css: Make font property a shorthand"
The hack in gtk_style_context_get_font() was causing segfaults in
combobox code. This is not acceptable and I'm not awake enough to fix
it, so just reverting until it's fixed sanely is easiest.
Benjamin Otte [Tue, 31 May 2011 10:42:30 +0000 (12:42 +0200)]
Revert "API: Add API to set style properties to be inherit"
Inheritance is now done using style property flags, so thereis no ned
anymore to clobber the pspec flags namespace.
Also, there is no need to expose this functionality in the public API
without exposing more of the styleproperty API.
Benjamin Otte [Mon, 30 May 2011 18:25:41 +0000 (20:25 +0200)]
themingengine: Improve junction handling code
As junctions just modify the border radius and we now have a per-corner
border-radius, we can just set the border-radius to 0 for those corners
and get the same effect.
Benjamin Otte [Thu, 26 May 2011 01:50:53 +0000 (03:50 +0200)]
css: Add all border-radius properties
Implement all border-radisu properties as specified by
http://www.w3.org/TR/css3-background/#the-border-radius
The end goal here is to get joined buttons to really look joined.
Benjamin Otte [Wed, 25 May 2011 23:01:44 +0000 (01:01 +0200)]
css: Rename function to _gtk_style_property_parse_value()
... and take an optional style property as argument. This way, we can
allow custom parse functions for properties. The style property needs to
be optional so that we can use it for widget style properties, too.
Benjamin Otte [Mon, 23 May 2011 05:16:17 +0000 (07:16 +0200)]
styleproperty: Change _css_value_to_string()
Name it _gtk_style_property_print_value() and actually pass it the style
property. This way, we can later change it to use custom print functions
for different style properties.
Benjamin Otte [Wed, 25 May 2011 20:21:15 +0000 (22:21 +0200)]
API: Change semantics of gtk_container_get_child_path()
Include the child widget path in the returned path now. This allows
customizing the path of the current widgets - like adding flags to child
widgets (and maybe siblings in the future).
Benjamin Otte [Wed, 1 Jun 2011 15:45:14 +0000 (17:45 +0200)]
notebook: Include arrow size in tab size computation
We don't want tabs to resize when a 2nd page is added, just because the
scroll arrows are now visible. And we do want the arrow size to be
included.
Note: Previosuly this code was never run, as the check
requisition->width < tab_width
was only run when tab_width wasn't computed, so was still equal to 0
(same for the height). So what this patch essentially does it add the
functionality of the if switch.
Matthias Clasen [Tue, 31 May 2011 23:12:13 +0000 (19:12 -0400)]
GtkApplication: Add window-added/-removed signals
This is useful to let unrelated parts of an application (or
plugins) learn about the windows of an application. Based
on a patch by Matt Barnes,
https://bugzilla.gnome.org/show_bug.cgi?id=641087
Carlos Garnacho [Mon, 30 May 2011 17:29:22 +0000 (19:29 +0200)]
gtkcssprovider: Free shorthand border GValues in the right place
The call to gtk_border_free() within unpack_border() felt completely
in the wrong place, as the border actually pertains to the GValue
being unpacked. Plus, the GValue itself was also being leaked.
Carlos Garnacho [Mon, 30 May 2011 17:26:28 +0000 (19:26 +0200)]
gtkcssprovider: plug several leaks
In finalize(), clear all rulesets.
In parse_declaration(), Free the GValue under unhandled error situations.
In gtk_css_provider_load_internal(), Do not leak the file contents.
Carlos Garnacho [Mon, 30 May 2011 17:21:42 +0000 (19:21 +0200)]
gtkstyleproperty: Plug two leaks
In rgba_value_parse(), unref the symbolic color once we've resolved it.
In gradient_value_parse(), take the GtkGradient so we leave no dangling
references.
Carlos Garnacho [Mon, 30 May 2011 17:04:22 +0000 (19:04 +0200)]
gtkcssprovider: Use g_slice_dup() to copy GValues around
GValues stored in GtkCssRulesets are gslice managed, so don't
g_memdup() GValues from shorthand properties. This fixes
memory corruptions when reloading contents in a GtkCssProvider.