Hello,

Recently when dealing with css providers I have been trying to figure
out a way to check if a given resource exists. This is something that
can be achieved by using the error parameter in some functions[0] in
GTK 3.0 but it does not exist anymore in GTK 4.0.

I could create a GFile with a resource uri by using g_file_new_for_uri
and then use g_file_query_exists, but it does not seem the best way
for doing so.

So my question is, what is the proper way of checking if a resource
exists regarding future compatibility?

Best regards,

[0] gtk_css_provider_load_from_file, gtk_css_provider_load_from_data,
gtk_css_provider_load_from_path
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
https://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to