Editing MIME TypesQt Creator uses the Internet media type (MIME type) of the file to determine which mode and editor to use for opening the file. For example, Qt Creator opens C++ source and header files in the C++ editor, and Qt widget based UI files (.ui) in Qt Designer. To identify the MIME type of a file, Qt Creator uses matching by pattern and matching by contents. First, Qt Creator looks at the filename to check whether it matches the patterns specified for any MIME type. If no match is found, it checks the contents of the file for magic headers specified for the file. The magic headers can contain text strings or bytes. The type of the header value, string or byte, determines how Qt Creator interprets the value. Qt Creator searches for the value within a specified range in the files and takes the priority of the magic header into account. If you specify wide search ranges, openging files in Qt Creator might take a long time. Therefore, you are advised to use the recommended values for the range and priority of the magic header. If your files do not match the predefined MIME types, you can edit the MIME types to add filename extensions and magic headers. You cannot add new MIME types, however. To edit MIME types:
To revert all the changes you have made to the MIME type definitions, select Reset All. Note: If you now select OK or Apply, you permanently lose all your own patterns and magic headers. The changes are reverted the next time you start Qt Creator. [Previous: Using Maemo or MeeGo Harmattan Emulator] [Next: Showing Task List Files in the Build Issues Pane] © 2008-2011 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide. All other trademarks are property of their respective owners. Privacy Policy Licensees holding valid Qt Commercial licenses may use this document in accordance with the Qt Commercial License Agreement provided with the Software or, alternatively, in accordance with the terms contained in a written agreement between you and Nokia. Alternatively, this document may be used under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. X
|