nuliknol
12th June 2014, 01:16
Hi,
I would like to ask , which declaration of object is faster?
QLabel lbl_name;
lbl_name.setText("Name:");
or this:
QLabel *lbl_name;
lbl_name= new QLabel("Name:");
Or in other words, is it best to use pointers to objects or objects themselves ?
I am going to use this for creating dialogs and windows in my app.
TIA
I would like to ask , which declaration of object is faster?
QLabel lbl_name;
lbl_name.setText("Name:");
or this:
QLabel *lbl_name;
lbl_name= new QLabel("Name:");
Or in other words, is it best to use pointers to objects or objects themselves ?
I am going to use this for creating dialogs and windows in my app.
TIA