Merge branch 'master' of https://github.com/nhnent/raphael
This commit is contained in:
commit
13e96e0041
|
|
@ -474,6 +474,9 @@ define(["./raphael.core"], function(R) {
|
||||||
if (o._.sx != 1 || o._.sy != 1) {
|
if (o._.sx != 1 || o._.sy != 1) {
|
||||||
value /= mmax(abs(o._.sx), abs(o._.sy)) || 1;
|
value /= mmax(abs(o._.sx), abs(o._.sy)) || 1;
|
||||||
}
|
}
|
||||||
|
if (o.paper._vbSize) {
|
||||||
|
value *= o.paper._vbSize;
|
||||||
|
}
|
||||||
node.setAttribute(att, value);
|
node.setAttribute(att, value);
|
||||||
if (attrs["stroke-dasharray"]) {
|
if (attrs["stroke-dasharray"]) {
|
||||||
addDashes(o, attrs["stroke-dasharray"], params);
|
addDashes(o, attrs["stroke-dasharray"], params);
|
||||||
|
|
|
||||||
|
|
@ -878,9 +878,9 @@ define(["./raphael.core"], function(R) {
|
||||||
};
|
};
|
||||||
R._engine.setViewBox = function (x, y, w, h, fit) {
|
R._engine.setViewBox = function (x, y, w, h, fit) {
|
||||||
R.eve("raphael.setViewBox", this, this._viewBox, [x, y, w, h, fit]);
|
R.eve("raphael.setViewBox", this, this._viewBox, [x, y, w, h, fit]);
|
||||||
var paperSize = this.getSize(),
|
var width = this.width,
|
||||||
width = paperSize.width,
|
height = this.height,
|
||||||
height = paperSize.height,
|
size = 1 / mmax(w / width, h / height),
|
||||||
H, W;
|
H, W;
|
||||||
if (fit) {
|
if (fit) {
|
||||||
H = height / h;
|
H = height / h;
|
||||||
|
|
@ -896,10 +896,10 @@ define(["./raphael.core"], function(R) {
|
||||||
this._viewBoxShift = {
|
this._viewBoxShift = {
|
||||||
dx: -x,
|
dx: -x,
|
||||||
dy: -y,
|
dy: -y,
|
||||||
scale: paperSize
|
scale: size
|
||||||
};
|
};
|
||||||
this.forEach(function (el) {
|
this.forEach(function (el) {
|
||||||
el.transform("...");
|
el.transform("");
|
||||||
});
|
});
|
||||||
return this;
|
return this;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
14
raphael.js
14
raphael.js
|
|
@ -6392,7 +6392,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||||
if (o._.sx != 1 || o._.sy != 1) {
|
if (o._.sx != 1 || o._.sy != 1) {
|
||||||
value /= mmax(abs(o._.sx), abs(o._.sy)) || 1;
|
value /= mmax(abs(o._.sx), abs(o._.sy)) || 1;
|
||||||
}
|
}
|
||||||
node.setAttribute(att, value);
|
if (o.paper._vbSize) {
|
||||||
|
value *= o.paper._vbSize;
|
||||||
|
} node.setAttribute(att, value);
|
||||||
if (attrs["stroke-dasharray"]) {
|
if (attrs["stroke-dasharray"]) {
|
||||||
addDashes(o, attrs["stroke-dasharray"], params);
|
addDashes(o, attrs["stroke-dasharray"], params);
|
||||||
}
|
}
|
||||||
|
|
@ -8226,9 +8228,9 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||||
};
|
};
|
||||||
R._engine.setViewBox = function (x, y, w, h, fit) {
|
R._engine.setViewBox = function (x, y, w, h, fit) {
|
||||||
R.eve("raphael.setViewBox", this, this._viewBox, [x, y, w, h, fit]);
|
R.eve("raphael.setViewBox", this, this._viewBox, [x, y, w, h, fit]);
|
||||||
var paperSize = this.getSize(),
|
var width = this.width,
|
||||||
width = paperSize.width,
|
height = this.height,
|
||||||
height = paperSize.height,
|
size = 1 / mmax(w / width, h /height),
|
||||||
H, W;
|
H, W;
|
||||||
if (fit) {
|
if (fit) {
|
||||||
H = height / h;
|
H = height / h;
|
||||||
|
|
@ -8244,10 +8246,10 @@ return /******/ (function(modules) { // webpackBootstrap
|
||||||
this._viewBoxShift = {
|
this._viewBoxShift = {
|
||||||
dx: -x,
|
dx: -x,
|
||||||
dy: -y,
|
dy: -y,
|
||||||
scale: paperSize
|
scale: size
|
||||||
};
|
};
|
||||||
this.forEach(function (el) {
|
this.forEach(function (el) {
|
||||||
el.transform("...");
|
el.transform("");
|
||||||
});
|
});
|
||||||
return this;
|
return this;
|
||||||
};
|
};
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue