diff options
author | jiteshjha | 2016-06-30 18:54:27 +0530 |
---|---|---|
committer | jiteshjha | 2016-06-30 18:54:27 +0530 |
commit | d4a60563097530c60a39ae0dd9bfc75826b255c5 (patch) | |
tree | a1d2b5c3c44f3979bfb0a122a83c09f253c750de /index.html | |
parent | 1643dcd2803d9f19d52af25ebb64fb68e6e5fac8 (diff) | |
download | xcos-on-web-d4a60563097530c60a39ae0dd9bfc75826b255c5.tar.gz xcos-on-web-d4a60563097530c60a39ae0dd9bfc75826b255c5.tar.bz2 xcos-on-web-d4a60563097530c60a39ae0dd9bfc75826b255c5.zip |
added display parameters
Diffstat (limited to 'index.html')
-rw-r--r-- | index.html | 15 |
1 files changed, 14 insertions, 1 deletions
@@ -414,9 +414,22 @@ // Uncomment this block to see XML tags work graph.convertValueToString = function(cell) { + if (mxUtils.isNode(cell.value)) { - return cell.getAttribute('label', ''); + var stylesheet = graph.getStylesheet(); + var style = stylesheet.styles[cell.style]; + var displayedLabel = style['displayedLabel']; + if(displayedLabel != null) { + var displayParameter = cell.blockInstance.instance.displayParameter; + for(i in displayParameter) { + displayedLabel = displayedLabel.replace("%s", displayParameter[i].toString()); + } + return displayedLabel; + } + else { + return cell.getAttribute('label', ''); + } } }; |