$kparts::createReadOnlyPart$
<br><p>
This is a PyKDE-only function that handles the machinery necessary
to create a KParts::ReadOnlyPart. It executes the following C++ code:
</p>
<table border="0" bgcolor="#f0f0f0" width="100%">
<tr>
<td>
<pre>
 KParts::ReadOnlyPart
   *createReadOnlyPart (const QString&amp; lib,
                        QObject *parent,
                        const QString&amp; name,
                        const char *className,
                        const QStringList &amp;args)
{
    KLibFactory *factory =
        KLibLoader::self ()-&gt;factory ((const char *)lib);

    if (factory)
        return
            static_cast&lt;KParts::ReadOnlyPart*&gt;
                (factory-&gt;create (parent,
                                    (const char *)name,
                                    className,
                                    args));
        else
                return NULL;
}
</pre>
</td>
</tr>
</table>
<p>
Notice that it takes care of creating the KLibFactory for you, and
returns the part cast to type KParts::ReadOnlyPart.  The actual
part has a different class (derived from KParts::ReadOnlyPart),
and calls to openURL or openFile will use the part's overloaded
methods. Currently it isn't possible to call KParts::ReadOnlyPart::openURL
if it has been overloaded.
</p>
<p>
Usage: KParts.createReadOnlyPart (lib, parent, name, className, args)
</p>
$end$


$kparts::createReadWritePart$
<br><p>
This is a PyKDE-only function that handles the machinery necessary
to create a KParts::ReadWritePart. It executes the following C++ code:
</p>
<table border="0" bgcolor="#f0f0f0" width="100%">
<tr>
<td>
<pre>
 KParts::ReadWritePart
   *createReadWritePart (const QString&amp; lib,
                         QObject *parent,
                         const QString&amp; name,
                         const char *className,
                         const QStringList &amp;args)
{
    KLibFactory *factory =
        KLibLoader::self ()-&gt;factory ((const char *)lib);

    if (factory)
        return
            static_cast&lt;KParts::ReadWritePart*&gt;
                (factory-&gt;create (parent,
                                    (const char *)name,
                                    className,
                                    args));
        else
                return NULL;
}
</pre>
</td>
</tr>
</table>
<p>
Notice that it takes care of creating the KLibFactory for you, and
returns the part cast to type KParts::ReadWritePart.  The actual
part has a different class (derived from KParts::ReadWritePart),
and calls to openURL or openFile will use the part's overloaded
methods. Currently it isn't possible to call KParts::ReadWritePart::openURL
if it has been overloaded.
</p>
<p>
Usage: KParts.createReadWritePart (lib, parent, name, className, args)
</p>
$end$


$kparts::createReadOnlyPart$
//doc

//<para>

// This is a PyKDE-only function that handles the machinery necessary

// to create a KParts::ReadOnlyPart. It executes the following C++ code:

//</para>

//<ProgramListing>

// KParts::ReadOnlyPart *createReadOnlyPart (const QString&amp; lib, QObject *parent,

//                                           const QString&amp; name, const char *className,

//                                           const QStringList &amp;args)

//{

//    KLibFactory *factory = KLibLoader::self ()-&gt;factory ((const char *)lib);

//

//    if (factory)

//            return static_cast&lt;KParts::ReadOnlyPart*&gt; (factory-&gt;create (parent,

//                                               (const char *)name, className, args));

//        else

//                return NULL;

//</ProgramListing>

//<para>

// Notice that it takes care of creating the KLibFactory for you, and

// returns the part cast to type KParts::ReadOnlyPart.  The actual

// part has a different class (derived from KParts::ReadOnlyPart),

// and calls to openURL or openFile will use the part's overloaded

// methods. Currently it isn't possible to call KParts::ReadOnlyPart::openURL

// if it has been overloaded.

//</para>

//<para>

// Usage: KParts.createReadOnlyPart (lib, parent, name, className, args)

//</para>

//end

$end$


$kparts::createReadWritePart$
//doc

//<para>

// This is a PyKDE-only function that handles the machinery necessary

// to create a KParts::ReadWritePart. It executes the following C++ code:

//</para>

//<ProgramListing>

// KParts::ReadWritePart *createReadWritePart (const QString&amp; lib, QObject *parent,

//                                           const QString&amp; name, const char *className,

//                                           const QStringList &amp;args)

// {

//     KLibFactory *factory = KLibLoader::self ()-&gt;factory ((const char *)lib);

//

//     if (factory)

//             return static_cast&lt;KParts::ReadWritePart*&gt; (factory-&gt;create (parent,

//                                                (const char *)name, className, args));

//         else

//                 return NULL;

//</ProgramListing>

//<para>

// Notice that it takes care of creating the KLibFactory for you, and

// returns the part cast to type KParts::ReadWritePart.  The actual

// part has a different class (derived from KParts::ReadWritePart),

// and calls to openURL or openFile will use the part's overloaded

// methods. Currently it isn't possible to call KParts::ReadWritePart::openURL

// if it has been overloaded.

//</para>

//<para>

// Usage: KParts.createReadWritePart (lib, parent, name, className, args)

//</para>

//end

$end$


