February 2019
Intermediate to advanced
450 pages
11h 59m
English
To complete the interaction of our GoMail examples, we'll make use of the standard signals and slots within qt. Firstly, we need to set up an instance of our test email server and load the data. We add a setMessage(*client.EmailMessage) function to set the content of our labels, which can be called on the loading of our GUI and when the email list is clicked:
func (m *mainUI) setMessage(message *client.EmailMessage) { m.subject.SetText(message.Subject) m.to.SetText(message.ToEmailString()) m.from.SetText(message.FromEmailString()) m.date.SetText(message.DateString()) m.content.SetText(message.Content)}
The code to handle clicking on the email list looks something like the following snippet. We're creating an anonymous function ...
Read now
Unlock full access