User talk:RCraig09

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Useful links[edit]

Click at right to show/hide content

——— SVG:

SVG Text Font Test (by JoKalliauer)



——— Graphics & video:

20230117 Red- green- and blue-focused color palette

Excel .xlsx spreadsheets that automatically generate XML code for .SVG graphics[edit]

Click at right to show/hide content re User:RCraig09/Excel to XML for SVG
Transcluded from User:RCraig09/Excel to XML for SVG:
General concept above; examples below.
Warming stripes
(five examples compared)
Warming stripes bar chart
Bar chart (vertical)
Pie chart
Line charts
Scatterplot

I've uploaded .xlsx (Microsoft Excel) spreadsheets that automatically generate XML code for charts in SVG format.

You simply paste or enter your data into the spreadsheet, and specify image dimensions, number of grid lines, font sizes, etc. The spreadsheet instantly and automatically generates a column of XML code that you simply copy and paste into a text editor and save as an ".svg" file. The spreadsheets produce lean SVG code, avoiding the "extra stuff" that Inkscape inserts. They should save you time in creating SVG charts.

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.
  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 17 May 2023)
  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)
Transcluded from User:RCraig09/Warming stripes in shapes
An Excel .xlsx spreadsheet automatically+ generated the XML code for the following SVG images:
  • The spreadsheet user can toggle a switch to reverse the order of data, so red is in the center (or left side of first graphic) and blue is at the outside (or right side of first graphic).
  • The spreadsheet user can choose height and width (in pixels), to compress or expand shape vertically and horizontally, for example, to change an ellipse to a circle or a rectangle to a square.
  • To download the spreadsheet, go to User:RCraig09/Excel to XML for SVG.
  • Don't try to edit inside this colored box; make any comments about the spreadsheets or graphics at User talk:RCraig09RCraig09 (talk) 20:43, 20 May 2021 (UTC)[reply]


A cookie for you![edit]

Hey! Take some cookies for making svg version of CoA at my request. Thank you! janbery (talk) 18:46, 19 April 2020 (UTC)[reply]
Thank you Jan. It was a challenge... especially the lion. The original PNG lion had many weird features! —RCraig09 (talk) 18:50, 19 April 2020 (UTC)[reply]

Hi. Thanks for tagging files as copyright violations! Just a request: please do not replace an incorrect license with a copyvio tag. Simply add the copyvio tag in addition. Replacing the tag makes it more difficult and time consuming for administrators to verify what is going on and who is claiming what. Thanks, Storkk (talk) 12:57, 10 May 2020 (UTC)[reply]

Roger; wilco. Thanks for the heads up. ——RCraig09 (talk) 15:34, 10 May 2020 (UTC)[reply]

Thank you for your contributions to East Asian & Vietnamese sigillography[edit]

The Barnstar of Oriental sigillography
Thank you for uploading the Vietnamese imperial seal and imperial-consort seal. As well as making changes after I gave faulty instructions... --Donald Trung 『徵國單』 (No Fake News 💬) (WikiProject Numismatics 💴) (Articles 📚) 21:36, 29 September 2021 (UTC)[reply]
@Donald Trung: It is interesting to learn new things. Thank you for sharing your interests. —RCraig09 (talk) 22:09, 29 September 2021 (UTC)[reply]

[edit]

Greetings RCraig! May you please consider making a localised Wikipedia logo for Tumbuka language Wikipedia. Unfortunately we don't have our own logo whilst most local wikis do have. The English words "WIKIPEDIA" in Tumbuka translates "WIKIPEDIYA" and the motto "The Free Encyclopedia" translates "Nkhokwe Yavinjelu Yaulele". .

The Tumbuka Wikipedia is available at (tum.wikipedia.org). Thank you. Tumbuka Arch (talk) 15:32, 27 July 2022 (UTC)[reply]

@Tumbuka Arch: I suggest you place a request at Commons:Graphic Lab/Illustration workshop. Many more people will see your request. RCraig09 (talk) 20:22, 27 July 2022 (UTC)[reply]
Thanks,alright. Tumbuka Arch (talk) 11:38, 5 August 2022 (UTC)[reply]
Click at right to show/hide content
File:Flag of the United Arab Republic (1958–1971).svg has been listed at Commons:Deletion requests so that the community can discuss whether it should be kept or not. We would appreciate it if you could go to voice your opinion about this at its entry.

