Change style
This commit is contained in:
parent
c129af5142
commit
0676d16b3a
2 changed files with 18 additions and 1 deletions
|
@ -17,7 +17,7 @@ public class Main {
|
|||
Grid g=new Grid();
|
||||
|
||||
|
||||
System.setProperty("gs.ui.renderer", "org.graphstream.ui.j2dviewer.J2DGraphRenderer");
|
||||
System.setProperty("org.graphstream.ui.renderer", "org.graphstream.ui.j2dviewer.J2DGraphRenderer");
|
||||
Graph graph = new SingleGraph("Tutorial 1");
|
||||
graph.addAttribute("ui.stylesheet", "url('resources/style.css')");
|
||||
|
||||
|
|
17
resources/style.css
Normal file
17
resources/style.css
Normal file
|
@ -0,0 +1,17 @@
|
|||
node {
|
||||
size: 64px;
|
||||
fill-mode: image-scaled;
|
||||
fill-image: url('resources/images/r1.png');
|
||||
|
||||
}
|
||||
|
||||
edge {
|
||||
text-size: 20;
|
||||
size:2;
|
||||
text-offset:25,25;
|
||||
}
|
||||
|
||||
graph {
|
||||
padding: 50;
|
||||
|
||||
}
|
Loading…
Add table
Reference in a new issue