Printer Template fixed string

I guess I am going after this issue of alignment:

I want to print:

{NAME} | {QUANTITY} | {PRICE} | {TOTAL PRICE}

So I need a fixed column width in the name.

How can this be done?