SlideShare a Scribd company logo
1 of 23
Download to read offline
Share and Enjoy!
Alexander Nyßen
itemis AG
4
It‘s Bi!hday Time!
[initial contribution of Draw2d/GEF (MVC) by IBM in 2002]
[Zest joined 2007]
GEF 3.x / Zest 1.x
• Mature project with quite long history
• Base technology with lot's of users (direct & indirect
through GMF/Graphiti)
• Stable API, no breaking API changes since 2004 (GEF 3.0)
• Ready for CBI (migration to Git, Maven/Tycho completed)
• But API is organically evolved and there are ~400
bugzillas, out of which several require to break it
SomeTopics for a Renewal
• Re-thinking current componentization
• Support for the E4 application model
• Support for rotation and other transformations
• Support for curved connections
• Support for other rendering platforms than SWT
• Multi-touch gestures support
• Revision of the command framework
• Revision of connection handling (clipping container)
• Various renamings and restructurings on the detail level...
Zest 2 (since 2010)
• A provisional Zest 2 component was initiated in 2010, to
develop the next generation Zest API.
• Development takes place in parallel to maintenance
of Zest 1.x in its own Git repository.
• API is regarded to be provisional up to the final
graduation.
• Results are not provided as part of GEF 3.x / Zest 1.x but
published via Eclipse Marketplace.
GEF4 (since 2011)
• GEF4 was initiated - in analogy to Zest 2 - to develop the next
generation Draw2d and GEF (MVC) API.
• Development is to take place in parallel to maintenance of
Draw2d / GEF (MVC) 3.x in its own repository.
• Results are not provided as part of GEF 3.x / Zest 1.x but on own
update-sites.
• Initial plans (prior to 3.8):
• Create new double-precision Geometry API before 3.8.
• Start to migrate the Draw2d and GEF (MVC) code base
afterwards.
GEF4 + Zest 2 = GEF4
Modified plan (prior to Juno):
Unification of both approaches after Juno!
GEF4 - A Unified Approach
• A unified approach with a shared code base and a
common namespace (org.eclipse.gef4) for all plug-ins.
• Advantages:
• Clear distinction between GEF proper as the
production component and GEF4 as the provisional one
• Chance to not only refactor GEF components but the
componentization itself, which is only "historically"
justified.
GEF4 - Status Quo
• GEF4 Geometry component was initiated in 2011, work
has been finalized with the Juno release:
• Functionally complete (at least for now)
• 344 JUnit tests, ~77% instruction coverage
• GEF4 Graphics component was initiated directly after Juno
and is currently under work
• Initial infrastructure and simple example created
GEF4 Geometry
• No distinction in low and high precision, but just a single double-
precision API (with built-in imprecision for comparisons).
• Different geometric abstractions for different purposes:
• Euclidean (Vector, Straight,Angle)
• Projective (Vector3D, Straight3D)
• Planar (Point, Dimension, Line, QuadraticCurve, CubicCurve,
BezierCurve, Polyline, PolyBezier, Ellipse, Rectangle, Pie,Arc, Polygon,
CurvedPolygon, RoundedRectangle, Ring, Region, Path)
• Conversions to/from AWT and SWT (and between them)
GEF4 Planar Geometry - Features
• Support for "non-standard" geometries:
• Arbitrary Bezier curves, curved polygons
• Approximation via BezierCurves & Interpolation via PolyBeziers
• Characteristics-related core abstractions (IGeometry,
ICurve, IShape, IMultiShape)
• Construction-related base-classes (AbstractRectangleBased-
Geometry,AbstractPointListBasedGeometry,...)
• Direct support for affine transformations (ITranslatable,
IScalable, IRotatable)
• No direct SWT dependencies (SWT-related conversions
bundled in optional plug-in)
GEF4 Planar Geometry - Overview
GEF4 Planar Geometry - Abstractions
GEF4 Planar Geometry - Base Classes
GEF4 Geometry - Examples
GEF4 Geometry - Sample Code
// Bezier approximation of curves
BezierCurve[] fromCurve = curve.toBezier();
BezierCurve[] fromShape = shape.getOutline().toBezier();
ICurve[] fromPolyShape = polyShape.getOutlineSegments();
List<BezierCurve> beziers = new ArrayList<BezierCurve>();
for (ICurve c : fromPolyShape)
beziers.addAll(Arrays.asList(c.toBezier()));
// PolyBezier interpolation
PolyBezier interpolation = PolyBezier.interpolateCubic(p0, p1, p2, p3, ...);
// support for affine transformations
Polygon rhomb = new Rectangle(10, 10, 10, 10).getRotatedCCW(Angle.fromDeg(45));
PolyBezier slanted = new Ellipse(100, 100, 100, 50).getRotatedCCW(Angle.fromDeg(30));
Ring rotatedClippingArea = region.getRotatedCCW(Angle.fromDeg(300));
GEF4 Graphics - Features
• Support for rendering (planar) geometries, images,
and text on an underlying Canvas/Graphics
• Key abstractions (Font, Image, Color) and transparent
support for multiple widget toolkits (AWT, SWT)*
• Grouping of visual properties according to their
respective usage context (BlitProperties, DrawProperties,..)
• Full push/pop/restore of graphics state
• Extensible image processing support (Pixel-Filter,
Channel-Filter, Convolution-Filter)
*) JavaFX already prototyped byTom Schindl
GEF4 Graphics - Overview
GEF4 Graphics - Examples
GEF4 Graphics - Sample Code
final Ellipse ellipse = new Ellipse(50, 50, 350, 200);
final Rectangle rectangle = new Rectangle(100, 160, 125, 220);
final Polygon triangle = new Polygon(260, 170, 190, 300, 330, 300);
 
