Commit Graph

22034 Commits

Author SHA1 Message Date
Matthias Clasen
c16fa45bfe inspector: Use a separate display connection
This helps isolate the inspector from some of the changes that
it can trigger. To specify a different display, set
GTK_INSPECTOR_DISPLAY to the name of the display to use for
the inspector window. If no display is specified, GTK+ will
use a separate connection to the default display.
2014-10-24 15:57:33 -04:00
Matthias Clasen
fea13fcfc1 Fix a problem with screen changes and csd
When a new screen is set on a window, we unrealize it, to
recreate all the resources. But we don't reset the client_decorated
flag, so realize() doesn't call create_decoration() - which makes
sense, since the decoration already exists. But the side-effect
of create_decoration() is to select the rgba visual, and visuals
are per-screen.

Fix this by looking for the rgba visual in set_screen(), and
replacing it with the rgba visual for the new screen, if necessary.
2014-10-24 15:57:33 -04:00
Benjamin Otte
2002613012 styleproperties: Move into deprecated directory 2014-10-24 21:31:40 +02:00
Benjamin Otte
a51378dda8 styleproperties: Deprecate 2014-10-24 21:31:40 +02:00
Benjamin Otte
433c20e59d styleproperties: Remove header where it's not used 2014-10-24 21:31:40 +02:00
Benjamin Otte
e2a0780543 styleproperties: Remove unused function 2014-10-24 21:31:40 +02:00
Benjamin Otte
a1f7c459b7 css: Disallow bypassing value computation
This special code was added back in the days when computation wasn't
idemptotent. These days it is.

Also, the bypass code path is only used in fallback code that is pretty
much unused.
2014-10-24 21:31:40 +02:00
Benjamin Otte
ec8a29b0c2 css: Remove unneeded header 2014-10-24 21:31:39 +02:00
Matthias Clasen
1aa3000ae6 Inspector: Show more misc info about widgets
This adds clip area, accessible role, mapped, realize,
is-toplevel, child-visible, mnemonic labels and tick
callbacks to the displayed information.
2014-10-24 08:34:13 -04:00
Matthias Clasen
a55000613a Add private API to query tick callbacks
This information can be useful for debugging purposes.
2014-10-24 08:34:13 -04:00
Lapo Calamandrei
1c3475d58a Revert "Adwaita: axes borders of notebooks inside frame"
This reverts commit 01e6811776.
This assumption doesn't work latelly
2014-10-24 13:01:41 +02:00
Chun-wei Fan
1c099ec784 gtk/deprecated/gtkstatusicon.c: Fix Build on C89 Compilers
Declare variable at the top of the block, which is needed from the change
in commit 1bad7865.
2014-10-24 12:23:31 +08:00
Emmanuele Bassi
183257f9e1 docs: Add replacement example for ImageMenuItem
Otherwise we will be doomed to answer the question of how to replace
GtkImageMenuItem for all eternity.
2014-10-23 17:42:19 +01:00
Brion Vibber
1bad7865d3 Fix to gtkstatusicon.c to allow building both X11 and Quartz backends
https://bugzilla.gnome.org/show_bug.cgi?id=739005
2014-10-22 22:56:51 -04:00
Joanmarie Diggs
2893a71a3e Implement support for ATK_STATE_HAS_TOOLTIP
https://bugzilla.gnome.org/show_bug.cgi?id=738982
2014-10-22 22:55:13 -04:00
Robert Ancell
0f26b26f1d Gdk: add an experimental backend for mir
This is disabled by default.  Enable with --enable-mir-backend.

