change "Sans embedded" to "DejaVu Sans".)
SVG files may require manual modification before being uploaded to Wikipedia. Compound objects created with the binary path tools (union, intersect etc.).Lines with arrow heads (the arrows need to be converted).To keep the SVGs editable, this should only be done to the files intended for upload, and these files can be deleted afterwards.Īs of February 2014, the objects that must be modified to render correctly by librsvg include: The operation "Stroke to Path", to be found under Menu>Path in Inkscape or via Ctrl+ Alt+ C, can be applied to all of the objects that are not rendered correctly. There is a simple work-around for the scarcities of librsvg. The file manager GNOME Files or c:Commons:Commons_SVG_Checker relies on librsvg, so it can be used to check the quality before a SVG is uploaded. The version of the rsvg program that is installed on wiki does not always correctly raster the Inkscape or SVG files, and does not recognize some formats in text-editor SVG files.
MediaWiki (the software from which Wikipedia is run) uses the librsvg-library to rasterize all of its svg files. If the placement or appearance of text in the image is important and there is uncertainty about which fonts are installed on a visitor's machine, then converting text into path information may be necessary.īad letter-alignment on small font-size For further fallbacks see c:Help:SVG#fallback.įonts that are available on Wikimedia servers may or may not be available on a visitor's machine. Wikimedia has default fonts, and will use Liberation Serif for Times New Roman and Liberation Sans for Arial. For a list of fonts available in Wikipedia, see available fonts on Meta. Many common fonts have non-proprietary alternatives that are similar in typographical style, resulting in minimal disruption to existing images during substitution. move the original, editable non-path text outside the visible area (example: File:Essigsäuresynthesen.svg).įor ease of subsequent editing and significantly smaller file sizes, substituting the font with an available font is recommended.move the original, editable non-path text into a separate editable text layer that you make transparent (warning: this might be removed by SVG optimizers), or.Group the text, create a copy, and convert the copy to paths.Converting the text into paths increases file size, and is therefore generally disfavored (except for text logos, etc.).(This is because "Liberation Sans" has the same letter size as "Arial", so it is less likely to mess up the text flow.) Also, Wikimedia has synonyms for substituting fonts, such as "Arial" for "Liberation Sans" therefore font-family="Arial,DejaVu Sans" will be rendered by "Liberation Sans" and not (as expected) by "DejaVu Sans". Therefore always define a Wikimedia-font first. Since local rendering should be as close as possible to Wikipedia, it should use locally the same font as it will have on Wikipedia, if available.It is better to specify a font available on Wikipedia (such as Liberation Sans) with fallback fonts such as: font-family="Liberation Sans,Arial,Helvetica,sans-serif", in which you define a font-list with similar fonts that at least contain one font for each Operating System such as Wikimedia (e.g. One can specify a generic font-family such as "sans-serif", "serif", or "monospace", but this can lead to inconsistent rendering.One can substitute a font that is available on Wikipedia.rsvg will not be able to locate such fonts, and the text will fail to appear in the rendered image. Fonts such as Geneva require licensing fees to distribute. Due to copyright restrictions, MediaWiki cannot use proprietary fonts that are commonly found on several proprietary operating systems.