Guys, I get a
"KPluginLoader::KPluginLoader: Could not find plugin "kwordpart""
this is my code and substituting kwordpart with katepart works OK which means that my application integrates the katepart in the mainwindow (KParts::MainWindow). I have build the whole koffice 2.1 without any errors and installed it in ~/koffice-2.1/install/, which I've put in the KDEDIRS variable ( via export in bashrc ). I can see the libkwordpart.so in the install/lib and install/lib/kde4 directory. I've read this on the forum:
"http://www.qtforum.org/post/47310/load-parts-w-o-install.html?highlight=kpart#post47310"
|
Source code
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
KPluginFactory *factory = KPluginLoader("kwordpart").factory();
KParts::ReadWritePart *m_part;
if (factory)
{
m_part = static_cast<KParts::ReadWritePart *>
(factory->create(this, "kwordpart" ));
if (m_part)
{
layout2->addWidget( m_part->widget() );
}
}
else
{
return;
}
|