method

add_columns

ruby latest stable - Class: JSON::Editor::JSONTreeView

Method deprecated or moved

This method is deprecated or moved on the latest stable version. The last existing version (v1_9_2_180) is shown here.

add_columns()
private

No documentation available.

# File ext/json/lib/json/editor.rb, line 720
      def add_columns
        cell = CellRendererPixbuf.new
        column = TreeViewColumn.new('Icon', cell,
          'pixbuf'      => ICON_COL
        )
        append_column(column)

        cell = CellRendererText.new
        column = TreeViewColumn.new('Type', cell,
          'text'      => TYPE_COL
        )
        append_column(column)

        cell = CellRendererText.new
        cell.editable = true
        column = TreeViewColumn.new('Content', cell,
          'text'       => CONTENT_COL
        )
        cell.signal_connect(:edited, &method(:cell_edited))
        append_column(column)
      end