From c6c7ca5d2fbe935468a8418f8e8d5fbecd960661 Mon Sep 17 00:00:00 2001 From: Thomas-Karl Pietrowski Date: Sat, 23 Jan 2016 20:34:25 +0100 Subject: [PATCH 1/3] Adding support for additional object files: * 3MF files * OBJ files --- cura.desktop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cura.desktop b/cura.desktop index edd482eed5..d0cb4398a1 100644 --- a/cura.desktop +++ b/cura.desktop @@ -8,6 +8,6 @@ TryExec=/usr/bin/cura_app.py Icon=/usr/share/cura/resources/images/cura-icon.png Terminal=false Type=Application -MimeType=application/sla;image/bmp;image/gif;image/jpeg;image/png +MimeType=application/sla;application/vnd.ms-3mfdocument;application/prs.wavefront-obj;image/bmp;image/gif;image/jpeg;image/png Categories=Graphics; Keywords=3D;Printing; From a88191d4c51e7e9186dcf6bb3c008490083caf55 Mon Sep 17 00:00:00 2001 From: Thomas-Karl Pietrowski Date: Mon, 25 Jan 2016 18:47:00 +0100 Subject: [PATCH 2/3] Adding cura.sharedmimeinfo * Originally taken from my own packaging of Cura on launchpad: ppa:thopiekar/cura - https://launchpad.net/~thopiekar/+archive/ubuntu/cura * It adds mime-types, which are supported by Cura, to the mime-database, so filemanagers can recognize these files. * This sharemimeinfo includes currently 3MF, STL and OBJ. --- cura.sharedmimeinfo | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 cura.sharedmimeinfo diff --git a/cura.sharedmimeinfo b/cura.sharedmimeinfo new file mode 100644 index 0000000000..9629aef5df --- /dev/null +++ b/cura.sharedmimeinfo @@ -0,0 +1,22 @@ + + + + 3D Manufacturing Format Document + + + + + + Computer-aided design and manufacturing format + + + + + + + Wavefront 3D Object file + + + + + \ No newline at end of file From 350466c73e0def6ff41d8b4c2be81ec57e7859e4 Mon Sep 17 00:00:00 2001 From: Thomas-Karl Pietrowski Date: Mon, 25 Jan 2016 19:34:33 +0100 Subject: [PATCH 3/3] Adding instructions to CMakeLists.txt to install cura.sharedmimeinfo as cura.xml into ${CMAKE_INSTALL_DATADIR}/mime/packages/ --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 9384c58ff4..995f85e871 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,6 +60,9 @@ if(NOT APPLE AND NOT WIN32) install(DIRECTORY cura DESTINATION lib/python${PYTHON_VERSION_MAJOR}/dist-packages FILES_MATCHING PATTERN *.py) install(FILES ${CMAKE_BINARY_DIR}/CuraVersion.py DESTINATION lib/python${PYTHON_VERSION_MAJOR}/dist-packages/cura) install(FILES cura.desktop DESTINATION ${CMAKE_INSTALL_DATADIR}/applications) + install(FILES cura.sharedmimeinfo + DESTINATION ${CMAKE_INSTALL_DATADIR}/mime/packages/ + RENAME cura.xml ) else() install(DIRECTORY cura DESTINATION lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages FILES_MATCHING PATTERN *.py) install(FILES ${CMAKE_BINARY_DIR}/CuraVersion.py DESTINATION lib/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}/site-packages/cura)