Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
vidjil
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1,712
Issues
1,712
List
Boards
Labels
Service Desk
Milestones
Merge Requests
87
Merge Requests
87
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
CI / CD
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
vidjil
vidjil
Commits
ec01f197
Commit
ec01f197
authored
Jan 06, 2015
by
Marc Duez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
scatterplot.js : adjustement for html export
parent
7963ad66
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
11 deletions
+20
-11
browser/css/vidjil.less
browser/css/vidjil.less
+1
-0
browser/js/scatterPlot.js
browser/js/scatterPlot.js
+19
-11
No files found.
browser/css/vidjil.less
View file @
ec01f197
...
...
@@ -306,6 +306,7 @@ line {
-ms-transition: fill 0.2s;
transition: fill 0.2s;
fill : @default;
stroke-width:4px;
}
.circle_inactive{
...
...
browser/js/scatterPlot.js
View file @
ec01f197
...
...
@@ -29,7 +29,7 @@ function ScatterPlot(id, model) {
this
.
gridSizeH
=
1
;
//grid height
//Margins left/right ( fixed value )
this
.
marge_left
=
1
2
0
;
this
.
marge_left
=
1
0
0
;
this
.
marge_right
=
10
;
this
.
marge_top
=
45
;
this
.
marge_bot
=
10
;
...
...
@@ -86,7 +86,7 @@ function ScatterPlot(id, model) {
//axis Y text position
this
.
rotation_y
=
0
;
this
.
text_position_y
=
40
;
this
.
sub_text_position_y
=
9
0
;
this
.
sub_text_position_y
=
8
0
;
//Clone selected
this
.
cloneSelected
=
-
1
;
...
...
@@ -256,7 +256,6 @@ ScatterPlot.prototype = {
//Action concernant tous les nodes présents dans le ScatterPlot
this
.
plot_container
.
selectAll
(
"
circle
"
)
.
attr
(
"
stroke-width
"
,
4
)
.
attr
(
"
stroke
"
,
""
)
.
attr
(
"
id
"
,
function
(
d
)
{
return
"
circle
"
+
d
.
id
;
...
...
@@ -819,12 +818,14 @@ ScatterPlot.prototype = {
/* Recalcule les coefficients d'agrandissement/réduction, en fonction de la taille de la div
* */
resize
:
function
(
div_width
,
div_height
)
{
var
print
=
true
if
(
typeof
div_height
==
'
undefined
'
){
var
div
=
document
.
getElementById
(
this
.
id
)
var
div_height
=
div
.
offsetHeight
var
div_width
=
div
.
offsetWidth
print
=
false
}
this
.
compute_size
(
div_width
,
div_height
)
this
.
compute_size
(
div_width
,
div_height
,
print
)
//Attributions
this
.
vis
=
d3
.
select
(
"
#
"
+
this
.
id
+
"
_svg
"
)
.
attr
(
"
width
"
,
div_width
)
...
...
@@ -840,7 +841,7 @@ ScatterPlot.prototype = {
.
initGrid
();
},
compute_size
:
function
(
div_width
,
div_height
)
{
compute_size
:
function
(
div_width
,
div_height
,
print
)
{
if
(
typeof
div_height
==
'
undefined
'
){
var
div
=
document
.
getElementById
(
this
.
id
)
var
div_height
=
div
.
offsetHeight
...
...
@@ -860,7 +861,7 @@ ScatterPlot.prototype = {
this
.
systemGrid
=
{}
}
if
(
this
.
splitY
!=
"
bar
"
&&
this
.
use_system_grid
&&
this
.
m
.
system_available
.
length
>
1
){
if
(
!
print
&&
this
.
splitY
!=
"
bar
"
&&
this
.
use_system_grid
&&
this
.
m
.
system_available
.
length
>
1
){
this
.
gridSizeW
=
0.8
*
this
.
resizeW
;
this
.
gridSizeH
=
1
*
this
.
resizeH
;
}
else
{
...
...
@@ -895,6 +896,14 @@ ScatterPlot.prototype = {
.
attr
(
"
y2
"
,
function
(
d
)
{
return
(
d
.
target
.
py
+
self
.
marge_top
);});
},
zap
:
function
()
{
this
.
node
.
each
(
function
(
d
)
{
d
.
x
=
d
.
x2
d
.
y
=
d
.
y2
d
.
r2
=
d
.
r1
})
},
/* Fonction permettant le calcul d'une étape d'animation
* */
tick
:
function
()
{
...
...
@@ -949,13 +958,12 @@ ScatterPlot.prototype = {
this
.
time0
=
this
.
time1
;
},
/* Fonction permettant le déplacement des nodes en fonction de la méthode de répartition utilisée à l'instant T
* */
move
:
function
()
{
self
=
this
;
return
function
(
d
)
{
if
(
d
.
x
!=
d
.
x2
)
{
var
delta
=
d
.
x2
-
d
.
x
;
var
s
=
((
d
.
r1
/
self
.
resizeCoef
))
...
...
@@ -1332,9 +1340,9 @@ ScatterPlot.prototype = {
var
className
=
"
sp_legend
"
if
(
space
<
1.1
){
this
.
rotation_x
=
3
3
0
;
this
.
text_position_x
=
3
5
;
this
.
sub_text_position_x
=
5
0
;
this
.
rotation_x
=
3
2
0
;
this
.
text_position_x
=
4
5
;
this
.
sub_text_position_x
=
5
5
;
className
=
"
sp_rotated_legend
"
;
}
else
{
this
.
rotation_x
=
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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