g.drawProperties().setLineWidth(4).setAntialiasing(true);
g.fillProperties().setAntialiasing(true);
 
g.pushState(); // saves the current set of properties on the stack
 
g.fillProperties().setColor(new Color(255, 0, 0));
g.drawProperties().setDashArray(25, 10).setColor(new Color(128, 0, 0));
 
g.fill(ellipse);
g.draw(ellipse.getOutline());
 
g.restoreState(); // restores the previously saved properties
 
g.fillProperties().setColor(new Color(0, 0, 255));
g.drawProperties().setLineJoin(LineJoin.ROUND)".setLineCap(LineCap.ROUND);
 
g.fill(rectangle);
g.draw(rectangle.getOutline());
 
g.popState(); // removes the previously saved properties from the stack
" " " // and enables the prior set of properties
 
g.fillProperties().setColor(new Color(0, 255, 0));
g.drawProperties().setColor(new Color(0, 128, 0)).setLineJoin(LineJoin.MITER);
 
g.fill(triangle);
g.draw(triangle.getOutline());
GEF4 - Outlook
• Planned on the short term (Kepler):
• Creation of GEF4 Canvas component (FigureCanvas/
Figures)
• Migration of Zest2 into GEF4 repository and update
site (including adoption of namespace)
• Planned on the mid/long-term :
• Adoption of migrated Zest components to new
GEF4 Geometry, Graphics, Canvas components
• Migration of remaining Draw2d/GEF (MVC) code
base, including re-modularization and adoption
And on the very short term...
• ... we are currently implementing Image#toString()...
ThankYou! Questions?

More Related Content

Viewers also liked

Quality management process model
Quality management process modelQuality management process model
Quality management process model
selinasimpson2701
 
Luxoft Horizon - Brochure
Luxoft Horizon - BrochureLuxoft Horizon - Brochure
Luxoft Horizon - Brochure
Marcin Jasinski
 
Quality management strategy template
Quality management strategy templateQuality management strategy template
Quality management strategy template
selinasimpson2701
 
10 things resilient people have in common
10 things resilient people have in common10 things resilient people have in common
10 things resilient people have in common
Diana Strinati Baur
 
The Rise of Games
The Rise of GamesThe Rise of Games
The Rise of Games
lbarakat
 
Water and Waste Water Treatment - EN - 140716 - webreduced
Water and Waste Water Treatment - EN - 140716 - webreducedWater and Waste Water Treatment - EN - 140716 - webreduced
Water and Waste Water Treatment - EN - 140716 - webreduced
Renan Norbiate de Melo
 
