def format idx
      case idx
      when Integer
        @formats[idx] || @default_format
      when String
        @formats.find do |fmt| fmt.name == idx end
      end
    end
def format idx
      case idx
      when Integer
        @formats[idx] || @default_format
      when String
        @formats.find do |fmt| fmt.name == idx end
      end
    end
The Format at _idx_, or - if _idx_ is a String -
 the Format with name == _idx_