本文整理了Java中com.mxgraph.view.mxGraph.updateCellSize()
方法的一些代码示例,展示了mxGraph.updateCellSize()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。mxGraph.updateCellSize()
方法的具体详情如下:
包路径:com.mxgraph.view.mxGraph
类名称:mxGraph
方法名:updateCellSize
[英]Updates the size of the given cell in the model using getPreferredSizeForCell to get the new size. This function fires beforeUpdateSize and afterUpdateSize events.
[中]使用getPreferredSizeForCell更新模型中给定单元格的大小,以获得新大小。此函数激发beforeUpdateSize和afterUpdateSize事件。
代码示例来源:origin: com.github.vlsi.mxgraph/jgraphx
/**
* Updates the size of the given cell in the model using
* getPreferredSizeForCell to get the new size. This function
* fires beforeUpdateSize and afterUpdateSize events.
*
* @param cell <mxCell> for which the size should be changed.
*/
public Object updateCellSize(Object cell)
{
return updateCellSize(cell, false);
}
代码示例来源:origin: org.tinyjee.jgraphx/jgraphx
/**
* Updates the size of the given cell in the model using
* getPreferredSizeForCell to get the new size. This function
* fires beforeUpdateSize and afterUpdateSize events.
*
* @param cell <mxCell> for which the size should be changed.
*/
public Object updateCellSize(Object cell)
{
return updateCellSize(cell, false);
}
代码示例来源:origin: arquillian/arquillian-cube
private void updateGraph(mxGraph graph, Object parent, Map<String, Object> insertedVertex, String containerId, CubeContainer cubeContainer) {
if (insertedVertex.containsKey(containerId)) {
// container is already added, probably because a direct link from another container
// now we need to add direct links of this one that before were transitive
Object currentContainer = insertedVertex.get(containerId);
createDirectLinks(graph, parent, insertedVertex, cubeContainer, currentContainer);
} else {
// create new cube and possible direct link (not transitive ones)
Object currentContainer = graph.insertVertex(parent, null, containerId, 0, 0, 80, 30);
graph.updateCellSize(currentContainer);
insertedVertex.put(containerId, currentContainer);
createDirectLinks(graph, parent, insertedVertex, cubeContainer, currentContainer);
}
}
代码示例来源:origin: arquillian/arquillian-cube
private void createDirectLinks(mxGraph graph, Object parent, Map<String, Object> insertedVertex, CubeContainer cubeContainer, Object currentContainer) {
// create relation to all direct links
if (cubeContainer.getLinks() != null) {
for (Link link : cubeContainer.getLinks()) {
final String linkId = link.getName();
Object linkContainer = null;
if (insertedVertex.containsKey(linkId)) {
linkContainer = insertedVertex.get(linkId);
} else {
linkContainer = graph.insertVertex(parent, null, linkId, 0, 0, 80, 30);
}
graph.updateCellSize(currentContainer);
graph.insertEdge(parent, null, link.getAlias(), currentContainer, linkContainer);
insertedVertex.put(linkId, linkContainer);
}
}
}
代码示例来源:origin: arquillian/arquillian-cube
graph.setCellStyles(mxConstants.STYLE_FILLCOLOR, "#00FF00", new Object[]{nwName});
graph.updateCellSize(nwName);
graph.insertEdge(parent, null, nw, containerName, nwName);
insertedVertex.put(nw, nwName);
代码示例来源:origin: org.opensingular/server-commons
private static Object insertVertex(mxGraph graph, MTask<?> task) {
final Object v = graph.insertVertex(graph.getDefaultParent(), task.getAbbreviation(), formatarNome(task.getName()),
20, 20, 20, 20);
graph.updateCellSize(v);
if (task.isWait()) {
setStyle(v, "TIMER");
} else if (task.isEnd()) {
setStyle(v, "END");
} else if (task.isJava()) {
if (task.getName().startsWith("Notificar")) {
setStyle(v, "MESSAGE");
} else {
setStyle(v, "JAVA");
}
}
return v;
}
代码示例来源:origin: org.opensingular/singular-requirement-commons
private static Object insertVertex(mxGraph graph, STask<?> task) {
final Object v = graph.insertVertex(graph.getDefaultParent(), task.getAbbreviation(), formatName(task.getName()),
20, 20, 20, 20);
graph.updateCellSize(v);
if (task.isWait()) {
setStyle(v, "TIMER");
} else if (task.isEnd()) {
setStyle(v, "END");
} else if (task.isPeople()) {
setStyle(v, "HUMAN");
} else if (task.isJava()) {
if (task.getName().startsWith("Notificar")) {
setStyle(v, "MESSAGE");
} else {
setStyle(v, "JAVA");
}
}
return v;
}
代码示例来源:origin: org.opensingular/singular-server-commons
private static Object insertVertex(mxGraph graph, STask<?> task) {
final Object v = graph.insertVertex(graph.getDefaultParent(), task.getAbbreviation(), formatName(task.getName()),
20, 20, 20, 20);
graph.updateCellSize(v);
if (task.isWait()) {
setStyle(v, "TIMER");
} else if (task.isEnd()) {
setStyle(v, "END");
} else if (task.isPeople()) {
setStyle(v, "HUMAN");
} else if (task.isJava()) {
if (task.getName().startsWith("Notificar")) {
setStyle(v, "MESSAGE");
} else {
setStyle(v, "JAVA");
}
}
return v;
}
代码示例来源:origin: org.opensingular/singular-requirement-module
private static Object insertVertex(mxGraph graph, STask<?> task) {
final Object v = graph.insertVertex(graph.getDefaultParent(), task.getAbbreviation(), formatName(task.getName()),
20, 20, 20, 20);
graph.updateCellSize(v);
if (task.isWait()) {
setStyle(v, "TIMER");
} else if (task.isEnd()) {
setStyle(v, "END");
} else if (task.isPeople()) {
setStyle(v, "HUMAN");
} else if (task.isJava()) {
if (task.getName().startsWith("Notificar")) {
setStyle(v, "MESSAGE");
} else {
setStyle(v, "JAVA");
}
}
return v;
}
内容来源于网络,如有侵权,请联系作者删除!