Ugalketa Funtzinoa Aitor
Ugalketa Funtzinoa AitorUgalketa Funtzinoa Aitor
Ugalketa Funtzinoa Aitor
AitorSanchez
 

Viewers also liked (19)

Quality management process model
Quality management process modelQuality management process model
Quality management process model
 
Luxoft Horizon - Brochure
Luxoft Horizon - BrochureLuxoft Horizon - Brochure
Luxoft Horizon - Brochure
 
Quality management strategy template
Quality management strategy templateQuality management strategy template
Quality management strategy template
 
September 2013
September 2013September 2013
September 2013
 
10 things resilient people have in common
10 things resilient people have in common10 things resilient people have in common
10 things resilient people have in common
 
The Rise of Games
The Rise of GamesThe Rise of Games
The Rise of Games
 
Issue 27
Issue 27Issue 27
Issue 27
 
Statinizzati.ppt
Statinizzati.pptStatinizzati.ppt
Statinizzati.ppt
 
Metro Bilbao
Metro Bilbao Metro Bilbao
Metro Bilbao
 
Sähköiset järjestelmät tiedonkeruussa - mitä ja keitä varten? Ari Kontiainen,...
Sähköiset järjestelmät tiedonkeruussa - mitä ja keitä varten? Ari Kontiainen,...Sähköiset järjestelmät tiedonkeruussa - mitä ja keitä varten? Ari Kontiainen,...
Sähköiset järjestelmät tiedonkeruussa - mitä ja keitä varten? Ari Kontiainen,...
 
Biologiset torjuntavalmisteet ja kasvunparanteet luomusipulin ja -perunan tuo...
Biologiset torjuntavalmisteet ja kasvunparanteet luomusipulin ja -perunan tuo...Biologiset torjuntavalmisteet ja kasvunparanteet luomusipulin ja -perunan tuo...
Biologiset torjuntavalmisteet ja kasvunparanteet luomusipulin ja -perunan tuo...
 
Ravinteiden kierrätyksen kärkihankkeen vuosi 2016 kuvina
Ravinteiden kierrätyksen kärkihankkeen vuosi 2016 kuvinaRavinteiden kierrätyksen kärkihankkeen vuosi 2016 kuvina
Ravinteiden kierrätyksen kärkihankkeen vuosi 2016 kuvina
 
Taina Aaltonen - Afrikkalaisen sikaruton torjunta politiikkanäkökulmasta
Taina Aaltonen - Afrikkalaisen sikaruton torjunta politiikkanäkökulmastaTaina Aaltonen - Afrikkalaisen sikaruton torjunta politiikkanäkökulmasta
Taina Aaltonen - Afrikkalaisen sikaruton torjunta politiikkanäkökulmasta
 
Tank Mixing Systems - EN - webreduced
Tank Mixing Systems - EN - webreducedTank Mixing Systems - EN - webreduced
Tank Mixing Systems - EN - webreduced
 
Water and Waste Water Treatment - EN - 140716 - webreduced
Water and Waste Water Treatment - EN - 140716 - webreducedWater and Waste Water Treatment - EN - 140716 - webreduced
Water and Waste Water Treatment - EN - 140716 - webreduced
 
January2015Scoop
January2015ScoopJanuary2015Scoop
January2015Scoop
 
Jari Siivari Suokas-työpaja 19-1-2017
Jari Siivari Suokas-työpaja 19-1-2017Jari Siivari Suokas-työpaja 19-1-2017
Jari Siivari Suokas-työpaja 19-1-2017
 
Ugalketa Funtzinoa Aitor
Ugalketa Funtzinoa AitorUgalketa Funtzinoa Aitor
Ugalketa Funtzinoa Aitor
 
Нормативные документы по пожарной безопасности
Нормативные документы по пожарной безопасностиНормативные документы по пожарной безопасности
Нормативные документы по пожарной безопасности
 

Similar to GEF4 - Share and Enjoy!

SharePoint Framework, Angular and Azure Functions
SharePoint Framework, Angular and Azure FunctionsSharePoint Framework, Angular and Azure Functions
SharePoint Framework, Angular and Azure Functions
Sébastien Levert
 
漫游iOS开发指南
漫游iOS开发指南漫游iOS开发指南
漫游iOS开发指南
jeff kit
 

