Fix textrange serialize issue