Commit Graph

46559 Commits

Author SHA1 Message Date
Cosimo Cecchi
2f420d0e14 scale: use gadgets instead of nodes for mark containers
The gadget is not yet allocated though.
2016-02-29 10:45:14 -08:00
Cosimo Cecchi
b73d274d55 scale: rename function arguments
To make them clearer. No functional change here.
2016-02-29 10:45:14 -08:00
Cosimo Cecchi
8d5d16ae56 scale: remove unused argument
It's always GTK_POS_TOP.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
bc41ff8af4 range: better hack for GtkColorScale
Just draw the slider, since that is the only thing GtkColorScale cares
about.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
887b6d65a1 range: deprecate gtk_range_get/set_min_slider_size()
Nothing uses these functions inside GTK anymore.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
424f17c0fb range: don't use gtk_range_set_min_slider_size()
The way this method is used from the GtkRange subclasses doesn't really
work well when the slider properties change as a consequence of e.g. a
style class being applied (e.g. the fine-tune style class).

In fact, there's no need to read the minimum slider size out of band,
and we can obtain the same result in a way that always work by setting a
private property on GtkRange.
2016-02-29 10:45:13 -08:00
Lapo Calamandrei
0468ff1545 Adwaita: some more WIP theme work for the new scale 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
3ff66edb6b gadget: simplify code 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
0883ff5eed range: use border box for slider area
Since we can use negative margins, we should not use the margin box
for the slider area. Use the border box instead, since that's what is
typically mapped to the visible area.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
6ecab5ee6b range: use new GtkCssGadget API instead of rolling our own 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
44178c0541 gadget: add API to get various area boxes
Compared to the function returning the allocation, these will return the
box in gadget coordinates.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
2d2a81682d range: simplify code
Instead of directly accessing the widget allocation, we can use the
gadget API to test whether the coordinates are in the main gadget.
2016-02-29 10:45:13 -08:00
Lapo Calamandrei
622f5aef4e Adwaita: WIP for new range theme 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
d1433c25f3 range: add a gadget for the whole widget area
This commit introduces another node, called "contents", that holds the
main contents of the range. This allows for the main gadget itself to
span across the whole surface of the widget now.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
a9ea544f3d scale: always add marks at the beginning or the end
Marks are always either the first or the last child of the scale.
2016-02-29 10:45:13 -08:00
Cosimo Cecchi
1d047f0097 range: use new GtkBoxGadget API instead of counting children 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
6370d6cb27 boxgadget: add APIs to insert gadgets next to siblings 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
6401e2405e range: use new GtkBoxGadget API instead of removing/inserting 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
06776d3d2f boxgadget: add API to set expand/align flags for gadget child 2016-02-29 10:45:13 -08:00
Cosimo Cecchi
6827bd5e04 range: move slider drawing where it belongs
The slider gadget is a child of the trough gadget, so draw it from
there.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
f0d9afd300 scrollbar: deprecate min-slider-length style property
In favor of min-height/min-width, like we did for other similar
properties.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
0974b0d843 range: whitespace fix 2016-02-29 10:45:12 -08:00
Cosimo Cecchi
fb11cc1baf range: remove border allocation hack
We can achieve the same result with a negative margin.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
1a116b9a95 colorscale: don't use style properties to determine slider size 2016-02-29 10:45:12 -08:00
Cosimo Cecchi
8b87eca11e Revert "range: move GtkColorScale special case to GtkColorScale"
This reverts commit d93d266ed9e3e26e382a4f6d4b5d4ea19eff3bcf.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
b927fc0874 Revert "range: simplify code"
This reverts commit a74f7dcaf8a02c96c6bfecab6969e1d33ecb9332.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
a7099d1468 range: simplify code
Now that everything is in the main gadget, we can just let it propagate
drawing to its children.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
b6f0b6be87 range: move GtkColorScale special case to GtkColorScale
Now we can just tweak the node visibility for it.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
cbbe237c18 range: remove special case that's not needed
We already set the gadget not to be visible in that case.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
ddb863e523 range: move slider inside the trough
This will require a rewrite of most of the theme, but it's the right
thing to do.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
d1c5ecfaef scale: deprecate slider-length style property
This can be achieved using min-height/min-width CSS properties now.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
c1eff2cce5 range: deprecate more style properties
These are never read now.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
413b9d5b3c range: continue porting to GtkGadgets
This commit rewrites a lot of the GtkRange internals to make full use
of the gadget structure.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
e9fe46ea5f gadget: add hit test functions
These will be useful in later commits.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
8c43b3ee60 range: remove unused code 2016-02-29 10:45:12 -08:00
Cosimo Cecchi
6c19947859 range: remove call that is not needed
gtk_range_calc_slider() already calls the same function when needed.
2016-02-29 10:45:12 -08:00
Cosimo Cecchi
83a6471c4e range: simplify code a bit 2016-02-29 10:45:11 -08:00
Cosimo Cecchi
d19215015e range: don't call gtk_range_calc_layout() in realize()
This should not be needed, and we want to get rid of
gtk_range_calc_layout().
2016-02-29 10:45:11 -08:00
Cosimo Cecchi
1f9de3cfec range: deprecate arrow-scaling style property
This can be done with CSS now.
2016-02-29 10:45:11 -08:00
Cosimo Cecchi
3b37f2a42a range: use newer GtkCssGadget API 2016-02-29 10:45:11 -08:00
Cosimo Cecchi
d0c671ddfe range: deprecate trough-under-steppers
It's not clear what this would do in a CSS world, and all the themes set
it to TRUE anyway...
2016-02-29 10:45:11 -08:00
Cosimo Cecchi
4bb0a8db47 range: first pass at porting to gadgets
There's still a lot to be done, but this is functional and we'll improve
the loose ends in the next commits.
2016-02-29 10:45:11 -08:00
Matthias Clasen
10e24b8e19 Move the level bar release note to the right section 2016-02-29 13:17:39 -05:00
Paolo Borelli
33ac51ea72 win32: init wintab when the device manager is constructed
No need to call a method explicitely after creating the object
2016-02-29 18:25:01 +01:00
Paolo Borelli
e9d2a622e2 win32: actually call _gdk_win32_screen_on_displaychange_event
41a371c435 factored out a method
but I forgot to actually amend the commit to call the new function
2016-02-29 18:25:01 +01:00
Ray Strode
316fe1dbbd wayland: deal with staging buffer getting allocated prematurely
The staging buffer gets allocated any time begin_paint is called
on the window. This can happen even with an empty paint region,
so we should cope with that situation. At the moment we crash
trying to post a runtime warning.

https://bugzilla.gnome.org/show_bug.cgi?id=762755
2016-02-29 10:52:00 -05:00
Jordi Mas
6ad67451f4 Fixes to Catalan translation 2016-02-29 16:34:30 +01:00
Timm Bäder
41119057dd frame: Fix horizontal size request
We were adding the border gadget size and the label widget size in any
case, but when calculating the width, we want the maximum of those two,
not the sum.

https://bugzilla.gnome.org/show_bug.cgi?id=760482
2016-02-29 14:19:38 +01:00
Paolo Borelli
38ad57948c gdk: remove the core_pointer field from GdkDisplay
It is not used anymore, so no need to set it

https://bugzilla.gnome.org/show_bug.cgi?id=762820
2016-02-29 14:15:04 +01:00
Paolo Borelli
502744be85 quartz: get the core pointer from the device manager
https://bugzilla.gnome.org/show_bug.cgi?id=762820
2016-02-29 14:15:04 +01:00