⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gledef.h

📁 是一个手机功能的模拟程序
💻 H
字号:
/*
 * Copyright (C) AU-System AB, 2000.
 * All rights reserved.
 *
 * This software is covered by the license agreement between
 * the end user and AU-System AB, and may be used and copied
 * only in accordance with the terms of the said agreement.
 *
 * AU-System AB does not assume any responsibility or 
 * liability for any errors or inaccuracies in this 
 * software, or any consequential, incidental or indirect 
 * damage arising out of the use of the Generic Layout Engine 
 * software.
 */

#ifndef __GLE_DEFINES_H__
#define __GLE_DEFINES_H__
   
#include "wipvrsn.h"
#ifndef WIPVRSN_1 
	#define WIPVRSN_1 2
#endif
#ifndef WIPVRSN_2 
	#define WIPVRSN_2 5
#endif



#ifndef min
	#define min(a, b) (((a) < (b)) ? (a) : (b))
#endif
#ifndef max
	#define max(a, b) (((a) > (b)) ? (a) : (b))
#endif

/* The Gle implements the MMIa_newKey and render them into the content */
/* Otherwise the application must implement MMIa_newKey and the key cannot be shown in content */
#define SHOW_KEYS_IN_CONTENT

/* The Gle render wml options into the content and make them selectable */
#define SHOW_OPTIONS_IN_CONTENT

/* define SUPPORT_NOWRAP to allow only breaks and paragraph wraps the content, when nowrap is true*/
#define SUPPORT_NOWRAP 

/* Enables table support */
#define SUPPORT_TABLES
//xmzhou
//#undef SUPPORT_TABLES 

/* Enables vertical scroll and navigating by key up/down */
#define SUPPORT_KEY_NAVIGATION
#undef SUPPORT_PEN_NAVIGATION

typedef enum GleConfigVars
{
  	/* Miscellaneous ---------------------------------------------------------*/
	gle_verticalSpaceBetweenElements = 1,
  	gle_horizontalSpaceBetweenElements = 2,
  	/* Miscellaneous end -----------------------------------------------------*/

    /* Scrolling -------------------------------------------------------------*/
	gle_scroll_pixelsVertical = 16,//8,   //zhaowm 2002.12.02   
	gle_scroll_pixelsHorizontal = 160,//48
    /* Scrolling end ---------------------------------------------------------*/

    /* Images ----------------------------------------------------------------*/
	gle_image_defaultVerticalSpace = 2,  /* Default value of vSpace, when not specified, generally a small, non-zero value */
	gle_image_defaultHorizontalSpace = 2,/* Default value of hSpace, when not specified, generally a small, non-zero value */
	gle_image_normalTextFontHeight = 11, /* Height of the most common font. Used to align images MIDDLE and TOP, related to text*/
    /* Images end ------------------------------------------------------------*/

    /* Fieldsets -------------------------------------------------------------*/
	gle_fieldset_borderExtent = 1,
	gle_fieldset_spaceLeft   = ( 3+gle_fieldset_borderExtent),
	gle_fieldset_spaceRight  = ( 3+gle_fieldset_borderExtent), 
	gle_fieldset_spaceTop    = (10+gle_fieldset_borderExtent),
	gle_fieldset_spaceBottom = ( 2+gle_fieldset_borderExtent),
	gle_fieldset_maxNumberNestled = 2,
    /* Fieldset ends ---------------------------------------------------------*/

	/* Optiongroups ----------------------------------------------------------*/
	#ifdef SHOW_OPTIONS_IN_CONTENT
		gle_optiongroup_tab = 10,
	#endif
	/* Optiongroups end ------------------------------------------------------*/

    /* Table cells -----------------------------------------------------------*/
	#ifdef SUPPORT_TABLES
		gle_cell_defaultHeight = 11, /* Minimum value of row height */
		gle_cell_defaultWidth  = 11, /* Minimum value of column width */
		gle_cell_maxTextWidth  = 50, /* Only images, not texts, can make a column width bigger than this value */
		
		gle_cell_borderExtent   = 1,
		gle_cell_spaceToBorder = 1, 
		
		gle_cell_vBefore  = (gle_cell_borderExtent+gle_cell_spaceToBorder),
		gle_cell_vBetween = (gle_cell_spaceToBorder+gle_cell_borderExtent+gle_cell_spaceToBorder),
		gle_cell_vAfter   = (gle_cell_spaceToBorder+gle_cell_borderExtent),
		
		gle_cell_hBefore  = (gle_cell_borderExtent+gle_cell_spaceToBorder),
		gle_cell_hBetween = (gle_cell_spaceToBorder+gle_cell_borderExtent+gle_cell_spaceToBorder),
		gle_cell_hAfter   = (gle_cell_spaceToBorder+gle_cell_borderExtent),
	#endif    
    /* Table cells end -------------------------------------------------------*/

    cfgGleEnd  /*  at least one compiler doesn't accept a comma after the last enum */
} GleConfigVars;

#define IS_DIGIT_1_TO_9(ch) ((ch>='1' && ch<='9') ? (TRUE) : (FALSE))
/* 1-9 */

#define IS_FORMAT_N(ch) ((ch>='0' && ch<='9') ? (TRUE) : (FALSE)) 
/* 0-9 */

#define IS_FORMAT_UPPERCASE_X(ch) (((ch>='A' && ch<='Z')  || ch==(WCHAR)((UINT8)'

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -