 
 
 
-class HexDrawB
-
-  constructor: (puzzle_app) ->
-    @puzzle = puzzle_app
-    @puzzle_view = @puzzle.puzzle_view
-
-    @mode = null
-    @context = null
-    @colors = ["#cc5050","#5050cc","#50cccc","#50cc50","#cccc50","#cc50cc","#000000"]
-
-
-  set_context: (mode) ->
-    @mode = mode
-    @context = @puzzle_view.get_drawing_context(mode)
-
-
-  fill_hex_ab: (a,b,c_no) ->
-    x = 113+a*14
-    y = 27+b*20
-    y = y-9 if (a%2 == 0)
-    @fill_hex_xy(x,y,c_no)
-
-
-  fill_hex_xy: (x,y,c_no) ->
-    @context.fillStyle = @colors[c_no]
-    @context.beginPath()
-    @context.moveTo(x,y)
-    @context.lineTo(x+10,y)
-    @context.lineTo(x+15,y+11)
-    @context.lineTo(x+10,y+20)
-    @context.lineTo(x-1,y+20)
-    @context.lineTo(x-6,y+10)
-    @context.lineTo(x,y)
-    @context.fill()
-    @context.closePath()
-
-
-  draw_all_hexes: () -> # [test/diagnostic method]
-    @set_context("canvas")
-    for row in [1..10]
-      for col in [1..24]
-        if row%2 == 0
-          if col%2 == 0
-            c = 1
-          else
-            c = 2
-        else
-          if col%2 == 0
-            c = 3
-          else
-            c = 4
-        @fill_hex_ab(col,row,c) unless (row==10 && col%2==1)
-
-
-
 #   #   #   #   #   #
 #   Global Scope Statements
 #   #   #   #   #   #

    @context = @puzzle_view.get_drawing_context(mode)


  fill_hex_ab: (a,b,c_no) ->
    x = 113+a*14
    y = 27+b*20
    y = y-9 if (a%2 == 0)
    @fill_hex_xy(x,y,c_no)


  fill_hex_xy: (x,y,c_no) ->
    @context.fillStyle = @colors[c_no]
    @context.beginPath()
    @context.moveTo(x,y)
    @context.lineTo(x+10,y)
    @context.lineTo(x+15,y+11)
    @context.lineTo(x+10,y+20)
    @context.lineTo(x-1,y+20)
    @context.lineTo(x-6,y+10)
    @context.lineTo(x,y)
    @context.fill()
    @context.closePath()


      b2 = 2*hx[1] + aa%2 - 1
      @test_left_right_top_bottom(aa,b2)
    @get_corner_fit()
    @get_box_xy()
    @report_metrics() if @metrics_report == true


  report_metrics: () ->
    console.log("HexBox: left = "+@left)
    console.log("HexBox: right = "+@right)
    console.log("HexBox: top = "+@top)
