svg
- Description
- SVG image creation functions
- Latest
- svg-1.1.0.20240804.74716.tar (.sig), 2024-Aug-07, 20.0 KiB
- Maintainer
- Lars Magne Ingebrigtsen <larsi@gnus.org>, Felix E. Klee <felix.klee@inka.de>
- Website
- https://elpa.gnu.org/packages/svg.html
- Browse ELPA's repository
- CGit or Gitweb
- Badge
To install this package from Emacs, use list-packages
.
Full description
This package allows creating SVG images in Emacs. SVG images are vector-based XML files, really, so you could create them directly as XML. However, that's really tedious, as there are some fiddly bits. In addition, the `svg-insert-image' function allows inserting an SVG image into a buffer that's updated "on the fly" as you add/alter elements to the image, which is useful when composing the images. Here are some usage examples: Create the base image structure, add a gradient spec, and insert it into the buffer: (setq svg (svg-create 800 800 :stroke "orange" :stroke-width 5)) (svg-gradient svg "gradient" 'linear '((0 . "red") (100 . "blue"))) (save-excursion (goto-char (point-max)) (svg-insert-image svg)) Then add various elements to the structure: (svg-rectangle svg 100 100 500 500 :gradient "gradient" :id "rec1") (svg-circle svg 500 500 100 :id "circle1") (svg-ellipse svg 100 100 50 90 :stroke "red" :id "ellipse1") (svg-line svg 100 190 50 100 :id "line1" :stroke "yellow") (svg-polyline svg '((200 . 100) (500 . 450) (80 . 100)) :stroke "green" :id "poly1") (svg-polygon svg '((100 . 100) (200 . 150) (150 . 90)) :stroke "blue" :fill "red" :id "gon1")
Old versions
svg-1.1.0.20240102.22814.tar.lz | 2024-Mar-31 | 4.96 KiB |
svg-1.1.0.20230930.220905.tar.lz | 2023-Oct-01 | 4.97 KiB |
svg-1.1.0.20230101.53112.tar.lz | 2023-Jan-01 | 4.91 KiB |
svg-1.1.0.20220101.24551.tar.lz | 2022-Jan-01 | 4.88 KiB |
svg-1.1.0.20220101.24551.tar.lz | 2022-Jan-01 | 4.88 KiB |
svg-1.1.0.20210914.55714.tar.lz | 2021-Sep-14 | 4.88 KiB |
svg-1.1.0.20210424.180712.tar.lz | 2021-Apr-24 | 4.88 KiB |
svg-1.1.0.20210101.91356.tar.lz | 2021-Mar-09 | 4.88 KiB |
svg-1.1.0.20201212.124832.tar.lz | 2020-Dec-14 | 4.88 KiB |
svg-1.1.0.20200906.2312.tar.lz | 2022-Feb-10 | 4.77 KiB |