Commit Graph

18962 Commits

Author SHA1 Message Date
Matthias Clasen
e5317f0f9a Improve struct packing in various places 2013-09-21 23:50:55 -04:00
Matthias Clasen
d137f74fe9 Remove priv pointer from GtkStackSwitcher
This is a new widget, so lets avoid the unnecessary
priv pointer while we still can.
2013-09-21 23:50:55 -04:00
Matthias Clasen
f0aba21fd2 Small cleanup for the previous commit
When setting an accessible type, we don't need to
set an accessible row anymore.
2013-09-21 20:56:46 -04:00
Matthias Clasen
c22e27f986 Add a GtkListBoxRow accessible
This lets us do two things:
1. Set the list-item role
2. Set selectable and selected states as appropriate

https://bugzilla.gnome.org/show_bug.cgi?id=692258
2013-09-21 20:51:22 -04:00
Matthias Clasen
bdd4d65e85 Small improvement to GtkLinkButton a11y
ATK has a visited state, so propagate the visited property
of GtkLinkButton to that state.
2013-09-21 20:51:21 -04:00
Federico Mena Quintero
1e5dde7eab places sidebar: Don't activate the bookmark if Eject was clicked
This should really fix https://bugzilla.gnome.org/show_bug.cgi?id=704087 ...

Signed-off-by: Federico Mena Quintero <federico@gnome.org>
2013-09-20 21:14:00 -05:00
Matthias Clasen
9f3627cd7c Trivial typo fix 2013-09-20 20:17:25 -04:00
Matthias Clasen
dab146fe30 Add accessible names to csd buttons
Its the right thing to do.
2013-09-20 15:02:17 -04:00
Florian Müllner
f081552da1 icontheme: Make sure icon_info->scale doesn't end up 0
GdkPixbuf will fail returning %NULL if we try to scale a pixbuf to (0, 0),
which will then trigger an assertion in gtk_icon_info_load_icon_finish();
we never want a scale of 0, so ensure it is at least 1.

https://bugzilla.gnome.org/show_bug.cgi?id=708384
2013-09-20 14:42:41 +02:00
Joshua Lock
24751cba8e places sidebar: don't open a bookmark when clicking eject
Trying to open a bookmark which is being ejected is at best confusing.

https://bugzilla.gnome.org/show_bug.cgi?id=704087
2013-09-19 18:05:49 -05:00
Alexander Larsson
7b7b8eaaff listbox: Don't crash if cursor_row is NULL in real_focus
https://bugzilla.gnome.org/show_bug.cgi?id=708320
2013-09-19 22:38:41 +02:00
Timm Bäder
e6ac9b0862 ListBox: Update docs of GtkListBoxUpdateHeaderFunc
before is always NULL for the first row.
2013-09-19 22:05:08 +02:00
Benjamin Otte
20696b1057 cssimage: Report filename of file failing to load 2013-09-18 17:07:41 +02:00
Cosimo Cecchi
fd581236d2 Revert "appchooserwidget: check for g_app_info_should_show()"
This reverts commit 84922d3317.

https://bugzilla.gnome.org/show_bug.cgi?id=702681
2013-09-17 11:01:36 -07:00
Cosimo Cecchi
b561e176fb Revert "appchooserbutton: filter out applications not supposed to be visible"
This reverts commit 5568dcb53c.

https://bugzilla.gnome.org/show_bug.cgi?id=702681
2013-09-17 11:01:30 -07:00
Benjamin Otte
8c0516a5f1 window: Fix child wfh size request
We need to subtract border_width from the size we're passing to the
children hfw functions as those are added by ourselves.

Fixes the window-border-width.ui reftest.
2013-09-17 15:52:27 +02:00
Matthias Clasen
6aa56979dc More documentation fixes 2013-09-17 01:28:39 -04:00
Matthias Clasen
dbbb9c8f8f Plug a memory leak in the css parser
color_value_parse was leaking a GtkCssSymbolicValue.
Reported in

https://bugzilla.gnome.org/show_bug.cgi?id=702034
2013-09-16 23:30:57 -04:00
Philip Chimento
c298c7acce Don't activate GtkExpander if mouse dragged away
Previously, when you clicked and held the button down on a
GtkExpander's label or disclosure triangle, then moved the mouse
away and released the button, the expander would still activate.
This brings the behavior in line with the more generally expected
behavior, as exhibited by GtkButton for example.

https://bugzilla.gnome.org/show_bug.cgi?id=706345
2013-09-16 22:43:02 -04:00
Matthias Clasen
f503d4debd Clarify GtkH/VBox documentation
Make it clearer that GtkBox still has uses.

