Benjamin Otte
b89939f5a4
inspector: Split out a function
2015-11-01 02:42:36 +01:00
Matthias Clasen
7568d17a15
toolpalette: Use element names
...
Give the GtkToolPalette and GtkToolItemGroup the element
names toolpalette and toolitemgroup.
2015-10-31 21:02:36 -04:00
Matthias Clasen
cacc63ea4b
HighContrast: Update toolbutton styling
2015-10-31 20:55:51 -04:00
Matthias Clasen
1bc2913f52
Adwaita: Update tool button styling
2015-10-31 20:52:41 -04:00
Matthias Clasen
4323dd34f3
tool button: Add an element name
...
Unsurprisingly, it is toolbutton.
2015-10-31 20:52:09 -04:00
Matthias Clasen
dba8eba6db
HighContrast: Update toolbar styling
...
Adapt to the changes in the previous commit.
2015-10-31 20:43:07 -04:00
Matthias Clasen
5ffd54aca8
Adwaita: Update toolbar styling
...
Adapt to the changes in the previous commit.
2015-10-31 20:42:41 -04:00
Matthias Clasen
7ee7019ca7
toolbar: Use an element name instead of a style class
...
The element name is ... toolbar.
2015-10-31 20:30:56 -04:00
Matthias Clasen
479d64e89a
progress bar: Add CSS documentation
2015-10-31 20:30:15 -04:00
Matthias Clasen
ca385af3c4
HighContrast: Update progressbar styling
...
Adapt to the changes in the previous commit.
2015-10-31 20:24:46 -04:00
Matthias Clasen
71afd762ed
Adwaita: Update progressbar styling
...
Adapt to the changes in the previous commit.
2015-10-31 20:24:19 -04:00
Matthias Clasen
73704d98cc
progressbar: Convert to CSS nodes
...
Use the element names progressbar and progress.
2015-10-31 20:20:13 -04:00
Matthias Clasen
bab20f1d10
trivial formatting fix
2015-10-31 19:23:47 -04:00
Matthias Clasen
7ea33d82ed
Remove a duplicate include
2015-10-31 19:19:53 -04:00
Matthias Clasen
d3abd83330
Adwaita: Fix up color button styling
...
There was one forgotten instance of the GtkColorSwatch type name.
2015-10-31 19:13:32 -04:00
Matthias Clasen
7465601c1e
HighContrast: Update the frame styling
...
Adapt to the changes in the previous commit.
2015-10-31 19:11:18 -04:00
Matthias Clasen
3de78decd4
Adwaita: Update frame styling
...
Adapt to the changes in the previous commit.
2015-10-31 19:10:52 -04:00
Matthias Clasen
aa5dc38b0d
frame: Use an element name instead of a style class
...
Unsurprisingly, the element name is ... frame.
2015-10-31 19:09:46 -04:00
Matthias Clasen
1f585151fd
Load settings.ini from all data dirs
...
An error in the loading function was making us load the file from
the first data dir repeatedly, instead.
https://bugzilla.gnome.org/show_bug.cgi?id=757377
2015-10-31 18:16:10 -04:00
Matthias Clasen
e2e198aae4
model button: Propagate state
...
Propagate the state to the CSS node for the indicator.
2015-10-31 00:08:00 -04:00
Matthias Clasen
b6fda5dc0a
inspector: Show CSS node state
...
This is useful when debugging state propagation issues between
CSS nodes.
2015-10-31 00:07:19 -04:00
Matthias Clasen
c265b58181
HighContrast: adjust message dialog styling
2015-10-30 23:49:44 -04:00
Matthias Clasen
d70d5ea6ec
adwaita: Adjust message dialog styling
2015-10-30 23:49:17 -04:00
Matthias Clasen
4fe1b9589e
message dialog: Use an element name
2015-10-30 23:48:46 -04:00
Matthias Clasen
dfedda3dee
color editor: Redo the non-activatable color swatch
...
Use a .activatable style class on the color swatch and tie the
hover effect to it. The color editor simply removes this class
now to get an inert color swatch.
This is more flexible and lets us avoid referring to the
GtkColorEditor type in the theme.
2015-10-30 22:19:07 -04:00
Matthias Clasen
42a231a61c
HighContrast: Adapt to color swatch changes
...
This needs more work and simplification.
2015-10-30 21:46:36 -04:00
Matthias Clasen
4e8aea012e
Adwaita: Adapt to color swatch changes
...
This needs more work and simplification.
2015-10-30 21:44:19 -04:00
Matthias Clasen
5ec9b330b3
swatch fixup
2015-10-30 21:43:50 -04:00
Matthias Clasen
e5d3c8dbae
color swatch: Convert to CSS nodes
...
Convert GtkColorSwatch to use the two elements colorswatch and
image.
2015-10-30 21:29:46 -04:00
Matthias Clasen
e3ef2c48d5
text view: Add css node docs
2015-10-30 21:00:01 -04:00
Matthias Clasen
a4a3736461
HighContrast: Update textview styling
...
Some updates to make text appear as usual.
2015-10-30 19:58:11 -04:00
Matthias Clasen
b39601bcc1
Adwaita: Update textview styling
...
Some updates to make text appear as usual. The border windows
probably need some more work.
2015-10-30 19:55:42 -04:00
Matthias Clasen
844f60f1f2
text view: Convert to CSS nodes
...
Use subnodes for the border windows, and add children to the right
subnodes.
2015-10-30 19:49:02 -04:00
Matthias Clasen
2b998aaad7
text view: Set an element name
...
And it will be...drumroll...textview.
2015-10-30 18:11:13 -04:00
Matthias Clasen
ee3799f151
icon view: Add an element name
...
Not surprising anybody, I decided to call it iconview.
2015-10-30 17:44:36 -04:00
Matthias Clasen
f97e2599e3
HighContrast: Adapt to changed treeview names
2015-10-30 17:38:04 -04:00
Matthias Clasen
739e0c17a1
Adwaita: Adapt to changed treeview names
2015-10-30 17:37:32 -04:00
Matthias Clasen
5b360a479d
tree view: Rename and document element names
...
The names are now treeview and header.
2015-10-30 17:25:43 -04:00
Matthias Clasen
a24dba28ae
HighContrast: Update font button styling
...
Use the new element name and style class.
2015-10-30 17:18:06 -04:00
Matthias Clasen
2cff7a68f2
Adwaita: Update font button styling
...
Use the new element name and style class.
2015-10-30 17:17:41 -04:00
Matthias Clasen
bd456ac67b
font button: Add an element name
...
Give this GtkButton subclass element name button and style class .font.
2015-10-30 17:09:59 -04:00
Matthias Clasen
85d971b40b
HighContrast: Update paned styling
...
Adapt to the new element names.
2015-10-30 15:53:28 -04:00
Matthias Clasen
828faaba64
Adwaita: Update paned styling
...
Adapt to the new element names in the previous commit.
This also adds back a selected state which gets used
for when the focus is placed on the separator with F8,
just so this functionality is not forgotten.
2015-10-30 15:53:28 -04:00
Matthias Clasen
0f2ce2bb1c
paned: Convert to CSS nodes
...
Add a subnode for the separator, and use it for drawing.
2015-10-30 15:53:28 -04:00
Matthias Clasen
97c1782246
Update the generated css for the previous commit
2015-10-30 14:51:41 -04:00
Timm Bäder
33ac663b13
popover: Use element name
...
Pick "popover" and add .menu for popover menus
2015-10-30 15:10:35 +01:00
Georges Basile Stavracas Neto
50c6a11b05
placesview: vertically align path labels
...
The current situation is somewhat sad, with the path
label totally misaligned throughout the rows.
This is fixed by using a size group for the path labels,
so they all have the same allocated size (with the max
of 15 chars). Also, instead of hiding the eject button,
set it child-invisible, so it is hidden and yet it's size
is allocated by GtkBox.
https://bugzilla.gnome.org/show_bug.cgi?id=757303
2015-10-30 11:35:43 -02:00
Lapo Calamandrei
84380b345d
Adwaita: fix vertical switch styling
2015-10-30 13:17:52 +01:00
Lapo Calamandrei
0a845fb563
Adwaita: fix switch sizing
...
moving -GtkSwitch-slider-width and -GtkSwitch-slider-height from
the GtkSwitch selector to the * wildcard selector as other style
props.
2015-10-30 12:53:44 +01:00
Matthias Clasen
af3789bb87
inspector: Drop the style property list
...
Style properties are now shown for each CSS node in the
CSS node tab, so we don't need a separate per-widget tab
for this.
2015-10-30 06:51:43 -04:00
Matthias Clasen
91af42263b
inspector: Drop the style classes list
...
Style classes can now be added/removed for each CSS node in
the CSS node tab, so we don't need a separate per-widget tab
for this.
2015-10-30 06:51:43 -04:00
Matthias Clasen
aa6e0ad3f2
menu button: Revisit style class one more time
...
Use .popup, which is already in use elsewhere, fits better with
the other button differentiating style classes, and does not
interfere with menus.
2015-10-30 06:16:10 -04:00
Matthias Clasen
c925a840b2
HighContrast: Update color button styling
...
Adapt to the previous commit.
2015-10-30 06:16:10 -04:00
Matthias Clasen
e148876dd4
Adwaita: Update color button styling
...
Adapt to the previous commit.
2015-10-30 06:16:10 -04:00
Matthias Clasen
7d18398eeb
color button: Add a style class
...
Add a .color style class to differentiate this button from the
normal ones.
2015-10-30 06:16:10 -04:00
Matthias Clasen
43e2ee31bc
HighContrast: Update headerbar styling
...
Adapt to the previous commit.
2015-10-30 01:09:18 -04:00
Matthias Clasen
40f9a0fe69
Adwaita: Update headerbar styling
...
Adapt to the previous commit.
2015-10-30 01:08:30 -04:00
Matthias Clasen
8c0c0f9c07
headerbar: Use an element name instead of a style class
...
Use the element name headerbar.
2015-10-30 01:07:58 -04:00
Matthias Clasen
b9c565b06c
Revisit menu button style
...
Change the style class to .menubutton, to avoid interference
from GtkMenu theming.
2015-10-30 01:07:27 -04:00
Matthias Clasen
ee81f3ee2f
menu button: Add a style class
...
Add a .menu style class to differentiate menu buttons from normal
ones.
2015-10-30 00:56:00 -04:00
Matthias Clasen
2c5e25a5c7
scale button: Add a style class
...
Add a .scale style class to differentiate scale buttons from normal
ones.
2015-10-30 00:51:13 -04:00
Matthias Clasen
4cd408e8d0
link button: Add a style class
...
Add a .link style class to differentiate link buttons from normal
buttons.
2015-10-30 00:50:48 -04:00
Matthias Clasen
9e5914ebde
HighContrast: Updates for recent changes
...
This is bit of a grab-bag, it includes fixes for spin buttons,
entries, buttons.
2015-10-30 00:40:50 -04:00
Matthias Clasen
d0e91ec088
Adwaita: Adapt to the button changes
...
The updates here cover the various button variants.
2015-10-30 00:40:50 -04:00
Matthias Clasen
8894e46183
model button: Convert to CSS nodes
...
Follow the same approach as used for the toggle button family:
Keep the button element name for button-like rendering, and
use a distinct modelbutton name otherwise, and add a subnode
for the indicator with name check or radio.
2015-10-30 00:40:50 -04:00
Matthias Clasen
c631656f0c
toggle button: Convert to css nodes
...
Convert GtkToggleButton and its subclasses to CSS nodes.
Keep the button element name for when we want to render
these button-like (but with .toggle, .check and .radio
style classes for differentiation).
When we want to render them with an indicator, use distinct
element names checkbutton and radiobutton, and add a subnode
for the indicator with name check or radio.
2015-10-30 00:40:50 -04:00
Matthias Clasen
826633b5b7
lockbutton: Revisit element name
...
Instead of a separate element name, keep button, and just
add a .lock style class, to inherit the button theming.
2015-10-30 00:26:04 -04:00
Matthias Clasen
cc2f189144
Adwaita: button fixes
2015-10-29 23:17:41 -04:00
Matthias Clasen
b350779a6f
togglebutton: Add a style class
...
This lets us differentiate toggle buttons from plain buttons
with button.toggle, without having to redo all the styling.
2015-10-29 23:04:47 -04:00
Matthias Clasen
a953e37735
button: Use an element name instead of a style class
2015-10-29 22:55:29 -04:00
Benjamin Otte
e39b8611bd
widget: Queue redraw on gtk_widget_queue_allocate()
...
Mirror the behavior of gtk_widget_queue_resize() and always queue a
redraw. If we ever want to cause allocates without redraws we can add
gtk_widget_queue_allocate_no_redraw() then.
I had initially assumed gtk_widget_size_allocate() would take care of
queueing redraws, but it does not do that when neither size nor position
change. And that is obviously what's happening after
gtk_widget_queue_allocate().
Fixes buttons sometimes not redrawing (the record button in
widget-factory after locking it, all buttons when switching to the dark
theme).
2015-10-30 02:09:17 +01:00
Matthias Clasen
32de7edf1d
Assistant: Fix page rmoval
...
We have to remove the page itself from the intermediate box
first, before removing the box from the notebook. Otherwise,
reffing the page to keep it alive is ineffective: the box
gets destroyed, and that destruction recurses over the page.
This fixes the problem in
https://bugzilla.gnome.org/show_bug.cgi?id=756385
2015-10-29 19:21:47 -04:00
Sébastien Granjoux
ffaaa1e66e
Add a more complex widget in the flipping assistant
...
This reproduces the problem from bug
https://bugzilla.gnome.org/show_bug.cgi?id=756385
2015-10-29 19:21:20 -04:00
Florian Müllner
a0a78a8973
Adwaita: Update double-border tweak for scrolled windows
...
Since commit b6dbfc791f
, GtkViewPort uses an element name.
2015-10-29 18:24:40 +01:00
Dominique Leuenberger
4f24c8569c
placessidebar: do not crash if uris is NULL
...
On Drag'n'Drop actions across system boundaries (VM host to guest), the
happen to be null.
https://bugzilla.gnome.org/show_bug.cgi?id=757298
2015-10-29 17:32:13 +01:00
Benjamin Otte
fc6f41c751
spinbutton: Don't set .entry
...
Also fix Adwaita to not use .entry anymore
2015-10-29 16:03:15 +01:00
Benjamin Otte
63f2fc752a
searchentry: Fix includes
2015-10-29 15:55:28 +01:00
Matthias Clasen
b6dbfc791f
viewport: Add an element name to the css node
...
This lets us avoid hardcoding the type in CSS.
2015-10-29 07:47:31 -04:00
Matthias Clasen
ea5f16fd2d
searchbar: Add an element name to the css node
...
This lets us avoid hardcoding the type in CSS.
2015-10-29 07:43:30 -04:00
Matthias Clasen
d634403d91
actionbar: Add an element name to the css node
...
This lets us avoid hardcoding the type in CSS.
2015-10-29 07:08:15 -04:00
Matthias Clasen
2936d7bae8
statusbar: Add an element name to the css node
...
This lets us avoid hardcoding the type in CSS.
2015-10-29 07:01:57 -04:00
Matthias Clasen
56d3e42a00
search entry: Add a style class
...
There should be little need to have separate styling for search
entries, so a separate name would be a bit overkill.
2015-10-28 23:58:39 -04:00
Matthias Clasen
a840a6d597
lock button: Add an element name
2015-10-28 23:57:57 -04:00
Matthias Clasen
bb7d7851ac
entry, spinbutton: Finish css node conversion
...
This commit creates entry and button subnodes for the buttons
in GtkSpinButton. The nodes are ordered like this for horizontal
spinbutton
+ entry
+ image.left
+ image.right
+ progress
+ button.down
+ button.up
and like this for vertical ones:
spinbutton
+ button.down
+ entry
+ button.up
This arrangement requires cooperation from GtkEntry to place
the entry subnodes correctly, and some small changes in the theme.
This commit also fixes progress rendering in vertical spin buttons.
2015-10-28 23:43:32 -04:00
Matthias Clasen
ebcad63e31
wip: spinbutton
2015-10-28 21:55:13 -04:00
Matthias Clasen
811c1c9484
spinbutton: Trivial cleanup
...
Use g_clear_object in a few places.
2015-10-28 21:55:13 -04:00
Benjamin Otte
4483636016
widget: Queue resize on parent on show/hide
...
When gtk_widget_show() or gtk_widget_hide() is called, don't queue a
resize on the widget itself but on the parent.
The widget itself may already be marked as in need of a resize and
the call would be optimized out and never reach the parent.
The parent size will change though because a child widget just changed
its visibility.
Fixes a bunch of issues with menus appearing black, toolbas not hiding
in widget-factory and also various reftests.
2015-10-29 01:03:09 +01:00
Benjamin Otte
cd20ae8fe1
container: Don't keep our own variable trying to track need for resize
...
Insteaad, introduce gtk_widget_needs_allocate() and use that.
2015-10-28 19:44:29 +01:00
Benjamin Otte
e07ff714b9
widget: Make invisible widgets not propagate resizes
...
Do not queue a resize on the parent if the widget is not visible.
Invisible widgets do not influence the parents size.
2015-10-28 19:44:29 +01:00
Benjamin Otte
bef44ab294
window: Don't queue resizes when inhibiting resizes
...
Since the frame clock, the inhibit happens on the GDK level, so this
code is no longer necessary.
2015-10-28 19:44:29 +01:00
Benjamin Otte
6866d1c06e
widget: Make gtk_widget_queue_allocate() not resize
...
This commit toggles the big switch. We now don't run size_allocate()
from the toplevel up anymore in cases where we don't need to.
Things might be broken in subtle ways as a result of this commit. We'll
have to find them and fix them.
2015-10-28 19:44:28 +01:00
Benjamin Otte
299600a7d4
widget: Track if a child needs an allocation
...
This is not used so far.
2015-10-28 19:44:28 +01:00
Benjamin Otte
f706891dd3
widget: Refactor function
...
Turn it from a loop into tail-calling itself.
2015-10-28 19:44:28 +01:00
Benjamin Otte
ab7e901cfd
widget: Move resize function into gtkwidget.c
...
There's no sizegroup specific code left in it, but lots of
widget-specifics.
2015-10-28 19:44:28 +01:00
Benjamin Otte
4fa74e68e9
sizegroup: Merge function into only caller
2015-10-28 19:44:28 +01:00
Benjamin Otte
b5dfe9b833
sizegroup: Simplify widget's size group invalidation
...
Since we do not queue resizes twice anymore, we can just walk the list
of groups without deduplication.
2015-10-28 19:44:28 +01:00
Benjamin Otte
a31123e9f0
sizegroup: Skip resizes on widgets that have resize queued
...
Widgets that already have a resize queued don't need to walk the whole
parent chain and queue another resize. It's enough to do it once per
resize.
This also means that sizegroups cannot use the shortcut of just
invalidating the first widget in the group anymore. That widget might
already have a resize queued while others don't.
2015-10-28 19:44:28 +01:00
Benjamin Otte
a4587ef4a0
widget: Warn on calls to queue_resize() during size_allocate()
...
This happens way too much, so it's disabled unless GTK_DEBUG=geometry is
on.
Also, we can't detect it in the call to queue_resize() yet, only during
size_allocate(), so the warning comes after the signal emission.
2015-10-28 19:44:28 +01:00
Benjamin Otte
4d631a9144
widget: Clear pending resizes after size_allocate()
...
This catches the cases where widgets call gtk_widget_queue_resize()
in their size_allocate() callback.
2015-10-28 19:44:28 +01:00
Benjamin Otte
3e3f17576e
widget: Warn if size-unqueried widgets get allocated
...
Widgets should have gtk_widget_get_preferred_width/height() called
on them before gtk_widget_size_allocate() gets called.
Add a check for this.
2015-10-28 19:44:28 +01:00