Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
sarah.grebing
ProofScriptParser
Commits
2e7c295f
Commit
2e7c295f
authored
May 28, 2018
by
Sarah Grebing
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added shprtcut for handling terms, now git the whole Java bug
parent
88addd0e
Pipeline
#22193
passed with stages
in 5 minutes and 27 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
2 deletions
+17
-2
ui/src/main/java/edu/kit/iti/formal/psdbg/gui/controller/DebuggerMain.java
...edu/kit/iti/formal/psdbg/gui/controller/DebuggerMain.java
+4
-2
ui/src/main/java/edu/kit/iti/formal/psdbg/gui/controls/ScriptArea.java
...ava/edu/kit/iti/formal/psdbg/gui/controls/ScriptArea.java
+13
-0
No files found.
ui/src/main/java/edu/kit/iti/formal/psdbg/gui/controller/DebuggerMain.java
View file @
2e7c295f
...
...
@@ -66,6 +66,7 @@ import org.reactfx.util.Timer;
import
javax.annotation.Nullable
;
import
javax.swing.*
;
import
java.awt.im.InputContext
;
import
java.io.File
;
import
java.io.FileWriter
;
import
java.io.IOException
;
...
...
@@ -277,6 +278,7 @@ public class DebuggerMain implements Initializable {
ImmutableList
<
Goal
>
openGoals
=
p
.
getSubtreeGoals
(
p
.
root
());
KeyData
kd
=
new
KeyData
(
openGoals
.
get
(
0
),
env
,
p
);
scriptController
.
getAutoCompleter
().
getArgumentCompleter
().
setDefaultKeyData
(
kd
);
};
getFacade
().
environmentProperty
().
addListener
(
invalidationListener
);
getFacade
().
proofProperty
().
addListener
(
invalidationListener
);
...
...
@@ -676,8 +678,8 @@ public class DebuggerMain implements Initializable {
private
void
onInterpreterError
(
DebuggerFramework
<
KeyData
>
keyDataDebuggerFramework
,
Throwable
throwable
)
{
Platform
.
runLater
(()
->
{
Utils
.
showExceptionDialog
(
"
E
rror during
E
xecution"
,
"Error during Script Execution"
,
"
Here should be some really good text...\nNothing will be the same. Everything broken
."
,
Utils
.
showExceptionDialog
(
"
An e
rror
has occurred
during
e
xecution
.
"
,
"Error during Script Execution"
,
"
Please reload the problem to get a consistent proof state
."
,
throwable
);
});
...
...
ui/src/main/java/edu/kit/iti/formal/psdbg/gui/controls/ScriptArea.java
View file @
2e7c295f
...
...
@@ -34,6 +34,7 @@ import javafx.scene.Node;
import
javafx.scene.Scene
;
import
javafx.scene.control.*
;
import
javafx.scene.input.*
;
import
static
javafx
.
scene
.
input
.
KeyCombination
.
CONTROL_ANY
;
import
javafx.scene.layout.*
;
import
javafx.scene.paint.Color
;
import
javafx.scene.paint.Paint
;
...
...
@@ -141,6 +142,7 @@ public class ScriptArea extends BorderPane {
private
void
init
()
{
codeArea
.
setAutoScrollOnDragDesired
(
false
);
InputMap
<
KeyEvent
>
inputMap
=
sequence
(
process
(
EventPattern
.
keyPressed
(),
(
e
)
->
{
...
...
@@ -148,6 +150,8 @@ public class ScriptArea extends BorderPane {
inlineToolbar
.
hide
();
return
PROCEED
;
}),
consume
(
keyPressed
(
new
KeyCodeCombination
(
KeyCode
.
E
,
KeyCombination
.
CONTROL_DOWN
))
,
(
e
)
->
addBackticks
()),
consumeWhen
(
keyPressed
(
KeyCode
.
ENTER
),
autoCompletion:
:
isVisible
,
e
->
autoCompletion
.
complete
()),
consume
(
keyPressed
(
KeyCode
.
ENTER
,
SHORTCUT_DOWN
),
...
...
@@ -241,6 +245,7 @@ public class ScriptArea extends BorderPane {
//this.moveTo(characterPosition, NavigationActions.SelectionPolicy.CLEAR);
});
mainScript
.
addListener
((
observable
)
->
updateMainScriptMarker
());
filePath
.
addListener
((
p
,
o
,
n
)
->
{
if
(
o
!=
null
)
...
...
@@ -357,6 +362,14 @@ public class ScriptArea extends BorderPane {
}
private
void
addBackticks
(){
int
pos
=
codeArea
.
getCaretPosition
();
insertText
(
pos
,
"``"
);
codeArea
.
displaceCaret
(
pos
+
1
);
}
private
void
highlightProblems
()
{
LinterStrategy
ls
=
LinterStrategy
.
getDefaultLinter
();
try
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment