Commit Graph

17 Commits

Author SHA1 Message Date
Benjamin Otte
1a143cd272 borderimage: Use style context as argument
... not the theming engine.
2014-08-16 19:39:44 +02:00
Benjamin Otte
fd73c1f8d9 themingengine: Draw fradctional border sizes 2012-10-31 11:09:12 +01:00
Benjamin Otte
1170ecfd2e cssvalue: Convert border-image-width to border value 2012-04-17 08:59:19 +02:00
Benjamin Otte
56f79fecce cssvalue: Add a border value
.. and parse border-image-slice with it.
2012-04-17 08:59:18 +02:00
Benjamin Otte
f785f7177c cssvalue: Add a custom value for repeats
In particular, that's background-repeat and border-image-repeat.

Also, fix up the border-image shorthand to allow any order.
2012-04-17 08:59:18 +02:00
Javier Jardón
9d0febc9a6 Change FSF Address 2012-02-27 17:06:11 +00:00
Benjamin Otte
fce45757cb borderimage: Change memory management
Making it a on-stack object simplifies things a lot.
2012-01-09 18:37:58 +01:00
Benjamin Otte
9b47a6a4e3 border-image: Remove pack/unpack functions
They are not used anymore. Also, it's no longer necessary to register
GtkBorderImage as a custom GType.
2012-01-09 18:37:58 +01:00
Benjamin Otte
84bc280440 borderimage: Add _gtk_border_image_new_for_context()
and use it.
2012-01-09 18:37:57 +01:00
Benjamin Otte
37b11b6c8a borderimage: Convert to using GtkCssImage 2012-01-09 18:37:57 +01:00
Benjamin Otte
32c8bbb575 styleproperty: Remove context arg from _gtk_style_context_query() 2012-01-09 18:37:56 +01:00
Alexander Larsson
c09148ca09 Add GtkStylePropertyContext and use it in when getting style properties
At the toplevel we have _gtk_theming_engine_get, which lets us pass
in a property context with (atm) the size to get the property for.
Then there is a lot of plumbing to push this down into the lower
layers of the style property code until finally hitting
the property resolvers.

I need this because I will be adding a property resolver for win32
theme parts, and they render differently depending on the size
(i.e. they don't scale linearly). The idea is that the code
to get the background properties will pass in the final size
and we will resolve the theme part specification to that particular
size.

If the old non-context calls are used we just hardcode a size
of 100x100.
2011-11-17 12:27:22 +01:00
Alexander Larsson
e953465e33 Save a generic boxes source in GtkImageBorder
We used to special handle gradient, but we want to be able to store
other sources (that will eventually resolve to cairo patterns).
For instance, this is needed to handle win32 theme part sources.
2011-11-17 12:27:21 +01:00
Cosimo Cecchi
3d1407a01a border-image: add support for border-image-width too
It's useful to set a slice size != border-width, as backgrounds are
clipped to border-width too.

As slices can be half-transparent and overlap the background,
this would not fill the border box properly if we only use a single
property for specifying the width.

Also, this brings us even closer to CSS3.
2011-06-09 20:01:57 -04:00
Benjamin Otte
c0a6b1fb90 borderimage: No need to resolve
border-image is a shorthand, so it's unpacked unresolved and repacked
resolved.
2011-06-09 05:51:54 +02:00
Cosimo Cecchi
4e95e6ae21 border-image: move private types to gtkcsstypes.c 2011-06-09 05:51:54 +02:00
Cosimo Cecchi
9976530fe0 border-image: change Gtk9Slice to GtkBorderImage
It's a similar private type, which is much more powerful, and respects
the CSS rendering specification for border-image.

https://bugzilla.gnome.org/show_bug.cgi?id=651194
2011-06-09 05:51:53 +02:00