00001 /* 00002 * Sudoku: A plug-in for the Video Disk Recorder 00003 * 00004 * Copyright (C) 2005-2007, Thomas Günther <tom@toms-cafe.de> 00005 * 00006 * This program is free software; you can redistribute it and/or modify 00007 * it under the terms of the GNU General Public License as published by 00008 * the Free Software Foundation; either version 2 of the License, or 00009 * (at your option) any later version. 00010 * 00011 * This program is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU General Public License along 00017 * with this program; if not, write to the Free Software Foundation, Inc., 00018 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 00019 */ 00020 00021 #ifndef VDR_SUDOKU_BITMAP_H 00022 #define VDR_SUDOKU_BITMAP_H 00023 00024 #include "sudoku.h" 00025 #include <vdr/config.h> 00026 #include <vdr/osdbase.h> 00027 #include <vdr/osd.h> 00028 00029 00030 namespace SudokuPlugin 00031 { 00032 00033 //--- class SudokuPlugin::Bitmap --------------------------------------------- 00034 00035 /** Plugin-specific version of the bitmap class */ 00036 class Bitmap : public cBitmap 00037 { 00038 public: 00039 00040 /** Constructor */ 00041 Bitmap(int width, int height); 00042 00043 /** Constructor for a bitmap with frame */ 00044 Bitmap(int width, int height, tColor frameColor, tColor backgroundColor); 00045 00046 /** Write a text into the bitmap. */ 00047 void text(const char* text, bool centered = true); 00048 00049 /** Draw a frame into the bitmap. */ 00050 void frame(int x1, int y1, int x2, int y2, tColor frameColor); 00051 }; 00052 00053 } // namespace SudokuPlugin 00054 00055 #endif // VDR_SUDOKU_BITMAP_H