minor improvements and some experiements with TextNode