https://bugzilla.gnome.org/show_bug.cgi?id=706269
2013-09-16 22:38:49 -04:00
Matthias Clasen
58e9e9d316 Improve gtk_widget_insert_action_group docs
Mention that group can be NULL. Related to

https://bugzilla.gnome.org/show_bug.cgi?id=708150
2013-09-16 21:13:00 -04:00
Matthias Clasen
eab0b3a59c Improve headerbar docs slightly
Explain how to achieve the same title lable style when using
a custom title.
2013-09-16 20:24:48 -04:00
Matthias Clasen
54773ba45b Allow theme to set close button position in headerbars
This allows GTK+ applications with headerbars to fit in
better in platforms that have window controls on the left.

To use this, set -GtkWindow-decoration-button-layout: 'close:'
in the theme.

https://bugzilla.gnome.org/show_bug.cgi?id=706708
2013-09-16 16:13:07 -04:00
Matthias Clasen
aa1435b741 Include CSD titlebar in focus chain
At least for header bars, there's often application controls
in this area, which should be included in the focus chain.
We make it so that the initial focus avoids the titlebar,
but tabbing around will eventually get there.

https://bugzilla.gnome.org/show_bug.cgi?id=708067
2013-09-16 14:38:38 -04:00
Matthias Clasen
d632474b74 Don't pass NULL to gdk_window_set_title
That is not allowed. This is fallout from a recent change
that makes GtkWindow listen for title changes in its
headerbar.
2013-09-16 13:07:18 -04:00
Benjamin Otte
45d896a6b5 Revert "a11y: Remove AtkSelection implementation from combobox"
This reverts commit 7cecc8e524.

It is impossible to use the selection object of the menu while it is
collapsed (collapsed menus deselect everything for a start), so even
though the original patch was correct, the followup issues are too big
to solve this quickly to a release.

https://bugzilla.gnome.org/show_bug.cgi?id=707786
2013-09-16 15:41:15 +02:00
Murray Cumming
98ca9a865f GtkWidget: Improve drag-leave and drag-data-received docs.
* gtk/gtkwidget.c: drag-leave signal: Document that it is called before
      drag-drop.
      drag-data-received signal: Document that it is up to the application
      to know why the data was requested (e.g. drag motion or drop).
    * demos/gtk-demo/toolpalette.c: interactive_canvas_drag_drop():
      Do not transform the drop_item created in the drag-motion handler.
      Instead caused drag-data-received to be called, remembering why,
      and create a new item there.
      interactive_canvas_drag_leave(): Remove the idle-handler hack,
      now that we do not need to keep the drag-motion drop_item alive until
      the drop.

I noticed that this patch was sitting in bug #605611 from 2009
though it had been approved. I do not remember much about why I
created it.
2013-09-16 14:06:14 +02:00
Kalev Lember
5f62785d41 listbox: Jump over insensitive rows with keynav
https://bugzilla.gnome.org/show_bug.cgi?id=708128
2013-09-16 11:43:26 +02:00
Alexander Larsson
247c4cecfc Don't ever return BASELINE from gtk_widget_get_halign
This is the same behaviour as gtk_widget_get_valign, except
we have no gtk_wiget_get_halign_with_baseline, as baselines make
no sense for halign.

Without this some widgets (like e.g. GtkOverlay) crash if you accidentally
set a BASELINE halign.
2013-09-16 12:33:56 +02:00
Sébastien Wilmet
310179176c Improve doc of gtk_text_buffer_paste_clipboard()
It didn't explain the behavior when there is a non-empty buffer
selection.

https://bugzilla.gnome.org/show_bug.cgi?id=339539
2013-09-16 09:48:24 +02:00
Sébastien Wilmet
8e916815bb textbuffer: fix selection replacement when pasting
It is more logical to first delete the selection and then pasting the
text. When the selection and the text contain tags, the new behavior is
more natural.

A segfault in paste_from_buffer() is also avoided. The segfault occurs when
the text to paste is deleted because it is the selection.

https://bugzilla.gnome.org/show_bug.cgi?id=339539
2013-09-16 09:48:24 +02:00
Sébastien Wilmet
a78fc4a9c5 Doc: small fixes in GtkTextView
Move GtkWrapMode from GtkTextTag to the GtkTextView section. The wrap
mode property is in the text view.

Links to the "mark-set" and "mark-deleted" signals.

Add a precision about gtk_text_buffer_get_iter_at_line().

Fix typo in gtk_text_tag_set_priority().

