MerginMaps / qgis-plugin

QGIS plugin for managing Mergin Maps projects
GNU General Public License v3.0
34 stars 13 forks source link

Expression for images in tooltip is broken in QGIS 3.36.0 #576

Open raherin opened 6 months ago

raherin commented 6 months ago

When adding an image preview to the tooltip as recommended in our documentation, the image does not appear in the tooltip in QGIS (see screenshot). However, the image still appears in the feature preview on the mobile app.

Screenshot 2024-03-05 100832

Screenshot 2024-03-05 101227

In order to get the image to appear in the tooltip on QGIS, the following script must be used:

<img src='file:///[%@project_folder%]/[% "photo" %]' width='250' />

However, when the script above is used and feature is opened in the mobile app, the image will not be scaled so it isn't really visible due to the size of the image.

Screenshot_20240305_104914

This currently only affects QGIS 3.36.0, we've tested it on 3.34LTS and everything still works as expected.