low-level svg helper