Doc editor with syntax highlighting, error detection