Help:Manual Importsvg

Table of Contents

Importing SVG What is SVG? SVG (Scalable Vector Graphics) is an open standard, or, since version 1.1, a family of open standars for two-dimensional vector graphics. It is based on XML and maintained by the World Wide Web Consortium (W3C). Since the orginal (primary) purpose of SVG was usage for static and dynamic vector graphics for the web, only a subset of the specification(s) is relevant for use in Scribus. The huge success of SVG resulted in considerations to expand its scope to a universal 2D vector format, and "universal" includes support for professional printing, which is all the more interesting for Scribus. The broadened scope of the standard, however, made it necessary to define subsets of SVG, called "profiles". As of version 1.1, two profiles have been defined, SVG Tiny for devices like mobile phones and SVG Basic for devices like PDAs. The W3C Working Draft for SVG 1.2 also includes a profile called SVG::Print, which provides the features required by professional printers. The SVG 1.2 draft also included support for other color spaces than sRGB, like CMYK or even spot colors. However, 1.2 will probably be skipped in favor of SVG 2.0, which may take some time to develop. Why SVG? The major advantage of SVG is its openness and the availabilty of the full specification with no strings attached. As a result, SVGs have become ubiquitous in many areas like cartography or geo services. Most vector graphics available via Wikimedia are also SVG files. Another advantage of SVG is its XML base. In other words, SVG files, like Scribus SLA files, consist of plain text, which can be easily read by other programs or even human beings. SVG is also more or less well-supported by many vector drawing programs, including Adobe Illustrator or CorelDraw. The leading Open Source vector drawing program [www.inkscape.org Inkscape] is even primarily designed as an SVG editor. Unlike many other graphics formats, SVG supports color management by referencing an ICC profile in its XML code. Importing SVG As with other vector formats, SVG files can either be opened directly via File &gt; Open or imported into an existing Scribus document via File &gt; Import &gt; Get Vector File. Scribus will often display a warning, which tells you that not all SVG features in the file are supported by Scribus. In most cases you need not worry about the warning, as many SVG features are irrelevant for import into Scribus. For example, the SVG specification allows for the inclusion of metadata. Since an SVG file will be converted into native Scribus vector curves, this information will be discarded, but it nevertheless triggers the warning. More serious issues may arise if an SVG files uses so-called "proprietary" tags, i.e., features that are missing in the SVG specification, but were deemed necessary by the creator of the program that writes the SVG. Based on experience, though, almost all SVGs will be imported at a reasonably good quality. Caveats Although Scribus supports most of the relevant features of the SVG 1.0 and 1.1 specifications, there are a few limitations, some of which are the result of SVG itself, while others are based on Scribus internals.  Dimensions: As you may have noticed when you tried to import an SVG file, the imported drawing often has huge dimensions. This is a result of SVG's original purpose as a graphics markup language (in contrast to a page description language like PostScript or PDF). Just like the creator of a web page doesn't know anything about the screen size or the browser that renders the page, the authors of the SVG specification considered the dimensions of an SVG drawing as a result of "negotiations" between a server that provides the graphic and a client (a web browser, a mobile phone), who is supposed to tell the server what the required dimensions are. In plain English: The dimensions of the drawing are whatever a client says they are. For a page layout program like Scribus, this information is useless, and as a result, the SVG importer is trying a "best guess" when it comes to the dimensions of an SVG drawing. This may or may not work to everyone's satisfaction, but you can easily re-scale an imported SVG by using the the X, Y, Z tab of the Properties Palette. Layers: The SVG specification doesn't support layers per se. Inkscape and Illustrator use groups with special attributes to function as layers, but these aren't recognized by Scribus yet. Thus, SVG files are always opened/imported as single-layer graphics. Fonts: In contrast to formats like PostScript, EPS or AI, SVG files cannot embed any font format that's required in commercial printing, i.e., Type 1, TrueType and OpenType. Instead, an SVG file includes references to a used font. SVGs can, however, embed fonts that use the SVG format themselves - those fonts are most commonly referred to as "SVG fonts" -, but the SVG import filter of Scribus doesn't recognize them, and they play no role in professional printing. As a result, text will probably not import or at least not correctly. If you have any control over the creation of the SVG file, you should insist on converting all text to outlines before importing a file into Scribus. In case you need to edit the text, it's easier to add it in Scribus and use the built-in typographic tools. Filters/Effects: The SVG specification defines a set of so-called "Filter Effects" for SVG drawings, but they aren't supported by Scribus yet. If you use one ore more of these filters in a drawing, you might consider exporting your SVG as a high-resolution bitmap, which will preserve the effects. Solid colors: The SVG 1.0 and 1.1 specifications define solid colors exclusively in the RGBA color space (RGB + transparency). Thus, most SVGs "in the wild" contain only RGB colors. The SVG 1.2 Working Draft also allows CMYK and spot colors, and some applications, like Inkscape or Illustrator, already create files that contain those colors. Scribus uses the SVG  tag to detect CMYK colors, but it imports those colors "as is", without taking into account a referenced color profile. Spot colors in SVG files are not supported, as the SVG specification requires the use of named color profiles. Color management: While the SVG specification supports the use of ICC color profiles, but just like fonts, profiles can't be embedded. The Scribus SVG import filter will ignore referenced color profiles and assume that RGB colors use the sRGB color space instead. 