Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members

DoubleBufferCanvas.h

Go to the documentation of this file.
00001 /*********************************************************************************
00002  *
00003  * Razor! Engine - A modular C++ presentation engine
00004  *
00005  * $Id: DoubleBufferCanvas.h,v 1.2 2000/12/09 10:47:30 christ Exp $
00006  *
00007  * Copyright (c) 2000 Tilo Christ. All Rights Reserved.
00008  *
00009  * This library is free software; you can redistribute it and/or
00010  * modify it under the terms of the GNU Lesser General Public
00011  * License as published by the Free Software Foundation; either
00012  * version 2.1 of the License, or (at your option) any later version.
00013  *
00014  * This library is distributed in the hope that it will be useful,
00015  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00016  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00017  * Lesser General Public License for more details.
00018  *
00019  * You should have received a copy of the GNU Lesser General Public
00020  * License along with this library; if not, write to the Free Software
00021  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00022  *
00023  **********************************************************************************/
00024 
00025 
00026 #ifndef DOUBLEBUFFERCANVAS_H
00027 #define DOUBLEBUFFERCANVAS_H
00028 
00029 #include <PalmOS.h>
00030 #include "Canvas.h"
00031 
00032 
00033 
00034 /**
00035  * DoubleBufferCanvas manages a <EM>double-buffered</EM> canvas into which a user can paint.
00036  */
00037 class DoubleBufferCanvas : public Canvas
00038 {
00039     public:
00040 
00041     DoubleBufferCanvas();
00042     
00043     ~DoubleBufferCanvas();
00044 
00045     void beginDraw(WinLockInitType initMode);
00046         
00047     void endDraw(RectangleType *bounds);
00048 
00049     void show();
00050 
00051     private:
00052     WinHandle deviceDrawWindowH;
00053     WinHandle screenBufferH;
00054 
00055     RectangleType currentBounds;
00056     RectangleType lastBounds;
00057     RectangleType copyBounds;
00058 };
00059 
00060 
00061 #endif

Razor! Engine Developer's Guide. Copyright © by Tilo Christ. All Rights Reserved. Last updated: 17 Dec 2000