require 'phi'
include Phi

APPLICATION.create_handle

form = Form.new :form1, "Menu->Hint_Test にマウスをおいてしばらく待つ"
memo = Memo.new form, :memo
Phi.new_menu form, :menu, [
  Phi.new_item('&File'          , ''            , :mi_file).add(*[
    Phi.new_item('&Hint_Test'        , 'Ctrl+H' , :mi_hint)
  ])
]
memo.hint = "This is Memo!!"

form.menu_attr_flatten  #++
form.mi_hint.hint = "This is Hint!!"
form.mi_hint.on_click = proc { |i| form.memo.lines.add i.hint }
form.show_hint = true
APPLICATION.show_hint = true

APPLICATION.on_hint = proc do |sender|
  p sender.hint
end

form.show
Phi.mainloop
