         context.fillRect left, 0, item_width, border_height
 
         # add number representation if settings.number == true
-        if settings.number
+        if @settings.number
 
           # set font style
           context.font = layout.font_size * height + "px monospace"
 
+          # get prefix
+          prefix = @number.substr(0, 1)
+
           # print prefix
-          context.fillText prefix, 0, border_height * layout.font_y  if settings.prefix
+          context.fillText prefix, 0, border_height * layout.font_y  if @settings.prefix
 
           # init offset
-          offset = item_width * 3 + ((if settings.prefix then layout.prefix_offset * canvas.width else 0))
+          offset = item_width * 3 + ((if @settings.prefix then layout.prefix_offset * @element.width else 0))
 
           # split number
-          chars = number.substr(1, 6).split("")
+          chars = @number.substr(1, 6).split("")
 
           # loop though left chars
           $.each chars, (key, value) ->

            offset += layout.font_stretch * width

          # offset for right numbers
          offset = 49 * item_width + ((if settings.prefix then layout.prefix_offset * canvas.width else 0))

          # loop though right chars
          $.each number.substr(6).split(""), (key, value) ->
            
            # print text
            context.fillText value, offset, border_height * layout.font_y

        code += z[parts[i]]
        i++

      #return result
      return code

    draw: (code) ->

      # layout vars
      layout =
        prefix_offset: 0.07
        font_stretch: 0.078
        border_line_height_number: 0.9
        border_line_height: 1
        line_height: 0.9
        font_size: 0.2
        font_y: 1.03

      # get width of barcode element
      width = (if @settings.prefix then @element.width * 0.8 else @element.width)

      # check if number should be printed
      if @settings.number
        border_height = layout.border_line_height_number * @element.height
        height = layout.line_height * border_height
      else
        border_height = layout.border_line_height * @element.height
        height = layout.line_height * border_height

      # calculate width of every element
      item_width = width / 95

      # check if canvas-element is available
      if @element.getContext

        # get draw context
        context = @element.getContext("2d")

        # set fill color
        context.fillStyle = @settings.color

        # init var for offset in x-axis
        left = (if @settings.prefix then @element.width * layout.prefix_offset else 0)

        # get chars of code for drawing every line
        lines = code.split("")
