hi!
I've got an application which shows a list of links in QTextBrowser, but if the user clicks one of them I want them to appear in a different - QWebView, not in QTextBrowser, I want the QTextBrowser to remain the same.
so I've done:
QWebView *webview;
QWebView *webview;
QTextBrowser *browser;
To copy to clipboard, switch view to plain text mode
connect(browser,
SIGNAL(sourceChanged
(QUrl &)),
this,
SLOT(showLink
(QUrl &)));
connect(browser, SIGNAL(sourceChanged(QUrl &)), this, SLOT(showLink(QUrl &)));
To copy to clipboard, switch view to plain text mode
and then:
showLink
(const QUrl &link
){
webview
->load
(QUrl(link
));
webview->show();
}
showLink(const QUrl &link)
{
webview->load(QUrl(link));
webview->show();
}
To copy to clipboard, switch view to plain text mode
anyway it doesn't work.
So I subclassed QTextBrowser and modified setSource() to do nothing. Still doesn't work...
thanks for any help.
Bookmarks