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


Java ApplicationWindow类代码示例

本文整理汇总了Java中org.eclipse.jface.window.ApplicationWindow的典型用法代码示例。如果您正苦于以下问题:Java ApplicationWindow类的具体用法?Java ApplicationWindow怎么用?Java ApplicationWindow使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(600, 600);
				
//				CollectionComboViewerWidget c = new CollectionComboViewerWidget(parent, 0, false, true, true);
				CollectionTableComboViewerWidget c = new CollectionTableComboViewerWidget(parent, 0, true, false, false);
				c.setAvailableCollections(createTestCollections());
				
//				InstallSpecificVersionDialog d = new InstallSpecificVersionDialog(getShell(), 0);
//				d.open();
				
				getShell().setSize(500, 200);

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:27,代码来源:CollectionTableComboViewerWidgetTest.java

示例2: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(600, 600);
				
//				CollectionComboViewerWidget c = new CollectionComboViewerWidget(parent, 0, false, true, true);
				CollectionSelectorWidget c = new CollectionSelectorWidget(parent, 0, false, null);
//				c.setAvailableCollections(createTestCollections());
				
//				InstallSpecificVersionDialog d = new InstallSpecificVersionDialog(getShell(), 0);
//				d.open();
				
				getShell().setSize(500, 200);

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:27,代码来源:CollectionSelectorWidgetTest.java

示例3: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(600, 600);
				
//				CollectionComboViewerWidget c = new CollectionComboViewerWidget(parent, 0, false, true, true);
				CollectionComboViewerWidget c = new CollectionComboViewerWidget(parent, 0, true, false, false);
				c.setAvailableCollections(createTestCollections());
				
//				InstallSpecificVersionDialog d = new InstallSpecificVersionDialog(getShell(), 0);
//				d.open();
				
				getShell().setSize(500, 200);

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:27,代码来源:CollectionComboViewerWidgetTest.java

示例4: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
	ApplicationWindow aw = new ApplicationWindow(null) {
		@Override
		protected Control createContents(Composite parent) {
			getShell().setSize(600, 600);
			SWTUtil.centerShell(getShell());
			
			List<TrpPage> pages = new ArrayList<>();
			pages.add(null);
			pages.add(null);
			pages.add(null);
			
			CommonExportDialog ced = new CommonExportDialog(getShell(), 0, null, "docName", pages);
			ced.open();

			return parent;
		}
	};
	aw.setBlockOnOpen(true);
	aw.open();

	Display.getCurrent().dispose();
	
	
}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:26,代码来源:CommonExportDialogTest.java

示例5: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(600, 600);
				
				InstallSpecificVersionDialog d = new InstallSpecificVersionDialog(getShell(), 0);
				d.open();

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:21,代码来源:InstallSpecificVersionDialogTest.java

示例6: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
	ApplicationWindow aw = new ApplicationWindow(null) {
		@Override
		protected Control createContents(Composite parent) {
			getShell().setSize(300, 200);
			SWTUtil.centerShell(getShell());
			
			LayoutAnalysisComposite.TEST = true;
			
			LayoutAnalysisDialog diag = new LayoutAnalysisDialog(getShell());
			diag.open();

			return parent;
		}
	};
	aw.setBlockOnOpen(true);
	aw.open();

	Display.getCurrent().dispose();
}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:21,代码来源:LayoutAnalysisDialogTest.java

示例7: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
//				parent.setLayout(new FillLayout());
				getShell().setSize(400, 600);
				
				DocMetadataEditor w = new DocMetadataEditor(parent, 0);
				
				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:20,代码来源:DocMetadataEditorTest.java

示例8: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
//				parent.setLayout(new FillLayout());
				getShell().setSize(400, 1000);
				
				DocInfoWidget w = new DocInfoWidget(parent, 0, null);
				
				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:20,代码来源:DocInfoWidgetTest.java

示例9: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
				getShell().setSize(400, 1000);
				
				ToolsWidget tw = new ToolsWidget(parent, 0);
				
//				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
		
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:21,代码来源:ToolsWidgetTest.java

示例10: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(600, 600);
				
				RecentDocsPreferences.init();
				
//				CollectionComboViewerWidget c = new CollectionComboViewerWidget(parent, 0, false, true, true);
				RecentDocsComboViewerWidget c = new RecentDocsComboViewerWidget(parent, 0);
//				c.set
				
				getShell().setSize(500, 200);

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:26,代码来源:RecentDocsComboViewerWidgetTest.java

