[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/svg-lib b67b120 30/32: Cosmetic changes
From: |
ELPA Syncer |
Subject: |
[elpa] externals/svg-lib b67b120 30/32: Cosmetic changes |
Date: |
Mon, 27 Sep 2021 16:57:51 -0400 (EDT) |
branch: externals/svg-lib
commit b67b1202f17432e9c8b60cd33e34ef8646bf80f9
Author: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
Commit: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
Cosmetic changes
---
svg-lib-demo.el | 6 +++---
svg-lib-demo.org | 1 +
svg-lib.el | 44 +++++++++++++++++++++-----------------------
3 files changed, 25 insertions(+), 26 deletions(-)
diff --git a/svg-lib-demo.el b/svg-lib-demo.el
index d778a35..1791b0c 100644
--- a/svg-lib-demo.el
+++ b/svg-lib-demo.el
@@ -20,7 +20,7 @@
(insert-image (svg-lib-progress-bar 0.75 nil :radius 8 :stroke 2 :padding 0))
-
+
(dotimes (i 10)
(insert-image (svg-lib-progress-pie (/ (+ i 1) 10.0) nil
:margin 1 :stroke 2 :padding 1)))
@@ -29,12 +29,12 @@
(dotimes (i 10)
(insert-image (svg-lib-icon "star" nil :scale (/ (+ i 1) 10.0))))
-
+
(insert-image (svg-lib-button "check-bold" "DONE" nil
:font-family "Roboto Mono"
:font-weight 500
:stroke 0 :background "#673AB7" :foreground "white"))
-
+
(insert-image (svg-lib-icon "gnuemacs" nil :collection "simple"
:stroke 0 :scale 1 :padding 0))
diff --git a/svg-lib-demo.org b/svg-lib-demo.org
index b67911f..de99589 100644
--- a/svg-lib-demo.org
+++ b/svg-lib-demo.org
@@ -57,6 +57,7 @@
#+end_src
+
* Progress count: [2/3]
:PROPERTIES:
:END:
diff --git a/svg-lib.el b/svg-lib.el
index 07c0ce7..3bce73d 100644
--- a/svg-lib.el
+++ b/svg-lib.el
@@ -1,13 +1,12 @@
-;;; svg-lib.el --- SVG tags, bars & icons -*- lexical-binding: t -*-
+;;; svg-lib.el --- SVG tags, progress bars & icons -*- lexical-binding: t -*-
-;; Copyright (C) 2021 Nicolas P. Rougier
+;; Copyright (C) 2021 Free Software Foundation, Inc.
-;; Author: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
-;; Homepage: https://github.com/rougier/svg-lib
-;; Keywords: convenience
+;; Maintainer: Nicolas P. Rougier <Nicolas.Rougier@inria.fr>
+;; URL: https://github.com/rougier/svg-lib
;; Version: 0.1
-
;; Package-Requires: ((emacs "27.1"))
+;; Keywords: svg, icons, tags, convenience
;; This file is not part of GNU Emacs.
@@ -36,22 +35,22 @@
;; compatibles with GNU Emacs:
;;
;; - Boxicons (https://github.com/atisawd/boxicons), available under a
-;; Creative Commons 4.0 license. As of version 2.07 (December 2020),
+;; Creative Commons 4.0 license. As of version 2.07 (December 2020),
;; this collection offers 1500 icons in two styles (regular & solid).
;; Gallery is available at https://boxicons.com/
;;
;; - Octicons (https://github.com/primer/octicons), available under a
-;; MIT License with some usage restriction for the GitHub logo. As of
+;; MIT License with some usage restriction for the GitHub logo. As of
;; version 11.2.0 (December 2020), this collection offers 201 icons.
;; Gallery available at https://primer.style/octicons/
;;
;; - Material (https://github.com/google/material-design-icons),
-;; available under an Apache 2.0 license. As of version 4.0.0
+;; available under an Apache 2.0 license. As of version 4.0.0
;; (December 2020), this collection offers 500+ icons in 4 styles
-;; (filled, outlined, rounded, sharp). Gallery available at
+;; (filled, outlined, rounded, sharp). Gallery available at
;; https://material.io/resources/icons/?style=baseline
;;
-;; - Bootstrap (https://github.com/twbs/icons), available under an MIT
+;; - Bootstrap (https://github.com/twbs/icons), available under a MIT
;; license. As of version 1.2.1 (December 2020), this collection
;; offers 1200+ icons in 2 styles (regular & filled). Gallery
;; available at https://icons.getbootstrap.com/
@@ -60,20 +59,26 @@
;; can be inserted inside a text without disturbing alignment.
;;
;; Note: Each icon is cached locally to speed-up loading the next time
-;; you use it. If for some reason the cache is corrupted you can
+;; you use it. If for some reason the cache is corrupted you can
;; force reload using the svg-icon-get-data function.
;;
;; If you want to add new collections (i.e. URL), make sure the icons
;; are monochrome, their size is consistent.
+;;; NEWS:
+
+;; Version 0.1:
+;; - Submission to ELPA
+
+
;;; Code:
(require 'svg)
(require 'xml)
(require 'cl-lib)
-;; Check if Emacs has been compled with svg support
+;; Check if Emacs has been compiled with svg support
(if (not (image-type-available-p 'svg))
- (error (concat "svg-lib.el requires Emacs to be compiled with svg
support.\n")))
+ (error "svg-lib.el requires Emacs to be compiled with svg support.\n"))
(defgroup svg-lib nil
@@ -113,8 +118,8 @@ collection (there are way too many to store them)."
:group 'svg-lib
:type 'directory)
+
;; Default style for all objects
-;; ---------------------------------------------------------------------
(defun svg-lib-style-compute-default (&optional face)
"Compute the default style according to face (which defaults
to the default face)."
@@ -153,7 +158,6 @@ to the default face)."
;; Convert Emacs color to SVG color
-;; ---------------------------------------------------------------------
(defun svg-lib-convert-color (color-name)
"Convert Emacs COLOR-NAME to #rrggbb form.
If COLOR-NAME is unknown to Emacs, then return COLOR-NAME as-is."
@@ -165,7 +169,6 @@ If COLOR-NAME is unknown to Emacs, then return COLOR-NAME
as-is."
;; SVG Library style build from partial specification
-;; ---------------------------------------------------------------------
(defun svg-lib-style (&optional base &rest args)
"Build a news style using BASE and style elements ARGS."
@@ -198,7 +201,6 @@ If COLOR-NAME is unknown to Emacs, then return COLOR-NAME
as-is."
;; Create an image displaying LABEL in a rounded box.
-;; ---------------------------------------------------------------------
(defun svg-lib-tag (label &optional style &rest args)
"Create an image displaying LABEL in a rounded box using given STYLE
and style elements ARGS."
@@ -251,8 +253,7 @@ and style elements ARGS."
-;; Create a progress bar
-;; ---------------------------------------------------------------------
+;; Create a progress pie
(defun svg-lib-progress-pie (value &optional style &rest args)
"Create a progress pie image with value VALUE using given STYLE
and style elements ARGS."
@@ -323,7 +324,6 @@ and style elements ARGS."
;; Create a progress bar
-;; ---------------------------------------------------------------------
(defun svg-lib-progress-bar (value &optional style &rest args)
"Create a progress bar image with value VALUE using given STYLE
and style elements ARGS."
@@ -381,7 +381,6 @@ and style elements ARGS."
;; Create a rounded box icon
-;; ---------------------------------------------------------------------
(defun svg-lib--icon-get-data (collection name &optional force-reload)
"Retrieve icon NAME from COLLECTION.
@@ -479,7 +478,6 @@ given STYLE and style elements ARGS."
;; Create an image displaying LABEL in a rounded box.
-;; ---------------------------------------------------------------------
(defun svg-lib-button (icon label &optional style &rest args)
"Create an image displaying LABEL in a rounded box using given STYLE
and style elements ARGS."
- [elpa] externals/svg-lib a1bfa49 15/32: Add svg-lib-icons-dir, (continued)
- [elpa] externals/svg-lib a1bfa49 15/32: Add svg-lib-icons-dir, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 38b0bad 03/32: Typo, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 004ab08 05/32: Better handling of default style + style simplification, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib a5b06a8 09/32: Forgot screenshot, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 9115bf7 12/32: Fix string/array nil issue on windows, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib e66a2d0 17/32: Merge pull request #3 from chenyanming/fix-windows-string-or-array-nil-error, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 461c155 06/32: Update with new style, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib e2d2d68 10/32: Better screenshot, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 952016b 11/32: Fix tasks status, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib ebde091 22/32: Added progress pies, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib b67b120 30/32: Cosmetic changes,
ELPA Syncer <=
- [elpa] externals/svg-lib 90bb561 18/32: Added tag example, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 0ce0302 19/32: Merge remote-tracking branch 'origin/master', ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 83834c6 20/32: Fix usage example in comment., ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 6876d54 26/32: Fix `font-info` query format., ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 2cab1a0 29/32: Merge remote-tracking branch 'origin/master', ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib f9e1bbb 32/32: Fix some warnings, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 04fdd1a 08/32: Added svg-lib-concat function for org-mode demo, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib d9a49ac 14/32: Delete the redundant url checking, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib 6ceae83 16/32: Change `svg-lib-icons-dir` default value, ELPA Syncer, 2021/09/27
- [elpa] externals/svg-lib f775af4 21/32: Merge pull request #5 from 404cn/master, ELPA Syncer, 2021/09/27