Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raw verification options issues - fix 2046945 #128

Merged
merged 51 commits into from
Jan 30, 2024
Merged
Changes from 3 commits
Commits
Show all changes
51 commits
Select commit Hold shift + click to select a range
b1827d3
Fixed bug where raw verifications would be empty when creating new query
mtygesen Dec 28, 2023
7c90d9e
Fixed bug where query options would be disabled when using raw verifi…
mtygesen Dec 28, 2023
375b87d
Fixed eof
mtygesen Dec 28, 2023
93613d5
And / or now enabled under ERK example, and also fixed issue where lo…
mtygesen Dec 30, 2023
9f1dbe2
Now disables open reduced when using raw verifications
mtygesen Dec 30, 2023
132a5b1
Now evaluates if open reduced net button should be enabled/disabled c…
mtygesen Dec 30, 2023
044472d
Fixed bug where raw verification options would appear when changing t…
mtygesen Dec 30, 2023
975afdc
Merged together with premature eof branch
mtygesen Jan 3, 2024
61f3fa2
Fixed bug where buttons would enable again when changing queryType an…
mtygesen Jan 3, 2024
16ac01e
updated function name
mtygesen Jan 3, 2024
769ee64
Removed extra semi colon
mtygesen Jan 3, 2024
4aa0047
Now works for verifypn
mtygesen Jan 4, 2024
3ace385
Now works for verifypn
mtygesen Jan 4, 2024
ef6cfa8
Refactors
mtygesen Jan 4, 2024
0865d31
Fixed k-bound bug
mtygesen Jan 4, 2024
04948f2
Changed raw verification field into text area
mtygesen Jan 7, 2024
369d57f
Changed raw verification field into text area
mtygesen Jan 7, 2024
6066040
updated text area in raw verification options
mtygesen Jan 8, 2024
bb75aef
now opens in advanced view if query using raw verification options
mtygesen Jan 8, 2024
e077b90
Restructured raw verification layout
mtygesen Jan 9, 2024
8cf62c2
Removed redundant inset
mtygesen Jan 9, 2024
96ae244
Fixed mismatching tmp file names
mtygesen Jan 9, 2024
5e87acb
removed log
mtygesen Jan 9, 2024
af292bc
Made code more clear
mtygesen Jan 9, 2024
8a2cee3
Fixed bug where state of useRawVerification was firstly updated secon…
mtygesen Jan 11, 2024
f7828af
Now correctly disables/enables components when selecting parts of a q…
mtygesen Jan 12, 2024
84fb967
Now correctly enables/disables options when opening new query and whe…
mtygesen Jan 13, 2024
0487d6f
Fixed NPE
mtygesen Jan 15, 2024
859af02
fix
mtygesen Jan 16, 2024
90046f0
fixed issue where not all options would be disabled correctly when us…
mtygesen Jan 16, 2024
d70e3b0
now correctly enables the options again when toggling the use button …
mtygesen Jan 16, 2024
c9fd4cb
Added guard to refreshOverApproximationOption so it exits immediatly …
mtygesen Jan 17, 2024
e4132cb
Fixed issue with siphon trap and use color reductions
mtygesen Jan 18, 2024
e93b4d8
Fixed unfolded paths being added to non-colored nets using DTAPN
mtygesen Jan 20, 2024
977084c
use colored reduction now only visible for colored nets
mtygesen Jan 22, 2024
3895112
Fixed issue with verifying multiple queries at once, and "use stubbor…
mtygesen Jan 23, 2024
76e9cf2
Use trace refinement and siphon trap analysis now only available for CTL
mtygesen Jan 24, 2024
143dd7e
Fixes Kbound analysis and LTL / HyperLTL focus
mtygesen Jan 24, 2024
c270579
removed debug log
mtygesen Jan 25, 2024
65a32ea
Fixed bug with add predicates button
mtygesen Jan 25, 2024
d3d8637
Now logic buttons should be enabled/disabled correctly
mtygesen Jan 26, 2024
5b9add6
Now allows multiple quantifiers for non-game untimed nets
mtygesen Jan 27, 2024
8584b40
Updated when logic buttons are enabled
mtygesen Jan 27, 2024
5bb553d
Now allows boolean operators for until quantifier
mtygesen Jan 28, 2024
170d613
Now also enables boolean operators for X, G, and F
mtygesen Jan 28, 2024
50cae6a
Simplified logic
mtygesen Jan 28, 2024
09a1d9b
Fixed boolean operators not enabled in some cases
mtygesen Jan 28, 2024
ba3c35a
Enable buttons if the condition is not met to ensure correct state in…
mtygesen Jan 28, 2024
61a6349
Removed binding flag
mtygesen Jan 28, 2024
f496b1c
Fixed problems with LTL/hyperLTL
mtygesen Jan 29, 2024
f1a5ec1
Small correction
mtygesen Jan 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 20 additions & 5 deletions src/main/java/net/tapaal/gui/petrinet/dialog/QueryDialog.java
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,7 @@ public static TAPNQuery showQueryDialogue(QueryDialogueOption option, TAPNQuery
return null;
}
guiDialog = new EscapableDialog(TAPAALGUI.getApp(), "Edit Query", true);