示例11: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) {
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
				getShell().setSize(300, 200);
				
				PageLockTablePagination w = new PageLockTablePagination(getShell(), 0, 25);
				
				
//				Button btn = new Button(parent, SWT.PUSH);
//				btn.setText("Open upload dialog");
//				btn.addSelectionListener(new SelectionAdapter() {
//					@Override public void widgetSelected(SelectionEvent e) {
//						(new UploadDialogUltimate(getShell(), null)).open();
//					}
//				});

				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:29,代码来源:PageLockTablePagination.java

示例12: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				getShell().setSize(600, 600);
				
				Exception e = new Exception("asdadf asdfasdf asdfasdfa sdfasdfa sdfaksdjfkl ajskldfjklaj dklfjalksjdfkljas kljlaksjdflkjaskl jfklajskldfjkl ajakljsfdlkjaklsdjfkl ajsdkljf klajsdklfj kljasldkfjla jdklfjaklsdj kljasdklfj klasdjfklj aklsdjfkl ajsdklfj kladjsfklajdklfj aklsjdfkl ajklsdfjkl ajsdklfj klsfdaj", 
						new Exception("ddd", new Exception(new Exception(new Exception(new Exception(new Exception(new Exception(new Exception())))))))); 
				
				String msg = "I am Error! adfasdf asdfasdf asdfasd asdf asdfa sdfasdfasdf asdfasdfa asdf asdfa sfasdfa sfd sa fdd asdf asdfas dddd dd asdf asdf asdf asdf asfdasdf asdf asfd asd fasdfasdf as fd\n mutliple lines long!\nasdf\nasdfasdfasd\nasdfasdf";
				
//				TrpMessageDialog.showErrorDialog(getShell(), "Error in...", msg, null, null);
				TrpMessageDialog.showErrorDialog(getShell(), "Error in...", msg, "a detailed error message!", e);
				
//				TrpErrorDialog d = new TrpErrorDialog(getShell(), "Error in...", "I am Error!", "detailed error message!", new Exception("asdadf", new Exception("ddd", new Exception())));
//				TrpMessageDialog d = new TrpMessageDialog(getShell(), "Error in...", "I am Error!", null, new Exception("asdadf", new Exception("ddd", new Exception())));
//				d.setSwtIcon(SWT.ICON_INFORMATION);
//				TrpErrorDialog d = new TrpErrorDialog(getShell(), "Error in...", "I am Error!", "detailed error message!", null);
//				d.open();
				
//				s = new Status(IStatus.ERROR, "ID0", 0, "", null);
//				ExceptionDetailsErrorDialog.openError(getShell(), "asdf", "massage", new Status(IStatus.ERROR, "ID0", 0, "", null));

//				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:34,代码来源:TrpMessageDialogTest.java

示例13: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws LoginException {		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				TrpServerConn conn;
				try {
					conn = new TrpServerConn(ATrpServerConn.TEST_SERVER_URI, args[0], args[1]);
					List<TrpDocMetadata> docs = conn.getAllDocs(1);
					System.out.println("nr of docs = "+docs.size());

//					DocumentsSelector ds = new DocumentsSelector(parent, 0, false, true);
//					ds.setDataList(docs);
					
					getShell().setSize(500, 800);
					SWTUtil.centerShell(getShell());
					DocumentsSelectorDialog dsd = new DocumentsSelectorDialog(getShell(), "Select documents", docs);
					if (dsd.open() == IDialogConstants.OK_ID) {
						System.out.println("n selected documents: "+dsd.getCheckedDocs().size());
						System.out.println("selected documents: "+CoreUtils.toListString(dsd.getCheckedDocs()));
					}
				} catch (Exception e1) {
					e1.printStackTrace();
					System.exit(1);
				}
	
				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();
	
		Display.getCurrent().dispose();

	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:35,代码来源:DocumentsSelectorTest.java

示例14: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(final String[] args) {
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
//				getShell().setSize(100, 100);
				
				try {
					Storage s = Storage.getInstance();
					
					s.updateProxySettings();
					
					s.login(TrpServerConn.PROD_SERVER_URI, args[0], args[1]);
				
					JobsDialog d = new JobsDialog(getShell());
					d.open();
					
				
				} catch (Exception e) {
					e.printStackTrace();
				}
				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();

		
		
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:33,代码来源:JobsDialogTest.java

示例15: main

import org.eclipse.jface.window.ApplicationWindow; //导入依赖的package包/类
public static void main(String[] args) throws Exception {
//		Storage s = Storage.getInstance();
//		s.login(TrpServerConn.SERVER_URIS[0], args[0], args[1]);
		
		ApplicationWindow aw = new ApplicationWindow(null) {
			@Override
			protected Control createContents(Composite parent) {
				// getShell().setLayout(new FillLayout());
				getShell().setSize(600, 600);
				
//				PAGEXmlViewer v = new PAGEXmlViewer(getShell(), SWT.MODELESS);
				XmlViewer v = new XmlViewer(getShell(), SWT.MODELESS);
//				v.getReloadBtn().addSelectionListener(new SelectionListener() {
//					
//					@Override public void widgetSelected(SelectionEvent e) {
//						logger.info("reload btn pressed!");
//					}
//					
//					@Override public void widgetDefaultSelected(SelectionEvent e) {
//					}
//				});
				
				try {
					v.open(new URL("https://dbis-thure.uibk.ac.at/f/Get?id=XBJUPGOGPTKOLLGWSFJIALZN"));
				} catch (IOException e) {
					e.printStackTrace();
				}
				


//				SWTUtil.centerShell(getShell());

				return parent;
			}
		};
		aw.setBlockOnOpen(true);
		aw.open();

		Display.getCurrent().dispose();
	}
 
开发者ID:Transkribus,项目名称:TranskribusSwtGui,代码行数:41,代码来源:XmlViewerTest.java


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