zoukankan      html  css  js  c++  java
  • Qt 4.7: QWebInspector Class Reference

    Qt 4.7: QWebInspector Class Reference

    QWebInspector Class Reference

    The QWebInspector class allows the placement and control of a QWebPage's inspector. The inspector can display a page's hierarchy, its loading statistics and the current state of its individual elements. It is mostly used by web developers. More...

     #include <QWebInspector>

    Inherits: QWidget.

    This class was introduced in Qt 4.6.

    Public Functions

    QWebInspector ( QWidget * parent = 0 )
    ~QWebInspector ()
    QWebPage *page () const
    voidsetPage ( QWebPage * page )

    Reimplemented Public Functions

    virtual boolevent ( QEvent * ev )
    virtual QSizesizeHint () const
    • 217 public functions inherited from QWidget
    • 29 public functions inherited from QObject
    • 13 public functions inherited from QPaintDevice

    Reimplemented Protected Functions

    virtual voidcloseEvent ( QCloseEvent * event )
    virtual voidhideEvent ( QHideEvent * event )
    virtual voidresizeEvent ( QResizeEvent * event )
    virtual voidshowEvent ( QShowEvent * event )
    • 37 protected functions inherited from QWidget
    • 7 protected functions inherited from QObject
    • 1 protected function inherited from QPaintDevice

    Additional Inherited Members

    • 58 properties inherited from QWidget
    • 1 property inherited from QObject
    • 19 public slots inherited from QWidget
    • 1 public slot inherited from QObject
    • 1 signal inherited from QWidget
    • 1 signal inherited from QObject
    • 4 static public members inherited from QWidget
    • 5 static public members inherited from QObject
    • 37 protected functions inherited from QWidget
    • 7 protected functions inherited from QObject
    • 1 protected function inherited from QPaintDevice
    • 1 protected slot inherited from QWidget


    Detailed Description

    The QWebInspector class allows the placement and control of a QWebPage's inspector. The inspector can display a page's hierarchy, its loading statistics and the current state of its individual elements. It is mostly used by web developers.

    The QWebPage to be inspected must be specified using the setPage() method.

    A typical use of QWebInspector follows:

         // ...
         QWebPage *page = new QWebPage;
         // ...
    
         QWebInspector *inspector = new QWebInspector;
         inspector->setPage(page);

    A QWebInspector can be made visible either programmatically using setVisible(), or by the user through the attached QWebPage's context menu.

    Note: A QWebInspector will display a blank widget if either:

    Resources

    This class acts mostly as a container and a controller for the inspector. Most of the resources needed by the inspector are owned by the associated QWebPage and are allocated the first time that:

    • an element is inspected
    • the QWebInspector is shown.

    Inspector configuration persistence

    The inspector allows the user to configure some options through its user interface (e.g. the resource tracking "Always enable" option). These settings will be persisted automatically by QtWebKit only if your application previously called QCoreApplication::setOrganizationName() and QCoreApplication::setApplicationName(). See QSettings's default constructor documentation for an explanation of why this is necessary.

    Member Function Documentation

    QWebInspector::QWebInspector ( QWidget * parent = 0 )

    Constructs an unbound QWebInspector with parent as its parent.


    QWebInspector::~QWebInspector ()

    Destroys the inspector.


    void QWebInspector::closeEvent ( QCloseEvent * event ) [virtual protected]

    Reimplemented from QWidget::closeEvent().


    bool QWebInspector::event ( QEvent * ev ) [virtual]

    Reimplemented from QObject::event().


    void QWebInspector::hideEvent ( QHideEvent * event ) [virtual protected]

    Reimplemented from QWidget::hideEvent().


    QWebPage * QWebInspector::page () const

    Returns the inspected QWebPage. If no web page is currently associated, a null pointer is returned.

    See also setPage().


    void QWebInspector::resizeEvent ( QResizeEvent * event ) [virtual protected]

    Reimplemented from QWidget::resizeEvent().


    void QWebInspector::setPage ( QWebPage * page )

    Bind this inspector to the QWebPage to be inspected.

    Notes:

    • There can only be one QWebInspector associated with a QWebPage and vice versa.
    • Calling this method with a null page will break the current association, if any.
    • If page is already associated to another QWebInspector, the association will be replaced and the previous QWebInspector will become unbound

    See also page().

  • 相关阅读:
    table布局与div布局
    HTML一般标签
    jquery
    PDO对象
    分页例题
    投票练习
    封装 链接数据库类
    访问数据方法
    面相对象多态
    面向对象
  • 原文地址:https://www.cnblogs.com/lexus/p/2442336.html
Copyright © 2011-2022 走看看