Container contentPane = guiDialog.getContentPane();

// 1 Set layout
Expand Down Expand Up @@ -822,10 +822,15 @@ private void updateQueryButtonsAccordingToSelection() {
int selectedIndex = queryType.getSelectedIndex();
if (current instanceof LTLANode || current instanceof LTLENode ||
((selectedIndex == 1 || selectedIndex == 2) && current instanceof TCTLPathPlaceHolder)) {
disjunctionButton.setEnabled(true);
conjunctionButton.setEnabled(true);
negationButton.setEnabled(false);
} else if (!lens.isGame()) {
disjunctionButton.setEnabled(true);
conjunctionButton.setEnabled(true);
negationButton.setEnabled(true);
}

if (lens.isGame()) {
if (newProperty instanceof TCTLAbstractPathProperty && !(newProperty instanceof TCTLPathPlaceHolder)) {
enableOnlyStateButtons();
Expand Down Expand Up @@ -1527,8 +1532,10 @@ private void init(QueryDialogueOption option, final TAPNQuery queryToCreateFrom)
initRawVerificationOptionsPanel();
initButtonPanel(option);

if(queryToCreateFrom != null) {
if (queryToCreateFrom != null) {
setupFromQuery(queryToCreateFrom);
} else {
setupRawVerificationOptionsFromQuery();
}

refreshTraceOptions();
Expand All @@ -1546,7 +1553,6 @@ private void init(QueryDialogueOption option, final TAPNQuery queryToCreateFrom)
refreshUndoRedo();

setEnabledOptionsAccordingToCurrentReduction();
//setVerificationOptionsEnabled(!queryToCreateFrom.getRawVerification());

makeShortcuts();

Expand Down Expand Up @@ -1589,6 +1595,11 @@ private void setupRawVerificationOptionsFromQuery(TAPNQuery queryToCreateFrom) {
rawVerificationOptionsTextField.setText(queryToCreateFrom.getRawVerificationPrompt());
}

private void setupRawVerificationOptionsFromQuery() {
rawVerificationOptionsEnabled.setSelected(false);
rawVerificationOptionsTextField.setText("-x 1 ");
}

private void setupTraceListFromQuery(TAPNQuery queryToCreateFrom) {
// First remove all elements (removes the default trace that was added)
traceModel.removeAllElements();
Expand Down Expand Up @@ -4526,7 +4537,11 @@ private void initRawVerificationOptionsPanel() {
rawVerificationOptionsTextField = new JTextField();
rawVerificationOptionsTextField.setEnabled(false);
rawVerificationOptionsTextField.setToolTipText(TOOL_TIP_RAW_VERIFICATION_TEXT_FIELD);


Dimension dim = new Dimension(200, 20);
rawVerificationOptionsTextField.setPreferredSize(dim);
rawVerificationOptionsTextField.setMaximumSize(dim);

rawVerificationOptionsHelpButton = new JButton("Help on options");
rawVerificationOptionsHelpButton.setEnabled(false);
rawVerificationOptionsHelpButton.setToolTipText(TOOL_TIP_RAW_VERIFICATION_HELP_BUTTON);
Expand Down Expand Up @@ -4635,10 +4650,10 @@ private void setAllEnabled(Container container, boolean isEnabled) {

protected void setEnabledOptionsAccordingToCurrentReduction() {
if (rawVerificationOptionsEnabled.isSelected()) {
refreshQueryEditingButtons();
return;
}

refreshQueryEditingButtons();
refreshTraceOptions();
if (lens.isTimed()) {
refreshSymmetryReduction();
Expand Down
Loading