Commit Graph

1984 Commits

Author SHA1 Message Date
Matthias Clasen
14900efe38 gtk-demo: Plug a big memory leak
The colors demo was leaking all its colors. Oops.
2020-08-06 21:14:11 -04:00
Matthias Clasen
04c3c659f5 gtk-demo: Plug a small memory leak
The settings demo was leaking a GtkBuilderScope.
2020-08-06 21:13:39 -04:00
Matthias Clasen
dcf37412c1 gtk-demo: Fix keynav in the puzzle demo
Fixes: #3023
2020-08-05 20:52:22 -04:00
Matthias Clasen
b58bad557b gtk-demo: Make fontrendering demo work more than once
We weren't cleaning up properly, causing the window
to not close the second time it is opened.

Fixes: #3019
2020-08-05 14:36:54 -04:00
Matthias Clasen
af63893377 Merge branch 'search-demo-fixes' into 'master'
Search demo fixes

Closes #3004

See merge request GNOME/gtk!2354
2020-08-03 02:18:41 +00:00
Matthias Clasen
3304df7042 Merge branch 'tagged-entry-demo' into 'master'
gtk-demo: Simplify the tagged entry demo

Closes #3005

See merge request GNOME/gtk!2353
2020-08-03 02:18:28 +00:00
Matthias Clasen
df85ef1754 gtk-demo: Fix cleanup of search entry demo
We can't use the ::destroy signal anymore; use
a weak ref instead, and make ensure the entry
stays around long enough for us to finish the
cleanup.

Fixes: #3004
2020-08-02 21:53:59 -04:00
Matthias Clasen
a7e25f2c73 gtk-demo: Make search progress visible again
Set a progress fraction, so that the pulsing progress
in the search entry demo is actually visible.
2020-08-02 21:47:21 -04:00
Matthias Clasen
4bdd94fd3f gtk-demo: Simplify the tagged entry demo
No need for an intermediate box widget here;
we can just use a box layout. As a side-effect,
this fixes the theme to apply to the selection.

Fixes: #3005
2020-08-02 21:39:23 -04:00
Matthias Clasen
af07cfea5f gtk-demo: Avoid invalid OpenType feature tags
ss00 doesn't exist, and we use xxxx as placeholder
for 'default' choices in alternatives. Add a warning
in case we run across invalid OpenType feature tags
in fonts.

Fixes: #2962
2020-08-02 21:13:37 -04:00
Matthias Clasen
ed13e6a41e grid layout: Rename some properties
Rename GtkGridLayoutChild:left-attach/top-attach to
GtkGridLayoutChild:column/row. Update all users.

Fixes: #2967
2020-08-02 17:58:03 -04:00
Timm Bäder
954a144336 mediastream demo: Add a weak pointer to the window
Do what other demos do as well.

