本文整理汇总了Java中y.view.EditMode类的典型用法代码示例。如果您正苦于以下问题:Java EditMode类的具体用法?Java EditMode怎么用?Java EditMode使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
EditMode类属于y.view包,在下文中一共展示了EditMode类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createEditMode
import y.view.EditMode; //导入依赖的package包/类
/**
* Overwritten to create an <code>EditMode</code> suitable for nested
* graphs.
*/
@Override
protected EditMode createEditMode() {
EditMode editMode = new HierarchyEditMode();
editMode.setCreateEdgeMode(new EditorCreateEdgeMode(this));
editMode.showNodeTips(true);
editMode.showEdgeTips(true);
return editMode;
}
示例2: registerViewModes
import y.view.EditMode; //导入依赖的package包/类
/**
* Adds the view modes to the view. This implementation adds a new EditMode
* created by {@link #createEditMode()} a new {@link AutoDragViewMode}.
*/
protected void registerViewModes() {
// edit mode will show tool tips over nodes
EditMode editMode = createEditMode();
if (editMode != null) {
view.addViewMode(editMode);
}
view.addViewMode(new AutoDragViewMode());
}
示例3: createEditMode
import y.view.EditMode; //导入依赖的package包/类
/**
* Callback used by {@link #registerViewModes()} to create the default
* EditMode
*
* @return an instance of {@link EditMode} with showNodeTips enabled
*/
protected EditMode createEditMode() {
EditMode editMode = new EditMode();
editMode.showNodeTips(true);
editMode.showEdgeTips(true);
return editMode;
}
示例4: actionPerformed
import y.view.EditMode; //导入依赖的package包/类
public void actionPerformed(ActionEvent e) {
Iterator viewModes = view.getViewModes();
while (viewModes.hasNext()) {
ViewMode viewMode = (ViewMode) viewModes.next();
if (viewMode instanceof EditMode) {
EditMode editMode = (EditMode) viewMode;
editMode.setChild(new AreaZoomMode(), null, null);
}
}
}
示例5: registerViewModes
import y.view.EditMode; //导入依赖的package包/类
private void registerViewModes() {
// edit mode will show tool tips over nodes
EditMode editMode = createEditMode();
if (editMode != null) {
viewer.addViewMode(editMode);
}
viewer.addViewMode(new AutoDragViewMode());
}
示例6: createEditMode
import y.view.EditMode; //导入依赖的package包/类
private EditMode createEditMode() {
EditMode editMode = new HierarchyEditMode();
editMode.showNodeTips(true);
return editMode;
}