Ah, excellent answer Martin, that cleared up a lot of things

I didn't realize methodInterface() was also able to deal with QImage and how the UI handled that, I've only used it for colors.
That does trigger two more questions though.
If I have an .svg file or a config file (text file with plain text content) would there be any way to pass that to the EWO?
For the text file I guess I can simply work around this using something similar to this CTRL script:
Code: Select all
string fileContent;
fileToString("path\\\\to\\\\config.cfg", fileContent,"UTF8");
dyn_string lines = strsplit(fileContent, '\\n');
EWO.setConfig(lines);
That would probably be a decent way of doing it as it limits the path scope to the /scripts/ folder which I guess is the best place for a config file to reside anyway.
However, .svg might be a bit more tricky as it's not convertible to a QImage without rasterizing it.
Is there any way of passing a .svg as a QVariant::ByteArray?
Qt's .svg renderer supports loading the serialized XML data as a QByteArray so this might be a viable option if possible?
I should clarify that embedding the .svg files into the widget (like the DialGauge EWO) is not an option.
Your input on this would be very welcomed, whether or not it's possible.
Thanks in advance!