Similar to GEF4 - Share and Enjoy! (20)

The Next Generation Eclipse Graphical Editing Framework
The Next Generation Eclipse Graphical Editing FrameworkThe Next Generation Eclipse Graphical Editing Framework
The Next Generation Eclipse Graphical Editing Framework
 
GEF 5.0.0 - From a User's Perspective
GEF 5.0.0 - From a User's PerspectiveGEF 5.0.0 - From a User's Perspective
GEF 5.0.0 - From a User's Perspective
 
Introduction to Griffon
Introduction to GriffonIntroduction to Griffon
Introduction to Griffon
 
dojox.gfx : the foundation for your crossbrowser advanced visualization.
dojox.gfx : the foundation for your crossbrowser advanced visualization.dojox.gfx : the foundation for your crossbrowser advanced visualization.
dojox.gfx : the foundation for your crossbrowser advanced visualization.
 
Introducing E-Cell 3.2
Introducing E-Cell 3.2Introducing E-Cell 3.2
Introducing E-Cell 3.2
 
ClickHouse new features and development roadmap, by Aleksei Milovidov
ClickHouse new features and development roadmap, by Aleksei MilovidovClickHouse new features and development roadmap, by Aleksei Milovidov
ClickHouse new features and development roadmap, by Aleksei Milovidov
 
OpenGLES Android Graphics
OpenGLES Android GraphicsOpenGLES Android Graphics
OpenGLES Android Graphics
 
State of GeoServer 2015
State of GeoServer 2015State of GeoServer 2015
State of GeoServer 2015
 
State of GeoServer 2.10
State of GeoServer 2.10State of GeoServer 2.10
State of GeoServer 2.10
 
Griffon Presentation
Griffon PresentationGriffon Presentation
Griffon Presentation
 
Gephi Toolkit Tutorial
Gephi Toolkit TutorialGephi Toolkit Tutorial
Gephi Toolkit Tutorial
 
GL Shading Language Document by OpenGL.pdf
GL Shading Language Document by OpenGL.pdfGL Shading Language Document by OpenGL.pdf
GL Shading Language Document by OpenGL.pdf
 
SharePoint Framework, Angular and Azure Functions
SharePoint Framework, Angular and Azure FunctionsSharePoint Framework, Angular and Azure Functions
SharePoint Framework, Angular and Azure Functions
 
Porting legacy apps to Griffon
Porting legacy apps to GriffonPorting legacy apps to Griffon
Porting legacy apps to Griffon
 
Road to sbt 1.0: Paved with server (2015 Amsterdam)
Road to sbt 1.0: Paved with server (2015 Amsterdam)Road to sbt 1.0: Paved with server (2015 Amsterdam)
Road to sbt 1.0: Paved with server (2015 Amsterdam)
 
Exploring Clojurescript
Exploring ClojurescriptExploring Clojurescript
Exploring Clojurescript
 
Jenkins Pipelines
Jenkins PipelinesJenkins Pipelines
Jenkins Pipelines
 
漫游iOS开发指南
漫游iOS开发指南漫游iOS开发指南
漫游iOS开发指南
 
lectureAll-OpenGL-complete-Guide-Tutorial.pdf
lectureAll-OpenGL-complete-Guide-Tutorial.pdflectureAll-OpenGL-complete-Guide-Tutorial.pdf
lectureAll-OpenGL-complete-Guide-Tutorial.pdf
 
Introduction of openGL
Introduction  of openGLIntroduction  of openGL
Introduction of openGL
 

Recently uploaded

AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
VictorSzoltysek
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
VishalKumarJha10
 

Recently uploaded (20)

AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICECHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
CHEAP Call Girls in Pushp Vihar (-DELHI )🔝 9953056974🔝(=)/CALL GIRLS SERVICE
 
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
W01_panagenda_Navigating-the-Future-with-The-Hitchhikers-Guide-to-Notes-and-D...
 
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdfAzure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
Azure_Native_Qumulo_High_Performance_Compute_Benchmarks.pdf
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
How To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.jsHow To Use Server-Side Rendering with Nuxt.js
How To Use Server-Side Rendering with Nuxt.js
 