If you created this file, please note that the fact that it has been proposed for deletion does not necessarily mean that we do not value your kind contribution. It simply means that one person believes that there is some specific problem with it, such as a copyright issue. Please see Commons:But it's my own work! for a guide on how to address these issues.

Please remember to respond to and – if appropriate – contradict the arguments supporting deletion. Arguments which focus on the nominator will not affect the result of the nomination. Thank you!

ColorfulSmoke (talk) 16:42, 30 August 2022 (UTC)[reply]

own work[edit]

Regarding your comment at Wikipedia:Wikipedia:SVG_help, I would like your opinion on a proposal to remove "own work" from the Upload-Wizard. I personally hate wrong {{Own}} claims, since they are difficult to detect and differently to missing source usually don't lead to a deletion.  — Johannes Kalliauer - Talk | Contributions 19:11, 7 April 2023 (UTC)[reply]

@JoKalliauer: I understand your frustration. I think that the "Own Work" option should remain, but should be modified:
This file is my own work (and not a copy or derivative of someone else's work)
RCraig09 (talk) 19:48, 7 April 2023 (UTC)[reply]

Thanks ![edit]

Hello RCraig, it been 3 years since we worked on raising awareness. Thank so much for your "Lower the curve / Raise the line" series of animations, it was a significant work which did spread understanding and awareness. Likely saved 10s of thousands, likely more. Thank you ! Yug (talk) 09:51, 10 May 2023 (UTC)[reply]

@Yug: I don't know if it saved lives, but in any event those GIFs were the result of a successful collaborative effort among several editors. So thanks to you. RCraig09 (talk) 13:33, 10 May 2023 (UTC) (moved from User page RCraig09 (talk) 21:44, 12 May 2023 (UTC))[reply]

Did you figure out guidance regarding fonts in thumbnail view?[edit]

Thanks for making this: File:20200522 SVG font rendering at different thumbnail sizes.gif, but there's no guidance you offer with respect to it. Looking at one of your more recent images File:202107 Percent of global area at temperature records - Global warming - NOAA.svg, the fonts appear better than I've been able to pull off. Did you figure any guidance out for how to avoid crap looking fonts, or did you create a bug against wikimedia for the issue?

I played around a bit with some svgs, but the fonts seem to be semi-crappy across all sizes, and there's no magical divide between 1.7 and 1.75. I also see that you made your demonstration graphic as a GIF instead of SVG, I guess to show the comparison, but since the complaint is about SVG it makes it hard to see if the issue is still real. A bug could have been fixed, or it could just be that the svg rendering engine decides to switch to a different base font once a font gets to a certain size, where the font size is determined by font size / image width. In that case, there's nothing magical about 1.7 vs 1.75 because it all depends on the base scaled font size.

Thoughts? Do you have an svg that can be used to test the 1.7 vs 1.75 issue? Efbrazil (talk) 19:08, 30 May 2023 (UTC)[reply]

Oy, User:Efbrazil, the GIF is ancient history, when I was still using Inkscape, and somewhat amateurishly. I've since vastly simplified my SVGs by starting with a spreadsheet chosen from User:RCraig09/Excel to XML for SVG, and then used a text editor to group all my text between
<g font-size="40px" font-family="Liberation Sans,sans-serif" text-anchor="middle" fill="black">
and
</g>.
My files have generally a fraction the byte count of Inkscape files (see how lean the code is for File:2000- Clean power installation - wind, solar, storage - US.svg).
Even so, there are ongoing SVG font rendering problems on Wikimedia, which seem to involve (can't be sure) <tspan> elements; and sometimes needing to include specifications in particular <text> elements rather than depending on inheriting them from a group <g> specification. (Recent details are shown here at Help:SVG.)
I've never seen a repetition of the upright=1.7 vs 1.75 issue, probably because I've mostly avoided Inkscape and gone to lean code. If you want to see an old kluge, though, you could experiment with older versions of File:20200508 New Zealand government structure.svg, which is the basis of the GIF. RCraig09 (talk) 19:36, 30 May 2023 (UTC)[reply]
Ah, the graphic was featured on the svg help common problems area which is how I stumbled on it. It read like it was part of a help topic. I just deleted the graphic from there so it won't cause other people confusion:
https://en.wikipedia.org/w/index.php?title=Wikipedia%3ASVG_help&diff=1157780134&oldid=1157775976
Funny you are currently editing that page further down, I hadn't seen that.
What I always want to do is match as closely as possible the text on wikipedia pages themselves.
One thing I was wondering about is whether it would help to have a preferred width for graphics. Right now I'm popping them out at a width of 960, but there's no real rhyme or reason to that number. At that width, a font-size of 37 renders to approximate the size of text on the wikipedia page. Do you have a preferred graphic width that you use, and does that help with fonts somehow? Efbrazil (talk) 22:57, 30 May 2023 (UTC)[reply]
@Efbrazil: I don't have a preferred pixel size for diagrams, though based on each graphic's content, my mental default is to choose a 16:9 or 4:3 aspect ratio just in case something is used on-screen. I make it big enough to comfortably fill my Mac desktop screen: usually 1200w:675h or 1000w:750h pixels. I've found there's really no ideal aspect ratio since content is so varied. The size gets scaled within Wikipedia articles anyway.
— I'm planning to replace the GIF at Help:SVG, because it's not true to say it's "no longer relevant" (your edit summary). The problem has not been solved, and so it's an ongoing warning that using small fonts may be the cause of someone's problems. It is indeed part of a help topic. I forget what is the danger zone for which fonts are too tiny, but with 1200w:675h or 1000w:750h I regularly use fonts as small as 30px or so (ideally >40px for substantive text, 50-70px for some chart titles, maybe smaller than 40px for less substantive numbers like years on a horizontal axis). Of course I try to simplify, simplify, simplify any SVG code within smelling distance of text: these RSV text rendering bugs make one superstitious. RCraig09 (talk) 02:48, 31 May 2023 (UTC)[reply]
I think keeping the graphic there in the meantime without guidance is just confusing though. What are people supposed to take away as guidance? Not to use 1.7, and instead use 1.75? Please replace it or delete it until you have something better.
What is really needed is prescriptive guidance, telling people how to create text that looks good in thumbnails. I have a system similar to yours. Maybe we should try to offer that guidance to people. How about this:
Fonts should be sized so that they look good as thumbnails on wikipedia pages and so they are easy to view on smartphones, which is how most people access wikipedia. Very few people click images and zoom them in to see them, so avoid using images with fonts that are too small to be legible in thumbnail view.
In order to match text on wikipedia pages, here is guidance that will get you close:
A font family similar to wikipedia that is browser and wikimedia safe is font-family="Liberation Sans,sans-serif"
The font size that appears in a thumbnail is a combination of svg width, thumbnail width, and font size. To match wikipedia font size as a thumbnail, use font-size = (63/(your upright value))*((your svg width)/1000). For instance, if the thumbnail will be scaled up to thumb upright=1.35 and your image has svg width of 960, set font-size in the svg to (63/1.35)*(960/1000) = 44.8. Efbrazil (talk) 17:01, 31 May 2023 (UTC)[reply]
@Efbrazil: I generally like the proposed text you've written. However, I sometimes zoom into/out-of a web page using Command+/- or Control+/-, which would subvert any specific numerical recommendations you make. I think your description is a bit long, but the formula and examples would be helpful (I haven't verified their accuracy). I suggest starting a section at en.WP's SVG help asking what other experienced editors have found to be a viable size threshold for font sizes, and maybe proposing specific shortened text. Also, I don't know where the description would be added where significant numbers of Graphic Dudes would even notice it.
— Re the GIF: There is (presumably) still a problem with small font size renderings, about which people should be made aware—so they can experiment with larger font sizes as I did. Your write-up might help, with its specifics. If you want to develop prescriptive guidance as you have suggested, that would supplement the warning provided by the GIF. RCraig09 (talk) 17:24, 31 May 2023 (UTC)[reply]
Good! I added a new section with most of the text plus your image, focused on font-size instead of font-family. I think it is better than what was there before, although there is room for improvmenet still. Go ahead an add edits as you see fit. Efbrazil (talk) 17:45, 31 May 2023 (UTC)[reply]

Problem uploading SVG map (created on Inkscape) to Commons[edit]

Hello RCraig, I saw that you are an experienced user in SVG files on WikiCommons and wanted to reach out to ask for help on a map I am trying to upload here. It is a map I made using Inkscape about different proposed subdivisions of my country, Bolivia. The problem I am having is when I use the Commons:Commons SVG Checker, it says "Successfully parsed XML structure" but also "Omited rendering of SVG because the file size limit has been reached", so I can't preview how well the SVG file I want to upload will look. I don't know if I have to first make the file size smaller in order to upload it to Commons or if there is something else I have to do. It is my first time uploading an SVG file, so I'm sort of lost here. Thank you in advance for your time and help. Ruditaly (talk) 13:30, 13 July 2023 (UTC)[reply]

@Ruditaly: You could try uploading to File:Test.svg, so that you and others can see your specific file. Also, help may be available at Help talk:SVG or Commons:Village pump. Buena suerte! —RCraig09 (talk) 13:52, 13 July 2023 (UTC)[reply]
Thank you very much. I actually have uploaded it to the File:Test.svg site, but for some reason the thumbnail shows my map with a black color, even though the colors on the labels in the top right part of the SVG show without problems. Do you maybe know why that is? Thanks again. Ruditaly (talk) 14:00, 13 July 2023 (UTC)[reply]
I'm sorry, I don't understand the problem. However, a 9,000,000 byte file is extremely large for SVG. For this map, I would expect a file size of ~300,000–1,000,000 bytes. Also, the file has 1,079 "paths" (separate elements), which does not seem necessary for the number of districts in Bolivia. I suggest asking experts at Help talk:SVG or Commons:Village pump. —RCraig09 (talk) 14:16, 13 July 2023 (UTC)[reply]
@Ruditaly: You could also ask for help at Wikipedia:SVG help on the English-language Wikipedia. RCraig09 (talk) 19:53, 14 July 2023 (UTC)[reply]

Commons:Chart and graph resources[edit]

Hi. Please see:
Commons:Chart and graph resources#Convert data to SVG format for charts and graphs
Feel free to edit that page. --Timeshifter (talk) 06:13, 27 August 2023 (UTC)[reply]

Thanks for the notice, User:Timeshifter. I've added an image that illustrates the process. RCraig09 (talk) 17:49, 27 August 2023 (UTC)[reply]

Please fix graph legend[edit]

Hello, please fix the legend on the following graph to correctly identify the axis as estimated household gun ownership rates. Thanks. File:20230604_Gun_death_rates_related_to_household_gun_ownership_rates_-_by_state_-_US.svg Anastrophe (talk) 21:03, 21 September 2023 (UTC)[reply]

@Anastrophe: Though practically all figures in complex graphs are estimates, I plan to make the change you suggest within 24 hours. Thanks for your feedback. RCraig09 (talk) 22:03, 21 September 2023 (UTC)[reply]

SVG help[edit]

Hi, Would you for some SVG work? Please see COM:GL/M#Create a SVG version of File:Topo 25 sheets orig.jpg. The main work is to draw a grid, and then add it to one of the existing SVG map. Thanks, Yann (talk) 16:49, 24 September 2023 (UTC)[reply]

@Yann: I regret that this type of conversion is not readily within my ability. I'm not sure your reason for your wanting to avoid a JPG, but if file size is a problem, you can reduce file size at tinyjpg.com or cloudconvert.com, and upload as a newer version. Best wishes. RCraig09 (talk) 18:37, 24 September 2023 (UTC)[reply]
OK, fine. Actually, I want it bigger, not smaller. ;o) Yann (talk) 18:58, 24 September 2023 (UTC)[reply]

