Colors.h
上传用户:hmc_gdtv
上传日期:2013-08-04
资源大小:798k
文件大小:2k
源码类别:

Windows Mobile

开发平台:

Visual C++

  1. /*
  2.  * Copyright (c) 2001,2002,2003 Mike Matsnev.  All Rights Reserved.
  3.  *
  4.  * Redistribution and use in source and binary forms, with or without
  5.  * modification, are permitted provided that the following conditions
  6.  * are met:
  7.  *
  8.  * 1. Redistributions of source code must retain the above copyright
  9.  *    notice immediately at the beginning of the file, without modification,
  10.  *    this list of conditions, and the following disclaimer.
  11.  * 2. Redistributions in binary form must reproduce the above copyright
  12.  *    notice, this list of conditions and the following disclaimer in the
  13.  *    documentation and/or other materials provided with the distribution.
  14.  * 3. Absolutely no warranty of function or purpose is made by the author
  15.  *    Mike Matsnev.
  16.  *
  17.  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
  18.  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  19.  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  20.  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
  21.  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
  22.  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
  23.  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
  24.  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  25.  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
  26.  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  27.  * 
  28.  * $Id: Colors.h,v 1.9.2.3 2004/10/29 15:18:46 mike Exp $
  29.  * 
  30.  */
  31. #ifndef COLORS_H
  32. #define COLORS_H
  33. struct ColorItem {
  34.   const TCHAR *name;
  35.   COLORREF value;
  36.   COLORREF tempval;
  37. };
  38. extern ColorItem g_colors[];
  39. extern int g_color_profile;
  40. // first four are A_ attributes
  41. #define CI_NORM 0
  42. #define CI_BG 8
  43. #define CI_HBG 9
  44. #define CI_GAUGE 10
  45. #define CI_TOCL0 11
  46. #define CI_TOCBM 12
  47. #define CI_UINP 13
  48. #define CI_UINPBG 14
  49. #define CI_AS 15
  50. #define C_NORM (g_colors[CI_NORM].value)
  51. #define C_TCOLOR(c) (g_colors[(c)].value)
  52. #define C_BG (g_colors[CI_BG].value)
  53. #define C_HBG (g_colors[CI_HBG].value)
  54. #define C_GAUGE (g_colors[CI_GAUGE].value)
  55. #define C_TOCL0 (g_colors[CI_TOCL0].value)
  56. #define C_TOCBM (g_colors[CI_TOCBM].value)
  57. #define C_UINP (g_colors[CI_UINP].value)
  58. #define C_UINPBG (g_colors[CI_UINPBG].value)
  59. #define C_AS (g_colors[CI_AS].value)
  60. void SaveColors();
  61. void LoadColors();
  62. bool NextColorProfile();
  63. void AddColorProfileNames(void *menu,int startpos);
  64. #endif