Get the username and write it to text?

How to get the username of the person who clicked on the widget and write it to text? Hi all! Can this be done somehow? My programming skills are very bad, I have a simple number randomizer widget

Attach a click handler to the desired component, then in this event handler get the username, and set the state for the Text component with the data you need.