How to use images inline with text

I am trying to use some small SVG icons in line with text but it seems to only work in some situations as it seems to force a new line to start most of the time. I am unsure if this is a bug or intended.