Initial implementation for border painting for the new IF (including support for PDF, but not SVG, yet)