Thanks for your answer. It more like number 2 (similar request
here, but covers multiple scenarios). It is not a lot of work to do, but I thought If similar code exists in calibre and is easily re-usable it would be a better quality than writing it myself. According to your first bullet point, it is not re-usable so I will write it myself.