Task #2003

Enhance multiple charts engines cohabitation

Added by Sebastien Jacquot about 3 years ago. Updated about 1 year ago.

Status:Closed Start date:01/16/2017
Priority:Normal Due date:
Assignee:- % Done:


Category:Charts Spent time: -
Target version:TXM 0.8.0


Enhance multiple charts engines cohabitation to be able to lazy create some charts with another charts engine even if the current selected charts engine does not manage the type of chart (some kind of downgrade functionality).
Eg.: to create a Wordcloud with R even if the current charts engine is JFreeChart and does not implement a Wordcloud chart creator. The cohabitation is also linked with the management of other future charts engine contributions, eg.: graph charts engine or using other wordcloud library.


Store a list of current installed charts engine extensions in TBX layer.
Store a list of current installed SWT charts components provider extensions in RCP layer.
Provide some preference pages for all the charts engine extensions with display format. The display format (Java, svg, png, etc.) drives the SWT components provider used when creating a chart.

Validation tests

  • open the preferences (Tools\Parameters)
  • go to TXM\Advanced\Charts engine node and check that current engine is set to Java
  • go to TXM\Advanced\Charts engine\JFreeChart node and check that display format is set to "JFreeChart/Java2D"
  • go to TXM\Advanced\Charts engine\R node and check that display format is set to "svg"
  • create a CAH
    => a chart editor must open
  • additional tests
  • create a Wordcloud
    => a chart editor must open

(Since there are no chart creator in JFC charts engine for CAH or Wordcloud, if a chart is open it means the lazy charts engine change works.)


#1 Updated by Sebastien Jacquot almost 3 years ago

  • Description updated (diff)
  • Status changed from New to Feedback
  • % Done changed from 0 to 80
Done, the new behavior is:
  • at start, the toolbox creates a charts engine for all installed implementation contribution plug-ins, then set one as current from the default preferences or from the preferences file (at this moment a JFCChartsEngine and an RChartsEngine are created)
    • (the current charts engine can be retrieve with ChartsEngine.getCurrent() and all installed charts engine are stored in the ChartsEngine class)
  • the RCP then creates an SWT charts components providers for all installed implementation contributions, then set one as current that can manage, as input format, the output format of the current charts engine (at this moment a JFCSWTChartsComponentsProvider, a SVGSWTChartsComponentsProvider and a RasterSWTChartsComponentsProvider are created)
    • (the current SWT charts components provider can be retrieve with SWTChartsComponentsProvider.getCurrent() and all installed providers are stored in the SWTChartsComponentsProvider class)
  • changing the current charts engine in the preferences page change the current SWTChartsComponentsProvider by getting the first one that manages the output format of the current charts engine
  • when opening an editor with SWTChartsComponentsProvider.getCurrent().openEditor(), the provider checks if the current charts engine can render the asked type of chart, if no it looks if other charts engines can and uses another one if possible

#2 Updated by Sebastien Jacquot over 1 year ago

  • Target version changed from TXM 0.8.0a (split/restructuration) to TXM 0.8.0

#3 Updated by Sebastien Jacquot about 1 year ago

  • Status changed from Feedback to Closed
  • % Done changed from 80 to 100

Also available in: Atom PDF