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


Java TabFolder.setBounds方法代码示例

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


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

示例1: createContents

import org.eclipse.swt.widgets.TabFolder; //导入方法依赖的package包/类
/**
	 * Create contents of the application window.
	 * 
	 * @param parent
	 */
	@Override
	protected Control createContents(Composite parent)
	{
		/********************************************************************************
		 * Menu Bar
		 ********************************************************************************/
		// Menu menuBar = new Menu(parent.getShell(),SWT.BAR);
		// MenuItem menuItemRun = new MenuItem(menuBar,SWT.CASCADE);
		// menuItemRun.setText("&Run");
		// Menu menuRun = new Menu(menuItemRun);
		// menuItemRun.setMenu(menuRun);
		// parent.getShell().setMenuBar(menuBar);

		Composite containerMIPA = new Composite(parent, SWT.NONE);

		TabFolder tabFolderMIPA = new TabFolder(containerMIPA, SWT.BORDER);
		tabFolderMIPA.setBounds(0, 0, 943, 599);

//		TabItem tabItemPredicate = new TabItem(tabFolderMIPA, SWT.NONE);
//		tabItemPredicate
//				.setToolTipText("In this tab folder, the predicate is given in the form of xml file as well as the view of abstract syntax tree.");
//		tabItemPredicate.setText("Predicate");
//
//		SashForm sashPredicate = new SashForm(tabFolderMIPA, SWT.NONE);
//		sashPredicate
//				.setToolTipText("Drag to change the sizes of the two sides of the window.");
//		tabItemPredicate.setControl(sashPredicate);
//		
//		styledTextPredicate = new StyledText(sashPredicate, SWT.BORDER);
//		styledTextPredicate.setToolTipText("Predicate are shown here.");
//
//		Group grpPredicateTree = new Group(sashPredicate, SWT.NONE);
//		grpPredicateTree.setToolTipText("Tree view of predicate");
//		grpPredicateTree.setText("Predicate Tree View");
//
//		TreeViewer predicateTreeViewer = new TreeViewer(grpPredicateTree,
//				SWT.BORDER);
//		Tree treePredicate = predicateTreeViewer.getTree();
//		treePredicate.setBounds(10, 28, 444, 527);
//		sashPredicate.setWeights(new int[] { 1, 1 });
//		predicateTreeViewer
//				.setContentProvider(new PredicateTreeContentProvider());
//		predicateTreeViewer.setLabelProvider(new PredicateTreeLabelProvider());

		PredicateTabUI.getInstance(tabFolderMIPA);
		
/*		TabItem tabItemLattice = new TabItem(tabFolderMIPA, SWT.NONE);
		tabItemLattice.setToolTipText("representation of lattice");
		tabItemLattice.setText("Lattice");

		SashForm sashLattice = new SashForm(tabFolderMIPA, SWT.NONE);
		tabItemLattice.setControl(sashLattice);

		StyledText styledTextLattice = new StyledText(sashLattice, SWT.BORDER
				| SWT.READ_ONLY);
		styledTextLattice.setText("Information for lattice are given here \n.");
		styledTextLattice.setToolTipText("Information for lattice.");

		Group grpLatticeTree = new Group(sashLattice, SWT.NONE);
		grpLatticeTree.setToolTipText("tree view of lattice");
		grpLatticeTree.setText("Lattice Tree View");
		
		latticeTreeViewer = new TreeViewer(grpLatticeTree, SWT.BORDER);
		Tree latticeTree = latticeTreeViewer.getTree();
		latticeTree.setBounds(10, 29, 444, 526);
		latticeTreeViewer.setLabelProvider(new LatticeTreeLabelProvider());
		latticeTreeViewer.setContentProvider(new LatticeTreeContentProvider());
		sashLattice.setWeights(new int[] { 1, 1 });*/
		
		LatticeTabUI.getInstance(tabFolderMIPA);

		return containerMIPA;
	}
 
开发者ID:alg-nju,项目名称:mipa,代码行数:79,代码来源:MIPAAppllicationWindow.java


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