AI & Machine Learning Presentation Template
AI & Machine Learning Presentation TemplateAI & Machine Learning Presentation Template
AI & Machine Learning Presentation Template
 
Software Quality Assurance Interview Questions
Software Quality Assurance Interview QuestionsSoftware Quality Assurance Interview Questions
Software Quality Assurance Interview Questions
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
Tech Tuesday-Harness the Power of Effective Resource Planning with OnePlan’s ...
 
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected WorkerHow To Troubleshoot Collaboration Apps for the Modern Connected Worker
How To Troubleshoot Collaboration Apps for the Modern Connected Worker
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS LiveVip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
Vip Call Girls Noida ➡️ Delhi ➡️ 9999965857 No Advance 24HRS Live
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students8257 interfacing 2 in microprocessor for btech students
8257 interfacing 2 in microprocessor for btech students
 
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
call girls in Vaishali (Ghaziabad) 🔝 >༒8448380779 🔝 genuine Escort Service 🔝✔️✔️
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
The Real-World Challenges of Medical Device Cybersecurity- Mitigating Vulnera...
 

GEF4 - Share and Enjoy!

  • 1. Share and Enjoy! Alexander Nyßen itemis AG 4
  • 2. It‘s Bi!hday Time! [initial contribution of Draw2d/GEF (MVC) by IBM in 2002] [Zest joined 2007]
  • 3. GEF 3.x / Zest 1.x • Mature project with quite long history • Base technology with lot's of users (direct & indirect through GMF/Graphiti) • Stable API, no breaking API changes since 2004 (GEF 3.0) • Ready for CBI (migration to Git, Maven/Tycho completed) • But API is organically evolved and there are ~400 bugzillas, out of which several require to break it
  • 4. SomeTopics for a Renewal • Re-thinking current componentization • Support for the E4 application model • Support for rotation and other transformations • Support for curved connections • Support for other rendering platforms than SWT • Multi-touch gestures support • Revision of the command framework • Revision of connection handling (clipping container) • Various renamings and restructurings on the detail level...
  • 5. Zest 2 (since 2010) • A provisional Zest 2 component was initiated in 2010, to develop the next generation Zest API. • Development takes place in parallel to maintenance of Zest 1.x in its own Git repository. • API is regarded to be provisional up to the final graduation. • Results are not provided as part of GEF 3.x / Zest 1.x but published via Eclipse Marketplace.
  • 6. GEF4 (since 2011) • GEF4 was initiated - in analogy to Zest 2 - to develop the next generation Draw2d and GEF (MVC) API. • Development is to take place in parallel to maintenance of Draw2d / GEF (MVC) 3.x in its own repository. • Results are not provided as part of GEF 3.x / Zest 1.x but on own update-sites. • Initial plans (prior to 3.8): • Create new double-precision Geometry API before 3.8. • Start to migrate the Draw2d and GEF (MVC) code base afterwards.
  • 7. GEF4 + Zest 2 = GEF4 Modified plan (prior to Juno): Unification of both approaches after Juno!
  • 8. GEF4 - A Unified Approach • A unified approach with a shared code base and a common namespace (org.eclipse.gef4) for all plug-ins. • Advantages: • Clear distinction between GEF proper as the production component and GEF4 as the provisional one • Chance to not only refactor GEF components but the componentization itself, which is only "historically" justified.
  • 9. GEF4 - Status Quo • GEF4 Geometry component was initiated in 2011, work has been finalized with the Juno release: • Functionally complete (at least for now) • 344 JUnit tests, ~77% instruction coverage • GEF4 Graphics component was initiated directly after Juno and is currently under work • Initial infrastructure and simple example created
  • 10. GEF4 Geometry • No distinction in low and high precision, but just a single double- precision API (with built-in imprecision for comparisons). • Different geometric abstractions for different purposes: • Euclidean (Vector, Straight,Angle) • Projective (Vector3D, Straight3D) • Planar (Point, Dimension, Line, QuadraticCurve, CubicCurve, BezierCurve, Polyline, PolyBezier, Ellipse, Rectangle, Pie,Arc, Polygon, CurvedPolygon, RoundedRectangle, Ring, Region, Path) • Conversions to/from AWT and SWT (and between them)
  • 11. GEF4 Planar Geometry - Features • Support for "non-standard" geometries: • Arbitrary Bezier curves, curved polygons • Approximation via BezierCurves & Interpolation via PolyBeziers • Characteristics-related core abstractions (IGeometry, ICurve, IShape, IMultiShape) • Construction-related base-classes (AbstractRectangleBased- Geometry,AbstractPointListBasedGeometry,...) • Direct support for affine transformations (ITranslatable, IScalable, IRotatable) • No direct SWT dependencies (SWT-related conversions bundled in optional plug-in)
  • 12. GEF4 Planar Geometry - Overview
  • 13. GEF4 Planar Geometry - Abstractions
  • 14. GEF4 Planar Geometry - Base Classes
  • 15. GEF4 Geometry - Examples
  • 16. GEF4 Geometry - Sample Code // Bezier approximation of curves BezierCurve[] fromCurve = curve.toBezier(); BezierCurve[] fromShape = shape.getOutline().toBezier(); ICurve[] fromPolyShape = polyShape.getOutlineSegments(); List<BezierCurve> beziers = new ArrayList<BezierCurve>(); for (ICurve c : fromPolyShape) beziers.addAll(Arrays.asList(c.toBezier())); // PolyBezier interpolation PolyBezier interpolation = PolyBezier.interpolateCubic(p0, p1, p2, p3, ...); // support for affine transformations Polygon rhomb = new Rectangle(10, 10, 10, 10).getRotatedCCW(Angle.fromDeg(45)); PolyBezier slanted = new Ellipse(100, 100, 100, 50).getRotatedCCW(Angle.fromDeg(30)); Ring rotatedClippingArea = region.getRotatedCCW(Angle.fromDeg(300));
  • 17. GEF4 Graphics - Features • Support for rendering (planar) geometries, images, and text on an underlying Canvas/Graphics • Key abstractions (Font, Image, Color) and transparent support for multiple widget toolkits (AWT, SWT)* • Grouping of visual properties according to their respective usage context (BlitProperties, DrawProperties,..) • Full push/pop/restore of graphics state • Extensible image processing support (Pixel-Filter, Channel-Filter, Convolution-Filter) *) JavaFX already prototyped byTom Schindl
  • 18. GEF4 Graphics - Overview
  • 19. GEF4 Graphics - Examples
  • 20. GEF4 Graphics - Sample Code final Ellipse ellipse = new Ellipse(50, 50, 350, 200); final Rectangle rectangle = new Rectangle(100, 160, 125, 220); final Polygon triangle = new Polygon(260, 170, 190, 300, 330, 300);   g.drawProperties().setLineWidth(4).setAntialiasing(true); g.fillProperties().setAntialiasing(true);   g.pushState(); // saves the current set of properties on the stack   g.fillProperties().setColor(new Color(255, 0, 0)); g.drawProperties().setDashArray(25, 10).setColor(new Color(128, 0, 0));   g.fill(ellipse); g.draw(ellipse.getOutline());   g.restoreState(); // restores the previously saved properties   g.fillProperties().setColor(new Color(0, 0, 255)); g.drawProperties().setLineJoin(LineJoin.ROUND)".setLineCap(LineCap.ROUND);   g.fill(rectangle); g.draw(rectangle.getOutline());   g.popState(); // removes the previously saved properties from the stack " " " // and enables the prior set of properties   g.fillProperties().setColor(new Color(0, 255, 0)); g.drawProperties().setColor(new Color(0, 128, 0)).setLineJoin(LineJoin.MITER);   g.fill(triangle); g.draw(triangle.getOutline());
  • 21. GEF4 - Outlook • Planned on the short term (Kepler): • Creation of GEF4 Canvas component (FigureCanvas/ Figures) • Migration of Zest2 into GEF4 repository and update site (including adoption of namespace) • Planned on the mid/long-term : • Adoption of migrated Zest components to new GEF4 Geometry, Graphics, Canvas components • Migration of remaining Draw2d/GEF (MVC) code base, including re-modularization and adoption
  • 22. And on the very short term... • ... we are currently implementing Image#toString()...