 
 collection_dropdown_menu = [
   {
-    name: 'sort by weight',
-    action: (c, t) ->
-      console.log('sort by weight')
-      c.addAnimations(c.sortNodes( ((n1, n2) -> n2.value - n1.value), t))
-  },
-  {
-    name: 'delete'
-    action: (c, t) ->
-      console.log('delete')
-      c.delete_flag = true
-  },
-  {
     name: 'tidy',
     action: (c, t) ->
       console.log('tidy trees')

    ctx.textAlign = 'center'
    ctx.textBaseline = 'middle'

    ctx.fillText(@value, 0, 0)
    ctx.restore()
 
    if @child0?

        console.log('not attempting to tidy multiple trees')
  },
  {
    name: 'remove values'
    action: (c, t) ->
      console.log('remove values')
      c.removeValues()
  },
  {
    name: 'Shannon-Fano',
    action: (c, t) ->
      console.log('Shannon-Fano')
      if not c.nodes[0].value?
        console.log('values required for Shannon-Fano')
      else
        c.reconstruct_as = ShannonFanoNodeCollection
  },
  {
    name: 'Huffman',
    action: (c, t) ->
      console.log('Huffman')
      if not c.nodes[0].value?
        console.log('values required for Huffman')
      else
        c.reconstruct_as = HuffmanNodeCollection
  },
  {
    name: 'sort by weight',
    action: (c, t) ->
      console.log('sort by weight')
      if not c.nodes[0].value?
        console.log('weights/values required to sort by weight')
      else
        c.addAnimations(c.sortNodes( ((n1, n2) -> n2.value - n1.value), t))
  },
  {
    name: 'delete'
    action: (c, t) ->
      console.log('delete')
      c.delete_flag = true
  },
]

huffman_collection_dropdown_menu = [
