Commit 5bb6e0af authored by maxchaza's avatar maxchaza
Browse files

Merge branch 'hotfix/init_label'

parents 0104f3d1 ca86a45d
......@@ -7,7 +7,7 @@
/**
* The version of the application.
*/
"version": "3.0.16",
"version": "3.0.17",
/**
* The relative path to the application's markup file (html, jsp, asp, etc.).
......
......@@ -160,24 +160,24 @@ d3.selection.prototype.addNodeText = function(style) {
var name = style.getDisplayLabel(d, style.getLabel(), style.isUseAlias());
name = name.split(' ');
el.text('');
for (var i = 0; i < name.length; i++) {
var nameDOMFormat = $("<div/>").html(name[i]).text();
var tspan = el.append('tspan').text(nameDOMFormat);
if (d.labelFont){
if (d.labelFont.fontX) {
tspan
.attr('x', function () {
return d.labelFont.fontX;
});
}
else tspan.attr('x', 0);
}
else tspan.attr('x', 0);
if(style.getLabel()!=="hidden") {
for (var i = 0; i < name.length; i++) {
var nameDOMFormat = $("<div/>").html(name[i]).text();
var tspan = el.append('tspan').text(nameDOMFormat);
if (d.labelFont) {
if (d.labelFont.fontX) {
tspan
.attr('x', function () {
return d.labelFont.fontX;
});
} else tspan.attr('x', 0);
} else tspan.attr('x', 0);
if (i > 0){
tspan.attr('dy', style.getFontSize());
if (i > 0) {
tspan.attr('dy', style.getFontSize());
}
}
}
})
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment