O'Reilly logo

Game Programming using Qt 5 Beginner's Guide - Second Edition by Lorenz Haas, Witold Wysota, Pavel Strakhov

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

What just happened?

The code we just created introduces a couple of new features. Let's go through them one by one.

First of all, we used a new element called Repeater. It does exactly what its name says—it repeats items declared within it using a given model. For each entry in the model, it creates an instance of a component assigned to a property called delegate (the property name means that it contains an entity to which the caller delegates some responsibility, such as describing a component to be used as a stencil by the caller). Item declared in Repeater describes the delegate even though we cannot see it explicitly assigned to a property. This is because delegate is a default property of the Repeater type, which means anything unassigned ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required