Initialize initializes the tree with the specified initial width and height It is normally used when the folder is embedded in another object.
(width, height float32)
| 57 | // Initialize initializes the tree with the specified initial width and height |
| 58 | // It is normally used when the folder is embedded in another object. |
| 59 | func (t *Tree) Initialize(width, height float32) { |
| 60 | |
| 61 | t.List.initialize(true, width, height) |
| 62 | t.SetStyles(&StyleDefault().Tree) |
| 63 | t.List.Subscribe(OnKeyDown, t.onKey) |
| 64 | t.List.Subscribe(OnKeyUp, t.onKey) |
| 65 | } |
| 66 | |
| 67 | // SetStyles sets the tree styles overriding the default style. |
| 68 | func (t *Tree) SetStyles(s *TreeStyles) { |
no test coverage detected