FreeCAD document icon

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
User avatar
easyw-fc
Veteran
Posts: 3629
Joined: Thu Jul 09, 2015 9:34 am

Re: FreeCAD document icon

Post by easyw-fc »

Hi, sorry to revive this old thread...
I'm having an issue in displaying the document icon for FC files...
-
FC-doc-ico.png
FC-doc-ico.png (98.79 KiB) Viewed 1970 times
I should expect the FC logo icon
-
FC-logo.png
FC-logo.png (7.19 KiB) Viewed 1970 times
OS: Linux Mint 19.1
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.1.
Build type: Release
Python version: 3.6.7
Qt version: 5.9.5
Coin version: 4.0.0a
OCC version: 7.3.0
openBrain
Veteran
Posts: 9034
Joined: Fri Nov 09, 2018 5:38 pm
Contact:

Re: FreeCAD document icon

Post by openBrain »

I never paid attention to that but indeed.
Here there is no specific icon for FC file in folder view (the icon is a blank sheet), and even worse on the desktop there is no icon at all...

OS: Ubuntu 18.04.2 LTS
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.1.
Build type: Release
Python version: 2.7.15rc1
Qt version: 5.9.5
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: French/France (fr_FR)
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: FreeCAD document icon

Post by NormandC »

User avatar
easyw-fc
Veteran
Posts: 3629
Joined: Thu Jul 09, 2015 9:34 am

Re: FreeCAD document icon

Post by easyw-fc »

NormandC wrote: Sat Apr 27, 2019 4:25 pm You guys should know to search the forum first...
would you guy stop annoying people with useless comments?
You should know me enough to know that I normally search deeply before posting and this thread was in my search results...
EDIT:
https://www.google.com/search?q=freecad ... ument+icon
/EDIT

You surely spend more time than others on this forum, so again please just help and stop annoying with your attitude.
User avatar
easyw-fc
Veteran
Posts: 3629
Joined: Thu Jul 09, 2015 9:34 am

Re: FreeCAD document icon

Post by easyw-fc »

FYI this is working on Linux Mint 19.1

Code: Select all

sudo cp ~/Documents/freecad.svg /usr/share/pixmaps/freecad.svg
sudo cp ~/Documents/freecad.png /usr/share/pixmaps/freecad.png
here my icon files
freecad.png
freecad.png (2.05 KiB) Viewed 1919 times
freecad.svg
(10.02 KiB) Downloaded 83 times
User avatar
kkremitzki
Veteran
Posts: 2511
Joined: Thu Mar 03, 2016 9:52 pm
Location: Illinois

Re: FreeCAD document icon

Post by kkremitzki »

It looks like we need to add some symlinks to this file: https://salsa.debian.org/science-team/f ... mmon.links
Like my FreeCAD work? I'd appreciate any level of support via Patreon, Liberapay, or PayPal! Read more about what I do at my blog.
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: FreeCAD document icon

Post by NormandC »

easyw-fc wrote: Sat Apr 27, 2019 5:32 pm You surely spend more time than others on this forum, so again please just help and stop annoying with your attitude.
I did provide a link about why it happens, didn't I. :roll:
Last edited by NormandC on Mon Apr 29, 2019 3:49 am, edited 2 times in total.
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: FreeCAD document icon

Post by NormandC »

kkremitzki wrote: Sun Apr 28, 2019 10:51 pm It looks like we need to add some symlinks to this file: https://salsa.debian.org/science-team/f ... mmon.links
The old freecad-stable package used to copy into /usr/share/icons/hicolor/ through the rules file. Very few applications copy icons in the /pixmaps folder, at least from what I'm seeing on my system. The document icon should go in /mimetypes I believe.

https://git.launchpad.net/~freecad-main ... elease#n44

Code: Select all

override_dh_icons:
	install -m 644 debian/freecad/usr/share/freecad/freecad-icon-16.png debian/freecad/usr/share/icons/hicolor/16x16/apps/freecad.png
	install -m 644 debian/freecad/usr/share/freecad/freecad-icon-32.png debian/freecad/usr/share/icons/hicolor/32x32/apps/freecad.png
	install -m 644 debian/freecad/usr/share/freecad/freecad-icon-32.png debian/freecad/usr/share/icons/hicolor/48x48/apps/freecad.png
	install -m 644 debian/freecad/usr/share/freecad/freecad-icon-64.png debian/freecad/usr/share/icons/hicolor/64x64/apps/freecad.png
	install -m 644 debian/freecad/usr/share/freecad/freecad.svg debian/freecad/usr/share/icons/hicolor/scalable/apps/freecad.svg
	install -m 644 debian/freecad/usr/share/freecad/freecad-doc.png debian/freecad/usr/share/icons/hicolor/64x64/mimetypes/application-x-extension-fcstd.png

User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: FreeCAD document icon

Post by NormandC »

I tested both

Code: Select all

sudo cp freecad-doc.png /usr/share/icons/hicolor/64x64/mimetypes/application-x-extension-fcstd.png
and

Code: Select all

sudo cp freecad-doc.svg /usr/share/icons/hicolor/scalable/mimetypes/application-x-extension-fcstd.svg
since they amount to what the old freecad package did.

I'm not sure why but it took a couple reboots to get it working. I'm not sure which one did, the png one or the svg one. I suggest copying both.

IMO it is best to save in .../mimetypes/ and rename the files as above to make sure they're not confused with the FreeCAD application icon.

BTW, LibreOffice also creates symlinks of its icons to /usr/share/icons/gnome/*/apps/ and /usr/share/icons/gnome/*/mimetypes/. I wonder if freecad should do the same.
Post Reply