• Skip to content
  • Skip to link menu
KDE 4.0 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KHTML

khtml_part.h

Go to the documentation of this file.
00001 // -*- c-basic-offset: 2 -*-
00002 /* This file is part of the KDE project
00003  *
00004  * Copyright (C) 1998, 1999 Torben Weis <weis@kde.org>
00005  *                     1999-2001 Lars Knoll <knoll@kde.org>
00006  *                     1999-2001 Antti Koivisto <koivisto@kde.org>
00007  *                     2000-2001 Simon Hausmann <hausmann@kde.org>
00008  *                     2000-2001 Dirk Mueller <mueller@kde.org>
00009  *                     2000 Stefan Schimanski <1Stein@gmx.de>
00010  *
00011  * This library is free software; you can redistribute it and/or
00012  * modify it under the terms of the GNU Library General Public
00013  * License as published by the Free Software Foundation; either
00014  * version 2 of the License, or (at your option) any later version.
00015  *
00016  * This library is distributed in the hope that it will be useful,
00017  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00018  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00019  * Library General Public License for more details.
00020  *
00021  * You should have received a copy of the GNU Library General Public License
00022  * along with this library; see the file COPYING.LIB.  If not, write to
00023  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00024  * Boston, MA 02110-1301, USA.
00025  */
00026 #ifndef __khtml_part_h__
00027 #define __khtml_part_h__
00028 
00029 #include "dom/dom_doc.h"
00030 #include "dom/dom2_range.h"
00031 
00032 #include <kparts/part.h>
00033 #include <kparts/browserextension.h>
00034 #include <kdemacros.h>
00035 #include <kfind.h>
00036 #include <kfinddialog.h>
00037 #include <klocalizedstring.h>
00038 #include <kencodingdetector.h>
00039 #include <QtCore/QRegExp>
00040 
00041 class KHTMLPartPrivate;
00042 class KHTMLPartBrowserExtension;
00043 class KJSProxy;
00044 class KHTMLView;
00045 class KHTMLSettings;
00046 class KJavaAppletContext;
00047 class KJSErrorDlg;
00048 
00049 namespace DOM
00050 {
00051   class HTMLDocument;
00052   class HTMLDocumentImpl;
00053   class DocumentImpl;
00054   class HTMLTitleElementImpl;
00055   class HTMLFrameElementImpl;
00056   class HTMLIFrameElementImpl;
00057   class HTMLObjectElementImpl;
00058   class HTMLFormElementImpl;
00059   class HTMLAnchorElementImpl;
00060   class HTMLMetaElementImpl;
00061   class NodeImpl;
00062   class Node;
00063   class HTMLEventListener;
00064   class EventListener;
00065   class HTMLPartContainerElementImpl;
00066   class HTMLObjectBaseElementImpl;  
00067 }
00068 
00069 namespace KJS
00070 {
00071   class Interpreter;
00072   class HTMLElement;
00073 }
00074 
00075 namespace khtml
00076 {
00077   class DocLoader;
00078   class RenderPart;
00079   class ChildFrame;
00080   class MousePressEvent;
00081   class MouseDoubleClickEvent;
00082   class MouseMoveEvent;
00083   class MouseReleaseEvent;
00084   class DrawContentsEvent;
00085   class CachedObject;
00086   class RenderWidget;
00087   class CSSStyleSelector;
00088   class HTMLTokenizer;
00089   class XMLTokenizer;
00090 }
00091 
00092 namespace KJS {
00093     class Window;
00094     class WindowFunc;
00095     class ExternalFunc;
00096     class JSEventListener;
00097     class JSLazyEventListener;
00098     class JSNodeFilter;
00099     class DOMDocument;
00100     class SourceFile;
00101     class ScheduledAction;
00102 //    class DebugDocument;
00103 }
00104 
00105 namespace KParts
00106 {
00107   class PartManager;
00108   class LiveConnectExtension;
00109 }
00110 
00111 namespace KWallet
00112 {
00113   class Wallet;
00114 }
00115 
00186 class KHTML_EXPORT KHTMLPart : public KParts::ReadOnlyPart
00187 {
00188   Q_OBJECT
00189   friend class KHTMLView;
00190   friend class DOM::HTMLTitleElementImpl;
00191   friend class DOM::HTMLFrameElementImpl;
00192   friend class DOM::HTMLIFrameElementImpl;
00193   friend class DOM::HTMLObjectBaseElementImpl;
00194   friend class DOM::HTMLObjectElementImpl;
00195   friend class DOM::HTMLAnchorElementImpl;
00196   friend class DOM::HTMLMetaElementImpl;
00197   friend class DOM::NodeImpl;
00198   friend class KHTMLRun;
00199   friend class DOM::HTMLFormElementImpl;
00200   friend class KJS::Window;
00201   friend class KJS::ScheduledAction;
00202   friend class KJS::JSNodeFilter;
00203   friend class KJS::WindowFunc;
00204   friend class KJS::ExternalFunc;
00205   friend class KJS::JSEventListener;
00206   friend class KJS::JSLazyEventListener;
00207   friend class KJS::DOMDocument;
00208   friend class KJS::HTMLElement;
00209   friend class KJS::SourceFile;
00210 //  friend class KJS::DebugDocument;
00211   friend class KJSProxy;
00212   friend class KHTMLPartBrowserExtension;
00213   friend class DOM::DocumentImpl;
00214   friend class DOM::HTMLDocumentImpl;
00215   friend class KHTMLPartBrowserHostExtension;
00216   friend class khtml::HTMLTokenizer;
00217   friend class khtml::XMLTokenizer;
00218   friend class khtml::RenderWidget;
00219   friend class khtml::CSSStyleSelector;
00220   friend class KHTMLPartIface;
00221   friend class KHTMLPartFunction;
00222   friend class KHTMLPopupGUIClient;
00223 
00224   Q_PROPERTY( bool javaScriptEnabled READ jScriptEnabled WRITE setJScriptEnabled )
00225   Q_PROPERTY( bool javaEnabled READ javaEnabled WRITE setJavaEnabled )
00226   Q_PROPERTY( bool dndEnabled READ dndEnabled WRITE setDNDEnabled )
00227   Q_PROPERTY( bool pluginsEnabled READ pluginsEnabled WRITE setPluginsEnabled )
00228 
00229   /*
00230    *
00231    * Don't add setOnlyLocalReferences here. It shouldn't be accessible via DBus.
00232    *
00233    **/
00234   Q_PROPERTY( bool modified READ isModified )
00235   Q_PROPERTY( QString encoding READ encoding WRITE setEncoding )
00236   Q_PROPERTY( QString lastModified READ lastModified )
00237   Q_PROPERTY( bool metaRefreshEnabled READ metaRefreshEnabled WRITE setMetaRefreshEnabled )
00238 
00239 public:
00240   enum GUIProfile { DefaultGUI, BrowserViewGUI /* ... */ };
00241 
00254   KHTMLPart( QWidget *parentWidget = 0,
00255              QObject *parent = 0, GUIProfile prof = DefaultGUI );
00274   KHTMLPart( KHTMLView *view, QObject *parent = 0, GUIProfile prof = DefaultGUI );
00275 
00279   virtual ~KHTMLPart();
00280 
00286   virtual bool openUrl( const KUrl &url );
00287 
00291   virtual bool closeUrl();
00292 
00299   virtual void showError( KJob* job );
00300 
00304   DOM::HTMLDocument htmlDocument() const;
00305 
00309   DOM::Document document() const;
00310 
00314    QString documentSource() const;
00315 
00319   DOM::Node activeNode() const;
00320 
00324   KParts::BrowserExtension *browserExtension() const;
00325   KParts::BrowserHostExtension *browserHostExtension() const;
00326 
00330   KHTMLView *view() const;
00331 
00338   void setJScriptEnabled( bool enable );
00339 
00344   bool jScriptEnabled() const;
00345 
00363   KJS::Interpreter *jScriptInterpreter();
00364 
00376   void setStatusMessagesEnabled( bool enable );
00377 
00381   bool statusMessagesEnabled() const;
00382 
00386   void setMetaRefreshEnabled( bool enable );
00387 
00391   bool metaRefreshEnabled() const;
00392 
00397   QVariant executeScript( const DOM::Node &n, const QString &script );
00398 
00403   void setDNDEnabled( bool b );
00404 
00408   bool dndEnabled() const;
00409 
00416   void setJavaEnabled( bool enable );
00417 
00421   bool javaEnabled() const;
00422 
00426   void setPluginsEnabled( bool enable );
00427 
00431   bool pluginsEnabled() const;
00432 
00439   void setAutoloadImages( bool enable );
00446   bool autoloadImages() const;
00447 
00464   void setOnlyLocalReferences( bool enable );
00465 
00470   bool onlyLocalReferences() const;
00471 
00474   bool isCaretMode() const;
00475 
00479   bool isEditable() const;
00480 
00493   void setCaretPosition(DOM::Node node, long offset, bool extendSelection = false);
00494 
00498   enum CaretDisplayPolicy {
00499       CaretVisible, 
00500       CaretInvisible, 
00501       CaretBlink 
00502   };
00503 
00507   CaretDisplayPolicy caretDisplayPolicyNonFocused() const;
00508 
00518   void setCaretDisplayPolicyNonFocused(CaretDisplayPolicy policy);
00519 
00520 #ifndef KDE_NO_COMPAT
00521   KUrl baseURL() const;
00522 #endif
00523 
00527   KUrl backgroundURL() const;
00528 
00532   void scheduleRedirection( int delay, const QString &url, bool lockHistory = true );
00533 
00556   virtual void begin( const KUrl &url = KUrl(), int xOffset = 0, int yOffset = 0 );
00557 
00578   virtual void write( const char *str, int len = -1 );
00579 
00587   virtual void write( const QString &str );
00588 
00592   virtual void end();
00593 
00594   /*
00595    * Prints the current HTML page laid out for the printer.
00596    *
00597    * (not implemented at the moment)
00598    */
00599   //    void print(QPainter *, int pageHeight, int pageWidth);
00600 
00604   void paint( QPainter *, const QRect &, int = 0, bool * = 0 );
00605 
00612   bool setEncoding( const QString &name, bool override = false );
00613 
00619   QString encoding() const;
00620 
00630   void setUserStyleSheet( const KUrl &url );
00631 
00641   void setUserStyleSheet( const QString &styleSheet );
00642 
00643 public:
00644 
00650   void setStandardFont( const QString &name );
00651 
00658   void setFixedFont( const QString &name );
00659 
00667   bool gotoAnchor( const QString &name );
00668 
00674   bool nextAnchor();
00675 
00679   bool prevAnchor();
00680 
00684   void setURLCursor( const QCursor &c );
00685 
00689   QCursor urlCursor() const;
00690 
00694   enum FindOptions
00695   {
00696     FindLinksOnly   = 1 * KFind::MinimumUserOption,
00697     FindNoPopups    = 2 * KFind::MinimumUserOption
00698     //FindIncremental = 4 * KFind::MinimumUserOption
00699   };
00700 
00705   void findText();
00706 
00714   void findText( const QString &str, long options, QWidget *parent = 0,
00715                  KFindDialog *findDialog = 0 );
00716 
00720   void findTextBegin();
00721 
00727   bool findTextNext( bool reverse = false );
00728 
00738   void setZoomFactor(int percent);
00739 
00743   int zoomFactor() const;
00744 
00754   void setFontScaleFactor(int percent);
00755 
00759   int fontScaleFactor() const;
00760 
00764   virtual QString selectedText() const;
00765 
00772   QString selectedTextAsHTML() const;
00773 
00777   DOM::Range selection() const;
00778 
00789   void selection(DOM::Node &startNode, long &startOffset,
00790         DOM::Node &endNode, long &endOffset) const;
00791 
00795   void setSelection( const DOM::Range & );
00796 
00805   bool hasSelection() const;
00806 
00810   void selectAll();
00811 
00817   void show();
00818 
00824   void hide();
00825 
00830   KParts::PartManager *partManager();
00831 
00839   virtual void saveState( QDataStream &stream );
00849   virtual void restoreState( QDataStream &stream );
00850 
00857   DOM::Node nodeUnderMouse() const;
00858 
00866   DOM::Node nonSharedNodeUnderMouse() const;
00867 
00871   const KHTMLSettings *settings() const;
00872 
00879   KHTMLPart *parentPart();
00880 
00886   QStringList frameNames() const;
00887 
00888   QList<KParts::ReadOnlyPart*> frames() const;
00889 
00893   KHTMLPart *findFrame( const QString &f );
00894 
00902   KHTMLPart *findFrameParent( KParts::ReadOnlyPart *callingPart, const QString &f, khtml::ChildFrame **childFrame=0 );
00903 
00909   KParts::ReadOnlyPart *currentFrame() const;
00910 
00917   bool frameExists( const QString &frameName );
00918 
00922   KJSProxy *framejScript(KParts::ReadOnlyPart *framePart);
00923 
00927   KParts::ReadOnlyPart *findFramePart( const QString &f );
00933   void setJSStatusBarText( const QString &text );
00934 
00940   void setJSDefaultStatusBarText( const QString &text );
00941 
00947   QString jsStatusBarText() const;
00948 
00954   QString jsDefaultStatusBarText() const;
00955 
00959   QString referrer() const;
00960 
00964   QString pageReferrer() const;
00965 
00969   QString lastModified() const;
00970 
00974   void preloadStyleSheet( const QString &url, const QString &stylesheet );
00975 
00979   void preloadScript( const QString &url, const QString &script );
00980 
00984   bool restored() const;
00985 
00986   // ### KDE4 remove me
00987   enum FormNotification { NoNotification = 0, Before, Only, Unused=255 };
00993   void setFormNotification(FormNotification fn);
00994 
01000   FormNotification formNotification() const;
01001 
01008   KUrl toplevelURL();
01009 
01015   bool isModified() const;
01016 
01020   void setSuppressedPopupIndicator( bool enable, KHTMLPart *originPart = 0 );
01021 
01025   bool inProgress() const;
01026 
01027 Q_SIGNALS:
01031   void onURL( const QString &url );
01032 
01038   void popupMenu( const QString &url, const QPoint &point );
01039 
01043   void selectionChanged();
01044 
01052   void nodeActivated( const DOM::Node & );
01053 
01056   void docCreated();
01057 
01068   void caretPositionChanged(const DOM::Node &node, long offset);
01069 
01070 
01076   void formSubmitNotification(const char *action, const QString& url,
01077                   const QByteArray& formData, const QString& target,
01078                   const QString& contentType, const QString& boundary);
01079 
01083   void configurationChanged();
01084 
01085 
01086 protected:
01087 
01092   KUrl completeURL( const QString &url );
01093 
01100   void htmlError( int errorCode, const QString& text, const KUrl& reqUrl );
01101 
01102   virtual void customEvent( QEvent *event );
01103 
01107   virtual void khtmlMousePressEvent( khtml::MousePressEvent *event );
01111   virtual void khtmlMouseDoubleClickEvent( khtml::MouseDoubleClickEvent * );
01115   virtual void khtmlMouseMoveEvent( khtml::MouseMoveEvent *event );
01119   virtual void khtmlMouseReleaseEvent( khtml::MouseReleaseEvent *event );
01123   virtual void khtmlDrawContentsEvent( khtml::DrawContentsEvent * );
01124 
01128   virtual void guiActivateEvent( KParts::GUIActivateEvent *event );
01129 
01133   virtual bool openFile();
01134 
01135   virtual bool urlSelected( const QString &url, int button, int state,
01136                             const QString &_target,
01137                             const KParts::OpenUrlArguments& args = KParts::OpenUrlArguments(),
01138                             const KParts::BrowserArguments& browserArgs = KParts::BrowserArguments() );
01139 
01148   virtual KParts::ReadOnlyPart *createPart( QWidget *parentWidget,
01149                                             QObject *parent,
01150                                             const QString &mimetype, QString &serviceName,
01151                                             QStringList &serviceTypes, const QStringList &params);
01152 
01153   // This is for RenderPartObject. We want to ask the 'download plugin?'
01154   // question only once per mimetype
01155   bool pluginPageQuestionAsked( const QString& mimetype ) const;
01156   void setPluginPageQuestionAsked( const QString& mimetype );
01157 
01158   enum PageSecurity { NotCrypted, Encrypted, Mixed };
01159   void setPageSecurity( PageSecurity sec );
01160 
01164   virtual bool doOpenStream( const QString& mimeType );
01165 
01169   virtual bool doWriteStream( const QByteArray& data );
01170 
01174   virtual bool doCloseStream();
01175 
01176 public Q_SLOTS:
01177 
01187   void setActiveNode( const DOM::Node &node );
01188 
01192   void stopAnimations();
01193 
01201   QVariant executeScript( const QString &script );
01202 
01212   void setCaretMode(bool enable);
01213 
01224   void setEditable(bool enable);
01225 
01241   void setCaretVisible(bool show);
01242 
01243   // ### KDE4 FIXME:
01244   //          Remove this and make the one below protected+virtual slot.
01245   //          Warning: this is effectively "internal".  Be careful.
01246   void submitFormProxy( const char *action, const QString &url,
01247                         const QByteArray &formData,
01248                         const QString &target,
01249                         const QString& contentType = QString(),
01250                         const QString& boundary = QString() );
01251 
01252 protected Q_SLOTS:
01253 
01259   virtual void slotFinished( KJob* );
01260 
01261 protected:
01267   virtual void startingJob( KIO::Job * ) {}
01268 
01269 private Q_SLOTS:
01270 
01274   void reparseConfiguration();
01275 
01279   void slotData( KIO::Job*, const QByteArray &data );
01283   void slotInfoMessage( KJob*, const QString& msg );
01287   void slotRestoreData( const QByteArray &data );
01291   void slotFinishedParsing();
01295   void slotRedirect();
01299   void slotRedirection( KIO::Job*, const KUrl& );
01303   void slotDebugScript();
01307   void slotDebugDOMTree();
01311   void slotDebugRenderTree();
01315   void slotStopAnimations();
01319   virtual void slotViewDocumentSource();
01323   virtual void slotViewFrameSource();
01327   void slotViewPageInfo();
01331   virtual void slotSaveBackground();
01335   virtual void slotSaveDocument();
01339   virtual void slotSaveFrame();
01343   virtual void slotSecurity();
01347   virtual void slotSetEncoding(const QString &);
01348 
01352   virtual void slotUseStylesheet();
01353 
01354   virtual void slotFind();
01355   virtual void slotFindDone(); // ### remove me
01356   virtual void slotFindDialogDestroyed();
01357   void slotFindNext();
01358   void slotFindPrev();
01359   void slotFindAheadText();
01360   void slotFindAheadLink();
01361 
01362   void slotIncZoom();
01363   void slotDecZoom();
01364   void slotIncZoomFast();
01365   void slotDecZoomFast();
01366   
01367   void slotIncFontSize();
01368   void slotDecFontSize();
01369   void slotIncFontSizeFast();
01370   void slotDecFontSizeFast();
01371 
01372   void slotLoadImages();
01373   void slotWalletClosed();
01374   void launchWalletManager();
01375   void walletMenu();
01376 
01380   void submitFormAgain();
01381 
01385   void updateActions();
01389   void slotPartRemoved( KParts::Part *part );
01393   void slotActiveFrameChanged( KParts::Part *part );
01397   void slotChildStarted( KIO::Job *job );
01401   void slotChildCompleted();
01405   void slotChildCompleted( bool );
01409   void slotParentCompleted();
01413   void slotChildURLRequest( const KUrl &url, const KParts::OpenUrlArguments&, const KParts::BrowserArguments &args );
01417   void slotChildDocCreated();
01421   void slotRequestFocus( KParts::ReadOnlyPart * );
01422   void slotLoaderRequestStarted( khtml::DocLoader*, khtml::CachedObject* obj);
01423   void slotLoaderRequestDone( khtml::DocLoader*, khtml::CachedObject *obj );
01424   void checkCompleted();
01425 
01429   void slotAutoScroll();
01430 
01431   void slotPrintFrame();
01432 
01433   void slotSelectAll();
01434 
01438   void slotProgressUpdate();
01439 
01440   /*
01441    * @internal
01442    */
01443   void slotJobPercent( KJob*, unsigned long );
01444 
01445   /*
01446    * @internal
01447    */
01448   void slotJobDone( KJob* );
01449 
01450   /*
01451    * @internal
01452    */
01453   void slotUserSheetStatDone( KJob* );
01454 
01455   /*
01456    * @internal
01457    */
01458   void slotJobSpeed( KJob*, unsigned long );
01459 
01463   void slotClearSelection();
01464 
01468   void slotZoomView( int );
01469 
01473   void slotHighlight( const QString &, int index, int length );
01474 
01478   void slotAutomaticDetectionLanguage(KEncodingDetector::AutoDetectScript scri);
01479 
01483   void slotToggleCaretMode();
01484 
01488   void suppressedPopupMenu();
01489 
01493   void togglePopupPassivePopup();
01494 
01498   void showSuppressedPopups();
01499 
01503   void launchJSConfigDialog();
01504 
01508   void launchJSErrorDialog();
01509 
01513   void removeJSErrorExtension();
01514 
01518   void disableJSErrorExtension();
01519 
01523   void jsErrorDialogContextMenu();
01524 
01530   void restoreScrollPosition();
01531 
01532   void walletOpened(KWallet::Wallet*);
01533 
01534 private:
01535 
01536   KJSErrorDlg *jsErrorExtension();
01537 
01538   enum StatusBarPriority { BarDefaultText, BarHoverText, BarOverrideText };
01539   void setStatusBarText( const QString& text, StatusBarPriority p);
01540 
01541   bool restoreURL( const KUrl &url );
01542   void resetFromScript();
01543   void emitSelectionChanged();
01544   void onFirstData(const QString& firstData);
01545   // Returns whether callingHtmlPart may access this part
01546   bool checkFrameAccess(KHTMLPart *callingHtmlPart);
01547   bool openUrlInFrame(const KUrl &url, const KParts::OpenUrlArguments& arguments, const KParts::BrowserArguments &browserArguments);
01548   void startAutoScroll();
01549   void stopAutoScroll();
01550   void overURL( const QString &url, const QString &target, bool shiftPressed = false );
01551   void resetHoverText(); // Undo overURL and reset HoverText
01552 
01553   bool processObjectRequest( khtml::ChildFrame *child, const KUrl &url, const QString &mimetype );
01554   KParts::LiveConnectExtension *liveConnectExtension( const DOM::NodeImpl *);
01555 
01556   KWallet::Wallet* wallet();
01557 
01558   void openWallet(DOM::HTMLFormElementImpl*);
01559   void saveToWallet(const QString& key, const QMap<QString,QString>& data);
01560   void dequeueWallet(DOM::HTMLFormElementImpl*);
01561 
01562   void enableFindAheadActions(bool);
01563 
01567   // ### KDE4 FIXME:
01568   //          It is desirable to be able to filter form submissions as well.
01569   //          For instance, forms can have a target and an inheriting class
01570   //          might want to filter based on the target.  Make this protected
01571   //          and virtual, or provide a better solution.
01572   //          See the web_module for the sidebar for an example where this is
01573   //          necessary.
01574   void submitForm( const char *action, const QString &url, const QByteArray &formData,
01575                    const QString &target, const QString& contentType = QString(),
01576                    const QString& boundary = QString() );
01577 
01578   void popupMenu( const QString &url );
01579 
01580   void init( KHTMLView *view, GUIProfile prof );
01581 
01582 
01583   void clear();
01584 
01585   bool scheduleScript( const DOM::Node &n, const QString& script);
01586 
01587   QVariant crossFrameExecuteScript(const QString& target, const QString& script);
01588   QVariant executeScheduledScript();
01589 
01590   bool requestFrame( DOM::HTMLPartContainerElementImpl *frame, const QString &url, const QString &frameName,
01591                      const QStringList &args = QStringList(), bool isIFrame = false );
01592 
01600   QString requestFrameName();
01601 
01602   bool requestObject(  DOM::HTMLPartContainerElementImpl *frame, const QString &url, const QString &serviceType,
01603                       const QStringList &args = QStringList() );
01604 
01605   bool requestObject( khtml::ChildFrame *child, const KUrl &url,
01606                       const KParts::OpenUrlArguments &args = KParts::OpenUrlArguments(),
01607                       const KParts::BrowserArguments& browserArgs = KParts::BrowserArguments() );
01608 
01609   DOM::EventListener *createHTMLEventListener( QString code, QString name, DOM::NodeImpl *node );
01610 
01611   DOM::HTMLDocumentImpl *docImpl() const;
01612   DOM::DocumentImpl *xmlDocImpl() const;
01613   khtml::ChildFrame *frame( const QObject *obj );
01614 
01615   khtml::ChildFrame *recursiveFrameRequest( KHTMLPart *callingHtmlPart, const KUrl &url,
01616                                             const KParts::OpenUrlArguments& args, const KParts::BrowserArguments &browserArgs,
01617                                             bool callParent = true );
01618 
01619   bool checkLinkSecurity( const KUrl &linkURL,const KLocalizedString &message = KLocalizedString(), const QString &button = QString() );
01620   QVariant executeScript( const QString& filename, int baseLine, const DOM::Node &n, const QString& script );
01621 
01622   KJSProxy *jScript();
01623 
01624   KHTMLPart *opener();
01625   long cacheId() const;
01626   void setOpener( KHTMLPart *_opener );
01627   bool openedByJS();
01628   void setOpenedByJS( bool _openedByJS );
01629 
01630   void checkEmitLoadEvent();
01631   void emitLoadEvent();
01632 
01633   bool initFindNode( bool selection, bool reverse, bool fromCursor );
01634 
01635   void extendSelection( DOM::NodeImpl* node, int offset, DOM::Node& selectionNode, long& selectionOffset, bool right, bool paragraph );
01645   void extendSelectionTo(int x, int y, int absX, int absY, const DOM::Node &innerNode);
01649   bool isExtendingSelection() const;
01650   KEncodingDetector *createDecoder();
01651   QString defaultEncoding() const;
01652 
01654   QString defaultExtension() const;
01655 
01659   void zoomIn(const int stepping[], int count);
01663   void zoomOut(const int stepping[], int count);
01664 
01665   void incFontSize(const int stepping[], int count);
01666 
01667   void decFontSize(const int stepping[], int count);
01668 
01669   void emitCaretPositionChanged(const DOM::Node &node, long offset);
01670 
01671   void setDebugScript( bool enable );
01672 
01673   void runAdFilter();
01674 
01675   KHTMLPartPrivate *d;
01676   friend class KHTMLPartPrivate;
01677 };
01678 
01679 
01680 #endif

KHTML

Skip menu "KHTML"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • KIO
  • KIOSlave
  • KJS
  •   WTF
  • KJSEmbed
  • KNewStuff
  • KParts
  • Kross
  • KUtils
  • Nepomuk
  •   core
  • Phonon
  •   Backend
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal