Added escape function, and cleared up syntax in pyEditor