test16.nim 404 B

1234567891011121314151617181920212223
  1. # --- Test 16. Use EditText node. --- #
  2. import nodesnim
  3. Window("hello world")
  4. var
  5. mainobj: SceneObj
  6. main = Scene("Main", mainobj)
  7. edittextobj: EditTextObj
  8. edittext = EditText(edittextobj)
  9. main.addChild(edittext)
  10. edittext.color = Color(1f, 1f, 1f) # default text color.
  11. edittext.hint_color = Color(1f, 0.6, 1f)
  12. edittext.resize(512, 256)
  13. addScene(main)
  14. setMainScene("Main")
  15. windowLaunch()