This backend is a combined work of Robert Ancell and Ryan Lortie.
2014-10-22 11:17:15 -05:00
Matthias Clasen
911f3fb6d2 Drop a reference to gtkthemingengineprivate.h
That file does not exist.
2014-10-22 01:18:54 -04:00
Matthias Clasen
fc13ff501d GtkSidebar: Make docs show up 2014-10-22 01:13:00 -04:00
Matthias Clasen
e14c0bb394 Document gtk_sidebar_get_stack 2014-10-22 01:12:59 -04:00
Matthias Clasen
33851dbe24 Document gtk_printer_option_set_get_groups 2014-10-22 01:12:59 -04:00
Matthias Clasen
10f3d330be Fix docs for gtk_settings_set_property_value 2014-10-22 00:32:38 -04:00
Matthias Clasen
f73db86a63 Fix docs for gtk_css_provider_load_from_resource 2014-10-22 00:32:38 -04:00
Matthias Clasen
3b3a623520 Add new papersize api to the docs 2014-10-22 00:32:32 -04:00
Benjamin Otte
7d96770453 cssnodedeclaration: Fix src/dest swap in memmove()
The main cause here were the wrong style classes being removed, such as
"message-dialog" instead of "csd" for GtkMessageDialog.
2014-10-22 03:39:17 +02:00
Lapo Calamandrei
cf5f6759f0 Adwaita: use -gtk-icon-source: none on paned...
...to get rid of the handle decoration istead of setting a transparent
background and abuse a background image for the background color.
2014-10-21 20:35:50 +02:00
Benjamin Otte
c2864a81a4 modelbutton: Fix up for style context changes
- Don't do work anymore that's done in GtkButton
- Don't do a save/restore just to set the state, instead set the state
  in the right places.
2014-10-21 20:31:05 +02:00
Benjamin Otte
727bdd1929 inspector: Add missing directory when scanning for themes 2014-10-21 20:31:05 +02:00
Lapo Calamandrei
298974b9da Adwaita: colorswatch on selected elements style fix 2014-10-21 16:34:42 +02:00
Lapo Calamandrei
01e6811776 Adwaita: axes borders of notebooks inside frame
This is what the old adwaita did, not having a better solution for
removing double borders, better to have this back even if it can
be problematic in certain cases.
2014-10-21 15:37:39 +02:00
Lapo Calamandrei
51bfa10eed Adwaita: properly fix places sidebar
Forgot to treat treeview background... Some code refactoring in
the process.
2014-10-21 15:37:39 +02:00
Lapo Calamandrei
01b4720ec8 Adwaita: wide paned separator style
...paned separator decoration fixed in the process.
2014-10-21 13:25:17 +02:00
Bastien Nocera
d0f4e73999 gtkwidget: Fix typo in comment 2014-10-21 10:10:50 +02:00
Benjamin Otte
8abc6e06b2 css: Add "-gtk-icon-source: builtin"
... and make it the default. This takes over the meaning from "none" for
this property in that it draws the fallback builtin image.
"none" now literally means no image will be drawn.
2014-10-21 05:53:19 +02:00
Benjamin Otte
7eb3b6c71f stylecontext: fix icon-source extents computation
for the builtin image or invalid matrix case. We used to return invalid
memory in those cases. And that was not good.
2014-10-21 05:53:19 +02:00
Benjamin Otte
57d24f173a render: We use CHECKED now, not ACTIVE
Update docs and custom rendering of checkmarks and radio buttons
2014-10-21 05:53:19 +02:00
Matthias Clasen
4ed98878c6 GtkScrolledWindow: Add documentation
Document the new overlay scrolling APIs, and add some more
documentation for the other touch support: kinetic scrolling
and overshoot.
2014-10-20 23:07:45 -04:00
Matthias Clasen
47ce01116b Add some overlay scrollbar theming to Adwaita 2014-10-20 23:07:45 -04:00
Matthias Clasen
4455266c5b GtkScrolledWindow: Add overlay scrollbars
This commit adds a mode to GtkScrolledWindow in which it puts
narrow, auto-hiding scrollbars over the content, instead of
allocating room for the scrollbars outside of the content. We
use traditional scrollbars if we find a mouse or if overlay
scrolling has explicitly turned off.

