got this

Qt Code:
  1. #include <QThread>
  2.  
  3. class QString;
  4.  
  5. class SerialThread : public QThread
  6. {
  7. Q_OBJECT
  8.  
  9. public:
  10. SerialThread(QObject *parent = 0);
  11.  
  12. protected:
  13. void run();
  14.  
  15. signals:
  16. void testowy(QString);
  17. };
To copy to clipboard, switch view to plain text mode 

while putting signal-slot mechanism to deliver some data from thread to my main its enough to do something like this in main thread as i got

SerialThread thread;

Qt Code:
  1. (...)
  2.  
  3. connect(&thread, SIGNAL(testowy(QString)),msg,SLOT(append(QString)));
To copy to clipboard, switch view to plain text mode 

but i would like also to send a QString from main thread to thread

I could call something like thread.publicFunction(QString) from main but i wonder if its a propper way