fdo#30732 Retain selected character attributes for table of contents

The text and selected attributes are copied from the source text node
and added to the target node at the corresponding positions.

Conflicts:
	sw/inc/ToxTextGenerator.hxx
	sw/source/core/tox/ToxTextGenerator.cxx

Change-Id: Ifa329bfcb2b9691120513236909bcadaf1127b5e
Reviewed-on: https://gerrit.libreoffice.org/9610
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>