Do as little work at draw-time as possible. Many thanks to @jekstrand and @robclark for moral support with this MR, and to @krh for masterminding the GenXML "|" trick.