当前位置: 首页>>代码示例>>Java>>正文


Java Connector.setBendpoints方法代码示例

本文整理汇总了Java中org.eclipse.gmf.runtime.notation.Connector.setBendpoints方法的典型用法代码示例。如果您正苦于以下问题:Java Connector.setBendpoints方法的具体用法?Java Connector.setBendpoints怎么用?Java Connector.setBendpoints使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.eclipse.gmf.runtime.notation.Connector的用法示例。


在下文中一共展示了Connector.setBendpoints方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createDependency_4002

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
* @generated
*/
public Edge createDependency_4002(
		EObject domainElement, View containerView, int index, boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(ClassDiagramVisualIDRegistry.getType(DependencyEditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter
		.getColor(prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(
		edge,
		NotationPackage.eINSTANCE.getLineStyle_LineColor(),
		FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore, IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
			.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB).intValue());
	}
	Routing routing = Routing.get(prefStore.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:adisandro,项目名称:MMINT,代码行数:43,代码来源:ClassDiagramViewProvider.java

示例2: createTransition_4001

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createTransition_4001(EObject domainElement,
		View containerView, int index, boolean persisted,
		PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(StatemachineVisualIDRegistry
			.getType(TransitionEditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:spoenemann,项目名称:xtext-gef,代码行数:53,代码来源:StatemachineViewProvider.java

示例3: createContractRoleAID_4001

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createContractRoleAID_4001(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry
			.getType(ContractRoleAIDEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:50,代码来源:SmcViewProvider.java

示例4: createContractRoleBID_4002

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createContractRoleBID_4002(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry
			.getType(ContractRoleBIDEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:50,代码来源:SmcViewProvider.java

示例5: createFactLink_4003

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createFactLink_4003(EObject domainElement, View containerView,
		int index, boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry.getType(FactLinkEditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:49,代码来源:SmcViewProvider.java

示例6: createFactLink_4006

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createFactLink_4006(EObject domainElement, View containerView,
		int index, boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry.getType(FactLink2EditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:49,代码来源:SmcViewProvider.java

示例7: createPlayerBinding_4004

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createPlayerBinding_4004(EObject domainElement,
		View containerView, int index, boolean persisted,
		PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry
			.getType(PlayerBindingEditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:51,代码来源:SmcViewProvider.java

示例8: createExternalFactLink_4005

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createExternalFactLink_4005(EObject domainElement,
		View containerView, int index, boolean persisted,
		PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList points = new ArrayList(2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(SmcVisualIDRegistry
			.getType(ExternalFactLinkEditPart.VISUAL_ID));
	edge.setElement(domainElement);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
			.getLineStyle_LineColor(), FigureUtilities
			.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
				.getRoutingStyle_Routing(), routing);
	}
	return edge;
}
 
开发者ID:road-framework,项目名称:ROADDesigner,代码行数:51,代码来源:SmcViewProvider.java

示例9: createGroupFirstTeam_4001

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createGroupFirstTeam_4001(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(GroupFirstTeamEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例10: createMatchHome_4002

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createMatchHome_4002(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(MatchHomeEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例11: createGroupSecondTeam_4003

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createGroupSecondTeam_4003(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(GroupSecondTeamEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例12: createMatchAway_4004

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createMatchAway_4004(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(MatchAwayEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例13: createTeamAtGroup_4005

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createTeamAtGroup_4005(View containerView, int index,
		boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(TeamAtGroupEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例14: createEliminationMatchWinner_4006

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createEliminationMatchWinner_4006(View containerView,
		int index, boolean persisted, PreferencesHint preferencesHint) {
	Connector edge = NotationFactory.eINSTANCE.createConnector();
	edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
	RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
			.createRelativeBendpoints();
	ArrayList<RelativeBendpoint> points = new ArrayList<RelativeBendpoint>(
			2);
	points.add(new RelativeBendpoint());
	points.add(new RelativeBendpoint());
	bendpoints.setPoints(points);
	edge.setBendpoints(bendpoints);
	ViewUtil.insertChildView(containerView, edge, index, persisted);
	edge.setType(Wc2014VisualIDRegistry
			.getType(EliminationMatchWinnerEditPart.VISUAL_ID));
	edge.setElement(null);
	// initializePreferences
	final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
			.getPreferenceStore();

	org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
			prefStore, IPreferenceConstants.PREF_LINE_COLOR);
	ViewUtil.setStructuralFeatureValue(edge,
			NotationPackage.eINSTANCE.getLineStyle_LineColor(),
			FigureUtilities.RGBToInteger(lineRGB));
	FontStyle edgeFontStyle = (FontStyle) edge
			.getStyle(NotationPackage.Literals.FONT_STYLE);
	if (edgeFontStyle != null) {
		FontData fontData = PreferenceConverter.getFontData(prefStore,
				IPreferenceConstants.PREF_DEFAULT_FONT);
		edgeFontStyle.setFontName(fontData.getName());
		edgeFontStyle.setFontHeight(fontData.getHeight());
		edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
		edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
		org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
				.getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
		edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
				.intValue());
	}
	Routing routing = Routing.get(prefStore
			.getInt(IPreferenceConstants.PREF_LINE_STYLE));
	if (routing != null) {
		ViewUtil.setStructuralFeatureValue(edge,
				NotationPackage.eINSTANCE.getRoutingStyle_Routing(),
				routing);
	}
	return edge;
}
 
开发者ID:ggxx,项目名称:HelloBrazil,代码行数:52,代码来源:Wc2014ViewProvider.java

示例15: createDcaseLink001_3001

import org.eclipse.gmf.runtime.notation.Connector; //导入方法依赖的package包/类
/**
 * @generated
 */
public Edge createDcaseLink001_3001(EObject domainElement,
        View containerView, int index, boolean persisted,
        PreferencesHint preferencesHint) {
    Connector edge = NotationFactory.eINSTANCE.createConnector();
    edge.getStyles().add(NotationFactory.eINSTANCE.createFontStyle());
    RelativeBendpoints bendpoints = NotationFactory.eINSTANCE
            .createRelativeBendpoints();
    ArrayList points = new ArrayList(2);
    points.add(new RelativeBendpoint());
    points.add(new RelativeBendpoint());
    bendpoints.setPoints(points);
    edge.setBendpoints(bendpoints);
    ViewUtil.insertChildView(containerView, edge, index, persisted);
    edge.setType(DcaseVisualIDRegistry
            .getType(DcaseLink001EditPart.VISUAL_ID));
    edge.setElement(domainElement);
    // initializePreferences
    final IPreferenceStore prefStore = (IPreferenceStore) preferencesHint
            .getPreferenceStore();

    org.eclipse.swt.graphics.RGB lineRGB = PreferenceConverter.getColor(
            prefStore, IPreferenceConstants.PREF_LINE_COLOR);
    ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
            .getLineStyle_LineColor(), FigureUtilities
            .RGBToInteger(lineRGB));
    FontStyle edgeFontStyle = (FontStyle) edge
            .getStyle(NotationPackage.Literals.FONT_STYLE);
    if (edgeFontStyle != null) {
        FontData fontData = PreferenceConverter.getFontData(prefStore,
                IPreferenceConstants.PREF_DEFAULT_FONT);
        edgeFontStyle.setFontName(fontData.getName());
        edgeFontStyle.setFontHeight(fontData.getHeight());
        edgeFontStyle.setBold((fontData.getStyle() & SWT.BOLD) != 0);
        edgeFontStyle.setItalic((fontData.getStyle() & SWT.ITALIC) != 0);
        org.eclipse.swt.graphics.RGB fontRGB = PreferenceConverter
                .getColor(prefStore, IPreferenceConstants.PREF_FONT_COLOR);
        edgeFontStyle.setFontColor(FigureUtilities.RGBToInteger(fontRGB)
                .intValue());
    }
    Routing routing = Routing.get(prefStore
            .getInt(IPreferenceConstants.PREF_LINE_STYLE));
    if (routing != null) {
        ViewUtil.setStructuralFeatureValue(edge, NotationPackage.eINSTANCE
                .getRoutingStyle_Routing(), routing);
    }
    Node label4061 = createLabel(edge, DcaseVisualIDRegistry
            .getType(DcaseLink001Userdef001DescUserdef00EditPart.VISUAL_ID));
    label4061.setLayoutConstraint(NotationFactory.eINSTANCE
            .createLocation());
    Location location4061 = (Location) label4061.getLayoutConstraint();
    location4061.setX(0);
    location4061.setY(40);
    return edge;
}
 
开发者ID:d-case,项目名称:d-case_editor,代码行数:58,代码来源:DcaseViewProvider.java


注:本文中的org.eclipse.gmf.runtime.notation.Connector.setBendpoints方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。