Grammar and textuality