XLSX files with data for the SVG graphs created by you[edit]

Where could we find files with data inserted for all SVG graphs which were created by you from XLSX? In case we want to update the existing graph with the data from the new year? I am personally interested for the graph you did for https://en.wikipedia.org/wiki/Growth_of_photovoltaics . Thanks for interesting work though. Please reply. — User:Sintaj User talk:Sintaj 13:02, 29 October 2023

@Sintaj: Welcome to Wikimedia.
— Exactly which image do you want updated?
— If you want changes to a file I uploaded, it would be easier for me to make changes myself, rather than trying to teach another editor how. Please describe what changes you want.
— It is rare for one editor to change another editor's image. This is because the image may be used in many different Wikipedia articles, and in Wikipedia articles in different languages. If you want to make your own chart, you will have to start with the source data linked at the Wikimedia Commons file description page.
— Separately: when you post to a User Talk page, you should add it to the bottom of the page. That is why I have moved your post down here. RCraig09 (talk) 15:41, 29 October 2023 (UTC)[reply]

Warning stripes picture as featured picture candidate in Commons[edit]

Hello ! Since you uploaded the picture, would you support my proposal to promote it a featured picture in Commons? Commons:Featured picture candidates/File:20181204 Warming stripes (global, WMO, 1850-2018) - Climate Lab Book (Ed Hawkins).png Effco (talk) 12:24, 4 November 2023 (UTC)[reply]

