Display Xplained fonts application. More...
#include <assert.h>#include <string.h>#include <hugemem.h>#include <physmem.h>#include <status_codes.h>#include <gfx/gfx.h>#include <gfx/win.h>#include <gfx/wtk.h>#include <gfx/sysfont.h>#include "app_fonts.h"#include <mainloop.h>#include "app_desktop.h"#include "file_loader.h"Go to the source code of this file.
Data Structures | |
| struct | app_fonts |
| Application context. More... | |
Defines | |
Font definitions and configuration | |
| #define | FONT_HEADER_SIZE 16 |
| Number of bytes in the header for the font files loaded from the TSFS. | |
| #define | NUMBER_OF_FONTS 4 |
| Number of fonts present in the application. | |
Page configuration | |
| #define | PAGE_NUM_BLANK_SCREEN 0 |
| Page number containing a blank page used while application is loading the font files. | |
| #define | PAGE_NUM_MIN 1 |
| Number of initial page to show, minimum value. | |
| #define | PAGE_NUM_MAX 5 |
| Number of last page to show, maximum value. | |
Color scheme | |
| #define | COLOR_TEXT GFX_COLOR(255, 255, 255) |
| Color on text strings. | |
| #define | COLOR_TEXT_SHADED GFX_COLOR(150, 150, 150) |
| Color on shaded text strings. | |
| #define | COLOR_BACKGROUND GFX_COLOR(0, 0, 0) |
| Background color. | |
| #define | COLOR_FILL GFX_COLOR(48, 120, 158) |
| Color on filled rectangles, progress bar and horizontal lines. | |
| #define | COLOR_FILL_BORDER GFX_COLOR(30, 74, 98) |
| Color on filled rectangle borders. | |
Text appearance | |
| #define | TEXT_INDENT 5 |
| Number of pixels to indent a string. | |
| #define | TEXT_PADDING 3 |
| Number of pixels to add in front of a string. | |
| #define | TEXT_PADDING_NEWLINE 2 |
| Number of pixels for space after newline. | |
Enumerations | |
| enum | app_fonts_button_ids { BUTTON_NEXT_ID, BUTTON_PREV_ID, BUTTON_QUIT_ID } |
Command event ID. More... | |
Functions | |
| static void | draw_font_box (gfx_coord_t y, struct font *font, char *fontname) |
| Draw a filled box on the screen starting at line y. | |
| static void | screen_draw_splash (void) |
| Draw the fonts introduction splash page. | |
| static void | screen_draw_fonts_info (void) |
| Draw the fonts info page. | |
| static void | screen_draw_fonts_list (void) |
| Draw the fonts list page. | |
| static void | screen_draw_language_info (void) |
| Draw the language information page. | |
| static void | screen_draw_messages (void) |
| Draw the messages in different languages page. | |
| static void | app_fonts_frame_draw_handler (struct win_window *win, const struct win_clip_region *clip) |
| Frame draw handler. | |
| static bool | app_fonts_frame_command_handler (struct wtk_basic_frame *frame, win_command_t command_data) |
| Frame command handler handling the button events. | |
| static status_t | app_fonts_load (void) |
| Schedules loading of next non-loaded font. | |
| static void | app_fonts_load_worker (struct workqueue_task *task) |
| Setup the font objects after loading fonts from the file system. | |
| void | app_fonts_launch (struct workqueue_task *task) |
| Launches the application. | |
Variables | |
| static struct app_fonts * | the_fonts_app |
| Statically allocated context pointer. | |
Font metadata | |
| static struct font | font_ericat |
| Erica Type. | |
| static struct font | font_fixedrus |
| Fixed-width Russian. | |
| static struct font | font_larabie |
| Larabie. | |
| static struct font | font_monofur |
| Monofur. | |
Display Xplained fonts application.
Copyright (C) 2010 Atmel Corporation. All rights reserved.
Definition in file app_fonts.c.
1.6.3