Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "GEF/GEF4/MVC/Examples"

< GEF‎ | GEF4‎ | MVC
m (Logo Example (UI-integration))
m (Logo Example (Web-integration))
 
(10 intermediate revisions by the same user not shown)
Line 1: Line 1:
 +
__NOTOC__
 
== Logo Example (Standalone, Eclipse UI, Web) ==
 
== Logo Example (Standalone, Eclipse UI, Web) ==
  
Line 7: Line 8:
 
*'''bundle: org.eclipse.gef4.mvc.examples.logo'''
 
*'''bundle: org.eclipse.gef4.mvc.examples.logo'''
  
The standalone JavaFX application is only indirectly-bundled on our update-site and can better be checked out in source (<code>org.eclipse.gef4.mvc.examples.logo</code>) from our [http://git.eclipse.org/c/gef/org.eclipse.gef4.git/ GEF4 Git repository]. In order to have the example plug-in compile properly, all other required GEF4 bundles will either have to be installed (in a matching version) into your running eclipse platform, added to a target definition (the already provided in the active target platform (the provided target definitions may be augmented for this purpose), or checked out in source as well. You will also have to install e(fx)clipse in your running eclipse instance and target platform (see [[GEF/Contributor Guide | GEF Project Contributor Guide]] for details on how to obtain the sources and setup your workspace). Having prepared everything as outlined before, the standalone example might easily be started by launching <code>org.eclipse.gef4.mvc.examples.logo.MvcLogoExample</code> via the context menu ('Run As' -> 'Java Application').
+
The standalone JavaFX application is only indirectly-bundled on our update-site and can better be checked out in source (<code>org.eclipse.gef4.mvc.examples.logo</code>) from our [http://git.eclipse.org/c/gef/org.eclipse.gef4.git/ GEF4 Git repository]. In order to have the example plug-in compile properly, all other required GEF4 bundles will either have to be installed (in a matching version) into your running eclipse platform (if this is used as target), added to a target definition (the target definitions contained in <code>org.eclipse.gef4.target</code> may be augmented for this purpose), or checked out in source as well. You will also have to install e(fx)clipse in your running eclipse instance and target platform (see [[GEF/Contributor Guide | GEF Project Contributor Guide]] for details on how to obtain the sources and setup your workspace). Having prepared everything as outlined before, the standalone example might easily be started by launching <code>org.eclipse.gef4.mvc.examples.logo.MvcLogoExample</code> via the context menu ('Run As' -> 'Java Application').
  
 
[[Image:GEF4_MVC_FX_Example.png|383px]]
 
[[Image:GEF4_MVC_FX_Example.png|383px]]
Line 18: Line 19:
 
*'''bundle: org.eclipse.gef4.mvc.examples.logo.ui'''
 
*'''bundle: org.eclipse.gef4.mvc.examples.logo.ui'''
  
The Eclipse UI integration is realized by means of an Eclipse view (org.eclipse.gef4.mvc.examples.logo.ui), which integrates with the Eclipse Workbench operation history as well as the Eclipse UI properties view).
+
The Eclipse UI-integrated version of the [[#Logo Example (Standalone)|Logo Example]], which integrates with the Eclipse Workbench operation history as well as the Eclipse UI properties view, can simply be installed from our update-sites. It is accessible via the 'GEF4 MVC Logo Example' view, which can be opened via the ''Window -> Show View -> Other...'' menu, being located in the ''Other'' category.
 +
 
 +
<small>Note that, if you are running on Linux with GTK3, you have to force SWT to use the GTK2 API by setting the environment variable SWT_GTK3 to 0, because of a JavaFX/SWT integration bug ([https://bugs.eclipse.org/bugs/show_bug.cgi?id=469126 Bugzilla #469126]).</small>
  
 
[[Image:GEF4_MVC_FX_UI_Example.png|500px]]
 
[[Image:GEF4_MVC_FX_UI_Example.png|500px]]
 
The Eclipse UI-integrated version can simply be installed from our update-sites. It can then easily be accessed in your runtime eclipse application via the ''Window->Show View->Other...'' menu, where it is located in the ''Other'' category. Note that, if you are running on Linux with GTK3, you have to force SWT to use the GTK2 API by setting the environment variable SWT_GTK3 to 0, because of a JavaFX/SWT integration bug ([https://bugs.eclipse.org/bugs/show_bug.cgi?id=469126 Bugzilla #469126]).
 
  
 
=== Logo Example (Web-integration) ===
 
=== Logo Example (Web-integration) ===
Line 32: Line 33:
 
[[Image:GEF4_MVC_FX_Example_Web.png|500px]]
 
[[Image:GEF4_MVC_FX_Example_Web.png|500px]]
  
The web-integrated version of the standalone example is provided in a bundled form on hudson.eclipse.org and can be accessed at  [https://hudson.eclipse.org/hudson/job/gef4-master/lastSuccessfulBuild/artifact/org.eclipse.gef4.mvc.examples.logo.web-files/index.html  https://hudson.eclipse.org/hudson/job/gef4-master/lastSuccessfulBuild/artifact/org.eclipse.gef4.mvc.examples.logo.web-files/index.html]. You will need to have the Java plug-in installed into your browser, and you may have to adjust your Java plug-in security settings to allow java content for the respective url.
+
The web-integrated version of the standalone example is provided in a bundled form on hudson.eclipse.org and can be accessed at  [https://hudson.eclipse.org/gef/job/gef4-master/lastSuccessfulBuild/artifact/org.eclipse.gef4.mvc.examples.logo.web-files/index.html  https://hudson.eclipse.org/gef/job/gef4-master/lastSuccessfulBuild/artifact/org.eclipse.gef4.mvc.examples.logo.web-files/index.html]. You will need to have the Java plug-in installed into your browser (see [https://www.java.com/en/download/help/browser_activate_plugin.xml How can I run or activate Java in the browser?] for details) to properly run the example, and you will have to adjust your Java plug-in security settings to ''Enable Java content in the browser'' and use security level ''High'' instead of ''Very High'' (see [https://www.java.com/en/download/help/jcp_security.xml How do I control when an untrusted applet or application runs in my web browser?]).
 +
 
 +
'''Please note that running the web example from your local workspace will not be possible if you use a Java plug-in of Java 8 Update 20 and later versions. This is because the ''Medium'' security level that still allowed the execution of unsigned applications has been removed, and because the MVC Logo web example, if built locally (using Maven/Tycho), is unsigned (we use a special Maven profile that enables signing with the Eclipse Foundation certificate on hudson.eclipse.org only).'''
  
 
[[Category:GEF]]
 
[[Category:GEF]]

Latest revision as of 08:20, 18 July 2015

Logo Example (Standalone, Eclipse UI, Web)

The GEF4 MVC Logo example demonstrates the interplay of all MVC components (i.e. MVC, MVC.FX, MVC.UI, and MVC.FX.UI), and is also based on other GEF4 components. It comes in three variants: a standalone JavaFX application, a deployed Eclipse UI-integration, as well as a JNLP-based web integration.

Logo Example (Standalone)

  • bundle: org.eclipse.gef4.mvc.examples.logo

The standalone JavaFX application is only indirectly-bundled on our update-site and can better be checked out in source (org.eclipse.gef4.mvc.examples.logo) from our GEF4 Git repository. In order to have the example plug-in compile properly, all other required GEF4 bundles will either have to be installed (in a matching version) into your running eclipse platform (if this is used as target), added to a target definition (the target definitions contained in org.eclipse.gef4.target may be augmented for this purpose), or checked out in source as well. You will also have to install e(fx)clipse in your running eclipse instance and target platform (see GEF Project Contributor Guide for details on how to obtain the sources and setup your workspace). Having prepared everything as outlined before, the standalone example might easily be started by launching org.eclipse.gef4.mvc.examples.logo.MvcLogoExample via the context menu ('Run As' -> 'Java Application').

GEF4 MVC FX Example.png

Logo Example (UI-integration)

  • feature: org.eclipse.gef4.mvc.examples
  • bundle: org.eclipse.gef4.mvc.examples
  • bundle: org.eclipse.gef4.mvc.examples.logo
  • bundle: org.eclipse.gef4.mvc.examples.logo.ui

The Eclipse UI-integrated version of the Logo Example, which integrates with the Eclipse Workbench operation history as well as the Eclipse UI properties view, can simply be installed from our update-sites. It is accessible via the 'GEF4 MVC Logo Example' view, which can be opened via the Window -> Show View -> Other... menu, being located in the Other category.

Note that, if you are running on Linux with GTK3, you have to force SWT to use the GTK2 API by setting the environment variable SWT_GTK3 to 0, because of a JavaFX/SWT integration bug (Bugzilla #469126).

GEF4 MVC FX UI Example.png

Logo Example (Web-integration)

  • bundle: org.eclipse.gef4.mvc.examples.logo.web

The web-integrated version of the standalone application is realized via Java WebStart.

GEF4 MVC FX Example Web.png

The web-integrated version of the standalone example is provided in a bundled form on hudson.eclipse.org and can be accessed at https://hudson.eclipse.org/gef/job/gef4-master/lastSuccessfulBuild/artifact/org.eclipse.gef4.mvc.examples.logo.web-files/index.html. You will need to have the Java plug-in installed into your browser (see How can I run or activate Java in the browser? for details) to properly run the example, and you will have to adjust your Java plug-in security settings to Enable Java content in the browser and use security level High instead of Very High (see How do I control when an untrusted applet or application runs in my web browser?).

Please note that running the web example from your local workspace will not be possible if you use a Java plug-in of Java 8 Update 20 and later versions. This is because the Medium security level that still allowed the execution of unsigned applications has been removed, and because the MVC Logo web example, if built locally (using Maven/Tycho), is unsigned (we use a special Maven profile that enables signing with the Eclipse Foundation certificate on hudson.eclipse.org only).

Back to the top