Is it possible to change vertex style dynamically on some external event? I tried to do this using the following code:

function someExternalEventHandler(){
  var cell = graph.getSelectionCell();
  cell.style = 'MyNewVertexStyle';
}

asked 17 Apr '12, 11:16

Kravets%20Vladimir's gravatar image

Kravets Vladimir
35115
accept rate: 0%


Yes, use graph.getModel().setStyle(cell, 'NewStyle')

link

answered 17 Apr '12, 15:55

Gaudenz's gravatar image

Gaudenz
80.1k1310
accept rate: 39%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×228
×50
×39

Asked: 17 Apr '12, 11:16

Seen: 2,321 times

Last updated: 17 Apr '12, 15:55