Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow customization of jqPlot parameters - show/hide canvasLegend #3341

Closed
chmielot opened this issue Aug 23, 2012 · 7 comments
Closed

Allow customization of jqPlot parameters - show/hide canvasLegend #3341

chmielot opened this issue Aug 23, 2012 · 7 comments
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. wontfix If you can reproduce this issue, please reopen the issue or create a new one describing it.
Milestone

Comments

@chmielot
Copy link

Use case: The canvas legend of pie charts doesn't make sense, actually. Currently a canvas legend with the word "visits" is shown.
This patch prepares piwik to customize plot parameters. Plot parameters that should be allowed to be customized need to be added to Piwik_ViewDataTable::init() to the protected $plotProperties variable. Plot options are then fully under control of PIWIK and if desires arise to customize other parameters as well, they can easily be added.
Of course modifications to jqplot.js are unavoidable to $.extend() the default settings.

Please review and tell if you can think of better implementations. This one seems pretty straight forward and transparent to me.

@chmielot
Copy link
Author

Attachment:
3341-custom-plot-properties.diff

@robocoder
Copy link
Contributor

I think a pre-requisite should be to update libs/jqplot.

@chmielot
Copy link
Author

Replying to vipsoft:

I think a pre-requisite should be to update libs/jqplot.

Is there a ticket to update jqplot? I found a lot of custom functionality in jqplot.js, doesn't seem to be easy to update it.
As the changes in jqplot seem to affect piwik code only, the canvasLegend parameter is still in the docs, and the only thing I've done is to extend the canvasLegend options, this could be merge to 1.8.4, couldn't it? Else we gonna get into trouble when updating to future PIWIK versions. :/ I struggled to do it as good as possible to integrate jqplot options, it's not a dirty hack for that one option 'canvasLegend'. What do you think?

@mattab
Copy link
Member

mattab commented Sep 11, 2012

Sorry about the delay in replying. Thank you for the patch!

Did you have any other patches you wished us to commit to help you build better data visualization using Piwik ?

We have put all our ideas and discussion about the Interactive JS Jqplot graphs, in this ticket: #3110

Please comment there if you wish to make a new point or suggestion. Or create new tickets for patches (or submit them in here and we'll review all at once).

regarding updating jqplot, I'm not sure. Have you looked into it? is it doable ?

@mattab
Copy link
Member

mattab commented Oct 19, 2012

@chmielot are you still interested to help with jqplot update maybe?

@chmielot
Copy link
Author

@matt, unfortunately I have no time to work on this now. It's possible that I'm gonna have some time to look into it in december, but can't promise anything. In this particular case, better don't count on me.
The patches I submitted arose from use cases I need to support. Nevertheless, none of the patches is a hack and I think they are integrated well.

@mattab
Copy link
Member

mattab commented Dec 14, 2012

please reopen if patch

@chmielot chmielot added this to the 1.x - Piwik 1.x milestone Jul 8, 2014
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. wontfix If you can reproduce this issue, please reopen the issue or create a new one describing it.
Projects
None yet
Development

No branches or pull requests

3 participants