I'm missing something - graph png in a control page

Posted on
Fri Sep 17, 2021 10:47 am
sjoing offline
Posts: 28
Joined: Oct 12, 2005

I'm missing something - graph png in a control page

I've been scouring the user manual trying to find the part where Indigo control pages are creating that use Matplotlib graph png files - but I can't find that. My problem is that the graph png file doesn't get updated by the Indigo control page because I have to insert it as a 'Static Image / Caption'. So when I go to Safari and view this control page, other items will refresh such as device controls, but the Matplotlib graph png file will not. If I refresh the page manually it loads the latest graph, of course, but that's not the workflow I'm looking for. I feel like I'm missing some part of the big picture regarding how to use the png files that Matplotlib generates. Thank you in advance for any help.

Posted on
Fri Sep 17, 2021 12:58 pm
DaveL17 offline
User avatar
Posts: 6739
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: I'm missing something - graph png in a control page

If you leave the control page displayed, the chart won't change because it's loaded as a static image. That's true.

If you want to leave the same page displayed and have the freshest version of the chart always visible, you should add it to the page as a Refreshing Image URL object and point to the file specifically.
Code: Select all
file:///Library/Application Support/Perceptive Automation/Indigo 2021.1/Web Assets/images/controls/static/FILENAME.png
The downside to this approach is that these links will break when your Indigo version is updated. Therefore, if you choose to go with the Refreshing Image URL approach, it's best to save the images to a location that is independent of the Indigo version (a location that you control) such as
Code: Select all
file:///Users/USERNAME/Pictures/FILENAME.png
or something to that effect.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Fri Sep 17, 2021 12:58 pm
DaveL17 offline
User avatar
Posts: 6739
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: I'm missing something - graph png in a control page

p.s. I will update the plugin wiki to provide this information to help others. Thanks for brining it up!

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Fri Sep 17, 2021 4:12 pm
sjoing offline
Posts: 28
Joined: Oct 12, 2005

Re: I'm missing something - graph png in a control page

Thank you Dave! I had tried 'Refreshing Image URL' previously, but the file// prefix to the path was the trick I was missing.

Posted on
Fri Sep 17, 2021 4:21 pm
DaveL17 offline
User avatar
Posts: 6739
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: I'm missing something - graph png in a control page

Glad to hear that you were able to get it to work!

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 2 guests

cron