       for query in [@success_query, @value_query, @target_query]
         max = x if (x = query.future_value()) > max
         max = x if (x = query.present_value()) > max
+      max = 0 if max < 0
       # Let's add some padding
-      max = 0 if max < 0
       max * 1.05
 
     min_value: => if (m = @get('min')) then m else 0
 
-    update_scale: => @scale = @scale.domain([@min_value(), @max_value()]).range([0, @namespace.width - 80])
+    update_scale: => @scale.domain([@min_value(), @max_value()])
 
     axis_builder: => @axis.scale(@scale)
 


    initialize: ->
      @key = @model.get 'key'
      @namespace = D3.target_bar
      @namespace.series = @model.series
      @targets = []
      @targets.push(new @namespace.Target(t)) for t in @namespace.data[@key]

      @initialize_defaults()

    outer_height: -> 250

    draw: =>
      margins =
        top: 25
        bottom: 10
        left: 35
        right: 18

      @width = @available_width() - (margins.left + margins.right)
      @height = @outer_height() - (margins.top + margins.bottom)
      @namespace.width = @width
      t.scale.range([80, @width]) for t in @targets
      @svg = @create_svg_container @width, @height, @margins

      # Every target belongs to a group which is translated altogether

        .attr('x', (d) -> d.scale(d.target_value()) - 1)
        .attr('fill', (d) -> if d.successful() then '#008040' else '#ff0000')
        .style('opacity', (d) -> if d.is_set() then 0.7 else 0.0)
