GitXplorerGitXplorer
t

vscode-icons.el

public
0 stars
0 forks
0 issues

Commits

List of commits on branch main.
Unverified
98691c1a7b1f4f7de2c4162eed390d7dfdfd6669

feat: new icon for shellscript, webmode

ttaquangtrung committed 9 hours ago
Unverified
9d74985b7ac7ae3486b3f47540e00611153f7e0b

fix: remove ini icons, update config icon

ttaquangtrung committed 3 days ago
Unverified
6d3034a3f10fa10cdf96d6d3ea8fc281e93bf199

feat: update some file regex icons

ttaquangtrung committed 4 days ago
Unverified
7d5bdbca711ae36f30047986015647260706247e

refactor: remove some light icons, update text/log icons

ttaquangtrung committed 9 days ago
Unverified
f529bd389ea747075f41401bc7fd0b4867eba93b

feat: icons for some file exts

ttaquangtrung committed 11 days ago
Unverified
c8965f867b10d599d41d7d20ae092468056ff49a

refactor: restructure some icons

ttaquangtrung committed 12 days ago

README

The README file for this repository.

vscode-icons.el

Library for displaying VSCode icons in Emacs.

Introduction

This library displays beautiful SVG icons adopted from modern VSCode extensions such as Microsoft's vscode-icons, VSCode Icons Team's vscode-icons, and Material Theme's vscode-material-icon-theme.

It improves existing packages like all-the-icons.el, nerd-icons.el, and vscode-icon-emacs by providing various original, pretty, and high-quality icons using SVG format. The other packages all-the-icons.el and nerd-icons.el only display single color icons while vscode-icon-emacs only display PNG icons, whose quality might be affected when being resized.

Usage

Below are some useful APIs to get icons:

  • vscode-icons-icon-for-file
  • vscode-icons-icon-for-dir
  • vscode-icons-icon-for-mode
  • vscode-icons-icon-for-imenu
  • vscode-icons-icon-for-buffer

Sample code to use the APIs to prepend the icon in front of a file name.

(defun prepend-file-icon (file-name)
  "Prepend an icon in front of a file name."
  (let* ((icon (if (file-directory-p file-name)
                   (or (vscode-icons-icon-for-dir file-name)
                       (vscode-icons-default-dir-icon))
                 (or (vscode-icons-icon-for-file file-name)
                     (vscode-icons-default-file-icon)))))
    ;; Return a new string which is prepended with the file icon.
    (concat (propertize " " 'display icon) " " file-name)))

Illustration of integrating vscode-icons into dired-mode:

Acknowledgements

This package is inspired by the following projects:

Icons are downloaded from these projects: