Fonts

Dependents:   Sample_program_Font72

Committer:
WaleedElmughrabi
Date:
Mon Jan 07 20:12:16 2019 +0000
Revision:
0:6456c97209ed
Fonts

Who changed what in which revision?

UserRevisionLine numberNew contents of line
WaleedElmughrabi 0:6456c97209ed 1 /**
WaleedElmughrabi 0:6456c97209ed 2 ******************************************************************************
WaleedElmughrabi 0:6456c97209ed 3 * @file fonts.h
WaleedElmughrabi 0:6456c97209ed 4 * @author MCD Application Team
WaleedElmughrabi 0:6456c97209ed 5 * @version V1.0.0
WaleedElmughrabi 0:6456c97209ed 6 * @date 18-February-2014
WaleedElmughrabi 0:6456c97209ed 7 * @brief Header for fonts.c file
WaleedElmughrabi 0:6456c97209ed 8 ******************************************************************************
WaleedElmughrabi 0:6456c97209ed 9 * @attention
WaleedElmughrabi 0:6456c97209ed 10 *
WaleedElmughrabi 0:6456c97209ed 11 * <h2><center>&copy; COPYRIGHT(c) 2014 STMicroelectronics</center></h2>
WaleedElmughrabi 0:6456c97209ed 12 *
WaleedElmughrabi 0:6456c97209ed 13 * Redistribution and use in source and binary forms, with or without modification,
WaleedElmughrabi 0:6456c97209ed 14 * are permitted provided that the following conditions are met:
WaleedElmughrabi 0:6456c97209ed 15 * 1. Redistributions of source code must retain the above copyright notice,
WaleedElmughrabi 0:6456c97209ed 16 * this list of conditions and the following disclaimer.
WaleedElmughrabi 0:6456c97209ed 17 * 2. Redistributions in binary form must reproduce the above copyright notice,
WaleedElmughrabi 0:6456c97209ed 18 * this list of conditions and the following disclaimer in the documentation
WaleedElmughrabi 0:6456c97209ed 19 * and/or other materials provided with the distribution.
WaleedElmughrabi 0:6456c97209ed 20 * 3. Neither the name of STMicroelectronics nor the names of its contributors
WaleedElmughrabi 0:6456c97209ed 21 * may be used to endorse or promote products derived from this software
WaleedElmughrabi 0:6456c97209ed 22 * without specific prior written permission.
WaleedElmughrabi 0:6456c97209ed 23 *
WaleedElmughrabi 0:6456c97209ed 24 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
WaleedElmughrabi 0:6456c97209ed 25 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
WaleedElmughrabi 0:6456c97209ed 26 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
WaleedElmughrabi 0:6456c97209ed 27 * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
WaleedElmughrabi 0:6456c97209ed 28 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
WaleedElmughrabi 0:6456c97209ed 29 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
WaleedElmughrabi 0:6456c97209ed 30 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
WaleedElmughrabi 0:6456c97209ed 31 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
WaleedElmughrabi 0:6456c97209ed 32 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
WaleedElmughrabi 0:6456c97209ed 33 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
WaleedElmughrabi 0:6456c97209ed 34 *
WaleedElmughrabi 0:6456c97209ed 35 ******************************************************************************
WaleedElmughrabi 0:6456c97209ed 36 */
WaleedElmughrabi 0:6456c97209ed 37
WaleedElmughrabi 0:6456c97209ed 38 /* Define to prevent recursive inclusion -------------------------------------*/
WaleedElmughrabi 0:6456c97209ed 39 #ifndef __FONTS_H
WaleedElmughrabi 0:6456c97209ed 40 #define __FONTS_H
WaleedElmughrabi 0:6456c97209ed 41
WaleedElmughrabi 0:6456c97209ed 42 /* Max size of bitmap will based on a font24 (17x24) */
WaleedElmughrabi 0:6456c97209ed 43 #define MAX_HEIGHT_FONT 72
WaleedElmughrabi 0:6456c97209ed 44 #define MAX_WIDTH_FONT 51
WaleedElmughrabi 0:6456c97209ed 45 #define OFFSET_BITMAP 54
WaleedElmughrabi 0:6456c97209ed 46
WaleedElmughrabi 0:6456c97209ed 47 #ifdef __cplusplus
WaleedElmughrabi 0:6456c97209ed 48 extern "C" {
WaleedElmughrabi 0:6456c97209ed 49 #endif
WaleedElmughrabi 0:6456c97209ed 50
WaleedElmughrabi 0:6456c97209ed 51 /* Includes ------------------------------------------------------------------*/
WaleedElmughrabi 0:6456c97209ed 52 #include <stdint.h>
WaleedElmughrabi 0:6456c97209ed 53
WaleedElmughrabi 0:6456c97209ed 54 typedef struct _tFont
WaleedElmughrabi 0:6456c97209ed 55 {
WaleedElmughrabi 0:6456c97209ed 56 const uint8_t *table;
WaleedElmughrabi 0:6456c97209ed 57 uint16_t Width;
WaleedElmughrabi 0:6456c97209ed 58 uint16_t Height;
WaleedElmughrabi 0:6456c97209ed 59
WaleedElmughrabi 0:6456c97209ed 60 } sFONT;
WaleedElmughrabi 0:6456c97209ed 61 extern sFONT Font72;
WaleedElmughrabi 0:6456c97209ed 62 extern sFONT Font24;
WaleedElmughrabi 0:6456c97209ed 63 extern sFONT Font20;
WaleedElmughrabi 0:6456c97209ed 64 extern sFONT Font16;
WaleedElmughrabi 0:6456c97209ed 65 extern sFONT Font12;
WaleedElmughrabi 0:6456c97209ed 66 extern sFONT Font8;
WaleedElmughrabi 0:6456c97209ed 67
WaleedElmughrabi 0:6456c97209ed 68 #ifdef __cplusplus
WaleedElmughrabi 0:6456c97209ed 69 }
WaleedElmughrabi 0:6456c97209ed 70 #endif
WaleedElmughrabi 0:6456c97209ed 71
WaleedElmughrabi 0:6456c97209ed 72 #endif /* __FONTS_H */
WaleedElmughrabi 0:6456c97209ed 73
WaleedElmughrabi 0:6456c97209ed 74
WaleedElmughrabi 0:6456c97209ed 75 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
WaleedElmughrabi 0:6456c97209ed 76