Difference between revisions of "Multicolor text"

From Inkscape Wiki
Jump to navigation Jump to search
 
Line 1: Line 1:
Multicolor text can be done in inkscape, although it is a bit of hack.
+
Multicolored text in Inkscape is easy. Just select parts of the text with Text tool and assign colors to them (via Fill and Stroke, or swatches, or Paste style)...
 
 
First save your svg file and find the text of interest in the XML file.  Find the tspan tag which encloses your text and add tspan tags which delineate the colors to be found in your text.
 
 
 
Specify the color for your text as a "fill" attribute, as follows:
 
 
 
<nowiki>
 
<tspan style="fill:#ff0000">this</tspan>
 
<tspan style="fill:#00ff00">is</tspan>
 
<tspan style="fill:#0000ff">multicolor</tspan>
 
<tspan style="fill:#000000">text</tspan>
 
</nowiki>
 
 
 
Now your image will display the text in multiple colors.  This is particularly useful for snapping text to curves, which can be apain otherwise.
 
 
 
[http://www.scripps.edu/~ityonemo/mctest.png link title]
 

Latest revision as of 18:49, 25 March 2006

Multicolored text in Inkscape is easy. Just select parts of the text with Text tool and assign colors to them (via Fill and Stroke, or swatches, or Paste style)...