Classes | |
class | ActionEditorWindow |
Public Member Functions | |
void | addAction (Action a) |
void | clearHighlight () |
void | controlEvent (ControlEvent ev) |
void | draw () |
void | drawActionsTreeLayout () |
synchronized void | drawTransitions (PApplet app) |
Frame | findFrame () |
Action | getCurrTask () |
boolean | highlightAction (Action a, boolean expand) |
boolean | highlightAction (String identifier, boolean expand) |
void | keyPressed (KeyEvent e) |
void | loadPrologPlan (String identifier) |
void | mouseClicked (MouseEvent e) |
void | mouseDragged (MouseEvent e) |
void | mouseEntered (MouseEvent e) |
void | mouseExited (MouseEvent e) |
void | mouseMoved (MouseEvent e) |
void | mousePressed (MouseEvent e) |
void | mouseReleased (MouseEvent e) |
void | setTask (Action action) |
void | setup () |
void | syncWithProlog () |
Static Public Member Functions | |
static void | arrow (PApplet applet, float x, float y, float width, float height) |
static void | arrowFromTo (PApplet applet, Vector2f from, Vector2f to, float lineWidth, float blockLength) |
static Vector< Vector2f > | getArrowVertices (PApplet applet, Vector2f from, Vector2f to, float lineWidth, float blockLength) |
Public Attributes | |
ControlP5 | controlP5 |
Private Member Functions | |
void | drawActions () |
void | drawHistory () |
int | getHistoryHover (float x, float y) |
void | initControlP5 () |
void | updateHistoryPosition () |
Private Attributes | |
ActionTransition | activeTransition |
Textfield | base_iri = null |
ArrayList < ActionSelectHistoryInfo > | clickHistory = new ArrayList<ActionSelectHistoryInfo>() |
Action | currTask = null |
PFont | dejavuFont |
Action | draggedAction |
Vector2f | draggingStart = new Vector2f(0,0) |
Textfield | end_action |
Vector2f | globalPosOffset = new Vector2f(0,0) |
long | lastClickTime = 0 |
Textfield | new_recipe_label = null |
Textfield | new_recipe_shortname = null |
Action | newTransitionFromAction |
Vector2f | newTransitionToLocation = new Vector2f() |
boolean | select_end = false |
boolean | select_start = false |
Action | selectedAction |
Textfield | start_action |
Static Private Attributes | |
static final Cursor | handCursor = new Cursor(Cursor.HAND_CURSOR) |
static final Cursor | moveCursor = new Cursor(Cursor.MOVE_CURSOR) |
static final Cursor | normalCursor = new Cursor(Cursor.DEFAULT_CURSOR) |
static final long | serialVersionUID = 7695328948788620463L |
Visualization applet for action plans as sequences or state machines.
Definition at line 43 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.addAction | ( | Action | a | ) | [inline] |
Implements edu.tum.cs.ias.knowrob.vis.applets.IAddActionCallback.
Definition at line 1027 of file PlanVisAppletFsm.java.
static void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.arrow | ( | PApplet | applet, |
float | x, | ||
float | y, | ||
float | width, | ||
float | height | ||
) | [inline, static] |
Draw an arrow pointing right at given position.
applet | Applet to draw on |
x | x position of the arrow bounding box. |
y | y position of the arrow bounding box |
width | width of the arrow |
height | height of the arrow |
Definition at line 309 of file PlanVisAppletFsm.java.
static void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.arrowFromTo | ( | PApplet | applet, |
Vector2f | from, | ||
Vector2f | to, | ||
float | lineWidth, | ||
float | blockLength | ||
) | [inline, static] |
Draw an arrow between the given two points with current stroke and fill settings.
applet | Applet to draw on |
from | Start position of arrow |
to | End position of arrow |
lineWidth | Width of arrow line (not the stroke). |
Definition at line 231 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.clearHighlight | ( | ) | [inline] |
Clear all highlighted actions so that none is highlighted.
Definition at line 1016 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.controlEvent | ( | ControlEvent | ev | ) | [inline] |
Handle control events from controlP5
ev | The ControlEvent generated by controlP5 |
Definition at line 907 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.draw | ( | ) | [inline] |
Definition at line 153 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.drawActions | ( | ) | [inline, private] |
Definition at line 433 of file PlanVisAppletFsm.java.
Draw the current selected action
Definition at line 375 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.drawHistory | ( | ) | [inline, private] |
Draw the current history in the upper area of the window
Definition at line 362 of file PlanVisAppletFsm.java.
synchronized void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.drawTransitions | ( | PApplet | app | ) | [inline] |
Definition at line 451 of file PlanVisAppletFsm.java.
Frame edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.findFrame | ( | ) | [inline] |
Definition at line 1035 of file PlanVisAppletFsm.java.
static Vector<Vector2f> edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.getArrowVertices | ( | PApplet | applet, |
Vector2f | from, | ||
Vector2f | to, | ||
float | lineWidth, | ||
float | blockLength | ||
) | [inline, static] |
Definition at line 245 of file PlanVisAppletFsm.java.
Definition at line 1043 of file PlanVisAppletFsm.java.
int edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.getHistoryHover | ( | float | x, |
float | y | ||
) | [inline, private] |
Get index of history object under current mouse position. If mouse isn't on history, -1 will be returned.
x | mouse x position |
y | mouse y position |
Definition at line 955 of file PlanVisAppletFsm.java.
boolean edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.highlightAction | ( | Action | a, |
boolean | expand | ||
) | [inline] |
Highlight the action referenced by a
a | action to highlight |
expand | Expand all the parents of a so that a is visible |
Definition at line 979 of file PlanVisAppletFsm.java.
boolean edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.highlightAction | ( | String | identifier, |
boolean | expand | ||
) | [inline] |
Highlight the action referenced by identifier
identifier | action identified by identifier to highlight |
expand | Expand all the parents of identifier so that identifier is visible |
Definition at line 993 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.initControlP5 | ( | ) | [inline, private] |
Definition at line 465 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.keyPressed | ( | KeyEvent | e | ) | [inline] |
Definition at line 862 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.loadPrologPlan | ( | String | identifier | ) | [inline] |
Load a plan by starting with the given identifier and load all it's referenced actions recursively.
identifier | Something like 'http://www.roboearth.org/kb/serve_drink.owl#ServeADrink' |
Definition at line 185 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseClicked | ( | MouseEvent | e | ) | [inline] |
Definition at line 625 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseDragged | ( | MouseEvent | e | ) | [inline] |
Definition at line 544 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseEntered | ( | MouseEvent | e | ) | [inline] |
Definition at line 848 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseExited | ( | MouseEvent | e | ) | [inline] |
Definition at line 855 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseMoved | ( | MouseEvent | e | ) | [inline] |
Definition at line 511 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mousePressed | ( | MouseEvent | e | ) | [inline] |
Definition at line 575 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.mouseReleased | ( | MouseEvent | e | ) | [inline] |
Definition at line 611 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.setTask | ( | Action | action | ) | [inline] |
Sets the action which should be selected at the beginning. If none set, nothing will be drawn.
action | action to set as start action |
Definition at line 214 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.setup | ( | ) | [inline] |
Definition at line 131 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.syncWithProlog | ( | ) | [inline] |
Synchronize all changes that have been made with the underlying Prolog engine
Definition at line 941 of file PlanVisAppletFsm.java.
void edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.updateHistoryPosition | ( | ) | [inline, private] |
Update position for each ActionSelectHistoryInfo object in the clickHistory array. Needed for example if a new history object is added/deleted.
Definition at line 331 of file PlanVisAppletFsm.java.
Definition at line 115 of file PlanVisAppletFsm.java.
Textfield edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.base_iri = null [private] |
Definition at line 120 of file PlanVisAppletFsm.java.
ArrayList<ActionSelectHistoryInfo> edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.clickHistory = new ArrayList<ActionSelectHistoryInfo>() [private] |
history of selected actions. It's used like a breadcrumbs menu. If you select an action it will be added to this arrray. If you go back to a certain action in the history all remaining actions after the selected will be removed from history.
Definition at line 104 of file PlanVisAppletFsm.java.
Definition at line 118 of file PlanVisAppletFsm.java.
Action edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.currTask = null [private] |
Currently loaded task structure
Definition at line 60 of file PlanVisAppletFsm.java.
PFont edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.dejavuFont [private] |
Font for drawing text
Definition at line 50 of file PlanVisAppletFsm.java.
Currently dragged action
Definition at line 66 of file PlanVisAppletFsm.java.
Vector2f edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.draggingStart = new Vector2f(0,0) [private] |
Used in MouseDragging for calculating the dragging distance
Definition at line 113 of file PlanVisAppletFsm.java.
Textfield edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.end_action [private] |
Definition at line 124 of file PlanVisAppletFsm.java.
Vector2f edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.globalPosOffset = new Vector2f(0,0) [private] |
Draw offset. Used when image moved/dragged.
Definition at line 109 of file PlanVisAppletFsm.java.
final Cursor edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.handCursor = new Cursor(Cursor.HAND_CURSOR) [static, private] |
Hand cursor
Definition at line 86 of file PlanVisAppletFsm.java.
long edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.lastClickTime = 0 [private] |
mouseClicked has a bug so that for each click it is called two times. Prevent it by time measure
Definition at line 97 of file PlanVisAppletFsm.java.
final Cursor edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.moveCursor = new Cursor(Cursor.MOVE_CURSOR) [static, private] |
Move cursor
Definition at line 91 of file PlanVisAppletFsm.java.
Textfield edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.new_recipe_label = null [private] |
Definition at line 122 of file PlanVisAppletFsm.java.
Textfield edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.new_recipe_shortname = null [private] |
Definition at line 121 of file PlanVisAppletFsm.java.
Buffer storing the action from which a new transition is being created (user clicked on its outbound connector)
Definition at line 72 of file PlanVisAppletFsm.java.
Vector2f edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.newTransitionToLocation = new Vector2f() [private] |
Definition at line 74 of file PlanVisAppletFsm.java.
final Cursor edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.normalCursor = new Cursor(Cursor.DEFAULT_CURSOR) [static, private] |
Normal cursor (arrow)
Definition at line 81 of file PlanVisAppletFsm.java.
boolean edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.select_end = false [private] |
Definition at line 127 of file PlanVisAppletFsm.java.
boolean edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.select_start = false [private] |
Definition at line 126 of file PlanVisAppletFsm.java.
Currently selected action
Definition at line 55 of file PlanVisAppletFsm.java.
final long edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.serialVersionUID = 7695328948788620463L [static, private] |
Definition at line 45 of file PlanVisAppletFsm.java.
Textfield edu.tum.cs.ias.knowrob.vis.applets.PlanVisAppletFsm.start_action [private] |
Definition at line 123 of file PlanVisAppletFsm.java.