1 /***************************************************************************
2 * Copyright (c) 2024 Microsoft Corporation
3 *
4 * This program and the accompanying materials are made available under the
5 * terms of the MIT License which is available at
6 * https://opensource.org/licenses/MIT.
7 *
8 * SPDX-License-Identifier: MIT
9 **************************************************************************/
10
11
12 /**************************************************************************/
13 /**************************************************************************/
14 /** */
15 /** GUIX Component */
16 /** */
17 /** Prompt Management (Prompt) */
18 /** */
19 /**************************************************************************/
20
21 #define GX_SOURCE_CODE
22
23
24 /* Include necessary system files. */
25
26 #include "gx_api.h"
27 #include "gx_system.h"
28 #include "gx_canvas.h"
29 #include "gx_context.h"
30 #include "gx_widget.h"
31 #include "gx_prompt.h"
32 #include "gx_pixelmap_prompt.h"
33
34
35 /**************************************************************************/
36 /* */
37 /* FUNCTION RELEASE */
38 /* */
39 /* _gx_pixelmap_prompt_draw PORTABLE C */
40 /* 6.1 */
41 /* AUTHOR */
42 /* */
43 /* Kenneth Maxwell, Microsoft Corporation */
44 /* */
45 /* DESCRIPTION */
46 /* */
47 /* This function draws the specified pixelmap prompt, which is a */
48 /* special type of widget. */
49 /* */
50 /* INPUT */
51 /* */
52 /* widget Widget control block */
53 /* */
54 /* OUTPUT */
55 /* */
56 /* None */
57 /* */
58 /* CALLS */
59 /* */
60 /* _gx_widget_children_draw Draw children widgets */
61 /* _gx_prompt_text_draw Draw prompt text */
62 /* _gx_context_pixelmap_get Retrieve pixelmap image */
63 /* _gx_canvas_pixelmap_draw Draw a pixelmap */
64 /* _gx_canvas_pixelmap_tile Tile a pixelmap */
65 /* _gx_prompt_text_draw Draw a text prompt */
66 /* */
67 /* CALLED BY */
68 /* */
69 /* Application Code */
70 /* GUIX Internal Code */
71 /* */
72 /* RELEASE HISTORY */
73 /* */
74 /* DATE NAME DESCRIPTION */
75 /* */
76 /* 05-19-2020 Kenneth Maxwell Initial Version 6.0 */
77 /* 09-30-2020 Kenneth Maxwell Modified comment(s), */
78 /* resulting in version 6.1 */
79 /* */
80 /**************************************************************************/
_gx_pixelmap_prompt_draw(GX_PIXELMAP_PROMPT * prompt)81 VOID _gx_pixelmap_prompt_draw(GX_PIXELMAP_PROMPT *prompt)
82 {
83 /* Draw pixelmap prompt's background. */
84 _gx_pixelmap_prompt_background_draw(prompt);
85
86 /* Draw the text */
87 _gx_prompt_text_draw((GX_PROMPT *)prompt);
88
89 /* Draw children widgets of prompt widget. */
90 _gx_widget_children_draw((GX_WIDGET *)prompt);
91 }
92
93