Commit Graph

48401 Commits

Author SHA1 Message Date
Benjamin Otte
ad64402a55 filechooserwidget: Query dpi from CssStyle 2016-10-16 18:17:21 +02:00
Benjamin Otte
77cdbfde97 fontchooserwidget: Query dpi from CssStyle 2016-10-16 18:17:21 +02:00
Benjamin Otte
fec8069e7b API: screen: Stop storing font options
font options are only ever set by the GtkSettings object and only ever
used inside GTK, so just store them there.
2016-10-16 18:17:21 +02:00
Benjamin Otte
fcbd480c76 API: Remove GDK_WA_CURSOR
The cursor was set using gdk_window_set_cursor() even in
gdk_window_new().

So instead of having yet another flag, just make the users of that flag
call gdk_window_set_cursor() directly after the window was created.
2016-10-16 18:17:21 +02:00
Benjamin Otte
2fd5048943 API: window: Remove suppport for changing wmclass_name/group
X11 was the only backend to support it and people can just override it
using XSetClassHint() directly.
The docs already advertised the function as "Do not use".

Keep the existing call to XSetClassHint() in place, so that we keep
setting the same values as in GTK3.
2016-10-16 18:17:21 +02:00
Timm Bäder
fe24fcbc3e Delete gtkvbox.{c,h} 2016-10-16 18:17:21 +02:00
Timm Bäder
fb3d9022ad Remove GtkHBox 2016-10-16 18:17:21 +02:00
Benjamin Otte
9a5de96187 API: Remove GtkNumerableIcon 2016-10-16 18:17:21 +02:00
Benjamin Otte
d09e48cec1 API: Remove -gtk_widget_get_root_window() 2016-10-16 18:17:21 +02:00
Benjamin Otte
9be9e00a0e API: screen: Remove gdk_screen_make_display_name()
It's identical to gdk_display_get_name().
2016-10-16 18:17:21 +02:00
Benjamin Otte
6b9e481e38 API: screen: Remove gdk_screen_get_active_window()
... and gdk_screen_get_window_stack().

Those functions were originally added in
5afb4f0f11 but do not seem to be used as
they are not implemented anywhere but in X.

As GDK is not meant to fulfill window management functionality I'm going
to remove these functions without replacements.
2016-10-16 18:17:21 +02:00
Benjamin Otte
26f9b584be API: gdk: Remove gdk_screen_get_number()
It's useless everywhere but in internal X11 code.
2016-10-16 18:17:21 +02:00
Benjamin Otte
0be88cc76e API: Remove gdk_screen_get_width() and gdk_screen_get_height()
... and gdk_screen_get_width_mm() and gdk_screen_get_height_mm() and
the shortcut counterparts that call these functions on the default
screen.

Modern display servers don't provide an ability to query the size of a
screen or display so we shouldn't allow that either.
2016-10-16 18:17:21 +02:00
Benjamin Otte
579edbbca8 display: Insist that backends implement the monitor vfuncs
We cannot fallback anymore once we remove the ability to query screen
size, and that's about to happen.
2016-10-16 18:17:21 +02:00
Benjamin Otte
ed30f271f5 gdk: Insist axis.min_value < axis.max_value
Remove fallback code that would substitute screen size otherwise.
2016-10-16 18:17:21 +02:00
Benjamin Otte
2033b06cb6 gdk: Require passing screen size to translate_screen_coord() 2016-10-16 18:17:21 +02:00
Benjamin Otte
4445807421 shooter: Use root window size instead of screen size
Avoids usage deprecated screen size.
2016-10-16 18:17:21 +02:00
Benjamin Otte
013caef941 testgtk: Remove feature unsupported in Wayland
Wayland doesn't allow positioning windows randomly, so don't try.
2016-10-16 18:17:21 +02:00
Benjamin Otte
c2125e80a3 API: window: Remove geometry support 2016-10-16 18:17:21 +02:00
Benjamin Otte
4ed9452e90 API: menu: Remove tearoff support 2016-10-16 18:17:21 +02:00
Benjamin Otte
1a0a423250 API: gdk: Remove monitor APIs on GdkScreen 2016-10-16 18:17:21 +02:00
Benjamin Otte
d2a8667f83 API: Remove GtkStatusIcon 2016-10-16 18:17:21 +02:00
Benjamin Otte
c0276e2c5c applaunchcontext: Ignore screen name
It's guaranteed to be identical to the display name.
2016-10-16 18:17:21 +02:00
Benjamin Otte
9222b4cd7c inspector: Use display name instead of screen name
This is for future compatibility as they are guaranteed to be identical.
2016-10-16 18:17:21 +02:00
Benjamin Otte
f7cebf5c1f wayland: Use GdkMonitor APIs 2016-10-16 18:17:21 +02:00
Benjamin Otte
7232b4f735 x11: Use GdkMonitor APIs 2016-10-16 18:17:21 +02:00
Benjamin Otte
d33c251cf6 gdk: Use GdkMonitor APIs
... instead of the old ones using GdkScreen
2016-10-16 18:17:21 +02:00
Benjamin Otte
266fd36f3f inspector: Port to GdkMonitor 2016-10-16 18:17:21 +02:00
Benjamin Otte
29c570a660 tests: Port to GdkMonitor 2016-10-16 18:17:21 +02:00
Benjamin Otte
76d95c312d display: Don't return NULL in get_primary_monitor()
Nobody ever does a NULL check there so all that causes is crashes. So
we better return a non-primary monitor than NULL.

