Aggregation can be best described as an "IS-PART-OF"-relation. That is a relation which does not apply to classes derived from .ui-generated classes, as those .ui-generated classes are not a part of your dialog, but a simple parent for inheritance.

A good example for aggregation would be a car with an engine and tires:

Qt Code:
  1. // engine is-part-of a car
  2. class Engine
  3. {
  4. };
  5.  
  6. // tire is-part-of a car
  7. class Tire
  8. {
  9. };
  10.  
  11. // a car is build from tires and an engine
  12. class Car
  13. {
  14. private:
  15. Engine m_engine;
  16. Tire* m_tires[4];
  17. };
  18.  
  19. // and now inheritance:
  20. // a Volkswagen is-a car
  21. class Volkswagen : public Car
  22. {
  23. };
To copy to clipboard, switch view to plain text mode 

So, the basic difference between aggregation and inheritance boils down to:
1) Inheritance means you inherit something from one class to another (IS-KIND-OF or IS-A relationship)
2) Aggregation combines several simple parts to construct a more complex object (IS-PART-OF relationship)