-
Notifications
You must be signed in to change notification settings - Fork 3
Graphics: Plots
RichardHerz edited this page Apr 6, 2018
·
3 revisions
I have been using the flot.js library and Javascript to plot data in web pages. Flot.js puts the plots into an empty HTML div.
In the LiveCode project, represent the area of the plot in this way:
- place a button on the card
- set the name of the button with the first word as PLOTDIV followed by a space and the rest of the name you desire to use - PLOTDIV must be followed by at least one more word to be re-imported correctly
- set the style of the button to rectangle
- set the showBorder property of the button to true
- set the size and location of the button to represent the area of the plot
This specially named button in the LC stack will get exported to be a div element in the HTML file.
Use the HTML ID of the plot div in your Javascript code that uses flot.js to generate the plot.