Qt 4.8
Public Functions | Properties | List of all members
EGLNullWSWindowSurface Class Reference

#include <eglnullwswindowsurface.h>

Inheritance diagram for EGLNullWSWindowSurface:
QWSGLWindowSurface QWSWindowSurface QWindowSurface

Public Functions

 EGLNullWSWindowSurface (QWidget *widget)
 
 EGLNullWSWindowSurface ()
 
virtual QImage image () const
 Implement this function to return an image of the top-level window. More...
 
virtual bool isValid () const
 Implement this function to return true if the surface is a valid surface for the given top-level window; otherwise return false. More...
 
virtual QString key () const
 Implement this function to return a string that uniquely identifies the class of this surface. More...
 
virtual QPaintDevicepaintDevice ()
 Implement this function to return the appropriate paint device. More...
 
virtual ~EGLNullWSWindowSurface ()
 
- Public Functions inherited from QWSGLWindowSurface
QGLContextcontext () const
 Returns the QGLContext of the window surface. More...
 
 QWSGLWindowSurface (QWidget *widget)
 Constructs an empty QWSGLWindowSurface for the given top-level window. More...
 
 QWSGLWindowSurface ()
 Constructs an empty QWSGLWindowSurface. More...
 
void setContext (QGLContext *context)
 Sets the QGLContext for this window surface to context. More...
 
 ~QWSGLWindowSurface ()
 Destroys the QWSGLWindowSurface object and frees any allocated resources. More...
 
- Public Functions inherited from QWSWindowSurface
virtual void beginPaint (const QRegion &)
 This function is called before painting onto the surface begins, with the region in which the painting will occur. More...
 
const QRegion clipRegion () const
 Returns the region currently visible on the screen. More...
 
virtual void endPaint (const QRegion &)
 This function is called after painting onto the surface has ended, with the region in which the painting was performed. More...
 
virtual void flush (QWidget *widget, const QRegion &region, const QPoint &offset)
 Flushes the given region from the specified widget onto the screen. More...
 
bool isBuffered () const
 Returns true if the QWSWindowSurface::Buffered is set; otherwise returns false. More...
 
bool isOpaque () const
 Returns true if the QWSWindowSurface::Opaque is set; otherwise returns false. More...
 
bool isRegionReserved () const
 Returns true if the QWSWindowSurface::RegionReserved is set; otherwise returns false. More...
 
virtual bool lock (int timeout=-1)
 
virtual bool move (const QPoint &offset)
 Move the surface with the given offset. More...
 
virtual QRegion move (const QPoint &offset, const QRegion &newClip)
 Move the surface with the given offset. More...
 
virtual QPoint painterOffset () const
 Returns the offset to be used when painting. More...
 
virtual QByteArray permanentState () const
 Implement this function to return the data required for creating a server-side representation of the surface. More...
 
 QWSWindowSurface ()
 Constructs an empty surface. More...
 
 QWSWindowSurface (QWidget *widget)
 Constructs an empty surface for the given top-level widget. More...
 
virtual void releaseSurface ()
 
void setClipRegion (const QRegion &)
 Sets the region currently visible on the screen to be the given clip region. More...
 
virtual void setGeometry (const QRect &rect)
 Sets the currently allocated area to be the given rect. More...
 
virtual void setGeometry (const QRect &rect, const QRegion &mask)
 
virtual void setPermanentState (const QByteArray &state)
 Implement this function to attach a server-side surface instance to the corresponding client side instance using the given data. More...
 
virtual void setTransientState (const QByteArray &state)
 
SurfaceFlags surfaceFlags () const
 Returns the surface flags describing the contents of this surface. More...
 
virtual QByteArray transientState () const
 
virtual void unlock ()
 
int winId () const
 
 ~QWSWindowSurface ()
 
- Public Functions inherited from QWindowSurface
virtual QImagebuffer (const QWidget *widget)
 Returns a QImage pointer which represents the actual buffer the widget is drawn into or 0 if this is unavailable. More...
 
virtual WindowSurfaceFeatures features () const
 
QRect geometry () const
 Returns the currently allocated area on the screen. More...
 
virtual QPixmap grabWidget (const QWidget *widget, const QRect &rectangle=QRect()) const
 Returns a QPixmap generated from the part of the backing store corresponding to widget. More...
 
bool hasFeature (WindowSurfaceFeature feature) const
 
virtual QPoint offset (const QWidget *widget) const
 Returns the offset of widget in the coordinates of this window surface. More...
 
 QWindowSurface (QWidget *window, bool setDefaultSurface=true)
 Constructs an empty surface for the given top-level window. More...
 
