alexmurray / emacs-snap

GNU Emacs in a snap
https://snapcraft.io/emacs
71 stars 13 forks source link

Gtk warnings on launch in Ubuntu 16.04 #48

Closed poretsky closed 1 year ago

poretsky commented 1 year ago

There is a lot of gtk warnings in Ubuntu 16.04 in addition to the fontconfig one mentioned in #10.

The first one is a complaint about locale support:

(process:17738): Gtk-WARNING **: 09:34:08.058: Locale not supported by C library. Using the fallback 'C' locale.

And then a bunch of theme parsing errors as follows:

(emacs:17738): Gtk-WARNING **: 09:34:08.072: Theme parsing error: gtk-widgets-borders.css:31:18: The :insensitive pseudo-class is deprecated. Use :disabled instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.073: Theme parsing error: gtk-widgets-assets.css:35:18: The :insensitive pseudo-class is deprecated. Use :disabled instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.075: Theme parsing error: gtk-widgets-assets.css:356:32: The :inconsistent pseudo-class is deprecated. Use :indeterminate instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.076: Theme parsing error: gtk-widgets-assets.css:488:36: The :focused pseudo-class is deprecated. Use :focus instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:16:33: The style property GtkMenu:horizontal-padding is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:17:31: The style property GtkMenu:vertical-padding is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:19:32: The style property GtkMenuItem:arrow-scaling is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:20:30: The style property GtkNotebook:tab-overlap is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:40:32: The style property GtkWidget:separator-width is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:41:33: The style property GtkWidget:separator-height is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:42:32: The style property GtkWidget:wide-separators is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:43:27: The style property GtkWidget:link-color is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:44:35: The style property GtkWidget:visited-link-color is deprecated and shouldn't be used anymore. It will be removed in a future version

(emacs:17738): Gtk-WARNING **: 09:34:08.077: Theme parsing error: gtk-widgets.css:126:19: The :insensitive pseudo-class is deprecated. Use :disabled instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.078: Theme parsing error: gtk-widgets.css:391:27: The :prelight pseudo-class is deprecated. Use :hover instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.078: Theme parsing error: gtk-widgets.css:442:23: The :focused pseudo-class is deprecated. Use :focus instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.079: Theme parsing error: gtk-widgets.css:696:10: not a number

(emacs:17738): Gtk-WARNING **: 09:34:08.079: Theme parsing error: gtk-widgets.css:696:24: Using Pango syntax for the font: style property is deprecated; please use CSS syntax

(emacs:17738): Gtk-WARNING **: 09:34:08.080: Theme parsing error: gtk-widgets.css:829:34: The :inconsistent pseudo-class is deprecated. Use :indeterminate instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.080: Theme parsing error: gtk-widgets.css:986:33: The :focused pseudo-class is deprecated. Use :focus instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.082: Theme parsing error: gtk-widgets.css:1505:18: The 'outline-radius' property has been renamed to '-gtk-outline-radius'

(emacs:17738): Gtk-WARNING **: 09:34:08.082: Theme parsing error: gtk-widgets.css:1578:14: Expected a string.

(emacs:17738): Gtk-WARNING **: 09:34:08.082: Theme parsing error: gtk-widgets.css:1607:15: The 'icon-shadow' property has been renamed to '-gtk-icon-shadow'

(emacs:17738): Gtk-WARNING **: 09:34:08.085: Theme parsing error: gtk-widgets.css:2121:21: The '-gtk-image-effect' property has been renamed to '-gtk-icon-effect'

(emacs:17738): Gtk-WARNING **: 09:34:08.085: Theme parsing error: unity.css:109:15: The 'icon-shadow' property has been renamed to '-gtk-icon-shadow'

(emacs:17738): Gtk-WARNING **: 09:34:08.085: Theme parsing error: gedit.css:65:67: The :prelight pseudo-class is deprecated. Use :hover instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.086: Theme parsing error: gedit.css:102:15: The 'icon-shadow' property has been renamed to '-gtk-icon-shadow'

(emacs:17738): Gtk-WARNING **: 09:34:08.086: Theme parsing error: nautilus.css:29:47: The :prelight pseudo-class is deprecated. Use :hover instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.086: Theme parsing error: nautilus.css:40:16: The 'outline-radius' property has been renamed to '-gtk-outline-radius'

(emacs:17738): Gtk-WARNING **: 09:34:08.086: Theme parsing error: nautilus.css:50:71: Using one color stop with linear-gradient() is deprecated.

(emacs:17738): Gtk-WARNING **: 09:34:08.086: Theme parsing error: gnome-panel.css:71:35: The :prelight pseudo-class is deprecated. Use :hover instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.087: Theme parsing error: unity-greeter.css:49:30: The :focused pseudo-class is deprecated. Use :focus instead.

(emacs:17738): Gtk-WARNING **: 09:34:08.087: Theme parsing error: calendar.css:9:18: The 'outline-radius' property has been renamed to '-gtk-outline-radius'

(emacs:17738): Gtk-WARNING **: 09:34:08.095: Theme parsing error: gtk-keys.css:108:18: The 'gtk-key-bindings' property has been renamed to '-gtk-key-bindings'

I've squeezed out the most of repetitions. There were several hundreds warnings in total.

alexmurray commented 1 year ago

Unfortunately this sort of thing is inevitable when trying to run something like the emacs snap which is a single build of an application with all its dependencies bundled together. As it uses a much newer GTK versions etc than what was present on Ubuntu 16.04, when trying to read the users/systems Gtk configuration settings it will then complain about deprecations etc. As such it is not really possible to fix this, other than using a much older version of GTK for the snap, but then that would look out of place on newer distros. Since Ubuntu 16.04 currently only makes up about 0.7% of the users of the emacs snap this will not be changing unfortunately. I suggest you may just have to live with seeing these errors, or you could write a small wrapper script to filter them out, or upgrade to a newer Ubuntu release.

poretsky commented 1 year ago

And wouldn't help somehow making a snap without gtk dependency like emacs-lucid packages in Ubuntu?