Skip to content

Commit 1308c5b

Browse files
committed
Changed paths to fxml files + Prepared reversal of log negative axis
1 parent 8aebcb2 commit 1308c5b

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

src/main/java/dimorphisms/GraphicHelper.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,11 @@ public GraphicHelper() {
3535
" -fx-effect: null;\n" +
3636
"}\n" +
3737
".default-color0.chart-series-line { -fx-stroke: #e9967a; }\n");
38+
//this is used for reversing the second log scale
39+
//materialLinearGraphic.setScaleY(-1);
40+
materialLinearGraphic.setCreateSymbols(false);
3841
this.materialLogGraphic = new LineChart<>(xAxis,yAxisLog);
3942
this.materialLogGraphic = new LineChart<>(xAxis,yAxisLog);
40-
materialLogGraphic.setCreateSymbols(false);
4143
materialLogGraphic.setStyle(".chart-series-line { \n" +
4244
" -fx-stroke-width: 2px;\n" +
4345
" -fx-effect: null;\n" +

src/main/java/dimorphisms/ViewController.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public void start(Stage primaryStage) throws Exception{
2828
this.primaryStage = primaryStage;
2929
domainController = new DomainController();
3030
FXMLLoader fxmlLoader = new FXMLLoader();
31-
Pane p = fxmlLoader.load(getClass().getResource("../../resources/MainMenu.fxml").openStream());
31+
Pane p = fxmlLoader.load(getClass().getResource("/MainMenu.fxml").openStream());
3232
MainMenu fooController = (MainMenu) fxmlLoader.getController();
3333
fooController.setViewController(this);
3434

@@ -56,7 +56,7 @@ public static void main(String[] args) {
5656
public void newMaterial(String materialName) throws IOException {
5757

5858
FXMLLoader fxmlLoader = new FXMLLoader();
59-
GridPane pane = fxmlLoader.load(getClass().getResource("../../resources/DataEntry.fxml").openStream());
59+
GridPane pane = fxmlLoader.load(getClass().getResource("/DataEntry.fxml").openStream());
6060
DataEntry dataEntry = (DataEntry) fxmlLoader.getController();
6161
dataEntry.setViewController(this);
6262
dataEntry.setMaterialName(materialName);
@@ -66,7 +66,7 @@ public void newMaterial(String materialName) throws IOException {
6666
primaryStage.show();
6767
domainController.newMaterial(materialName);
6868
fxmlLoader = new FXMLLoader();
69-
Pane p = fxmlLoader.load(getClass().getResource("../../resources/GraphicView.fxml").openStream());
69+
Pane p = fxmlLoader.load(getClass().getResource("/GraphicView.fxml").openStream());
7070
GraphicView fooController = (GraphicView) fxmlLoader.getController();
7171
fooController.setViewController(this);
7272
graphicViewScene = new Scene(p,715,415);
@@ -89,7 +89,7 @@ public void viewGraphic() throws IOException {
8989
*/
9090
public void viewStableDiagram() throws IOException {
9191
FXMLLoader fxmlLoader = new FXMLLoader();
92-
Pane p = fxmlLoader.load(getClass().getResource("../../resources/GraphicView.fxml").openStream());
92+
Pane p = fxmlLoader.load(getClass().getResource("/GraphicView.fxml").openStream());
9393
GraphicView fooController = (GraphicView) fxmlLoader.getController();
9494
fooController.setViewController(this);
9595

0 commit comments

Comments
 (0)