if (this.div != null && this.div.style.background != 'transparent')
{
container.style.cursor = 'default';
this.div.style.background = 'transparent';
this.div.style.borderStyle = 'dashed';
mxUtils.setOpacity(this.div, 100);
}
}
}
// Workaround for no resize event of container parent in
// Firefox, canvas needs update of limited drawing area
else
{
wnd.addListener(mxEvent.RESIZE_END, function(evt)
{
graph.sizeDidChange();
});
}
// Gets the default parent for inserting new cells. This
// is normally the first child of the root (ie. layer 0).
var parent = graph.getDefaultParent();
// Adds cells to the model in a single step
graph.getModel().beginUpdate();
try
{
var v1 = graph.insertVertex(parent, null, 'Hello,', 20, 20, 80, 30);
var v2 = graph.insertVertex(parent, null, 'World!', 200, 150, 80, 30);
var e1 = graph.insertEdge(parent, null, '', v1, v2);
}
finally
{
// Updates the display
graph.getModel().endUpdate();
}
wnd.setMaximizable(true);
wnd.setResizable(true);
wnd.setVisible(true);
var lorem = 'Lorem ipsum dolor sit amet, consectetur adipisici elit, sed eiusmod tempor incidunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquid ex ea commodi consequat. Quis aute iure reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint obcaecat cupiditat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. ';
var content = document.createElement('div');
mxUtils.write(content, lorem + lorem + lorem);
wnd = new mxWindow('Scrollable, resizable, auto height', content, 300, 50, 200, null, true, true);