Second approach for generating padding around border. Still a not so great solution.