Wiki Article

Talk:SVG

Nguồn dữ liệu từ Wikipedia, hiển thị bởi DefZone.Net

Hear ye! Excel .xlsx spreadsheets that automatically generate XML code for .SVG charts/graphs

[edit]
General concept above; examples below.
Warming stripes
... in a shape
Warming stripes bar chart
Bar chart
Pie chart
Variable-width bar chart
Line charts
Scatterplot
Radar chart

I've uploaded spreadsheets that automatically generate XML code for charts in SVG format.

Summary: You simply paste or enter your data into the spreadsheet, and specify image dimensions, number of grid lines, data ranges, font sizes, etc. The spreadsheets instantly and automatically generate a column of XML code. You simply copy and paste that code into a text editor and save as an ".svg" file. The spreadsheets produce lean SVG code, and should save you time in creating SVG charts. Though my original spreadsheets are written in Microsoft Excel, I've received reports that they also work if read into other spreadsheet programs.

Feedback and suggestions on my talk page are welcome. RCraig09 (talk) 23:41, 19 February 2021 (UTC)[reply]

Click HOW TO for detailed explanation.
Click HERE (else HERE) to download the spreadsheets.
Click here to see an example of how the spreadsheets work, internally.
  1. Warming stripes — Accepts a single dataset and converts to SVG code portraying Ed Hawkins' warming stripes graphics. User chooses vertical or horizontal stripes; normal or reverse data ordering; or from a variety of geometric shapes (updated 17 May 2023). . . . . Click here to see examples of warming stripes embedded in different shapes.
  2. Warming stripes bar chart — Accepts a single dataset and creates a conventional bar chart whose individual bars/columns are coloured according to Dr. Hawkins' warming stripes colour scheme. Alternate option: choose one colour for ascending bars and another colour for descending bars. (updated 28 August 2023)
  3. Line charts — Accepts up to six datasets. (updated 30 August 2023)
  4. Vertical bar charts (column charts) — Accepts up to six datasets. Toggle between clustered and stacked charts; user can adjust "Yfloor"—the Y level (usually=0) from which columns rise or fall; user chooses to keep or ignore negative input values. (updated 27 August 2023)
  5. Horizontal bar charts — Accepts up to six datasets. Toggle between clustered and stacked charts; user can adjust "Yfloor"—the value (usually=0) from which bars extend; user chooses to keep or ignore negative input values. (updated 27 August 2023)
  6. Scatter plots — Accepts up to five datasets. (updated 28 August 2023)
  7. Pie charts — Accepts a single dataset of up to 36 items. (updated 28 December 2025)
  8. Variable-width bar charts — Accepts up to six datasets; is like "Vertical bar charts", above, but user can choose different widths for different bars. (updated 27 August 2023)
  9. Radar charts — Accepts up to six datasets. (updated 6 May 2025)
In addition to manually entering code and using vector graphics editors, users can use spreadsheet programs' concatenate function to join numeric cell values and text strings in series, to generate full SVG declarations.
Supplemental: The above-listed spreadsheets use spreadsheet programs' concatenate function to automatically form files including SVG declarations. —RCraig09 (talk) 04:48, 8 January 2025 (UTC)[reply]

Question about the origin of SVG

[edit]

Adobe claimed Dutch software engineer Martijn Koster first proposed the SVG file format in 1994. [1] Does it right? -- Great Brightstar (talk) 06:40, 16 May 2025 (UTC)[reply]

The redirect SVG BAsic has been listed at redirects for discussion to determine whether its use and function meets the redirect guidelines. Readers of this page are welcome to comment on this redirect at Wikipedia:Redirects for discussion/Log/2025 August 4 § SVG BAsic until a consensus is reached. 1234qwer1234qwer4 14:14, 4 August 2025 (UTC)[reply]

Nominal

[edit]

A lot of online sources talk about the "nominal" size (i.e., dimensions) of an SVG image. This concept should probably be discussed somewhere in this article. - dcljr (talk) 03:09, 25 August 2025 (UTC)[reply]

Several factors may affect this. The main thing to look at is the svg element, which has several attributes (all of which are optional) that might define what we could consider to be the "nominal" size. These include:
  • the width= and height= attributes, possibly the most important for this purpose. They may specify the size using various units such as px, in, mm etc. If the units are omitted, px is assumed; if the attributes are omitted, 100% is assumed.
  • the third and fourth values in the viewBox= attribute; these are dimensionless, and px is implied
  • the style= attribute might set the width: and height: properties
  • the class= attribute might be associated with a stylesheet rule that includes declarations that set the width: and height: properties
Since none of those attributes are mandatory, it follows that a SVG image whose svg element lacks all of these attributes will have no nominal size, and the size of the image needs to be set by the document that uses the image, often by setting the width= and height= attributes in an img element. --Redrose64 🌹 (talk) 20:20, 25 August 2025 (UTC)[reply]
OK. Thanks. But I literally meant that this should be discussed addressed in the article (not just here on the talk page, for my benefit [grin]). The term "nominal" is used in relation to the "size" of SVG images in quite a few places, including on MediaWiki's "File:" pages for SVG images (see just below the image itself, after the "Original file" link), in some of MediaWiki.org's documentation about site logos, and in at least one published book about Inkscape. - dcljr (talk) 13:43, 26 August 2025 (UTC)[reply]