sailfishos-applications / daily-comics

Comic strips reader for SailfishOS
https://openrepos.net/content/olf/daily-comics
Other
2 stars 2 forks source link

[Suggestion] Allow for more than one return value by an extraction rule #53

Open Olf0 opened 7 months ago

Olf0 commented 7 months ago

Inspired by and based upon https://github.com/tardypad/sailfishos-daily-comics/issues/23.

Allow for additional <name>=<value> pairs as return values, while the first return value stays always just the image URL of a comic strip.

This can be used to return the content of an image's alt tag by alt=<string>, which is used by some comics to provide an interpretation hint, e.g. xkcd. This could also be used to return a title for a strip, which may be originally provided by a title HTML attribute or determined by other means.

The original idea was to display the alt string below and the title string above the comic strip, but alternatively overlaid text might be used to keep the strip's display size as large as possible; as this may obstruct details of the strip, one would have to ensure that these texts are not laid over the exact same places of a strip in portrait versus landscape orientation (so a user can always see it all by turning the device) or that they vanish when double-tapping (single-tapping already displays a different overlay with extra functions) or (likely best solution) that the text overlays stay static when zooming and panning the strip image. Edit: Oh, double-tap is already used, do these uses conflict?

Olf0 commented 1 week ago

Other approaches to multiple return values are discussed in issue #109.