For test purposes, GTK_TEST_TOUCHSCREEN can be used to get
overlay scrolling even in the presence of a mouse. The
environment variable GTK_OVERLAY_SCROLLING can also be used
to force overlay scrolling on or off.
2014-10-20 23:07:45 -04:00
Matthias Clasen
1fad6b049b GtkRange: Add a style class during dragging
This will be used to identify a scrollbar is being dragged - we
don't actually need the style class; another way to keep track
of the dragging status would be ok too.
2014-10-20 23:07:45 -04:00
Benjamin Otte
a3995d8c86 stylecontext: Handle querying the wrong state better
When a getter function (like get_color()) is called and the passed in
state doesn't match the current state returned via get_state(), we used
to do a trick: We called save()/set_state() on the context before
getting the values.

Unfortunately, since 3a337156d1 this
has the unfortunate side effect that it also creates a child element.
This breaks various old codebases (spinbutton has been fixed in
998feeb2bc, Webkit is fixed in
https://bugs.webkit.org/show_bug.cgi?id=137803 ) unfortunately.

So instead, look up the values manually ensuring that no child element
is created but the correct state is used.
2014-10-21 03:03:28 +02:00
Benjamin Otte
caf709bb81 stylecontext: Return a ref in lookup_values_for_state
This will be necessary when we stop caching values for lookups with the
"wrong" state.
2014-10-21 03:03:28 +02:00
Benjamin Otte
cc2f2dd9b8 computedvalues: Add to_string() and print() functions
The functions are unused. But they are very convenient to use from a
debugger, if you know what I mean...
2014-10-21 03:03:28 +02:00
Benjamin Otte
4cc4e18d56 stylecontext: Don't copy CSS values on context_save()
Keeping them is a bad idea now where the widget paths are actually
changed by a save(). And almost all of the time, state or style classes
will be changed anyway.

Looking them up again is just a hash table lookup anyway.
2014-10-21 03:03:28 +02:00
Benjamin Otte
57cafc277b stylecontext: Use node declaration in hash
Don't use the StyleInfo anymore.
2014-10-21 03:03:28 +02:00
Benjamin Otte
5c2c659122 stylecontext: Split out functionality into custom object
GtkCssNodeDeclaration is a new struct with copy-on-write semantics.

It encapsulated the properties used to define a node in the CSS tree.

The idea is to use it in various places for caching, in particular as
key in hash tables.
2014-10-21 03:03:28 +02:00
Carlos Garnacho
ca9d15df92 scrolledwindow: Add ::edge-overshot signal
This signal is emitted whenever user scrolling hits the overshoot
edge in the given direction. May be useful to add "reload" or "load
more" behaviors in apps.

https://bugzilla.gnome.org/show_bug.cgi?id=738534
2014-10-20 18:52:43 +02:00
Lapo Calamandrei
c84f544fc3 Adwaita: GtkPlacesSidebar treeview text color fix
With my latest changes we have a darker text color for views and
entries (which I assume are content), the places sidebar is totally
chrome though so it needs the chrome text color back.
2014-10-20 15:25:30 +02:00
Matthias Clasen
cf0c9eb158 GtkPaned: Add a "wide-handle" property
This can be used by applications to indicate that a paned is expected
to be actively used by the users for configuring the UI, and needs
a prominent handle.

https://bugzilla.gnome.org/show_bug.cgi?id=738860
2014-10-20 08:50:53 -04:00
Matthias Clasen
d7b64c63e0 Improve tooltip-text/markup docs
Clarify priorities between the two,
https://bugzilla.gnome.org/show_bug.cgi?id=681185
2014-10-19 23:28:34 -04:00
Matthias Clasen
a8f4269157 GtkAboutDialog: Don't shout
Don't use all-caps in the UI - it looks scary.

https://bugzilla.gnome.org/show_bug.cgi?id=671138
2014-10-19 23:16:06 -04:00