Fixed text sample bugs.