Skip to content

Commit 0ca5adf

Browse files
committed
Automatic layout parameters in smartgraph.properties are now deprecated in favor of instantiated strategies in code.
1 parent ccbfac4 commit 0ca5adf

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

README.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,8 @@ In windows the JVM machine should automatically take care of that, while in Linu
6969
Graph<String, String> g = new GraphEdgeList<>();
7070
// ... see Examples below
7171

72-
SmartPlacementStrategy strategy = new SmartCircularSortedPlacementStrategy();
73-
SmartGraphPanel<String, String> graphView = new SmartGraphPanel<>(g, strategy);
72+
SmartPlacementStrategy initialPlacement = new SmartCircularSortedPlacementStrategy();
73+
SmartGraphPanel<String, String> graphView = new SmartGraphPanel<>(g, initialPlacement);
7474
Scene scene = new Scene(graphView, 1024, 768);
7575

7676
Stage stage = new Stage(StageStyle.DECORATED);
@@ -246,6 +246,11 @@ edge.label = false
246246
edge.arrow = false
247247

248248
# (automatic) Force-directed layout related configurations
249+
#
250+
# Notice: deprecated since version 1.1. Force directed layout strategies are now
251+
# instantiated and can be swapped at runtime, per the Strategy design pattern.
252+
# The parameters are passed as arguments or one can use the default ones described
253+
# in the javadoc documentation.
249254
# -- You should experiment with different values for your
250255
# -- particular problem, knowing that not all will achieve
251256
# -- a stable state

0 commit comments

Comments
 (0)