/***************************************************************************
                            KHTMLPart.m -  description
                             -------------------
    begin                : Thu Mar 21 01:01:29 2002
    copyright            : (C) 2000-2002 Lost Highway Ltd. All rights reserved.
    email                : Lost_Highway@tipitina.demon.co.uk
    generated by         : duke@tipitina on Thu Mar 21 01:01:29 2002, using kalyptus 0.9.
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This library is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU Library General Public License as       *
 *   published by the Free Software Foundation; either version 2 of the    *
 *   License, or (at your option) any later version.                       *
 *                                                                         *
 ***************************************************************************/

#include <qtc/qt_QString.h>
#include <qtc/qt_QCString.h>
#include <kdec/kde_KHTMLPart.h>
#include <kdec/kde_KURL.h>
#include <kdec/kde_URLArgs.h>
#include <kdeobjc/KDESupport.h>
#include <kdeobjc/KHTMLPart.h>
#include <kdeobjc/DOMNode.h>
#include <kdeobjc/Job.h>
#include <kdeobjc/KHTMLView.h>
#include <kdeobjc/KURL.h>
#include <qtobjc/QCursor.h>
#include <qtobjc/QDataStream.h>
#include <qtobjc/QPainter.h>
#include <qtobjc/QRect.h>
#include <qtobjc/QWidget.h>
#include <kdeobjc/URLArgs.h>


@implementation  KHTMLPart


- initWithWidget: (QWidget *)parentWidget widgetname: (NSString *)widgetname parent: (QObject *)parent name: (NSString *)name prof: (int)prof
{
	if ([self qt] == 0L) {
		[self setQt: kde_new_KHTMLPart((qt_QWidget *) [parentWidget qt], (char*) [widgetname cString], (qt_QObject *) [parent qt], (char*) [name cString], (int)prof)];
		[self setAllocatedInObjcWorld: YES];
		[QtSupport setObject: self forQtKey: [self qt]];
	}
	[super init];
	return self;
}

- init
{
	if ([self qt] == 0L) {
		[self setQt: kde_new_KHTMLPart(0, 0, 0, 0, [KHTMLPart DefaultGUI])];
		[self setAllocatedInObjcWorld: YES];
		[QtSupport setObject: self forQtKey: [self qt]];
	}
	[super init];
	return self;
}

- initWithHTMLView: (KHTMLView*)view parent: (QObject *)parent name: (NSString *)name prof: (int)prof
{
	if ([self qt] == 0L) {
		[self setQt: kde_new_KHTMLPart1((kde_KHTMLView*) [view qt], (qt_QObject *) [parent qt], (char*) [name cString], (int)prof)];
		[self setAllocatedInObjcWorld: YES];
		[QtSupport setObject: self forQtKey: [self qt]];
	}
	[super init];
	return self;
}

- initWithHTMLView: (KHTMLView*)view 
{
	if ([self qt] == 0L) {
		[self setQt: kde_new_KHTMLPart1((kde_KHTMLView*) [view qt], 0, 0, [KHTMLPart DefaultGUI])];
		[self setAllocatedInObjcWorld: YES];
		[QtSupport setObject: self forQtKey: [self qt]];
	}
	[super init];
	return self;
}

- (void) dealloc
{
	if ([self qt] != 0L) {
		if ([self allocatedInObjcWorld] && [self parent] == nil) {
			kde_del_KHTMLPart((kde_KHTMLPart *)[self qt]);
		}
		[QtSupport removeQtKey: [self qt]];
		[self setQt: 0L];
	}
	[super dealloc];
}

- (BOOL) openURL: (KURL*)url
{
	return (BOOL) kde_KHTMLPart_openURL((kde_KHTMLPart *)[self qt], (kde_KURL*) [url qt]);
}

- (BOOL) closeURL
{
	return (BOOL) kde_KHTMLPart_closeURL((kde_KHTMLPart *)[self qt]);
}

- showError: (Job*)job
{
	kde_KHTMLPart_showError((kde_KHTMLPart *)[self qt], (kde_Job*) [job qt]);
	return self;
}

//- (HTMLDocument*) htmlDocument
//{
//	return (HTMLDocument*) [QtSupport objectForQtKey: kde_KHTMLPart_htmlDocument((kde_KHTMLPart *)[self qt]) withClass: [HTMLDocument class] allocatedInObjcWorld: YES];
//}

