Commit c319a298 authored by LULUDBR\Lulu's avatar LULUDBR\Lulu

SequentMatcher update + highlighting

parent 6cf2c028
Pipeline #16551 canceled with stages
in 90 minutes and 5 seconds
......@@ -32,7 +32,7 @@ public class SequentMatcher extends BorderPane {
public GoalOptionsMenu goalOptionsMenu = new GoalOptionsMenu();
@FXML
private SequentViewMatcher sequentView;
private SequentView sequentView;
@FXML
private ListView<GoalNode<KeyData>> goalView;
......@@ -74,7 +74,7 @@ public class SequentMatcher extends BorderPane {
newValue.forEach((name, mp) -> {
PosInOccurrence pio = mp.pio();
Range r = cursorPosition.get(pio);
sequentView.setStyleClass(r.start(),r.end(), "sequent-highlight"); //TODO
sequentView.setStyleClass(r.start(),r.end(), "sequent-highlight");
System.out.println("Highlight " + r.start() + " " + r.end());
});
......
......@@ -2,6 +2,7 @@ package edu.kit.iti.formal.psdbg.gui.controls;
import com.google.common.collect.BiMap;
import com.google.common.collect.HashBiMap;
import edu.kit.iti.formal.psdbg.gui.ProofScriptDebugger;
import edu.kit.iti.formal.psdbg.gui.model.InspectionModel;
import edu.kit.iti.formal.psdbg.interpreter.data.KeyData;
import javafx.beans.property.ObjectProperty;
......@@ -16,6 +17,7 @@ import javafx.scene.control.*;
import javafx.stage.Modality;
import javafx.stage.Stage;
import javafx.stage.StageStyle;
import org.dockfx.DockNode;
import java.util.function.Function;
......@@ -34,18 +36,25 @@ public class SequentOptionsMenu extends ContextMenu {
@Override
public void handle(ActionEvent event) {
//TODO: Abchecken ob überhaupt eine Sequenz vorhanden ist
try {
SequentMatcher root1 = new SequentMatcher();
root1.setGoals(model.getGoals());
root1.setSelectedGoalNodeToShow(model.getSelectedGoalNodeToShow());
root1.getStyleClass().add("sequent-view");
Stage stage = new Stage();
stage.setTitle("Sequent Matcher");
stage.setScene(new Scene(root1));
Scene scene = new Scene(root1);
scene.getStylesheets().addAll(
// ProofScriptDebugger.class.getClass().getResource("debugger-ui.css").toExternalForm()
getClass().getResource("/edu/kit/iti/formal/psdbg/gui/debugger-ui.css")
.toExternalForm());
stage.setScene(scene);
stage.show();
//TODO: probably have to add a few things here (Lulu)
} catch (Exception e) {
e.printStackTrace();
......
<?xml version="1.0" encoding="UTF-8"?>
<?import edu.kit.iti.formal.psdbg.gui.controls.SequentViewMatcher?>
<?import javafx.geometry.Insets?>
<?import javafx.scene.control.Button?>
<?import javafx.scene.control.Label?>
......@@ -13,6 +12,7 @@
<?import de.jensd.fx.glyphs.materialdesignicons.MaterialDesignIconView?>
<?import edu.kit.iti.formal.psdbg.gui.controls.SectionPane?>
<?import javafx.scene.layout.Pane?>
<?import edu.kit.iti.formal.psdbg.gui.controls.SequentView?>
<fx:root xmlns="http://javafx.com/javafx/8.0.121" xmlns:fx="http://javafx.com/fxml/1"
type="edu.kit.iti.formal.psdbg.gui.controls.SequentMatcher">
<center>
......@@ -35,7 +35,7 @@
<SectionPane title="Sequent" minHeight="0.0" minWidth="0.0" prefHeight="633.0"
prefWidth="341.0">
<center>
<SequentViewMatcher fx:id="sequentView"/>
<SequentView fx:id="sequentView"/>
</center>
</SectionPane>
<SplitPane dividerPositions="0.28551136363636365" layoutX="11.0" layoutY="12.0"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment