Bug 28020 - .ui files not recognized as gtk builder files
Summary: .ui files not recognized as gtk builder files
Status: RESOLVED FIXED
Alias: None
Product: shared-mime-info
Classification: Unclassified
Component: general (show other bugs)
Version: unspecified
Hardware: Other All
: medium enhancement
Assignee: Shared Mime Info group
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-07 08:38 UTC by william.jon.mccann
Modified: 2013-05-17 22:14 UTC (History)
5 users (show)

See Also:
i915 platform:
i915 features:


Attachments
patch (13.95 KB, patch)
2012-09-16 15:42 UTC, william.jon.mccann
Details | Splinter Review

Description william.jon.mccann 2010-05-07 08:38:33 UTC
gtk builder files (.ui) files are identified as:

Qt Designer file (application/x-designer)
Comment 1 Bastien Nocera 2011-05-25 05:55:16 UTC
Please follow the instructions at:
http://cgit.freedesktop.org/xdg/shared-mime-info/tree/HACKING#n31
for mime-type additions.
Comment 2 william.jon.mccann 2012-09-16 15:42:17 UTC
Created attachment 67246 [details] [review]
patch
Comment 3 william.jon.mccann 2012-09-16 15:42:56 UTC
Matthias, does application/x-gtk-builder seem ok to you?
Comment 4 Matthias Clasen 2012-09-17 12:50:31 UTC
sure, sounds fine to me
Comment 5 Bastien Nocera 2012-09-17 13:30:00 UTC
The test suite fails with your value in tests/list:
gtk-builder.ui, 'name' test: expected application/x-gtk-builder, got application/x-designer

Committed with that fixed.

commit 77c334309bba791eb7f0c8e4cd0f9053502fd27c
Author: William Jon McCann <jmccann@redhat.com>
Date:   Sun Sep 16 11:30:02 2012 -0400

    Add application/x-gtk-builder type
    
    https://bugs.freedesktop.org/show_bug.cgi?id=28020
Comment 6 Tristan Van Berkom 2013-05-06 19:18:13 UTC
Any reason to not go with the application/x-glade mime type we've been
using forever ?

Won't this cause some conflicts, like:
   https://bugzilla.gnome.org/show_bug.cgi?id=698705 ?

I don't really know all the details of how mime types work,
just asking out of curiousity, as it seems to have broken
something (at least in anjuta) to have invented a new mime type.
Comment 7 Thomas Kluyver 2013-05-16 17:33:47 UTC
I think a new Mime type is justified because these are two different file formats - albeit both XML based with a .ui extension. It would be perfectly reasonable for an application to be able to handle one format but not the other, in which case it would just list one MIME type.

For reference, here are samples of glade XML (the old format):
http://people.gnome.org/~newren/tutorials/developing-with-gnome/html/apb.html

And gtkbuilder XML (the new format):
http://www.pygtk.org/docs/pygtk/class-gtkbuilder.html#gtkbuilder-ui-definition-example


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.