Fixes gdk-wayland always returning NULL.
2016-10-16 18:17:21 +02:00
Benjamin Otte
dcb816f99a gdk: Fix docs typo 2016-10-16 18:17:21 +02:00
Benjamin Otte
7016409e9f gdk: Get rid of unused variables 2016-10-16 18:15:37 +02:00
Aurimas Černius
713d4ad3e6 Updated Lithuanian translation 2016-10-15 22:07:36 +03:00
Matthias Clasen
a703ba8406 Avoid 0/FALSE confusion
Since this is supposedly exemplary code, lets get it right.

https://bugzilla.gnome.org/show_bug.cgi?id=772683
2016-10-14 11:15:27 -04:00
Alan Jenkins
b7baf3371b shortcutswindow: working version of set_section_name()
(testing before+after, it actually works now)

https://bugzilla.gnome.org/show_bug.cgi?id=772926
2016-10-14 10:57:32 -04:00
Matthias Clasen
565b35ac00 Add new gestures to gtk4-demo
Show the new single-finger swipe gestures in the builder
shortcuts example.
2016-10-13 15:02:36 -04:00
Felix Riemann
b6cdc3961a GtkShortcutsShortcut: Support single finger swipe gestures
https://bugzilla.gnome.org/show_bug.cgi?id=772770
2016-10-13 15:02:36 -04:00
Jakub Steiner
21fa12120c gestures: provide new artwork
- illustrations for single finger swiping left and right

https://bugzilla.gnome.org/show_bug.cgi?id=772770
2016-10-13 15:02:36 -04:00
Ben Iofel
a9464f65c3 docs: replace gtk3 with gtk4 in man pages 2016-10-13 13:45:14 -04:00
Alan Jenkins
38667b8dd0 scrolledwindow: fix leak of pan_gesture
https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:02 -04:00
Alan Jenkins
982c4a70b6 headerbar: fix leak of label_sizing_box
Since the widget is not added to a container, we have the responsibility
to sink the initial floating reference, and ultimately to unref it.

https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:02 -04:00
Alan Jenkins
3731da14a0 headerbar: fix leak of separator
https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:02 -04:00
Alan Jenkins
8ef4f7fd74 headerbar: fix leak of start_box/end_box
gtk_widget_destroy() removes widgets from their container.  However
_internal_ widgets must be unref'ed using gtk_widget_unparent() instead.
This is symmetric with the fact that these widgets were ref'ed by direct
call to gtk_widget_set_parent().  It's also the method that was used in
gtk_headerbar_destroy().

https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:01 -04:00
Alan Jenkins
8aa9339b2d shortcutsgroup: fix leak of title
like previous commit, albeit simpler this time

https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:01 -04:00
Alan Jenkins
353281d9d0 applicationwindow: fix leak of help_overlay
> Due to Gtk+ keeping a reference to the window internally,
> gtk_window_new() does not return a reference to the caller.
> To delete a GtkWindow, call gtk_widget_destroy().

Caller(s) aren't expecting a need to delete help_overlay themselves
once they've installed it.  (E.g. see gtk_application_window_added()).

I didn't notice any direct precedents, but there's a parallel in the
current implementation of gtk_container_destroy() which uses
gtk_widget_destroy() on any added widget.

This avoids leaking 100s of kB per window, when I tested nautilus.

https://bugzilla.gnome.org/show_bug.cgi?id=772859
2016-10-13 09:39:01 -04:00
Christian Hergert
133da65433 menusectionbox: add support for "text-direction" attribute
This allows the use of a "text-direction" hint set to one of "none", "rtl",
or "ltr" to enforce the text direction of a "horizontal-buttons"
display-hint.

This is useful when a menu has buttons that map to physical space in the
UI and therefore must match the application widgetry.

https://bugzilla.gnome.org/show_bug.cgi?id=772775
2016-10-13 06:34:50 -04:00
Olivier Fourdan
9e2b1ad39e gdkwindow: configure native windows in move_native_children()
ClutterEmbed on Wayland uses a subsurface and relocates it on configure
events, but when placed within a scrolled window, no configure event is
emitted and the ClutterEmbed subsurface remains static.

Emit a configure event for native windows in GdkWindow's internal
move_native_children() so that custom widgets relying on configure
events such as ClutterEmbed can relocate their stuff.

Similarly, when switching to/from normal/maximized/fullscreen states
which change the shadows' size and possibly shows/hides a header bar,
we need to emit a configure event even if the abs_x/abs_y haven't
changed to make sure the subsurface is size appropriately.

https://bugzilla.gnome.org/show_bug.cgi?id=771320
https://bugzilla.gnome.org/show_bug.cgi?id=767713
2016-10-13 08:53:59 +02:00
Piotr Drąg
b65fbbf739 Update Polish translation 2016-10-12 19:50:06 +02:00
Lapo Calamandrei
9054e49776 Adwaita: dodge drop active style for window and decoration nodes
to hilight drop target there is a wildcard selector which turns
the border and shadow to green, this clearly shouldn't happen when
the whole window is a drop target.
2016-10-12 19:34:10 +02:00
Tom Tryfonidis
3e3f20854b Update Greek translation
(cherry picked from commit e74dc54567)
2016-10-11 11:05:34 +00:00