paste legend in text area per button click