I've code this below and works. When I selected (only one click) a fileName in myFileDialog, on the right, in the preview box appear if the file selected is a pixmap or not; I'd like, when I click, show in preview box, the preview of image (the image). How to do? Thanks
Code:
public: { if ( pix.isNull() ) { setText( "This is not a pixmap" ); } else { setText( "This is a pixmap" ); } } }; Preview* p = new Preview; myFileDialog* myFd = new myFileDialog(this,"",) myFd->setContentsPreviewEnabled( TRUE ); myFd->setContentsPreview( p, p ); file = myFd->selectedFile();