Class: Bioroebe::GUI::LibUI::ProteinToDNA

Inherits:
Object
  • Object
show all
Includes:
Bioroebe::GUI, ProteinToDNAModule, LibuiParadise::Extensions
Defined in:
lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb

Overview

Bioroebe::GUI::LibUI::ProteinToDNA

Constant Summary

Constants included from ProteinToDNAModule

ProteinToDNAModule::HEIGHT, ProteinToDNAModule::TITLE, ProteinToDNAModule::USE_THIS_FONT, ProteinToDNAModule::USE_THIS_TITLE_FOR_THE_MAIN_BUTTON, ProteinToDNAModule::WIDTH

Constants included from Bioroebe::GUI

ARRAY_ALL_GTK_WIDGETS, FONT_SIZE, OLD_VERBOSE_VALUE, USE_THIS_FONT, USE_THIS_FONT_FAMILY_FOR_GUI_APPLICATIONS

Instance Method Summary collapse

Methods included from ProteinToDNAModule

#aminoacid_sequence?, #border_size?, #create_buttons, #do_determine_the_backtrack_sequence, #filter_away_invalid_aminoacids_from_the_left_buffer, #left_buffer?, #menu, #padding?, #right_buffer?, #set_aminoacid_sequence, #shared_reset

Methods included from Bioroebe::GUI

#disable_warnings, #enable_warnings, #log_dir?

Constructor Details

#initialize(run_already = true) ⇒ ProteinToDNA

#

initialize

#

32
33
34
35
36
37
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 32

def initialize(
    run_already = true
  )
  reset
  run if run_already
end

Instance Method Details

#connect_skeletonObject

#

connect_skeleton

#

77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 77

def connect_skeleton
  abort_on_exception
  @outer_vbox = padded_vbox
  @outer_vbox.add_hsep
  @outer_vbox.maximal(@dataset[:top_hbox], 4)
  button_box = hbox(
    @dataset[:backtrack_button],
    @dataset[:quit_button]
  )
  @outer_vbox.minimal(button_box)
  window = ui_padded_main_window(
    @title,
    @width,
    @height,
    0
  )
  window.add(@outer_vbox)
  window.intelligent_exit
end

#create_left_bufferObject

#

create_left_buffer

#

107
108
109
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 107

def create_left_buffer
  @dataset[:left_buffer] = ui_text_view # The left text view.
end

#create_right_bufferObject

#

create_right_buffer

#

49
50
51
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 49

def create_right_buffer
  @dataset[:right_buffer] = ui_text_view # The right text view.
end

#create_skeletonObject

#

create_skeleton (skeleton tag)

#

56
57
58
59
60
61
62
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 56

def create_skeleton
  @outer_vbox = vbox
  create_buttons
  create_left_buffer  # Our left buffer.
  create_right_buffer # Our right buffer.
  create_top_hbox
end

#create_top_hboxObject

#

create_top_hbox

#

67
68
69
70
71
72
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 67

def create_top_hbox
  top_hbox = hbox
  top_hbox.maximal(left?)
  top_hbox.maximal(right?)
  @dataset[:top_hbox] = top_hbox
end

#resetObject

#

reset (reset tag)

#

42
43
44
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 42

def reset
  shared_reset
end

#runObject

#

run

#

100
101
102
# File 'lib/bioroebe/gui/libui/protein_to_DNA/protein_to_DNA.rb', line 100

def run
  create_skeleton_then_connect_skeleton
end