Modify text editor content retrieval with a much more elegant solution - refs BT#8968