Add "Empty" method to Hierarchy
This commit is contained in:
parent
641514c6d1
commit
8d3a708bca
@ -73,6 +73,11 @@ func (this *Hierarchy) SetRoot (root tomo.Box) {
|
|||||||
this.minimumClean = false
|
this.minimumClean = false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Empty returns whether or not the root of the Hierarchy is nil.
|
||||||
|
func (this *Hierarchy) Empty () bool {
|
||||||
|
return this.root == nil
|
||||||
|
}
|
||||||
|
|
||||||
// SetCanvas sets the held canvas of the Hierarchy that all boxes within it will
|
// SetCanvas sets the held canvas of the Hierarchy that all boxes within it will
|
||||||
// draw to. The Hierarchy will use the canvas.Canvas's bounds to lay itself out.
|
// draw to. The Hierarchy will use the canvas.Canvas's bounds to lay itself out.
|
||||||
func (this *Hierarchy) SetCanvas (can canvas.Canvas) {
|
func (this *Hierarchy) SetCanvas (can canvas.Canvas) {
|
||||||
|
Loading…
Reference in New Issue
Block a user