QGraphicsWebView Class Reference

#include <mw/QtWebKit/qgraphicswebview.h>

class QGraphicsWebView : public QGraphicsWidget, public QGraphicsWidget

The QGraphicsWebView class allows Web content to be added to a GraphicsView.

Inherits from

  • QGraphicsWebView
    Public Properties
    QIcon icon
    boolmodified
    boolresizesToContents
    booltiledBackingStoreFrozen
    QString title
    QUrl url
    qreal zoomFactor
    Public Member Functions
    QGraphicsWebView(QGraphicsItem *)
    ~QGraphicsWebView()
    virtual boolevent(QEvent *)
    boolfindText(const QString &, QWebPage::FindFlags)
    QWebHistory *history()
    QIcon icon()
    virtual QVariant inputMethodQuery(Qt::InputMethodQuery)
    boolisModified()
    boolisTiledBackingStoreFrozen()
    virtual QVariant itemChange(GraphicsItemChange, const QVariant &)
    voidload(const QUrl &)
    voidload(const QNetworkRequest &, QNetworkAccessManager::Operation, const QByteArray &)
    QWebPage *page()
    QAction *pageAction(QWebPage::WebAction)
    virtual voidpaint(QPainter *, const QStyleOptionGraphicsItem *, QWidget *)
    boolresizesToContents()
    voidsetContent(const QByteArray &, const QString &, const QUrl &)
    virtual voidsetGeometry(const QRectF &)
    voidsetHtml(const QString &, const QUrl &)
    voidsetPage(QWebPage *)
    voidsetResizesToContents(bool)
    voidsetTiledBackingStoreFrozen(bool)
    voidsetUrl(const QUrl &)
    voidsetZoomFactor(qreal)
    QWebSettings *settings()
    virtual QSizeF sizeHint(Qt::SizeHint, const QSizeF &)
    QString title()
    voidtriggerPageAction(QWebPage::WebAction, bool)
    virtual voidupdateGeometry()
    QUrl url()
    qreal zoomFactor()
    Protected Member Functions
    virtual voidcontextMenuEvent(QGraphicsSceneContextMenuEvent *)
    virtual voiddragEnterEvent(QGraphicsSceneDragDropEvent *)
    virtual voiddragLeaveEvent(QGraphicsSceneDragDropEvent *)
    virtual voiddragMoveEvent(QGraphicsSceneDragDropEvent *)
    virtual voiddropEvent(QGraphicsSceneDragDropEvent *)
    virtual voidfocusInEvent(QFocusEvent *)
    virtual boolfocusNextPrevChild(bool)
    virtual voidfocusOutEvent(QFocusEvent *)
    virtual voidhoverLeaveEvent(QGraphicsSceneHoverEvent *)
    virtual voidhoverMoveEvent(QGraphicsSceneHoverEvent *)
    virtual voidinputMethodEvent(QInputMethodEvent *)
    virtual voidkeyPressEvent(QKeyEvent *)
    virtual voidkeyReleaseEvent(QKeyEvent *)
    virtual voidmouseDoubleClickEvent(QGraphicsSceneMouseEvent *)
    virtual voidmouseMoveEvent(QGraphicsSceneMouseEvent *)
    virtual voidmousePressEvent(QGraphicsSceneMouseEvent *)
    virtual voidmouseReleaseEvent(QGraphicsSceneMouseEvent *)
    virtual boolsceneEvent(QEvent *)
    virtual voidwheelEvent(QGraphicsSceneWheelEvent *)
    Public Slots
    voidback()
    voidforward()
    voidreload()
    voidstop()
    Public Signals
    voidiconChanged()
    voidlinkClicked(const QUrl &)
    voidloadFinished(bool)
    voidloadProgress(int)
    voidloadStarted()
    voidstatusBarMessage(const QString &)
    voidtitleChanged(const QString &)
    voidurlChanged(const QUrl &)
    Inherited Attributes
    QGraphicsItem::d_ptr
    QGraphicsLayoutItem::d_ptr
    QGraphicsObject::effect
    QGraphicsObject::enabled
    QGraphicsObject::opacity
    QGraphicsObject::parent
    QGraphicsObject::pos
    QGraphicsObject::rotation
    QGraphicsObject::scale
    QGraphicsObject::transformOriginPoint
    QGraphicsObject::visible
    QGraphicsObject::x
    QGraphicsObject::y
    QGraphicsObject::z
    QObject::d_ptr
    QObject::objectName
    QObject::staticQtMetaObject
    Inherited Enumerations
    QGraphicsItem:@167
    QGraphicsItem:CacheMode
    QGraphicsItem:Extension
    QGraphicsItem:GraphicsItemFlag
    QGraphicsItem:PanelModality
    Inherited Functions
    QGraphicsItem::QGraphicsItem(QGraphicsItem *,QGraphicsScene *)
    QGraphicsItem::QGraphicsItem(QGraphicsItemPrivate &,QGraphicsItem *,QGraphicsScene *)
    QGraphicsItem::Q_DECLARE_FLAGS(GraphicsItemFlags,GraphicsItemFlag)
    QGraphicsItem::acceptDrops()const
    QGraphicsItem::acceptHoverEvents()const
    QGraphicsItem::acceptTouchEvents()const
    QGraphicsItem::acceptedMouseButtons()const
    QGraphicsItem::acceptsHoverEvents()const
    QGraphicsItem::addToIndex()
    QGraphicsItem::advance(int)
    QGraphicsItem::boundingRegion(const QTransform &)const
    QGraphicsItem::boundingRegionGranularity()const
    QGraphicsItem::cacheMode()const
    QGraphicsItem::childItems()const
    QGraphicsItem::children()const
    QGraphicsItem::childrenBoundingRect()const
    QGraphicsItem::clearFocus()
    QGraphicsItem::clipPath()const
    QGraphicsItem::collidesWithItem(const QGraphicsItem *,Qt::ItemSelectionMode)const
    QGraphicsItem::collidesWithPath(const QPainterPath &,Qt::ItemSelectionMode)const
    QGraphicsItem::collidingItems(Qt::ItemSelectionMode)const
    QGraphicsItem::commonAncestorItem(const QGraphicsItem *)const
    QGraphicsItem::contains(const QPointF &)const
    QGraphicsItem::cursor()const
    QGraphicsItem::data(int)const
    QGraphicsItem::deviceTransform(const QTransform &)const
    QGraphicsItem::effectiveOpacity()const
    QGraphicsItem::ensureVisible(const QRectF &,int,int)
    QGraphicsItem::ensureVisible(qreal,qreal,qreal,qreal,int,int)
    QGraphicsItem::extension(const QVariant &)const
    QGraphicsItem::filtersChildEvents()const
    QGraphicsItem::flags()const
    QGraphicsItem::focusItem()const
    QGraphicsItem::focusProxy()const
    QGraphicsItem::focusScopeItem()const
    QGraphicsItem::grabKeyboard()
    QGraphicsItem::grabMouse()
    QGraphicsItem::graphicsEffect()const
    QGraphicsItem::group()const
    QGraphicsItem::handlesChildEvents()const
    QGraphicsItem::hasCursor()const
    QGraphicsItem::hasFocus()const
    QGraphicsItem::hide()
    QGraphicsItem::hoverEnterEvent(QGraphicsSceneHoverEvent *)
    QGraphicsItem::inputMethodHints()const
    QGraphicsItem::installSceneEventFilter(QGraphicsItem *)
    QGraphicsItem::isActive()const
    QGraphicsItem::isAncestorOf(const QGraphicsItem *)const
    QGraphicsItem::isBlockedByModalPanel(QGraphicsItem **)const
    QGraphicsItem::isClipped()const
    QGraphicsItem::isEnabled()const
    QGraphicsItem::isObscured()const
    QGraphicsItem::isObscured(const QRectF &)const
    QGraphicsItem::isObscured(qreal,qreal,qreal,qreal)const
    QGraphicsItem::isObscuredBy(const QGraphicsItem *)const
    QGraphicsItem::isPanel()const
    QGraphicsItem::isSelected()const
    QGraphicsItem::isUnderMouse()const
    QGraphicsItem::isVisible()const
    QGraphicsItem::isVisibleTo(const QGraphicsItem *)const
    QGraphicsItem::isWidget()const
    QGraphicsItem::isWindow()const
    QGraphicsItem::itemTransform(const QGraphicsItem *,bool *)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,const QPainterPath &)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,const QPointF &)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,const QPolygonF &)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,const QRectF &)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,qreal,qreal)const
    QGraphicsItem::mapFromItem(const QGraphicsItem *,qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapFromParent(const QPainterPath &)const
    QGraphicsItem::mapFromParent(const QPointF &)const
    QGraphicsItem::mapFromParent(const QPolygonF &)const
    QGraphicsItem::mapFromParent(const QRectF &)const
    QGraphicsItem::mapFromParent(qreal,qreal)const
    QGraphicsItem::mapFromParent(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapFromScene(const QPainterPath &)const
    QGraphicsItem::mapFromScene(const QPointF &)const
    QGraphicsItem::mapFromScene(const QPolygonF &)const
    QGraphicsItem::mapFromScene(const QRectF &)const
    QGraphicsItem::mapFromScene(qreal,qreal)const
    QGraphicsItem::mapFromScene(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectFromItem(const QGraphicsItem *,const QRectF &)const
    QGraphicsItem::mapRectFromItem(const QGraphicsItem *,qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectFromParent(const QRectF &)const
    QGraphicsItem::mapRectFromParent(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectFromScene(const QRectF &)const
    QGraphicsItem::mapRectFromScene(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectToItem(const QGraphicsItem *,const QRectF &)const
    QGraphicsItem::mapRectToItem(const QGraphicsItem *,qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectToParent(const QRectF &)const
    QGraphicsItem::mapRectToParent(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapRectToScene(const QRectF &)const
    QGraphicsItem::mapRectToScene(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,const QPainterPath &)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,const QPointF &)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,const QPolygonF &)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,const QRectF &)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,qreal,qreal)const
    QGraphicsItem::mapToItem(const QGraphicsItem *,qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapToParent(const QPainterPath &)const
    QGraphicsItem::mapToParent(const QPointF &)const
    QGraphicsItem::mapToParent(const QPolygonF &)const
    QGraphicsItem::mapToParent(const QRectF &)const
    QGraphicsItem::mapToParent(qreal,qreal)const
    QGraphicsItem::mapToParent(qreal,qreal,qreal,qreal)const
    QGraphicsItem::mapToScene(const QPainterPath &)const
    QGraphicsItem::mapToScene(const QPointF &)const
    QGraphicsItem::mapToScene(const QPolygonF &)const
    QGraphicsItem::mapToScene(const QRectF &)const
    QGraphicsItem::mapToScene(qreal,qreal)const
    QGraphicsItem::mapToScene(qreal,qreal,qreal,qreal)const
    QGraphicsItem::matrix()const
    QGraphicsItem::moveBy(qreal,qreal)
    QGraphicsItem::opacity()const
    QGraphicsItem::opaqueArea()const
    QGraphicsItem::panel()const
    QGraphicsItem::panelModality()const
    QGraphicsItem::parentItem()const
    QGraphicsItem::parentObject()const
    QGraphicsItem::parentWidget()const
    QGraphicsItem::pos()const
    QGraphicsItem::prepareGeometryChange()
    QGraphicsItem::removeFromIndex()
    QGraphicsItem::removeSceneEventFilter(QGraphicsItem *)
    QGraphicsItem::resetMatrix()
    QGraphicsItem::resetTransform()
    QGraphicsItem::rotate(qreal)
    QGraphicsItem::rotation()const
    QGraphicsItem::scale()const
    QGraphicsItem::scale(qreal,qreal)
    QGraphicsItem::scene()const
    QGraphicsItem::sceneBoundingRect()const
    QGraphicsItem::sceneEventFilter(QGraphicsItem *,QEvent *)
    QGraphicsItem::sceneMatrix()const
    QGraphicsItem::scenePos()const
    QGraphicsItem::sceneTransform()const
    QGraphicsItem::scroll(qreal,qreal,const QRectF &)
    QGraphicsItem::setAcceptDrops(bool)
    QGraphicsItem::setAcceptHoverEvents(bool)
    QGraphicsItem::setAcceptTouchEvents(bool)
    QGraphicsItem::setAcceptedMouseButtons(Qt::MouseButtons)
    QGraphicsItem::setAcceptsHoverEvents(bool)
    QGraphicsItem::setActive(bool)
    QGraphicsItem::setBoundingRegionGranularity(qreal)
    QGraphicsItem::setCacheMode(CacheMode,const QSize &)
    QGraphicsItem::setCursor(const QCursor &)
    QGraphicsItem::setData(int,const QVariant &)
    QGraphicsItem::setEnabled(bool)
    QGraphicsItem::setExtension(Extension,const QVariant &)
    QGraphicsItem::setFiltersChildEvents(bool)
    QGraphicsItem::setFlag(GraphicsItemFlag,bool)
    QGraphicsItem::setFlags(GraphicsItemFlags)
    QGraphicsItem::setFocus(Qt::FocusReason)
    QGraphicsItem::setFocusProxy(QGraphicsItem *)
    QGraphicsItem::setGraphicsEffect(QGraphicsEffect *)
    QGraphicsItem::setGroup(QGraphicsItemGroup *)
    QGraphicsItem::setHandlesChildEvents(bool)
    QGraphicsItem::setInputMethodHints(Qt::InputMethodHints)
    QGraphicsItem::setMatrix(const QMatrix &,bool)
    QGraphicsItem::setOpacity(qreal)
    QGraphicsItem::setPanelModality(PanelModality)
    QGraphicsItem::setParentItem(QGraphicsItem *)
    QGraphicsItem::setPos(const QPointF &)
    QGraphicsItem::setPos(qreal,qreal)
    QGraphicsItem::setRotation(qreal)
    QGraphicsItem::setScale(qreal)
    QGraphicsItem::setSelected(bool)
    QGraphicsItem::setToolTip(const QString &)
    QGraphicsItem::setTransform(const QTransform &,bool)
    QGraphicsItem::setTransformOriginPoint(const QPointF &)
    QGraphicsItem::setTransformOriginPoint(qreal,qreal)
    QGraphicsItem::setTransformations(const QList< QGraphicsTransform * > &)
    QGraphicsItem::setVisible(bool)
    QGraphicsItem::setX(qreal)
    QGraphicsItem::setY(qreal)
    QGraphicsItem::setZValue(qreal)
    QGraphicsItem::shear(qreal,qreal)
    QGraphicsItem::show()
    QGraphicsItem::stackBefore(const QGraphicsItem *)
    QGraphicsItem::supportsExtension(Extension)const
    QGraphicsItem::toGraphicsObject()
    QGraphicsItem::toGraphicsObject()const
    QGraphicsItem::toolTip()const
    QGraphicsItem::topLevelItem()const
    QGraphicsItem::topLevelWidget()const
    QGraphicsItem::transform()const
    QGraphicsItem::transformOriginPoint()const
    QGraphicsItem::transformations()const
    QGraphicsItem::translate(qreal,qreal)
    QGraphicsItem::ungrabKeyboard()
    QGraphicsItem::ungrabMouse()
    QGraphicsItem::unsetCursor()
    QGraphicsItem::update(const QRectF &)
    QGraphicsItem::update(qreal,qreal,qreal,qreal)
    QGraphicsItem::window()const
    QGraphicsItem::x()const
    QGraphicsItem::y()const
    QGraphicsItem::zValue()const
    QGraphicsItem::~QGraphicsItem()
    QGraphicsLayoutItem::QGraphicsLayoutItem(QGraphicsLayoutItem *,bool)
    QGraphicsLayoutItem::QGraphicsLayoutItem(QGraphicsLayoutItemPrivate &)
    QGraphicsLayoutItem::contentsRect()const
    QGraphicsLayoutItem::effectiveSizeHint(Qt::SizeHint,const QSizeF &)const
    QGraphicsLayoutItem::geometry()const
    QGraphicsLayoutItem::graphicsItem()const
    QGraphicsLayoutItem::isLayout()const
    QGraphicsLayoutItem::maximumHeight()const
    QGraphicsLayoutItem::maximumSize()const
    QGraphicsLayoutItem::maximumWidth()const
    QGraphicsLayoutItem::minimumHeight()const
    QGraphicsLayoutItem::minimumSize()const
    QGraphicsLayoutItem::minimumWidth()const
    QGraphicsLayoutItem::ownedByLayout()const
    QGraphicsLayoutItem::parentLayoutItem()const
    QGraphicsLayoutItem::preferredHeight()const
    QGraphicsLayoutItem::preferredSize()const
    QGraphicsLayoutItem::preferredWidth()const
    QGraphicsLayoutItem::setGraphicsItem(QGraphicsItem *)
    QGraphicsLayoutItem::setMaximumHeight(qreal)
    QGraphicsLayoutItem::setMaximumSize(const QSizeF &)
    QGraphicsLayoutItem::setMaximumSize(qreal,qreal)
    QGraphicsLayoutItem::setMaximumWidth(qreal)
    QGraphicsLayoutItem::setMinimumHeight(qreal)
    QGraphicsLayoutItem::setMinimumSize(const QSizeF &)
    QGraphicsLayoutItem::setMinimumSize(qreal,qreal)
    QGraphicsLayoutItem::setMinimumWidth(qreal)
    QGraphicsLayoutItem::setOwnedByLayout(bool)
    QGraphicsLayoutItem::setParentLayoutItem(QGraphicsLayoutItem *)
    QGraphicsLayoutItem::setPreferredHeight(qreal)
    QGraphicsLayoutItem::setPreferredSize(const QSizeF &)
    QGraphicsLayoutItem::setPreferredSize(qreal,qreal)
    QGraphicsLayoutItem::setPreferredWidth(qreal)
    QGraphicsLayoutItem::setSizePolicy(QSizePolicy::Policy,QSizePolicy::Policy,QSizePolicy::ControlType)
    QGraphicsLayoutItem::setSizePolicy(const QSizePolicy &)
    QGraphicsLayoutItem::sizePolicy()const
    QGraphicsLayoutItem::~QGraphicsLayoutItem()
    QGraphicsObject::QGraphicsObject(QGraphicsItemPrivate &,QGraphicsItem *,QGraphicsScene *)
    QGraphicsObject::childrenChanged
    QGraphicsObject::enabledChanged
    QGraphicsObject::grabGesture(Qt::GestureType,Qt::GestureFlags)
    QGraphicsObject::heightChanged
    QGraphicsObject::opacityChanged
    QGraphicsObject::parentChanged
    QGraphicsObject::rotationChanged
    QGraphicsObject::scaleChanged
    QGraphicsObject::ungrabGesture(Qt::GestureType)
    QGraphicsObject::updateMicroFocus
    QGraphicsObject::visibleChanged
    QGraphicsObject::widthChanged
    QGraphicsObject::xChanged
    QGraphicsObject::yChanged
    QGraphicsObject::zChanged
    QGraphicsWidget::QGraphicsWidget(QGraphicsWidgetPrivate &,QGraphicsItem *,QGraphicsScene *,Qt::WindowFlags)
    QGraphicsWidget::changeEvent(QEvent *)
    QGraphicsWidget::close
    QGraphicsWidget::closeEvent(QCloseEvent *)
    QGraphicsWidget::geometryChanged
    QGraphicsWidget::grabKeyboardEvent(QEvent *)
    QGraphicsWidget::grabMouseEvent(QEvent *)
    QGraphicsWidget::hideEvent(QHideEvent *)
    QGraphicsWidget::initStyleOption(QStyleOption *)const
    QGraphicsWidget::layoutChanged
    QGraphicsWidget::moveEvent(QGraphicsSceneMoveEvent *)
    QGraphicsWidget::polishEvent()
    QGraphicsWidget::propertyChange(const QString &,const QVariant &)
    QGraphicsWidget::resizeEvent(QGraphicsSceneResizeEvent *)
    QGraphicsWidget::showEvent(QShowEvent *)
    QGraphicsWidget::ungrabKeyboardEvent(QEvent *)
    QGraphicsWidget::ungrabMouseEvent(QEvent *)
    QGraphicsWidget::windowFrameEvent(QEvent *)
    QGraphicsWidget::windowFrameSectionAt(const QPointF &)const
    QObject::QObject(QObjectPrivate &,QObject *)
    QObject::blockSignals(bool)
    QObject::childEvent(QChildEvent *)
    QObject::children()const
    QObject::connect(const QObject *,const QMetaMethod &,const QObject *,const QMetaMethod &,Qt::ConnectionType)
    QObject::connect(const QObject *,const char *,const QObject *,const char *,Qt::ConnectionType)
    QObject::connect(const QObject *,const char *,const char *,Qt::ConnectionType)const
    QObject::connectNotify(const char *)
    QObject::customEvent(QEvent *)
    QObject::deleteLater
    QObject::destroyed
    QObject::disconnect(const QObject *,const QMetaMethod &,const QObject *,const QMetaMethod &)
    QObject::disconnect(const QObject *,const char *)
    QObject::disconnect(const QObject *,const char *,const QObject *,const char *)
    QObject::disconnect(const char *,const QObject *,const char *)
    QObject::disconnectNotify(const char *)
    QObject::dumpObjectInfo()
    QObject::dumpObjectTree()
    QObject::dynamicPropertyNames()const
    QObject::eventFilter(QObject *,QEvent *)
    QObject::findChild(const QString &)const
    QObject::findChildren(const QRegExp &)const
    QObject::findChildren(const QString &)const
    QObject::inherits(const char *)const
    QObject::installEventFilter(QObject *)
    QObject::isWidgetType()const
    QObject::killTimer(int)
    QObject::moveToThread(QThread *)
    QObject::objectName()const
    QObject::parent()const
    QObject::property(const char *)const
    QObject::receivers(const char *)const
    QObject::registerUserData()
    QObject::removeEventFilter(QObject *)
    QObject::sender()const
    QObject::senderSignalIndex()const
    QObject::setObjectName(const QString &)
    QObject::setParent(QObject *)
    QObject::setProperty(const char *,const QVariant &)
    QObject::setUserData(uint,QObjectUserData *)
    QObject::signalsBlocked()const
    QObject::startTimer(int)
    QObject::thread()const
    QObject::timerEvent(QTimerEvent *)
    QObject::userData(uint)const
    QObject::~QObject()

    Detailed Description

    Since
    4.6
    An instance of this class renders Web content from a URL or supplied as data, using features of the QtWebKit module.

    If the width and height of the item are not set, they will default to 800 and 600, respectively. If the Web page contents is larger than that, scrollbars will be shown if not disabled explicitly.

    Properties Documentation

    icon

    QIcon icon

    the icon associated with the web page currently viewed

    By default, this property contains a null icon.

    See also: iconChanged(), QWebSettings::iconForUrl()

    modified

    boolmodified

    whether the document was modified by the user

    Parts of HTML documents can be editable for example through the {contenteditable} attribute on HTML elements.

    By default, this property is false.

    resizesToContents

    boolresizesToContents

    whether the size of the QGraphicsWebView and its viewport changes to match the contents size

    Since
    4.7
    If this property is set, the QGraphicsWebView will automatically change its size to match the size of the main frame contents. As a result the top level frame will never have scrollbars. It will also make CSS fixed positioning to behave like absolute positioning with elements positioned relative to the document instead of the viewport.

    This property should be used in conjunction with the QWebPage::preferredContentsSize property. If not explicitly set, the preferredContentsSize is automatically set to a reasonable value.

    See also: QWebPage::setPreferredContentsSize()

    tiledBackingStoreFrozen

    booltiledBackingStoreFrozen

    whether the tiled backing store updates its contents

    Since
    4.7
    If the tiled backing store is enabled using QWebSettings::TiledBackingStoreEnabled attribute, this property can be used to disable backing store updates temporarily. This can be useful for example for running a smooth animation that changes the scale of the QGraphicsWebView.

    When the backing store is unfrozen, its contents will be automatically updated to match the current state of the document. If the QGraphicsWebView scale was changed, the backing store is also re-rendered using the new scale.

    If the tiled backing store is not enabled, this property does nothing.

    See also: QWebSettings::TiledBackingStoreEnabled QGraphicsObject::scale

    title

    QString title

    the title of the web page currently viewed

    By default, this property contains an empty string.

    See also: titleChanged()

    url

    QUrl url

    the url of the web page currently viewed

    Setting this property clears the view and loads the URL.

    By default, this property contains an empty, invalid URL.

    See also: load(), urlChanged()

    zoomFactor

    qreal zoomFactor

    the zoom factor for the view

    Constructor & Destructor Documentation

    QGraphicsWebView ( QGraphicsItem * )

    QGraphicsWebView(QGraphicsItem *parent = 0)[explicit]

    Constructs an empty QGraphicsWebView with parent parent.

    See also: load()

    ~QGraphicsWebView ( )

    ~QGraphicsWebView()

    Destroys the item.

    Member Function Documentation

    back ( )

    voidback()[slot]

    Convenience slot that loads the previous document in the list of documents built by navigating links. Does nothing if there is no previous document.

    See also: forward()

    contextMenuEvent ( QGraphicsSceneContextMenuEvent * )

    voidcontextMenuEvent(QGraphicsSceneContextMenuEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::contextMenuEvent(QGraphicsSceneContextMenuEvent *)

    dragEnterEvent ( QGraphicsSceneDragDropEvent * )

    voiddragEnterEvent(QGraphicsSceneDragDropEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::dragEnterEvent(QGraphicsSceneDragDropEvent *)

    dragLeaveEvent ( QGraphicsSceneDragDropEvent * )

    voiddragLeaveEvent(QGraphicsSceneDragDropEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::dragLeaveEvent(QGraphicsSceneDragDropEvent *)

    dragMoveEvent ( QGraphicsSceneDragDropEvent * )

    voiddragMoveEvent(QGraphicsSceneDragDropEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::dragMoveEvent(QGraphicsSceneDragDropEvent *)

    dropEvent ( QGraphicsSceneDragDropEvent * )

    voiddropEvent(QGraphicsSceneDragDropEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::dropEvent(QGraphicsSceneDragDropEvent *)

    event ( QEvent * )

    boolevent(QEvent *)[virtual]

    Reimplemented from QGraphicsWidget::event(QEvent *)

    findText ( const QString &, QWebPage::FindFlags )

    boolfindText(const QString &subString,
    QWebPage::FindFlagsoptions = 0
    )

    Finds the specified string, subString, in the page, using the given options.

    If the HighlightAllOccurrences flag is passed, the function will highlight all occurrences that exist in the page. All subsequent calls will extend the highlight, rather than replace it, with occurrences of the new string.

    If the HighlightAllOccurrences flag is not passed, the function will select an occurrence and all subsequent calls will replace the current occurrence with the next one.

    To clear the selection, just pass an empty string.

    Returns true if subString was found; otherwise returns false.

    See also: QWebPage::selectedText(), QWebPage::selectionChanged()

    focusInEvent ( QFocusEvent * )

    voidfocusInEvent(QFocusEvent *)[protected, virtual]

    Reimplemented from QGraphicsWidget::focusInEvent(QFocusEvent *)

    focusNextPrevChild ( bool )

    boolfocusNextPrevChild(boolnext)[protected, virtual]

    Reimplemented from QGraphicsWidget::focusNextPrevChild(bool)

    focusOutEvent ( QFocusEvent * )

    voidfocusOutEvent(QFocusEvent *)[protected, virtual]

    Reimplemented from QGraphicsWidget::focusOutEvent(QFocusEvent *)

    forward ( )

    voidforward()[slot]

    Convenience slot that loads the next document in the list of documents built by navigating links. Does nothing if there is no next document.

    See also: back()

    history ( )

    QWebHistory *history()const

    Returns a pointer to the view's history of navigated web pages.

    It is equivalent to

    hoverLeaveEvent ( QGraphicsSceneHoverEvent * )

    voidhoverLeaveEvent(QGraphicsSceneHoverEvent *)[protected, virtual]

    Reimplemented from QGraphicsWidget::hoverLeaveEvent(QGraphicsSceneHoverEvent *)

    hoverMoveEvent ( QGraphicsSceneHoverEvent * )

    voidhoverMoveEvent(QGraphicsSceneHoverEvent *)[protected, virtual]

    Reimplemented from QGraphicsWidget::hoverMoveEvent(QGraphicsSceneHoverEvent *)

    icon ( )

    QIcon icon()const

    iconChanged ( )

    voidiconChanged()[signal]

    This signal is emitted whenever the icon of the page is loaded or changes.

    In order for icons to be loaded, you will need to set an icon database path using QWebSettings::setIconDatabasePath().

    See also: icon(), QWebSettings::setIconDatabasePath()

    inputMethodEvent ( QInputMethodEvent * )

    voidinputMethodEvent(QInputMethodEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::inputMethodEvent(QInputMethodEvent *)

    inputMethodQuery ( Qt::InputMethodQuery )

    QVariant inputMethodQuery(Qt::InputMethodQueryquery)const [virtual]

    Reimplemented from QGraphicsItem::inputMethodQuery(Qt::InputMethodQuery)const

    isModified ( )

    boolisModified()const

    isTiledBackingStoreFrozen ( )

    boolisTiledBackingStoreFrozen()const

    itemChange ( GraphicsItemChange, const QVariant & )

    QVariant itemChange(GraphicsItemChangechange,
    const QVariant &value
    )[virtual]

    Reimplemented from QGraphicsWidget::itemChange(GraphicsItemChange,const QVariant &)

    keyPressEvent ( QKeyEvent * )

    voidkeyPressEvent(QKeyEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::keyPressEvent(QKeyEvent *)

    keyReleaseEvent ( QKeyEvent * )

    voidkeyReleaseEvent(QKeyEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::keyReleaseEvent(QKeyEvent *)

    linkClicked ( const QUrl & )

    voidlinkClicked(const QUrl &)[signal]

    This signal is emitted whenever the user clicks on a link and the page's linkDelegationPolicy property is set to delegate the link handling for the specified url.

    See also: QWebPage::linkDelegationPolicy()

    load ( const QUrl & )

    voidload(const QUrl &url)

    Loads the specified url and displays it.

    Note:

    The view remains the same until enough data has arrived to display the new url.

    See also: setUrl(), url(), urlChanged()

    load ( const QNetworkRequest &, QNetworkAccessManager::Operation, const QByteArray & )

    voidload(const QNetworkRequest &request,
    QNetworkAccessManager::Operationoperation = QNetworkAccessManager::GetOperation,
    const QByteArray &body = QByteArray()
    )

    Loads a network request, request, using the method specified in operation.

    body is optional and is only used for POST operations.

    Note:

    The view remains the same until enough data has arrived to display the new url.

    See also: url(), urlChanged()

    loadFinished ( bool )

    voidloadFinished(bool)[signal]

    This signal is emitted when a load of the page is finished. ok will indicate whether the load was successful or any error occurred.

    See also: loadStarted()

    loadProgress ( int )

    voidloadProgress(intprogress)[signal]

    This signal is emitted every time an element in the web page completes loading and the overall loading progress advances.

    This signal tracks the progress of all child frames.

    The current value is provided by progress and scales from 0 to 100, which is the default range of QProgressBar.

    See also: loadStarted(), loadFinished()

    loadStarted ( )

    voidloadStarted()[signal]

    This signal is emitted when a new load of the page is started.

    See also: loadProgress(), loadFinished()

    mouseDoubleClickEvent ( QGraphicsSceneMouseEvent * )

    voidmouseDoubleClickEvent(QGraphicsSceneMouseEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *)

    mouseMoveEvent ( QGraphicsSceneMouseEvent * )

    voidmouseMoveEvent(QGraphicsSceneMouseEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::mouseMoveEvent(QGraphicsSceneMouseEvent *)

    mousePressEvent ( QGraphicsSceneMouseEvent * )

    voidmousePressEvent(QGraphicsSceneMouseEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::mousePressEvent(QGraphicsSceneMouseEvent *)

    mouseReleaseEvent ( QGraphicsSceneMouseEvent * )

    voidmouseReleaseEvent(QGraphicsSceneMouseEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *)

    page ( )

    QWebPage *page()const

    Returns a pointer to the underlying web page.

    See also: setPage()

    pageAction ( QWebPage::WebAction )

    QAction *pageAction(QWebPage::WebActionaction)const

    Returns a pointer to a QAction that encapsulates the specified web action action.

    paint ( QPainter *, const QStyleOptionGraphicsItem *, QWidget * )

    voidpaint(QPainter *,
    const QStyleOptionGraphicsItem *options,
    QWidget *widget = 0
    )[virtual]

    Reimplemented from QGraphicsWidget::paint(QPainter *,const QStyleOptionGraphicsItem *,QWidget *)

    reload ( )

    voidreload()[slot]

    Reloads the current document.

    See also: stop(), loadStarted()

    resizesToContents ( )

    boolresizesToContents()const

    sceneEvent ( QEvent * )

    boolsceneEvent(QEvent *)[protected, virtual]

    Reimplemented from QGraphicsWidget::sceneEvent(QEvent *)

    setContent ( const QByteArray &, const QString &, const QUrl & )

    voidsetContent(const QByteArray &data,
    const QString &mimeType = QString(),
    const QUrl &baseUrl = QUrl()
    )

    Sets the content of the web graphicsitem to the specified content data. If the mimeType argument is empty it is currently assumed that the content is HTML but in future versions we may introduce auto-detection.

    External objects referenced in the content are located relative to baseUrl.

    The data is loaded immediately; external objects are loaded asynchronously.

    See also: load(), setHtml(), QWebFrame::toHtml()

    setGeometry ( const QRectF & )

    voidsetGeometry(const QRectF &rect)[virtual]

    Reimplemented from QGraphicsWidget::setGeometry(const QRectF &)

    setHtml ( const QString &, const QUrl & )

    voidsetHtml(const QString &html,
    const QUrl &baseUrl = QUrl()
    )

    Sets the content of the web view to the specified html.

    External objects such as stylesheets or images referenced in the HTML document are located relative to baseUrl.

    The html is loaded immediately; external objects are loaded asynchronously.

    When using this method, WebKit assumes that external resources such as JavaScript programs or style sheets are encoded in UTF-8 unless otherwise specified. For example, the encoding of an external script can be specified through the charset attribute of the HTML script tag. Alternatively, the encoding can also be specified by the web server.

    This is a convenience function equivalent to setContent(html, "text/html", baseUrl).

    CAUTION:

    This function works only for HTML, for other mime types (i.e. XHTML, SVG) setContent() should be used instead.

    See also: load(), setContent(), QWebFrame::toHtml(), QWebFrame::setContent()

    setPage ( QWebPage * )

    voidsetPage(QWebPage *)

    Makes page the new web page of the web graphicsitem.

    The parent QObject of the provided page remains the owner of the object. If the current document is a child of the web view, it will be deleted.

    See also: page()

    setResizesToContents ( bool )

    voidsetResizesToContents(boolenabled)

    setTiledBackingStoreFrozen ( bool )

    voidsetTiledBackingStoreFrozen(boolfrozen)

    setUrl ( const QUrl & )

    voidsetUrl(const QUrl &)

    setZoomFactor ( qreal )

    voidsetZoomFactor(qreal)

    settings ( )

    QWebSettings *settings()const

    Returns a pointer to the view/page specific settings object.

    It is equivalent to

    See also: QWebSettings::globalSettings()

    sizeHint ( Qt::SizeHint, const QSizeF & )

    QSizeF sizeHint(Qt::SizeHintwhich,
    const QSizeF &constraint
    )const [virtual]

    Reimplemented from QGraphicsWidget::sizeHint(Qt::SizeHint,const QSizeF &)const

    statusBarMessage ( const QString & )

    voidstatusBarMessage(const QString &message)[signal]

    This signal is emitted when the statusbar text is changed by the page.

    stop ( )

    voidstop()[slot]

    Convenience slot that stops loading the document.

    See also: reload(), loadFinished()

    title ( )

    QString title()const

    titleChanged ( const QString & )

    voidtitleChanged(const QString &)[signal]

    This signal is emitted whenever the title of the main frame changes.

    See also: title()

    triggerPageAction ( QWebPage::WebAction, bool )

    voidtriggerPageAction(QWebPage::WebActionaction,
    boolchecked = false
    )

    Triggers the specified action. If it is a checkable action the specified checked state is assumed.

    See also: pageAction()

    updateGeometry ( )

    voidupdateGeometry()[virtual]

    Reimplemented from QGraphicsWidget::updateGeometry()

    url ( )

    QUrl url()const

    urlChanged ( const QUrl & )

    voidurlChanged(const QUrl &)[signal]

    This signal is emitted when the url of the view changes.

    See also: url(), load()

    wheelEvent ( QGraphicsSceneWheelEvent * )

    voidwheelEvent(QGraphicsSceneWheelEvent *)[protected, virtual]

    Reimplemented from QGraphicsItem::wheelEvent(QGraphicsSceneWheelEvent *)

    zoomFactor ( )

    qreal zoomFactor()const