Specialize hex formatting for 16 and 8 bit