QRect rect (const QWidget *widget) const
 Returns the rectangle for widget in the coordinates of this window surface. More...
 
virtual bool scroll (const QRegion &area, int dx, int dy)
 Scrolls the given area dx pixels to the right and dy downward; both dx and dy may be negative. More...
 
void setStaticContents (const QRegion &region)
 
QRegion staticContents () const
 
QWidgetwindow () const
 Returns a pointer to the top-level window associated with this surface. More...
 
virtual ~QWindowSurface ()
 Destroys this surface. More...
 

Properties

QWidgetwidget
 

Additional Inherited Members

- Public Types inherited from QWSWindowSurface
enum  SurfaceFlag { RegionReserved = 0x1, Buffered = 0x2, Opaque = 0x4 }
 This enum is used to describe the window surface's contents. More...
 
- Public Types inherited from QWindowSurface
enum  WindowSurfaceFeature { PartialUpdates = 0x00000001, PreservedContents = 0x00000002, StaticContents = 0x00000004, AllFeatures = 0xffffffff }
 
- Protected Functions inherited from QWSWindowSurface
void setSurfaceFlags (SurfaceFlags type)
 Sets the surface flags describing the contents of this surface, to be the given flags. More...
 
void setWinId (int id)
 
- Protected Functions inherited from QWindowSurface
bool hasStaticContents () const
 

Detailed Description

Definition at line 47 of file eglnullwswindowsurface.h.

Constructors and Destructors

◆ EGLNullWSWindowSurface() [1/2]

EGLNullWSWindowSurface::EGLNullWSWindowSurface ( QWidget widget)

Definition at line 50 of file eglnullwswindowsurface.cpp.

51  :
53  widget(w)
54 {
56 }
QWSGLWindowSurface()
Constructs an empty QWSGLWindowSurface.
void setSurfaceFlags(SurfaceFlags type)
Sets the surface flags describing the contents of this surface, to be the given flags.
Flags

◆ EGLNullWSWindowSurface() [2/2]

EGLNullWSWindowSurface::EGLNullWSWindowSurface ( )

Definition at line 58 of file eglnullwswindowsurface.cpp.

59  : widget(0)
60 {
62 }
void setSurfaceFlags(SurfaceFlags type)
Sets the surface flags describing the contents of this surface, to be the given flags.
Flags

◆ ~EGLNullWSWindowSurface()

EGLNullWSWindowSurface::~EGLNullWSWindowSurface ( )
virtual

Definition at line 64 of file eglnullwswindowsurface.cpp.

64 {}

Functions

◆ image()

QImage EGLNullWSWindowSurface::image ( ) const
virtual

Implement this function to return an image of the top-level window.

See also
geometry()

Implements QWSWindowSurface.

Definition at line 81 of file eglnullwswindowsurface.cpp.

82 {
83  return QImage();
84 }
The QImage class provides a hardware-independent image representation that allows direct access to th...
Definition: qimage.h:87

◆ isValid()

bool EGLNullWSWindowSurface::isValid ( ) const
virtual

Implement this function to return true if the surface is a valid surface for the given top-level window; otherwise return false.

Since
4.3
See also
window(), key()

Implements QWSWindowSurface.

Definition at line 76 of file eglnullwswindowsurface.cpp.

77 {
78  return qobject_cast<QGLWidget *>(window());
79 }
T qobject_cast(QObject *object)
Definition: qobject.h:375
The QGLWidget class is a widget for rendering OpenGL graphics.
Definition: qgl.h:474
QWidget * window() const
Returns a pointer to the top-level window associated with this surface.

◆ key()

QString EGLNullWSWindowSurface::key ( ) const
virtual

Implement this function to return a string that uniquely identifies the class of this surface.

See also
window(), isValid()

Implements QWSWindowSurface.

Definition at line 66 of file eglnullwswindowsurface.cpp.

67 {
68  return QLatin1String(PluginName);
69 }
const char *const PluginName
QLatin1String(DBUS_INTERFACE_DBUS))) Q_GLOBAL_STATIC_WITH_ARGS(QString

◆ paintDevice()

QPaintDevice * EGLNullWSWindowSurface::paintDevice ( )
virtual

Implement this function to return the appropriate paint device.

Implements QWSWindowSurface.

Definition at line 71 of file eglnullwswindowsurface.cpp.

72 {
73  return widget;
74 }

Properties

◆ widget

QWidget* EGLNullWSWindowSurface::widget
private

Definition at line 60 of file eglnullwswindowsurface.h.

Referenced by paintDevice().


The documentation for this class was generated from the following files: