How it works...

In order for this to work, we need two programs: a server program that connects all the clients and delivers their messages, and a client program used by the users to send and receive messages from other users.

Since the server program just sits behind the scenes and works out everything in silence, it doesn't need any user interface, and thus we only need it as a Qt Console Application.

The client program, however, requires a visually pleasant yet easy-to-use GUI for the users to read and write their messages. Therefore, we created the client program as a Qt Widgets Application instead.

The client program is relatively simple when compared to the server program. All it does is to connect to the server, send out the message input by the user, and print out everything the server sent to it.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset