0
0
mirror of https://github.com/Doodle3D/doodle3d-client.git synced 2024-12-22 13:13:48 +01:00

Implemented Copse as new WordArt font

This commit is contained in:
peteruithoven 2014-01-15 13:49:38 +01:00
parent d68b9cbefc
commit 606f7cb359
3 changed files with 626 additions and 633 deletions

View File

@ -0,0 +1,102 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
width="1785.8772"
height="37.343998"
id="svg3245"
version="1.1"
inkscape:version="0.48.4 r9939"
sodipodi:docname="New document 9">
<defs
id="defs3247" />
<sodipodi:namedview
id="base"
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1.0"
inkscape:pageopacity="0.0"
inkscape:pageshadow="2"
inkscape:zoom="0.66125533"
inkscape:cx="885.47012"
inkscape:cy="79.926821"
inkscape:document-units="px"
inkscape:current-layer="layer1"
showgrid="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0"
inkscape:window-width="1670"
inkscape:window-height="821"
inkscape:window-x="0"
inkscape:window-y="22"
inkscape:window-maximized="0" />
<metadata
id="metadata3250">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Layer 1"
inkscape:groupmode="layer"
id="layer1"
transform="translate(635.23282,-279.42656)">
<text
xml:space="preserve"
style="font-size:35.2932663px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Sans"
x="-638.04181"
y="220.68825"
id="text3253"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3255"
x="-638.04181"
y="220.68825" /><tspan
sodipodi:role="line"
x="-638.04181"
y="264.80484"
id="tspan3257"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:Copse;-inkscape-font-specification:Copse" /><tspan
sodipodi:role="line"
x="-638.04181"
y="308.44699"
id="tspan3259"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:Copse;-inkscape-font-specification:Copse">!&quot;#$%&amp;'()*+,-./0123456789:;&lt;=&gt;?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~</tspan><tspan
sodipodi:role="line"
x="-638.04181"
y="352.56357"
id="tspan3261"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:Copse;-inkscape-font-specification:Copse" /><tspan
sodipodi:role="line"
x="-638.04181"
y="396.68018"
id="tspan3263"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-family:Copse;-inkscape-font-specification:Copse" /></text>
<text
xml:space="preserve"
style="font-size:40px;font-style:normal;font-weight:normal;line-height:125%;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;font-family:Times New Roman;-inkscape-font-specification:Times New Roman"
x="488.13605"
y="59.544075"
id="text3016"
sodipodi:linespacing="125%"><tspan
sodipodi:role="line"
id="tspan3018"
x="488.13605"
y="59.544075" /></text>
</g>
</svg>

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@ -85,16 +85,30 @@ function getPointsFromPath(path) {
var cmds = path.split(' ');
var cursor = { x:0.0, y:0.0 };
var move = false;
var prevCmd = "";
for (var i=0; i<cmds.length; i++) {
var cmd = cmds[i];
var xy = cmds[i].split(",");
if (cmd=='m') move = true;
if (xy.length==2) {
cursor.x += parseFloat(xy[0]);
cursor.y += parseFloat(xy[1]);
points.push([cursor.x,cursor.y,move]); //{x:cursor.x,y:cursor.y,move:move})
move = false;
}
var cmd = cmds[i];
var xy = cmd.split(",");
if (cmd=='m') move = true;
if (xy.length==2) { // if there are two parts (a comma) we asume it's a l command. (So L is not supported)
cursor.x += parseFloat(xy[0]);
cursor.y += parseFloat(xy[1]);
points.push([cursor.x,cursor.y,move]);
move = false;
} else if (prevCmd == "h"){
cursor.x += parseFloat(cmd);
points.push([cursor.x,cursor.y,move]);
} else if (prevCmd == "v"){
cursor.y += parseFloat(cmd);
points.push([cursor.x,cursor.y,move]);
} else if (prevCmd == "H"){
cursor.x = parseFloat(cmd);
points.push([cursor.x,cursor.y,move]);
} else if (prevCmd == "V"){
cursor.y = parseFloat(cmd);
points.push([cursor.x,cursor.y,move]);
}
prevCmd = cmd;
}
return points;
}

File diff suppressed because it is too large Load Diff

Before

Width:  |  Height:  |  Size: 200 KiB

After

Width:  |  Height:  |  Size: 111 KiB