Fixes 2983
2020-08-01 08:59:46 +02:00
Chun-wei Fan
c97979873a demos: Fix running on Visual Studio builds
We need to mark the non-static callback functions for export.
2020-07-31 23:20:25 +08:00
Chun-wei Fan
e5600ab99b demos: Fix glarea demo on OpenGL/ES
Some implementations of the ES 1.00 shader (such as Google's ANGLE) do
not like the 'f' suffix for floats, so just drop it, as it should be
harmless to drop.
2020-07-30 14:26:33 +08:00
Matthias Clasen
9722bb4d9e iconbrowser: Add screenshots to appdata
appstream validation is picky and insists we have
at least on screenshot.
2020-07-29 20:23:46 -04:00
Matthias Clasen
ad3514216d Update our appdata files
Mention the new release in all our appdata files.
2020-07-29 17:58:45 -04:00
Matthias Clasen
59fce30200 icon-browser: Install desktop file and appdata
That is needed to make the flatpak build in our
ci happy.
2020-07-29 17:42:49 -04:00
Timm Bäder
b213b01200 widget-factory: Remove useless separators
They don't serve a purpose and are not relevant for theming purposes.
2020-07-28 06:14:45 +02:00
Timm Bäder
d5f0256f8b listbox demo: Remove frames around labels
Having frames around those labels looks stupid
2020-07-28 05:34:12 +02:00
Matthias Clasen
99ec400c2a gtk-demo: Simplify colors demo
Make best use of our new constructors.
2020-07-27 13:30:00 -04:00
Matthias Clasen
bc0182fa3e Merge branch 'ebassi/new-a11y' into 'master'
Accessibility rework

See merge request GNOME/gtk!2239
2020-07-27 11:55:19 +00:00
Matthias Clasen
d187ff858c Merge branch 'drop-down-constructor' into 'master'
GtkDropDown api revisions

See merge request GNOME/gtk!2286
2020-07-26 23:57:48 +00:00
Matthias Clasen
eb5c76210e gridview: Revise constructors
Make both gtk_grid_view_new and gtk_grid_view_new_with_factory
take a model as first argument, and make all arguments
allow-none and transfer full.

Update all callers.
2020-07-26 18:50:50 -04:00
Matthias Clasen
43000abeff listview: Revise constructors
Make both gtk_list_view_new and gtk_list_view_new_with_factory
take a model as first argument, and make all arguments
allow-none and transfer full.

Update all callers.
2020-07-26 18:27:23 -04:00
Matthias Clasen
f7ab6f665d dropdown: Revise constructors
A dropdown without a model is useless, so accept a model
and expression in the constructor. Allow them to be NULL,
but consume them if given. This makes chained constructors
convenient without breaking language bindings.

Drop gtk_drop_down_set_from_strings() and instead add
gtk_drop_down_new_from_strings().

Update all users.
2020-07-26 18:09:54 -04:00
Matthias Clasen
cdc263f796 multiselection: Make constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Also make the constructor return GtkMultiSelection *.

Update all callers.
2020-07-26 18:04:40 -04:00
Matthias Clasen
ccb9dcc86b singleselection: Make constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Update all callers.
2020-07-26 18:04:40 -04:00
Matthias Clasen
68d6671413 noselection: Make constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Update all callers.
2020-07-26 18:04:40 -04:00
Matthias Clasen
dd1c0c0b22 treelistmodel: Make constructor transfer full
Make gtk_tree_list_model_new() take the root model
as first argument, and make it transfer full, for
consistency with other wrapping list constructors.

Update all callers.

Still missing here: Make the model property writable,
and allow passing NULL in the constructor.
2020-07-26 18:04:40 -04:00
Matthias Clasen
a46cfd3ff4 sortlistmodel: Make constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Update all callers.
2020-07-26 18:04:40 -04:00
Matthias Clasen
706d464ae6 filterlistmodel: Make constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Update all callers.
2020-07-26 18:04:40 -04:00
Matthias Clasen
1e8be87026 flattenlistmodel: Make the constructor transfer full
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.

Update all callers.
2020-07-26 18:02:44 -04:00
Emmanuele Bassi
c63087a563 Remove ATK
To build a better world sometimes means having to tear the old one down.
        -- Alexander Pierce, "Captain America: The Winter Soldier"

ATK served us well for nearly 20 years, but the world has changed, and
GTK has changed with it. Now ATK is mostly a hindrance towards improving
the accessibility stack:

 - it maps to a very specific implementation, AT-SPI, which is Linux and
   Unix specific
 - it requires implementing the same functionality in three different
   layers of the stack: AT-SPI, ATK, and GTK
 - only GTK uses it; every other Linux and Unix toolkit and application
   talks to AT-SPI directly, including assistive technologies

Sadly, we cannot incrementally port GTK to a new accessibility stack;
since ATK insulates us entirely from the underlying implementation, we
cannot replace it piecemeal. Instead, we're going to remove everything
and then incrementally build on a clean slate:

 - add an "accessible" interface, implemented by GTK objects directly,
   which describe the accessible role and state changes for every UI
   element
 - add an "assistive technology context" to proxy a native accessibility
   API, and assign it to every widget
 - implement the AT context depending on the platform

For more information, see: https://gitlab.gnome.org/GNOME/gtk/-/issues/2833
2020-07-26 20:31:14 +01:00
Benjamin Otte
3078b180fe Replace "gdouble" with "double" 2020-07-25 00:47:36 +02:00
Benjamin Otte
556997f9df Replace "gfloat" with "float" 2020-07-25 00:47:36 +02:00
Benjamin Otte
d375dce9f5 Replace "gchar" with "char" 2020-07-25 00:47:36 +02:00
Benjamin Otte
d7266b25ba Replace "gint" with "int" 2020-07-25 00:47:36 +02:00
Benjamin Otte
b23f793753 gtk-demo: Add a progress bar when the colors demo resorts 2020-07-22 14:30:49 +02:00
Benjamin Otte
e8c4e1205a gtk-demo: Make colors demo do incremental sorting 2020-07-22 14:30:49 +02:00
Matthias Clasen
0e476c1f28 gtk-demo: Don't use GtkColorSwatch
Making our own is 80 lines of code, so just do it.
2020-07-17 20:44:06 -04:00
Matthias Clasen
f4a7c7f6bf gtk-demo: Use better api
We have a getter for the model, lets use it.
2020-07-16 16:26:41 -04:00
Benjamin Otte
e518c1f2f3 stringfilter: Make the constructor take an expression
An expression is critically important for a string filter and people
should be made aware of it when constructing the filter.
2020-07-16 20:43:16 +02:00
Benjamin Otte
c5ea59d7d1 gtk-demo: Don't make demos modal
That way, demo windows can be maximized and multiple demos can run at
once.

It's especially useful when using --run because the main window is
invisible then.
2020-07-16 20:43:16 +02:00
Matthias Clasen
b7eb663b82 gtk-demo: Make the words demo expand
We want to fill the window here.
2020-07-13 17:54:27 -04:00
Matthias Clasen
6502d3669f print-editor: Set the devel style class
Lets clearly communicate that we're unstable.
2020-07-13 08:27:51 -04:00
Matthias Clasen
53831e67a7 Integrate the new icons
Install and use the node-editor and print-editor icons.
2020-07-13 07:30:46 -04:00
Jakub Steiner
e742fc1206 demos: icons for Print and Node Editors
- probably needs meson build hooks
2020-07-13 07:30:46 -04:00
Matthias Clasen
b4096cee64 gtk-demo: Work harder to filter the tree
Arrange for an item to be visible if it either
matches the filter or has children that do.
2020-07-12 18:26:56 -04:00
Matthias Clasen
a888e1cb65 demo: Clear filter when search is stopped
When the search entry disappears on Escape,
reset the search string to "", so we don't
end up with a filtered list and no obvious
way to remove the filtering.
2020-07-12 16:47:51 -04:00
Matthias Clasen
c80b33b2ad gtk-demo: Make the search bar appear for typing
Having the search bar present from the start is
a bit jarring. Make it appear when called for.
2020-07-12 16:26:17 -04:00