SECTNView Class

class SECTNView: public CView

SECTNView is a CView replacement that adds automatic thumbnailing to your view.

Defined in: SECTNVW.H

Comments

To add thumbnailing support to your view, follow these easy steps:

1.Derive your application view from SECTNView instead of CView.
2.By default, this will automatically create a thumbnail for you. If you would like to optimize the drawing of the thumbnail (the default is to just redraw the entire client area into the thumbnail and scale it down to be displayed as a miniature), you can call IsThumbNailing in your OnDraw method to detect the special thumbnailing case.
3.SECTNView also provides some overridables such as OnPrepareThumbnail that let you set the size and other aspects of the thumbnail image before it is created.

The sample THUMBNL in the \SAMPLES\TOOLKIT\STANDARD\UIEXT\THUMBNL directory demonstrates how to add thumbnail support to your MFC application.

See Also

SECTNBitmap SECTNDC SECTNDocument SECTNFileDialog SECTNWinApp

Class Members

Public Members

BOOL IsThumbNailing()

Determines if the SECTNView is in the process of creating a thumbnail.

Protected Members

virtual void OnDraw(CDC* pDC)

Pure virtual function. OnDraw will be called with an SECTNDC during thumbnail creation.

virtual SECTNBitmap * GetThumbNailBitmap()

Called by SECTNDocument to get the thumbnail bitmap. Override to substantially change the thumbnailing logic.

virtual void OnPrepareThumbNail(CSize * pSize)

Override to specify a size. The default is the size of the client window.

virtual void OnThumbNail(SECTNDC * pDC)

Override to manipulate the SECTNDC for any specialized thumbnail drawing to be performed in your OnDraw routine.