Skip to content

Commit

Permalink
Mark initial state
Browse files Browse the repository at this point in the history
  • Loading branch information
tilk committed Apr 30, 2021
1 parent d06a6ac commit 79a1993
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/cells/fsm.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ export const FSM = Box.define('FSM', {
const node = new joint.shapes.standard.Circle({stateNo: n, id: 'state' + n, isInit: n == init_state});
node.attr('label/text', String(n));
node.resize(100,50);
if (n == init_state)
node.attr('body/strokeWidth', 3)
if (n == current_state)
node.attr('body/class', 'current_state');
node.addTo(this.fsmgraph);
Expand Down

0 comments on commit 79a1993

Please # to comment.