#23 add some functions for editor