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
G
gs-core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
graphstream
gs-core
Commits
b5e1f46f
Commit
b5e1f46f
authored
Jun 06, 2014
by
Antoine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixes #120
parent
d9d2aef0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
19 deletions
+11
-19
src/org/graphstream/ui/graphicGraph/GraphicGraph.java
src/org/graphstream/ui/graphicGraph/GraphicGraph.java
+11
-19
No files found.
src/org/graphstream/ui/graphicGraph/GraphicGraph.java
View file @
b5e1f46f
...
...
@@ -339,16 +339,8 @@ public class GraphicGraph extends AbstractElement implements Graph,
*/
public
void
computeBounds
()
{
if
(
boundsChanged
)
{
lo
.
x
=
lo
.
y
=
lo
.
z
=
Double
.
POSITIVE_INFINITY
;
// 1000000000; // A
// bug with
// Double.MAX_VALUE
// during
// comparisons ?
hi
.
x
=
hi
.
y
=
hi
.
z
=
Double
.
NEGATIVE_INFINITY
;
// -1000000000; // A
// bug with
// Double.MIN_VALUE
// during
// comparisons ?
lo
.
x
=
lo
.
y
=
lo
.
z
=
Double
.
MAX_VALUE
;
hi
.
x
=
hi
.
y
=
hi
.
z
=
-
Double
.
MAX_VALUE
;
for
(
Node
n
:
getEachNode
())
{
GraphicNode
node
=
(
GraphicNode
)
n
;
...
...
@@ -393,17 +385,17 @@ public class GraphicGraph extends AbstractElement implements Graph,
}
}
if
(
(
hi
.
x
-
lo
.
x
<
0.000001
)
)
{
hi
.
x
=
1
;
lo
.
x
=
-
1
;
if
(
hi
.
x
-
lo
.
x
<
0.000001
)
{
hi
.
x
=
hi
.
x
+
1
;
lo
.
x
=
lo
.
x
-
1
;
}
if
(
(
hi
.
y
-
lo
.
y
<
0.000001
)
)
{
hi
.
y
=
1
;
lo
.
y
=
-
1
;
if
(
hi
.
y
-
lo
.
y
<
0.000001
)
{
hi
.
y
=
hi
.
y
+
1
;
lo
.
y
=
lo
.
y
-
1
;
}
if
(
(
hi
.
z
-
lo
.
z
<
0.000001
)
)
{
hi
.
z
=
1
;
lo
.
z
=
-
1
;
if
(
hi
.
z
-
lo
.
z
<
0.000001
)
{
hi
.
z
=
hi
.
z
+
1
;
lo
.
z
=
lo
.
z
-
1
;
}
boundsChanged
=
false
;
...
...
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