keyurparekh
18th May 2011, 05:46
Hi all,
I am currently stuck in one problem. I am opening one HTML page using webkit module of QT. The is opening perfectly. But now i want to find text in that page.
How can i do that? Please give me some code example so that i can implement it. Below is my code to open HTML page.
.H file
class my2 : public QWidget , private Ui_Form
{
Q_OBJECT
public:
explicit my2(QWidget *parent = 0, Qt::WindowFlags f = 0 );
~my2();
public:
void setBaseUrl(const QUrl &url);
private:
QUrl baseUrl;
};
In C file
my2::my2(QWidget *parent, Qt::WindowFlags f ) :
QWidget(parent,f)
{
setupUi(this);
baseUrl = "http://www.itisl.com/Luminum/E-Book/Infotek/Physics/ch8/index.html";
setBaseUrl(baseUrl);
}
void my2::setBaseUrl(const QUrl &url)
{
webView->setUrl(url);
}
I have use Qwebview widget.
By this i m able to open HTML page perfectly. Now how can i find any word in this HTML page. Please tell me some solution so that i can solve this problem.
Thanks in Advance.
Regards,
Keyur Parekh
I am currently stuck in one problem. I am opening one HTML page using webkit module of QT. The is opening perfectly. But now i want to find text in that page.
How can i do that? Please give me some code example so that i can implement it. Below is my code to open HTML page.
.H file
class my2 : public QWidget , private Ui_Form
{
Q_OBJECT
public:
explicit my2(QWidget *parent = 0, Qt::WindowFlags f = 0 );
~my2();
public:
void setBaseUrl(const QUrl &url);
private:
QUrl baseUrl;
};
In C file
my2::my2(QWidget *parent, Qt::WindowFlags f ) :
QWidget(parent,f)
{
setupUi(this);
baseUrl = "http://www.itisl.com/Luminum/E-Book/Infotek/Physics/ch8/index.html";
setBaseUrl(baseUrl);
}
void my2::setBaseUrl(const QUrl &url)
{
webView->setUrl(url);
}
I have use Qwebview widget.
By this i m able to open HTML page perfectly. Now how can i find any word in this HTML page. Please tell me some solution so that i can solve this problem.
Thanks in Advance.
Regards,
Keyur Parekh