CGM support for eclipse oxygen author pre 19

<oXygen/> general issues.
SNO
Posts: 25
Joined: Mon Oct 01, 2012 3:05 pm

CGM support for eclipse oxygen author pre 19

Post by SNO » Mon Apr 27, 2020 1:17 pm

Hi,
as you describe in your description on git hub "https://github.com/oxygenxml/oxygenxml. ... rt.eclipse" this addon is only running on oxygen post version 19.
What exactly is the reason that it is not running on previous versions?

I use the eclipse version of the oxygen author.
Stefan Nöbauer
Senior Solution Architect
KGU-Consulting GmbH

sorin_carbunaru
Posts: 325
Joined: Mon May 09, 2016 9:37 am

Re: CGM support for eclipse oxygen author pre 19

Post by sorin_carbunaru » Mon Apr 27, 2020 2:55 pm

Hello,

The add-on needs some code/API from the Oxygen Eclipse Plugin that was not available prior to version 19.0.

By the way, please note that versions 19.x of Oxygen have reached their end-of-maintenance and end-of-support milestones.

Regards,
Sorin Carbunaru
oXygen XML

SNO
Posts: 25
Joined: Mon Oct 01, 2012 3:05 pm

Re: CGM support for eclipse oxygen author pre 19

Post by SNO » Tue Apr 28, 2020 2:03 pm

Hi,

thanx for your answer, i know that these versions are EOL but is there a possibility to extend oxygen 17 eclipse version to display CGM files?
Do you have a link to some customization guides for custom image renderer?

Thanx very much
Stefan Nöbauer
Senior Solution Architect
KGU-Consulting GmbH

adrian_sorop
Posts: 9
Joined: Wed Jun 22, 2016 2:48 pm

Re: CGM support for eclipse oxygen author pre 19

Post by adrian_sorop » Tue Apr 28, 2020 4:35 pm

Hello,

Before Oxygen 19, rendering CGM images in Author Mode was mad using a third party library from bdaum.

Here is a documentaion link from Oxygen's 17 Eclipse distribution: Customize Oxygen XML Editor plugin to Render CGM Images Version 17.0

The main issue is that the used third party is no longer available...officially.

If you manage to find the third party and follow the documentaion steps you should be able to render CGM files in Oxygen's eclipse plugin.

Let me know how this works,
Have a nice day,
Adrian S.
Adrian Sorop
<oXygen/> XML Editor
http://www.oxygenxml.com

SNO
Posts: 25
Joined: Mon Oct 01, 2012 3:05 pm

Re: CGM support for eclipse oxygen author pre 19

Post by SNO » Tue Apr 28, 2020 6:13 pm

yes this addon is not available any more,

What is the extension point of oxygen this addon was using? So I could write my own addon using JCGM.

Best regards
Stefan Nöbauer
Senior Solution Architect
KGU-Consulting GmbH

adrian_sorop
Posts: 9
Joined: Wed Jun 22, 2016 2:48 pm

Re: CGM support for eclipse oxygen author pre 19

Post by adrian_sorop » Tue Apr 28, 2020 6:38 pm

I could write my own addon using JCGM
If you want to write an add-on that uses the JCGM for versions before 19.0 don't do it. The classes will not be loaded by Oxygen and won't work.
Oxygen's versions 17 and 18 internal code relies on bdaum's CGM Panel Third party's API.
Adrian Sorop
<oXygen/> XML Editor
http://www.oxygenxml.com

Radu
Posts: 7103
Joined: Fri Jul 09, 2004 5:18 pm

Re: CGM support for eclipse oxygen author pre 19

Post by Radu » Wed Apr 29, 2020 8:22 am

Hi,

As Adrian said, we added in Oxygen 19.0 the support for using JCGM to load CGM images when the extra JAR library was added to the classpath.
Looking at how our code looked in Oxygen 19.0 we do have I think two possible workarounds (but I have not tested them):
1) If in the Oxygen Eclipse plugin's classpath (as defined in its MANIFEST.MF file) there is a Java library which uses the standard java JAI Image IO API to register a CGM image handler (via it's MANIFEST.MF/services file), this JAR library should be used to render the CGM image in the Author mode. I think this approach should work also with Oxygen 17
2) In Oxygen 18 we added our specific API to add image handlers. In the Oxygen plugin.xml there is an extension point called com.oxygenxml.editor.workspaceAccessPlugin. The API com.oxygenxml.workspace.api.eclipse.EclipseWorkspaceAccessPluginExtension.pluginStarted(EclipsePluginWorkspace) should be called when the Oxygen plugin is initialized and you can use the ro.sync.exml.workspace.impl.WorkspaceUtilitiesImpl.getImageUtilities() API to add a custom image handler.

https://www.oxygenxml.com/InstData/Edit ... ndler.html

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Post Reply