Playing around with :ascent, makes possible to keep the line-pixel-height fixed.
So in the following I simply use `insert-image`. Without the :ascent, the
'line-pixel-height' increases when inserting another character. With the
:ascent it is possible to reduce this 'increase'. For me the increase is 0
when I use an ascent value of 80.
(below the used code)
(with-current-buffer (get-buffer-create "test")
(setq left-margin-width 5)
(insert-image (svg-image (let* ((ph (line-pixel-height))
(size ph)
(svg (svg-create size size)))
(svg-circle svg ph ph ph :fill "red")
svg)
:ascent 80))
(switch-to-buffer (current-buffer)))