Thank you, @Effco: I have entered my support on the Featured Picture Candidate page. I'm not sure if there is anything more that can be done; is there a need to write a "blurb" to go along with the image when featured? If so, where and how? RCraig09 (talk) 15:49, 4 November 2023 (UTC)[reply]
Thank you ! I'm not sure about what a "blurb" is, I'm new to this featuring process :-) Effco (talk) 16:14, 4 November 2023 (UTC)[reply]
@Effco: A "blurb" is a short description that goes along with the featured image, so that viewers will better understand its nature and purpose. (See https://www.dictionary.com/browse/blurb .) The "blurb" for Friday's en.WP Picture of the Day (POTD) was really long; I think most are shorter, as you can see from the Commons Main page. However, the warming stripes image would require some explanation, though not nearly as long as the POTD blurb. RCraig09 (talk) 17:20, 4 November 2023 (UTC)[reply]
Ok thank you for the explanation. But do we need that blurb now ? — Preceding unsigned comment added by Effco (talk • contribs) 17:23, 4 November 2023 (UTC)[reply]
@Effco: I don't know for sure when a blurb is needed. To be safe, I just added a proposed blurb to the nomination page. RCraig09 (talk) 18:42, 4 November 2023 (UTC)[reply]

Happy new year[edit]

Wishing you a happy 2024 cmɢʟee ⋅τaʟκ 17:40, 31 December 2023 (UTC)[reply]

@Cmglee: Years ago, I had C++ programming experience, but never Javascript or Python etc., or how to use a browser for this purpose. I think that more people have access to Excel than know how to program in Javascript, even though Excel costs money. :-\ It's not practical for me to learn at this point. RCraig09 (talk) 05:54, 1 January 2024 (UTC)[reply]
That's a very fair point. Coming from the other side, I must say I'm a beginner in Excel, just know the basics and simple macro programming. Good luck with your Excel SVG endevour, cmɢʟee ⋅τaʟκ 06:21, 1 January 2024 (UTC)[reply]
@Cmglee: Actually, I wrote the Excel spreadsheets using basic arithmetic and text functions, though some cell contents are long and filled with pesky details. Nothing I would call a 'macro' (or serious sequential 'programming') is involved, since the average businessman can learn basic Excel. (Users of the spreadsheets, of course, don't even need to know much about Excel, but can simply paste data into the spreadsheets, enter a few numbers like axis ranges and font sizes, and copy+paste a column of text into an svg text file.) RCraig09 (talk) 06:32, 1 January 2024 (UTC)[reply]
CC @Timeshifter:
Thanks for explaining. I note that you host your spreadsheets on Google Drive as Commons doesn't allow .xlsx files.
Earlier last year, I collaborated with Timeshifter (talk · contribs) to create a Google Sheets spreadsheet to generate SVG to paste into a template SVG. A problem we faced is that my personal Google account always runs out of quota and the sheet becomes read-only. Your method still works in this case, but the user has to download the sheet to run on their own spreadsheet software. I wonder what a good solution is (besides ensuring my not going over quota!)
I suppose using Toolforge is best, but it's a steep learning curve. Cheers, cmɢʟee ⋅τaʟκ 07:47, 1 January 2024 (UTC)[reply]