Text blocks processing in Python.