Mostly cosmetic

Sync with latest SVG-Edit.
Tweak an icon.
This commit is contained in:
Jacques Distler 2010-02-13 00:11:13 -06:00
parent db7bbca920
commit d503100fe9
5 changed files with 115 additions and 85 deletions

View file

@ -318,6 +318,8 @@
<path d="M209.1,157.9c-0.8,0.7-1.7,1.5-2.7,2.6v17.4c0,4,0.4,5.3,2.7,5.9"/>
</g>
<g>
<polyline opacity="0.2" fill="#231F20" points="209.1,76.4 118.7,186.5 139.1,186.4 209.1,121 209.1,76.4 "/>
<polyline opacity="0.4" fill="#231F20" points="209.1,76.2 118.5,186.5 129.7,186.4 200.2,120.3 209.1,100.8 209.1,76.4 "/>
<path fill="#FFD761" d="M121.6,88.7l0.8,87.5l62.3-56.7c0,0-15.3-25.8-24.8-30C151.1,85.6,121.6,88.7,121.6,88.7z"/>
<path fill="#FEA01E" d="M209.1,19.5h-54l-33.5,69.2c0,0,29.7-3.4,38.3,0.8c8.9,4.4,25,30.8,25,30.8l24.2-50V19.5z"/>
<path d="M120.4,153.7l-0.6,25l23.8-16.9c0,0-8-7-11.2-8.1C129.4,152.8,120.4,153.7,120.4,153.7z"/>

Before

Width:  |  Height:  |  Size: 50 KiB

After

Width:  |  Height:  |  Size: 50 KiB

View file

@ -1,5 +1,5 @@
body {
background: #E8E8E8;
body {
background: #D8D8D8;
}
#svg_editor {
@ -106,7 +106,6 @@ body {
#svg_editor #layerpanel {
display: inline-block;
background-color: #E8E8E8;
position:absolute;
top: 1px;
bottom: 0px;
@ -124,7 +123,8 @@ body {
#svg_editor #sidepanel_handle {
display: inline-block;
position: absolute;
background-color: #E8E8E8;
background-color: #D8D8D8;
font-weight: bold;
left: 0px;
top: 40%;
width: 1em;
@ -247,17 +247,19 @@ body {
left: 4px;
}
#svg_editor #main_icon {
background: #E8E8E8;
position: relative;
top: -2px;
left: -2px;
padding: 1px 0 2px 1px;
width: 44px;
height: 30px;
border-left: 1px solid #EEE;
border-top: 1px solid #EEE;
border-right: 1px solid #CCC;
border-bottom: 1px solid #CCC;
border-left: 1px solid #FFF;
border-top: 1px solid #FFF;
border-right: 1px solid #808080;
border-bottom: 1px solid #808080;
border-radius: 8px;
-moz-border-radius: 8px;
-webkit-border-radius: 8px;
@ -376,7 +378,6 @@ body {
top: 75px;
left: 0;
padding-left: 2px;
background: #E8E8E8;
z-index: 4;
}
@ -556,8 +557,8 @@ span.zoom_tool {
width: 24px;
margin: 2px;
padding: 2px;
border-left: 1px solid #FFFFFF;
border-top: 1px solid #FFFFFF;
border-left: 1px solid #FFF;
border-top: 1px solid #FFF;
border-right: 1px solid #808080;
border-bottom: 1px solid #808080;
background-color: #E8E8E8;

View file

@ -171,12 +171,39 @@ function svg_edit_setup() {
var fillPaint = new $.jGraduate.Paint({solidColor: "FF0000"}); // solid red
var strokePaint = new $.jGraduate.Paint({solidColor: "000000"}); // solid black
// TODO: Unfortunately Mozilla does not handle internal references to gradients
// inside a data: URL document. This means that any elements filled/stroked
// with a gradient will appear black in Firefox, etc. See bug 308590
// https://bugzilla.mozilla.org/show_bug.cgi?id=308590
var saveHandler = function(window,svg) {
window.opener.postMessage(svg, window.location.protocol + '//' + window.location.host);
return;
// Creates and opens an HTML page that provides a link to the SVG, a preview, and the markup.
// Also includes warning about Mozilla bug #308590 when applicable
var win = window.open("data:image/svg+xml;base64," + Utils.encode64(svg));
// Alert will only appear the first time saved OR the first time the bug is encountered
var done = $.pref('save_notice_done') + ""; // TODO: Find out why this returns an object in FF when online
if(done !== "all") {
var note = 'Select "Save As..." in your browser to save this image as an SVG file.';
// Check if FF and has <defs/>
if(navigator.userAgent.indexOf('Gecko/') !== -1) {
if(svg.indexOf('<defs') !== -1) {
note += "\n\nNOTE: Due to a bug in your browser, this image may appear wrong (missing gradients or elements). It will however appear correct once actually saved.";
$.pref('save_notice_done', 'all');
done = "all";
} else {
$.pref('save_notice_done', 'part');
}
} else {
$.pref('save_notice_done', 'all');
}
if(done !== 'part') {
win.alert(note);
}
}
};
// called when we've selected a different element
@ -2785,7 +2812,7 @@ function svg_edit_setup() {
updateCanvas(true);
});
// var revnums = "svg-editor.js ($Rev: 1377 $) ";
// var revnums = "svg-editor.js ($Rev: 1386 $) ";
// revnums += svgCanvas.getVersion();
// $('#copyright')[0].setAttribute("title", revnums);
return svgCanvas;

View file

@ -1,4 +1,4 @@
/*
/*
* svgcanvas.js
*
* Licensed under the Apache License, Version 2