https://bugzilla.gnome.org/show_bug.cgi?id=708076
2013-09-14 21:45:00 +02:00
Alejandro Piñeiro
5045e1a91b GtkWindow: keep sync the title with own titlebar
Before this change, both titles were synced only if
gtk_window_set_title was called. Now both are synced
also calling gtk_header_bar_set_title
2013-09-13 18:08:58 +02:00
Alejandro Piñeiro
94d52f99f8 a11y: Set proper role for GtkHeaderBar
https://bugzilla.gnome.org/show_bug.cgi?id=707981
2013-09-13 11:02:11 +02:00
Alejandro Piñeiro
c6943fcbcf a11y: set ATK_ROLE_LIST_ITEM to GtkListBoxRow
https://bugzilla.gnome.org/show_bug.cgi?id=707915
2013-09-13 11:01:44 +02:00
Alejandro Piñeiro
ef41c2a60f a11y: Remove default description from GtkSwitch
https://bugzilla.gnome.org/show_bug.cgi?id=707926
2013-09-12 11:52:51 +02:00
Alejandro Piñeiro
a86c665398 a11y: not using default name for switch
A proper name or label is required. In the same way, if the
widget is labelled, ATs uses to expose both the label and the
name, making the final output not really user-friendly.

https://bugzilla.gnome.org/show_bug.cgi?id=707872
2013-09-10 22:46:35 -04:00
Matthias Clasen
096f2db4b0 Make logos in GtkAboutDialog bigger
When available, choose a size of up to 128 in GtkAboutDialog.
A 48x48 icon just looks too small in there.
2013-09-10 22:45:06 -04:00
Phil Clayton
59c4fb9d6a Add missing introspection annotations
https://bugzilla.gnome.org/show_bug.cgi?id=707519
2013-09-10 17:20:15 -04:00
Alexander Larsson
90383300d2 listbox: Set activate_signal on listboxrow class
keyboard navigation didn't support activation since we moved
the keynav to the child row widgets. We fix this by adding a
activate signal handler for the row and setting
widget_class->activate_signal to it.

https://bugzilla.gnome.org/show_bug.cgi?id=707778
2013-09-10 16:20:56 +02:00
Benjamin Otte
6d344b2c6b Revert "pango: Handle case where pango_layout_get_text() returns NULL"
This reverts commit 70ac2b24c3.

It turns out the correct fix is to make pango_layout_get_text() not
return NULL. This has been done, so we can drop this patch.

I won't bump the Pango dependency in configure.ac for this as I don't
consider the crash critical enough.
2013-09-09 17:19:28 +02:00
Benjamin Otte
70ac2b24c3 pango: Handle case where pango_layout_get_text() returns NULL
Fixes crashers with accessibility

https://bugzilla.gnome.org/show_bug.cgi?id=707659
2013-09-09 16:53:13 +02:00
Alexander Larsson
92edb76500 Pixel cache: Add no-pixel-cache debug flag
This is useful for benchmarking comparisons, and to verify if bugs
happend with or without the pixel cache.
2013-09-09 11:07:50 +02:00
Christian Hergert
9a45712ad6 textview: use pixelcache rendered area to inform invalidation region.
Use the pixelcache rendered area to inform what part of the cache should
be invalidated upon changes to the underlying textlayout.

By rendering the background to the pixelcache, we can avoid the need to
use RGBA content.

Also, we're using the pixel cache on the text windows bin_window (see
gtk_text_view_get_window) so we need to register the invalidation handler
on that, otherwise the region passed to the invalidate handler will get
clipped to the visible region.

https://bugzilla.gnome.org/show_bug.cgi?id=707244
2013-09-09 10:47:30 +02:00
Christian Hergert
7fabc94d3c pixelcache: add getter for extra width and height. 2013-09-06 15:57:22 -07:00
Christian Hergert
0eb8479256 textview: only set invalidate handler for text window. 2013-09-06 15:57:22 -07:00
Matthias Clasen
fc7d26860a Fix config dir <> data dir confusion
We added code to look for settings.ini in system config dirs,
and then proceeded to move it to /usr/share/gtk-3.0 :-(. So,
look in that location as well.
2013-09-06 09:43:16 -04:00
Benjamin Otte
e6e99c4f9f css: Change currentColor handling
We now pass NULL when the current color should be the default value of
the "color" property and we haven't looked up any value yet. This way we
don't need to look it up all the time and more importantly we can
resolve the default color, which is required because it's a
GtkCssColorValue and not a GtkCssRgbaValue.

Fixes assertions triggering at Polari startup.
2013-09-06 03:04:09 +02:00
Benjamin Otte
04b7c8e24e cssimage: Remove unused variables 2013-09-06 03:04:09 +02:00
Alexander Larsson
854f5818f8 Sync with changes in the cairo device-scale handling
The version of device scale that landed in upstream cairo
master already inherits the device scale in cairo_create_similar,
so no need to do that in gtk anymore.
2013-09-05 19:30:23 +02:00