CodeEdit icon indicating copy to clipboard operation
CodeEdit copied to clipboard

✨ Icons for every file format and file format opacity

Open iggy890 opened this issue 2 years ago • 18 comments
trafficstars

Is your feature request related to a problem? Please describe.

Related to: #1014

Describe the solution you'd like

CodeEdit does not have SF Symbols icons for every language (including those it doesn't have syntax highlighting).

Some filenames do not have their proper extensions because it would take too much time to research them.

  • [x] .c
  • [x] .cpp
  • [x] .cc
  • [x] .hpp
  • [x] .r
  • [x] .ruby
  • [x] .svelte
  • [x] .ts
  • [x] .sql
  • [x] .rust
  • [x] .scala
  • [x] .perl
  • [x] .php
  • [x] .kotlin
  • [x] .lua
  • [ ] .matlab
  • [x] .m (objective-c)
  • [x] .julia
  • [x] .cobol
  • [x] .groovy
  • [x] .d
  • [x] .zip
  • [x] .asm, .s, .inc, .wla, .SRC (assembly language)
  • [x] .jar
  • [x] .app
  • [x] .mov, .mp4 (video formats)
  • [x] .mp3, .wav (audio formats)
  • [x] .heic, .gif, .tga, .bmp, .psd, .hdr, .pic, .webp, .avif, .ppm, .pgm, .pbm, .pnm, .tiff, .pdf, .bmp (picture formats)
  • [ ] .xcodeproj
  • [x] .obj, .dae, .abc, .glb, .ply, .blend (3d model formats)
  • [x] .dmg, .pkg (app installer formats)
  • [x] .HTM
  • [x] .key
  • [x] .pptx
  • [x] .xml
  • [ ] .class
  • [x] .tex
  • [ ] .fon
  • [ ] .exe
  • [x] .lz
  • [x] .pyw
  • [x] .gzip
  • [x] .stl
  • [x] .gcode
  • [x] .dat
  • [ ] .sqlite
  • [x] .doc
  • [x] .docm
  • [x] .docx
  • [x] .log
  • [ ] .INFO
  • [x] .jng
  • [x] .PGM
  • [x] .pnm
  • [x] .pns
  • [x] .TIFF
  • [ ] .block
  • [x] .pyc
  • [x] .m4v
  • [ ] .vob
  • [x] .ppt
  • [x] .pps
  • [x] .tmp
  • [ ] .iso
  • [x] .xlsx
  • [x] .DS_Store

Added to fork?

  • [x] Fork

PR created?

  • [x] PR

PR ready for review?

  • [ ] Review

File icon opacity?

  • [ ] Opacity

Additional context

The SF Symbols library has a lot of icons that we could use for the languages. At some point I'm going to submit a PR from this fork: https://github.com/iggy890/CodeEdit/tree/file-icons

If you find anymore languages leave a comment below 👇

iggy890 avatar Mar 06 '23 14:03 iggy890

@austincondiff Could you assign this to me?

iggy890 avatar Mar 06 '23 14:03 iggy890

@austincondiff Could you assign this to me?

I'm not Austin, but here we go :)

0xWDG avatar Mar 06 '23 14:03 0xWDG

Thanks @0xWDG.

iggy890 avatar Mar 06 '23 14:03 iggy890

We might do this in such a way that it allows for icon packs in the future? This being said, should we add these new symbols to CodeEditSymbols? @CodeEditApp/maintainers what do you think?

austincondiff avatar Mar 06 '23 15:03 austincondiff

We might do this in such a way that it allows for icon packs in the future? This being said, should we add these new symbols to CodeEditSymbols? CodeEditApp/maintainers what do you think?

You're right about this, even though SF Symbols has updates we are still limited with a lot of programming languages.

iggy890 avatar Mar 06 '23 16:03 iggy890

I think this should be hold of. We want to give extension developers the possibility to build some sort of icon pack, and for that we first need an API architecture. If we build this right now, there is 95% chance that we'll have to rebuild it.

Also this issue expects that we want to use SF Symbols, which hasn't even been discussed. I personally think that SF Symbols is ill fitted here, they are not designed for this purpose.

matthijseikelenboom avatar Mar 07 '23 17:03 matthijseikelenboom

Ok, I'll work on a different PR and commit all of my (current changes) to the PR.

iggy890 avatar Mar 07 '23 17:03 iggy890

One Idea I got from using neovim a lot lately: What if we instead of SF Symbols use a DevIcons. They are available as SVGs and "just" need to be converted to SFSymbols (which tbh is a major chore task haha).

Optionally we could just use them as a font for the symbols.

lukepistrol avatar Mar 23 '23 22:03 lukepistrol

I think there are libraries to allow use SVGs directly in the project. This might be good to support different icons sets later down the road.

austincondiff avatar Mar 23 '23 23:03 austincondiff

Yeah, but the thing is, that those icons of a set need to be the same aspect ratio (squared). Otherwise scaling them correctly is practically impossible. You don't even need extra libraries Xcode supports svgs out-of-the-box.

lukepistrol avatar Mar 23 '23 23:03 lukepistrol

We can do that fairly easily. The view box should be a square aspect ratio regardless.

austincondiff avatar Mar 23 '23 23:03 austincondiff

We can do that fairly easily. The view box should be a square aspect ratio regardless.

"should" 😄 I had to work with icon sets at work which were all over the place, some tall, some wide, some square. And not even consistently.

lukepistrol avatar Mar 23 '23 23:03 lukepistrol

I think there are a lot of sets supported in VS code that could easily be ported that are all standardized.

austincondiff avatar Mar 23 '23 23:03 austincondiff

Maybe start a collection of those here or a link to an already existing collection.

lukepistrol avatar Mar 23 '23 23:03 lukepistrol

Hi! I created a file-icon association table using SF Symbols and a few custom symbols that you can use.

The list covers the list iggy890 made above, other ones I found in other issues/discussions in this organization, and some that VS Code covers (except for MATLAB, but I'm working on Julia). I've tried to stick to using symbols as similar to the ones used in Xcode, but for some I'm not sure what color or symbol should be used. The .exe symbol is split light/dark mode. Also, I looked through Xcode's contents but couldn't find the Python icon Apple uses.

Screen Shot 2023

Let me know what you think.

file-icons

CurbaiCode avatar Mar 31 '23 21:03 CurbaiCode

I like these. Yes, code edit will allow extension developers to change the icons but I think that SF symbols, https://github.com/devicons/devicon, and a "no icons" option should be shipped as included and could be picked in the appearance section. Very elegant

avasilic avatar Apr 01 '23 14:04 avasilic

Thank you! I think that those would be great options for UX. And I love the whole idea of CodeEdit. I can't wait for the production release!

CurbaiCode avatar Apr 03 '23 15:04 CurbaiCode

Here is an update of my SF Symbols set, adding a few more custom symbols:

file-icons

CurbaiCode avatar Apr 07 '23 20:04 CurbaiCode