//- (DOMDocument*) document
//{
//	return (DOMDocument*) kde_KHTMLPart_document((kde_KHTMLPart *)[self qt]);
//}

//- (DOMNode*) activeNode
//{
//	return (DOMNode*) kde_KHTMLPart_activeNode((kde_KHTMLPart *)[self qt]);
//}

- (BrowserExtension*) browserExtension
{
	return (BrowserExtension*) [QtSupport objectForQtKey: kde_KHTMLPart_browserExtension((kde_KHTMLPart *)[self qt]) withClass: [BrowserExtension class] allocatedInObjcWorld: YES];
}

- (KHTMLView*) view
{
	return (KHTMLView*) [QtSupport objectForQtKey: kde_KHTMLPart_view((kde_KHTMLPart *)[self qt]) withClass: [KHTMLView class] allocatedInObjcWorld: YES];
}

- setJScriptEnabled: (BOOL)enable
{
	kde_KHTMLPart_setJScriptEnabled((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) jScriptEnabled
{
	return (BOOL) kde_KHTMLPart_jScriptEnabled((kde_KHTMLPart *)[self qt]);
}

- setMetaRefreshEnabled: (BOOL)enable
{
	kde_KHTMLPart_setMetaRefreshEnabled((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) metaRefreshEnabled
{
	return (BOOL) kde_KHTMLPart_metaRefreshEnabled((kde_KHTMLPart *)[self qt]);
}

- (QVariant*) executeScript: (NSString *)script
{
static qt_QString * _qstring_script = 0L;
	return (QVariant*) [QtSupport objectForQtKey: kde_KHTMLPart_executeScript((kde_KHTMLPart *)[self qt], (qt_QString *) [script toQString: &_qstring_script]) withClass: [QVariant class] allocatedInObjcWorld: YES];
}

- (QVariant*) executeScript: (DOMNode*)n script: (NSString *)script
{
static qt_QString * _qstring_script = 0L;
	return (QVariant*) [QtSupport objectForQtKey: kde_KHTMLPart_executeScript1((kde_KHTMLPart *)[self qt], (kde_DOMNode*) [n qt], (qt_QString *) [script toQString: &_qstring_script]) withClass: [QVariant class] allocatedInObjcWorld: YES];
}

- setDNDEnabled: (BOOL)b
{
	kde_KHTMLPart_setDNDEnabled((kde_KHTMLPart *)[self qt], (int)b);
	return self;
}

- (BOOL) dndEnabled
{
	return (BOOL) kde_KHTMLPart_dndEnabled((kde_KHTMLPart *)[self qt]);
}

- setJavaEnabled: (BOOL)enable
{
	kde_KHTMLPart_setJavaEnabled((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) javaEnabled
{
	return (BOOL) kde_KHTMLPart_javaEnabled((kde_KHTMLPart *)[self qt]);
}

- (KJavaAppletContext*) javaContext
{
	return (KJavaAppletContext*) [QtSupport objectForQtKey: kde_KHTMLPart_javaContext((kde_KHTMLPart *)[self qt]) withClass: [KJavaAppletContext class] allocatedInObjcWorld: YES];
}

- (KJavaAppletContext*) createJavaContext
{
	return (KJavaAppletContext*) [QtSupport objectForQtKey: kde_KHTMLPart_createJavaContext((kde_KHTMLPart *)[self qt]) withClass: [KJavaAppletContext class] allocatedInObjcWorld: YES];
}

- setPluginsEnabled: (BOOL)enable
{
	kde_KHTMLPart_setPluginsEnabled((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) pluginsEnabled
{
	return (BOOL) kde_KHTMLPart_pluginsEnabled((kde_KHTMLPart *)[self qt]);
}

- setAutoloadImages: (BOOL)enable
{
	kde_KHTMLPart_setAutoloadImages((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) autoloadImages
{
	return (BOOL) kde_KHTMLPart_autoloadImages((kde_KHTMLPart *)[self qt]);
}

- setOnlyLocalReferences: (BOOL)enable
{
	kde_KHTMLPart_setOnlyLocalReferences((kde_KHTMLPart *)[self qt], (int)enable);
	return self;
}

- (BOOL) onlyLocalReferences
{
	return (BOOL) kde_KHTMLPart_onlyLocalReferences((kde_KHTMLPart *)[self qt]);
}

- enableJScript: (BOOL)e
{
	kde_KHTMLPart_enableJScript((kde_KHTMLPart *)[self qt], (int)e);
	return self;
}

- enableJava: (BOOL)e
{
	kde_KHTMLPart_enableJava((kde_KHTMLPart *)[self qt], (int)e);
	return self;
}

- enablePlugins: (BOOL)e
{
	kde_KHTMLPart_enablePlugins((kde_KHTMLPart *)[self qt], (int)e);
	return self;
}

- autoloadImages: (BOOL)e
{
	kde_KHTMLPart_autoloadImages1((kde_KHTMLPart *)[self qt], (int)e);
	return self;
}

- enableMetaRefresh: (BOOL)e
{
	kde_KHTMLPart_enableMetaRefresh((kde_KHTMLPart *)[self qt], (int)e);
	return self;
}

- (BOOL) setCharset: (NSString *)arg1 bool: (BOOL)arg2
{
static qt_QString * _qstring_arg1 = 0L;
	return (BOOL) kde_KHTMLPart_setCharset((kde_KHTMLPart *)[self qt], (qt_QString *) [arg1 toQString: &_qstring_arg1], (int)arg2);
}

- (KURL*) baseURL
{
	return (KURL*) [QtSupport objectForQtKey: kde_KHTMLPart_baseURL((kde_KHTMLPart *)[self qt]) withClass: [KURL class] allocatedInObjcWorld: YES];
}

- (NSString *) baseTarget
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_baseTarget((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- (KURL*) backgroundURL
{
	return (KURL*) [QtSupport objectForQtKey: kde_KHTMLPart_backgroundURL((kde_KHTMLPart *)[self qt]) withClass: [KURL class] allocatedInObjcWorld: YES];
}

- scheduleRedirection: (int)delay url: (NSString *)url lockHistory: (BOOL)lockHistory
{
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_scheduleRedirection((kde_KHTMLPart *)[self qt], (int)delay, (qt_QString *) [url toQString: &_qstring_url], (int)lockHistory);
	return self;
}

- scheduleRedirection: (int)delay url: (NSString *)url 
{
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_scheduleRedirection((kde_KHTMLPart *)[self qt], (int)delay, (qt_QString *) [url toQString: &_qstring_url], 1);
	return self;
}

- begin: (KURL*)url xOffset: (int)xOffset yOffset: (int)yOffset
{
	kde_KHTMLPart_begin((kde_KHTMLPart *)[self qt], (kde_KURL*) [url qt], (int)xOffset, (int)yOffset);
	return self;
}

- begin
{
	kde_KHTMLPart_begin((kde_KHTMLPart *)[self qt], kde_new_KURL(), 0, 0);
	return self;
}

- write: (NSString *)str len: (int)len
{
	kde_KHTMLPart_write((kde_KHTMLPart *)[self qt], (char*) [str cString], (int)len);
	return self;
}

//- write: (NSString *)str
//{
//	kde_KHTMLPart_write((kde_KHTMLPart *)[self qt], (char*) [str cString], -1);
//	return self;
//}

- write: (NSString *)str
{
static qt_QString * _qstring_str = 0L;
	kde_KHTMLPart_write1((kde_KHTMLPart *)[self qt], (qt_QString *) [str toQString: &_qstring_str]);
	return self;
}

- end
{
	kde_KHTMLPart_end((kde_KHTMLPart *)[self qt]);
	return self;
}

- paint: (QPainter *)arg1 rect: (QRect*)arg2 int: (int)arg3 int: (int*)arg4
{
	kde_KHTMLPart_paint((kde_KHTMLPart *)[self qt], (qt_QPainter *) [arg1 qt], (qt_QRect*) [arg2 qt], (int)arg3, (int*)arg4);
	return self;
}

- paint: (QPainter *)arg1 rect: (QRect*)arg2 
{
	kde_KHTMLPart_paint((kde_KHTMLPart *)[self qt], (qt_QPainter *) [arg1 qt], (qt_QRect*) [arg2 qt], 0, 0);
	return self;
}

- (BOOL) setEncoding: (NSString *)name override: (BOOL)override
{
static qt_QString * _qstring_name = 0L;
	return (BOOL) kde_KHTMLPart_setEncoding((kde_KHTMLPart *)[self qt], (qt_QString *) [name toQString: &_qstring_name], (int)override);
}

- (BOOL) setEncoding: (NSString *)name 
{
static qt_QString * _qstring_name = 0L;
	return (BOOL) kde_KHTMLPart_setEncoding((kde_KHTMLPart *)[self qt], (qt_QString *) [name toQString: &_qstring_name], 0);
}

- (NSString *) encoding
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_encoding((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- setUserStyleSheetWithURL: (KURL*)url
{
	kde_KHTMLPart_setUserStyleSheet((kde_KHTMLPart *)[self qt], (kde_KURL*) [url qt]);
	return self;
}

- setUserStyleSheet: (NSString *)styleSheet
{
static qt_QString * _qstring_styleSheet = 0L;
	kde_KHTMLPart_setUserStyleSheet1((kde_KHTMLPart *)[self qt], (qt_QString *) [styleSheet toQString: &_qstring_styleSheet]);
	return self;
}

- setStandardFont: (NSString *)name
{
static qt_QString * _qstring_name = 0L;
	kde_KHTMLPart_setStandardFont((kde_KHTMLPart *)[self qt], (qt_QString *) [name toQString: &_qstring_name]);
	return self;
}

- setFixedFont: (NSString *)name
{
static qt_QString * _qstring_name = 0L;
	kde_KHTMLPart_setFixedFont((kde_KHTMLPart *)[self qt], (qt_QString *) [name toQString: &_qstring_name]);
	return self;
}

- (BOOL) gotoAnchor: (NSString *)name
{
static qt_QString * _qstring_name = 0L;
	return (BOOL) kde_KHTMLPart_gotoAnchor((kde_KHTMLPart *)[self qt], (qt_QString *) [name toQString: &_qstring_name]);
}

- setURLCursor: (QCursor *)c
{
	kde_KHTMLPart_setURLCursor((kde_KHTMLPart *)[self qt], (qt_QCursor *) [c qt]);
	return self;
}

- (QCursor*) urlCursor
{
	return (QCursor*) [QtSupport objectForQtKey: kde_KHTMLPart_urlCursor((kde_KHTMLPart *)[self qt]) withClass: [QCursor class] allocatedInObjcWorld: YES];
}

- findTextBegin
{
	kde_KHTMLPart_findTextBegin((kde_KHTMLPart *)[self qt]);
	return self;
}

- (BOOL) findTextNext: (NSString *)str forward: (BOOL)forward caseSensitive: (BOOL)caseSensitive isRegExp: (BOOL)isRegExp
{
static qt_QString * _qstring_str = 0L;
	return (BOOL) kde_KHTMLPart_findTextNext((kde_KHTMLPart *)[self qt], (qt_QString *) [str toQString: &_qstring_str], (int)forward, (int)caseSensitive, (int)isRegExp);
}

- setZoomFactor: (int)percent
{
	kde_KHTMLPart_setZoomFactor((kde_KHTMLPart *)[self qt], (int)percent);
	return self;
}

- (int) zoomFactor
{
	return (int) kde_KHTMLPart_zoomFactor((kde_KHTMLPart *)[self qt]);
}

- (NSString *) selectedText
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_selectedText((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

//- (Range*) selection
//{
//	return (Range*) [QtSupport objectForQtKey: kde_KHTMLPart_selection((kde_KHTMLPart *)[self qt]) withClass: [Range class] allocatedInObjcWorld: YES];
//}

//- setSelection: (int)arg1
//{
//	kde_KHTMLPart_setSelection((kde_KHTMLPart *)[self qt], (DOM::Range) arg1);
//	return self;
//}

- (BOOL) hasSelection
{
	return (BOOL) kde_KHTMLPart_hasSelection((kde_KHTMLPart *)[self qt]);
}

- selectAll
{
	kde_KHTMLPart_selectAll((kde_KHTMLPart *)[self qt]);
	return self;
}

- show
{
	kde_KHTMLPart_show((kde_KHTMLPart *)[self qt]);
	return self;
}

- hide
{
	kde_KHTMLPart_hide((kde_KHTMLPart *)[self qt]);
	return self;
}

- (PartManager*) partManager
{
	return (PartManager*) [QtSupport objectForQtKey: kde_KHTMLPart_partManager((kde_KHTMLPart *)[self qt]) withClass: [PartManager class] allocatedInObjcWorld: YES];
}

- saveState: (QDataStream *)stream
{
	kde_KHTMLPart_saveState((kde_KHTMLPart *)[self qt], (qt_QDataStream *) [stream qt]);
	return self;
}

- restoreState: (QDataStream *)stream
{
	kde_KHTMLPart_restoreState((kde_KHTMLPart *)[self qt], (qt_QDataStream *) [stream qt]);
	return self;
}

//- (DOMNode*) nodeUnderMouse
//{
//	return (DOMNode*) kde_KHTMLPart_nodeUnderMouse((kde_KHTMLPart *)[self qt]);
//}

- (KHTMLSettings*) settings
{
	return (KHTMLSettings*) [QtSupport objectForQtKey: kde_KHTMLPart_settings((kde_KHTMLPart *)[self qt]) withClass: [KHTMLSettings class] allocatedInObjcWorld: YES];
}

- (KHTMLPart*) parentPart
{
	return (KHTMLPart*) [QtSupport objectForQtKey: kde_KHTMLPart_parentPart((kde_KHTMLPart *)[self qt]) withClass: [KHTMLPart class] allocatedInObjcWorld: YES];
}

- (NSArray *) frameNames
{
static qt_QStringList * _qlist = 0L;
	_qlist = kde_KHTMLPart_frameNames((kde_KHTMLPart *)[self qt]);
	return (NSArray *) [NSMutableArray arrayWithQStringList: _qlist];
}

- (KHTMLPart*) findFrame: (NSString *)f
{
static qt_QString * _qstring_f = 0L;
	return (KHTMLPart*) [QtSupport objectForQtKey: kde_KHTMLPart_findFrame((kde_KHTMLPart *)[self qt], (qt_QString *) [f toQString: &_qstring_f]) withClass: [KHTMLPart class] allocatedInObjcWorld: YES];
}

- (ReadOnlyPart*) currentFrame
{
	return (ReadOnlyPart*) [QtSupport objectForQtKey: kde_KHTMLPart_currentFrame((kde_KHTMLPart *)[self qt]) withClass: [ReadOnlyPart class] allocatedInObjcWorld: YES];
}

- (BOOL) frameExists: (NSString *)frameName
{
static qt_QString * _qstring_frameName = 0L;
	return (BOOL) kde_KHTMLPart_frameExists((kde_KHTMLPart *)[self qt], (qt_QString *) [frameName toQString: &_qstring_frameName]);
}

- setJSStatusBarText: (NSString *)text
{
static qt_QString * _qstring_text = 0L;
	kde_KHTMLPart_setJSStatusBarText((kde_KHTMLPart *)[self qt], (qt_QString *) [text toQString: &_qstring_text]);
	return self;
}

- setJSDefaultStatusBarText: (NSString *)text
{
static qt_QString * _qstring_text = 0L;
	kde_KHTMLPart_setJSDefaultStatusBarText((kde_KHTMLPart *)[self qt], (qt_QString *) [text toQString: &_qstring_text]);
	return self;
}

- (NSString *) jsStatusBarText
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_jsStatusBarText((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- (NSString *) jsDefaultStatusBarText
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_jsDefaultStatusBarText((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- (NSString *) referrer
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_referrer((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- (NSString *) lastModified
{
static qt_QString * _qstring = 0L;
	_qstring = kde_KHTMLPart_lastModified((kde_KHTMLPart *)[self qt]);
	return [NSString fromQString: _qstring];
}

- preloadStyleSheet: (NSString *)url stylesheet: (NSString *)stylesheet
{
static qt_QString * _qstring_stylesheet = 0L;
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_preloadStyleSheet((kde_KHTMLPart *)[self qt], (qt_QString *) [url toQString: &_qstring_url], (qt_QString *) [stylesheet toQString: &_qstring_stylesheet]);
	return self;
}

- preloadScript: (NSString *)url script: (NSString *)script
{
static qt_QString * _qstring_script = 0L;
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_preloadScript((kde_KHTMLPart *)[self qt], (qt_QString *) [url toQString: &_qstring_url], (qt_QString *) [script toQString: &_qstring_script]);
	return self;
}

- (BOOL) restored
{
	return (BOOL) kde_KHTMLPart_restored((kde_KHTMLPart *)[self qt]);
}

- setActiveNode: (DOMNode*)node
{
	kde_KHTMLPart_setActiveNode((kde_KHTMLPart *)[self qt], (kde_DOMNode*) [node qt]);
	return self;
}

- stopAnimations
{
	kde_KHTMLPart_stopAnimations((kde_KHTMLPart *)[self qt]);
	return self;
}

- (NSString *) dcopObjectId
{
static qt_QCString * _qcstring = 0L;
	_qcstring = kde_KHTMLPart_dcopObjectId((kde_KHTMLPart *)[self qt]);
	return [NSString fromQCString: _qcstring];
}

- (KURL*) completeURL: (NSString *)url
{
static qt_QString * _qstring_url = 0L;
	return (KURL*) [QtSupport objectForQtKey: kde_KHTMLPart_completeURL((kde_KHTMLPart *)[self qt], (qt_QString *) [url toQString: &_qstring_url]) withClass: [KURL class] allocatedInObjcWorld: YES];
}

- htmlError: (int)errorCode text: (NSString *)text reqUrl: (KURL*)reqUrl
{
static qt_QString * _qstring_text = 0L;
	kde_KHTMLPart_htmlError((kde_KHTMLPart *)[self qt], (int)errorCode, (qt_QString *) [text toQString: &_qstring_text], (kde_KURL*) [reqUrl qt]);
	return self;
}

- (BOOL) openFile
{
	return (BOOL) kde_KHTMLPart_openFile((kde_KHTMLPart *)[self qt]);
}

- urlSelected: (NSString *)url button: (int)button state: (int)state _target: (NSString *)_target args: (URLArgs*)args
{
static qt_QString * _qstring__target = 0L;
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_urlSelected((kde_KHTMLPart *)[self qt], (qt_QString *) [url toQString: &_qstring_url], (int)button, (int)state, (qt_QString *) [_target toQString: &_qstring__target], (kde_URLArgs*) [args qt]);
	return self;
}

- urlSelected: (NSString *)url button: (int)button state: (int)state _target: (NSString *)_target 
{
static qt_QString * _qstring__target = 0L;
static qt_QString * _qstring_url = 0L;
	kde_KHTMLPart_urlSelected((kde_KHTMLPart *)[self qt], (qt_QString *) [url toQString: &_qstring_url], (int)button, (int)state, (qt_QString *) [_target toQString: &_qstring__target], kde_new_URLArgs());
	return self;
}

- (ReadOnlyPart*) createPart: (QWidget *)parentWidget widgetName: (NSString *)widgetName parent: (QObject *)parent name: (NSString *)name mimetype: (NSString *)mimetype serviceName: (NSString *)serviceName serviceTypes: (NSArray *)serviceTypes params: (NSArray *)params
{
static qt_QStringList * _qlist_params = 0L;
static qt_QStringList * _qlist_serviceTypes = 0L;
static qt_QString * _qstring_serviceName = 0L;
static qt_QString * _qstring_mimetype = 0L;
	return (ReadOnlyPart*) [QtSupport objectForQtKey: kde_KHTMLPart_createPart((kde_KHTMLPart *)[self qt], (qt_QWidget *) [parentWidget qt], (char*) [widgetName cString], (qt_QObject *) [parent qt], (char*) [name cString], (qt_QString *) [mimetype toQString: &_qstring_mimetype], (qt_QString *) [serviceName toQString: &_qstring_serviceName], (qt_QStringList*) [serviceTypes toQStringList: (void *)&_qlist_serviceTypes], (qt_QStringList*) [params toQStringList: (void *)&_qlist_params]) withClass: [ReadOnlyPart class] allocatedInObjcWorld: YES];
}

+ (int) DefaultGUI
{
	return (int) KHTMLPART_DefaultGUI;
}

+ (int) BrowserViewGUI
{
	return (int) KHTMLPART_BrowserViewGUI;
}

@end
