Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Maintenance - Mise à jour mensuelle Lundi 6 Février entre 7h00 et 9h00
Open sidebar
metexplore
MetExploreViz
Commits
ca86a45d
Commit
ca86a45d
authored
Apr 16, 2020
by
maxchaza
Browse files
Fix label initialisation
parent
0104f3d1
Changes
2
Hide whitespace changes
Inline
Side-by-side
app.json
View file @
ca86a45d
...
...
@@ -7,7 +7,7 @@
/**
*
The
version
of
the
application.
*/
"version"
:
"3.0.1
6
"
,
"version"
:
"3.0.1
7
"
,
/**
*
The
relative
path
to
the
application's
markup
file
(html
,
jsp
,
asp
,
etc.).
...
...
resources/lib/functions/D3Extention.js
View file @
ca86a45d
...
...
@@ -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
());
}
}
}
})
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment