added better handling of paste from Word