Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

[Index] [Glossary] [Previous] [Next]



Location: w32std.h
Link against: ws32.lib

Class RDrawableWindow

RDrawableWindow

Support

Supported from 5.0

Description

Handle to a drawable window.

RDrawableWindows are RWindowBase which can be drawn to.

This class is not intended for user derivation, and cannot be initialised directly. The two concrete derived classes, RWindow and RBackedUpWindow, allow drawing but use different protocols because RWindow relies on the client to redraw invalid areas.

Derivation

MWsClientClassBase class for all classes whose objects are clients of the window server engine
RDrawableWindowHandle to a drawable window
RWindowBaseClient-side handle to a server-side window
RWindowTreeNodeHandle to a node in the server-side window tree

Defined in RDrawableWindow:
RDrawableWindow(), Scroll()

Inherited from MWsClientClass:
WsHandle()

Inherited from RWindowBase:
Activate(), AddKeyRect(), AllocPointerMoveBuffer(), CancelPointerRepeatEventRequest(), ClaimPointerGrab(), DisablePointerMoveBuffer(), DiscardPointerMoveBuffer(), DisplayMode(), EnableBackup(), EnablePointerMoveBuffer(), FadeBehind(), FreePointerMoveBuffer(), InquireOffset(), IsFaded(), IsNonFading(), MoveToGroup(), PasswordWindow(), PointerFilter(), Position(), RemoveAllKeyRects(), RequestPointerRepeatEvent(), RetrievePointerMoveBuffer(), SetCornerType(), SetExtentErr(), SetPointerCapture(), SetPointerGrab(), SetPosition(), SetRequiredDisplayMode(), SetShadowDisabled(), SetShadowHeight(), SetShape(), SetSizeErr(), SetVisible(), Size(), TCaptureDisabled, TCaptureDragDrop, TCaptureEnabled, TCaptureFlagAllGroups, TCaptureFlagDragDrop, TCaptureFlagEnabled, TCaptureFlags

Inherited from RWindowTreeNode:
Child(), ClearPointerCursor(), Close(), Destroy(), DisableErrorMessages(), DisableFocusChangeEvents(), DisableGroupChangeEvents(), DisableModifierChangedEvents(), DisableOnEvents(), EFadeIncludeChildren, EFadeWindowOnly, EnableErrorMessages(), EnableFocusChangeEvents(), EnableGroupChangeEvents(), EnableModifierChangedEvents(), EnableOnEvents(), FullOrdinalPosition(), NextSibling(), OrdinalPosition(), OrdinalPriority(), Parent(), PrevSibling(), SetCustomPointerCursor(), SetFaded(), SetNonFading(), SetOrdinalPosition(), SetPointerCursor(), TFadeControl


Construction and destruction


RDrawableWindow()

protected: RDrawableWindow();

Description

Protected default constructor which creates a sessionless, uninitialised drawable-window handle.

Handles to server-side objects must be created in a session in order to be operational; this constructor is merely a convenience to allow the handle to be stored as a data member. See RWindowTreeNode::RWindowTreeNode() for details of how the complete setup of a handle field may be deferred until the window server session is known


RDrawableWindow()

protected: RDrawableWindow(RWsSession& aWs);

Description

Protected default constructor which creates an initialised drawable-window handle within a server session.

Parameters

RWsSession &aWs

Window server session.

[Top]


Member functions


Scroll()

void Scroll(const TPoint &aOffset);

Description

Scrolls the window contents by an offset.

All parts of an RWindow window are either drawn with content copied from another part of the window or are invalidated. Areas are invalidated when the source content of the scroll would be outside the window or obscured behind another window. The areas that are invalidated are not blanked off.

For example, if the window is scrolled towards the right, then there is no content (from outside the window) to move into area on the left hand side. This area is invalidated. Similarly, no content can be scrolled out from under an obscuring window, so the area from beneath the obscuring window is also invalidated.

Note that for an RBackUpWindow, the contents of areas obscured by other windows are stored. In this case the window contents are scrolled out from "underneath" the obscuring window. In the example above the area on the left was invalidated but for this type of window the area simply contains its old pre-scroll contents.

Parameters

const TPoint& aOffset

Scroll offset, in pixels. Positive values cause the window contents to move downwards/right. Negative values cause contents to move upwards/left.


Scroll()

void Scroll(const TRect& aClipRect, const TPoint& aOffset);

Description

Scrolls the contents of a clip rectangle, independent of the other contents of the window.

This overload behaves in exactly the same way as the previous function, except that the scroll region is a clipping rectangle rather than the whole window. All parts of the clipping rectangle are either drawn with content copied from another part of the rectangle or are invalidated.

The RBackUpWindow behaviour is also similar to the behaviour in the function above.

Parameters

const TRect& aClipRect

Rectangle to which scrolling is to be clipped

const TPoint& aOffset

Scroll offset, in pixels. Positive values cause the window contents to move downwards and right. Negative values cause contents to move upwards and left.


Scroll()

void Scroll(const TPoint& aOffset, const TRect& aRect);

Description

Scrolls a rectangle within a window.

This function effectively moves the specified rectangle by the given offset with respect to the window. The destination rectangle may overlap and cover the old rectangle.

Note that if the source of this rectangle is an invalid area, ie it is obscured or lies outside the window, then this area in the destination rectangle will be invalidated.

Parameters

const TPoint& aOffset

Scroll offset, in pixels. Positive values cause the window contents to move downwards and right. Negative values cause contents to move upwards and left.

const TRect& aRect

The source rectangle for the scroll.


Scroll()

void Scroll(const TRect& aClipRect, const TPoint& aOffset, const TRect& aRect);

Description

Scrolls the contents of a source rectangle within a clipping rectangle.

The source rectangle is effectively copied from one position to another, with both the source and destination clipped to the clipping rectangle. Hence if the source and destination rectangles are inside the clipping region then this function behaves exactly like the previous function overload. However if the source or destination for the scrolled rectangle intersect the clipping rectangle then the function behaves similarly to the second function overload — with regards to invalidated regions etc.

Parameters

const TRect& aClipRect

Rectangle to which scrolling is to be clipped.

const TPoint& aOffset

Scroll offset, in pixels. Positive values cause the window contents to move downwards and right. Negative values cause contents to move upwards and left.

const TRect& aRect

Source rectangle for the scroll.