Skip to content

Instantly share code, notes, and snippets.

@davidsnyder
Created November 28, 2018 18:52
Show Gist options
  • Save davidsnyder/23bfbb4533f66f951617f76fde1bd1c9 to your computer and use it in GitHub Desktop.
Save davidsnyder/23bfbb4533f66f951617f76fde1bd1c9 to your computer and use it in GitHub Desktop.
require 'reterm'
include RETerm
results = {}
init_reterm {
win = Window.new
win.colors = :main
win.border!
layout1 = Layouts::Horizontal.new
win.component = layout1
child1 = layout1.add_child :rows => 3,
:cols => 20
dial = Components::Dial.new
child1.component = dial
child2 = layout1.add_child :rows => 15,
:cols => 40
entry = Components::Entry.new :title => "Enter: ", :label => "Text:"
child2.component = entry
###
win.activate!
results[:dial] = dial.value
results[:entry] = entry.value
}
puts "Input results: "
puts results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment