2 This file defines the Human Interface Infrastructure protocol which will
3 be used by resources which want to publish IFR/Font/String data and have it
4 collected by the Configuration engine.
6 Copyright (c) 2007 - 2008, Intel Corporation
7 All rights reserved. This program and the accompanying materials
8 are licensed and made available under the terms and conditions of the BSD License
9 which accompanies this distribution. The full text of the license may be found at
10 http://opensource.org/licenses/bsd-license.php
12 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
13 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
15 Module Name: FrameworkHii.h
17 @par Revision Reference:
18 This protocol is defined in HII spec 0.92.
22 #ifndef _FRAMEWORK_HII_H_
23 #define _FRAMEWORK_HII_H_
28 // To get EFI_GRAPHICS_OUTPUT_BLT_PIXEL,
29 // is defined in MdePkg/Protocol/GraphicsOutput.h
31 #include <Protocol/GraphicsOutput.h>
34 // In both EDK and EDK II, incompatbile change is done to Framework HII protocol.
35 // This change should cause a change of GUID in both of code and HII spec. But we
36 // update the GUID in code in EDK and EDK II. The 0.92 spec is not updated. This
39 #define EFI_HII_PROTOCOL_GUID \
41 0xd7ad636e, 0xb997, 0x459b, {0xbf, 0x3f, 0x88, 0x46, 0x89, 0x79, 0x80, 0xe1} \
44 #define EFI_HII_COMPATIBILITY_PROTOCOL_GUID \
46 0x5542cce1, 0xdf5c, 0x4d1b, { 0xab, 0xca, 0x36, 0x4f, 0x77, 0xd3, 0x99, 0xfb } \
50 typedef UINT16 STRING_REF
;
51 typedef UINT32 RELOFST
;
53 typedef struct _EFI_HII_PROTOCOL EFI_HII_PROTOCOL
;
55 typedef UINT16 FRAMEWORK_EFI_HII_HANDLE
;
60 #define NARROW_CHAR 0xFFF0
61 #define WIDE_CHAR 0xFFF1
62 #define NON_BREAKING_CHAR 0xFFF2
64 #define GLYPH_HEIGHT 19
66 #define EFI_HII_FONT 1
67 #define EFI_HII_STRING 2
69 #define EFI_HII_KEYBOARD 4
70 #define EFI_HII_HANDLES 5
71 #define EFI_HII_VARIABLE 6
72 #define EFI_HII_DEVICE_PATH 7
75 // References to string tokens must use this macro to enable scanning for
78 #define STRING_TOKEN(t) t
81 // The following types are currently defined:
82 // EFI_FORM_ID has been defined in UEFI spec.
84 typedef UINT16 EFI_FORM_LABEL
;
89 // The header found at the start of each package.
94 } EFI_HII_PACK_HEADER
;
97 // A form list consists of a large variety of structure
98 // possibilities so to represent the binary blob of data
99 // associated with a package of forms, we will assume a
100 // pointer to a self-describing data buffer.
103 EFI_HII_PACK_HEADER Header
;
107 EFI_HII_PACK_HEADER Header
; // Must be filled in
108 EFI_HANDLE ImageHandle
; // Must be filled in
109 EFI_HANDLE DeviceHandle
; // Optional
110 EFI_HANDLE ControllerHandle
; // Optional
111 EFI_HANDLE CallbackHandle
; // Optional
112 EFI_HANDLE COBExportHandle
; // Optional
113 } EFI_HII_HANDLE_PACK
;
116 // ********************************************************
117 // EFI_VARIABLE_CONTENTS
118 // ********************************************************
121 EFI_HII_PACK_HEADER Header
;
122 EFI_GUID VariableGuid
;
123 UINT32 VariableNameLength
;
126 // CHAR16 VariableName[]; //Null-terminated
128 } EFI_HII_VARIABLE_PACK
;
131 // ********************************************************
132 // EFI_DEVICE_PATH_PACK
133 // ********************************************************
136 EFI_HII_PACK_HEADER Header
;
138 // EFI_DEVICE_PATH DevicePath[];
140 } EFI_HII_DEVICE_PATH_PACK
;
143 // ********************************************************
144 // EFI_HII_DATA_TABLE
145 // ********************************************************
148 FRAMEWORK_EFI_HII_HANDLE HiiHandle
;
149 EFI_GUID PackageGuid
;
150 UINT32 DataTableSize
;
151 UINT32 IfrDataOffset
;
152 UINT32 StringDataOffset
;
153 UINT32 VariableDataOffset
;
154 UINT32 DevicePathOffset
;
155 UINT32 NumberOfVariableData
;
156 UINT32 NumberOfLanguages
;
158 // EFI_HII_DEVICE_PATH_PACK DevicePath[];
159 // EFI_HII_VARIABLE_PACK VariableData[];
160 // EFI_HII_IFR_PACK IfrData;
161 // EFI_HII_STRING_PACK StringData[];
163 } EFI_HII_DATA_TABLE
;
166 // ********************************************************
167 // EFI_HII_EXPORT_TABLE
168 // ********************************************************
171 UINT32 NumberOfHiiDataTables
;
174 // EFI_HII_DATA_TABLE HiiDataTable[];
176 } EFI_HII_EXPORT_TABLE
;
179 BOOLEAN FormSetUpdate
; // If TRUE, next variable is significant
180 EFI_PHYSICAL_ADDRESS FormCallbackHandle
; // If not 0, will update Formset with this info
181 BOOLEAN FormUpdate
; // If TRUE, next variable is significant
182 UINT16 FormValue
; // specify which form is to be updated if FormUpdate value is TRUE.
183 STRING_REF FormTitle
; // If not 0, will update Form with this info
184 UINT16 DataCount
; // The number of Data entries in this structure
185 UINT8
*Data
; // An array of 1+ op-codes, specified by DataCount
186 } FRAMEWORK_EFI_HII_UPDATE_DATA
;
191 #define LANG_RIGHT_TO_LEFT 0x00000001
194 // A string package is used to localize strings to a particular
195 // language. The package is associated with a particular driver
196 // or set of drivers. Tools are used to associate tokens with
197 // string references in forms and in programs. These tokens are
198 // language agnostic. When paired with a language pack (directly
199 // or indirectly), the string token resolves into an actual
200 // UNICODE string. The NumStringPointers determines how many
201 // StringPointers (offset values) there are as well as the total
202 // number of Strings that are defined.
205 EFI_HII_PACK_HEADER Header
;
206 RELOFST LanguageNameString
;
207 RELOFST PrintableLanguageName
;
208 UINT32 NumStringPointers
;
211 // RELOFST StringPointers[];
212 // EFI_STRING Strings[];
214 } EFI_HII_STRING_PACK
;
218 // A font list consists of a font header followed by a series
219 // of glyph structures. Note that fonts are not language specific.
222 EFI_HII_PACK_HEADER Header
;
223 UINT16 NumberOfNarrowGlyphs
;
224 UINT16 NumberOfWideGlyphs
;
228 // The IfrData in the EFI_HII_IFR_PACK structure definition
229 // is variable length, and not really part of the header. To
230 // simplify from code the size of the header, define an
231 // identical structure that does not include the IfrData field.
232 // Then use sizeof() this new structure to determine the
233 // actual size of the header.
236 EFI_HII_PACK_HEADER Header
;
237 } EFI_HII_IFR_PACK_HEADER
;
242 CHAR16 ShiftedUnicode
;
244 CHAR16 ShiftedAltGrUnicode
;
246 } FRAMEWORK_EFI_KEY_DESCRIPTOR
;
249 // This structure allows a sparse set of keys to be redefined
250 // or a complete redefinition of the keyboard layout. Most
251 // keyboards have a lot of commonality in their layouts, therefore
252 // only defining those keys that need to change from the default
253 // minimizes the passed in information.
255 // Additionally, when an update occurs, the active keyboard layout
256 // will be switched to the newly updated keyboard layout. This
257 // allows for situations that when a keyboard layout driver is
258 // loaded as part of system initialization, the system will default
259 // the keyboard behavior to the new layout.
261 // Each call to update the keyboard mapping should contain the
262 // complete set of key descriptors to be updated, since every
263 // call to the HII which contains an EFI_HII_KEYBOARD_PACK will
264 // wipe the previous set of overrides. A call to
267 EFI_HII_PACK_HEADER Header
;
268 FRAMEWORK_EFI_KEY_DESCRIPTOR
*Descriptor
;
269 UINT8 DescriptorCount
;
270 } EFI_HII_KEYBOARD_PACK
;
273 // The EFI_HII_PACKAGES can contain different types of packages just
274 // after the structure as inline data.
277 UINTN NumberOfPackages
;
280 // EFI_HII_HANDLE_PACK *HandlePack; // Only one pack.
281 // EFI_HII_IFR_PACK *IfrPack; // Only one pack.
282 // EFI_HII_FONT_PACK *FontPack[]; // Multiple packs ok
283 // EFI_HII_STRING_PACK *StringPack[]; // Multiple packs ok
284 // EFI_HII_KEYBOARD_PACK *KeyboardPack[]; // Multiple packs ok
288 typedef struct _EFI_HII_VARIABLE_PACK_LIST
{
289 struct _EFI_HII_VARIABLE_PACK_LIST
*NextVariablePack
;
290 EFI_HII_VARIABLE_PACK
*VariablePack
;
291 } EFI_HII_VARIABLE_PACK_LIST
;
297 Registers the various packs that are passed in via the Packages parameter.
299 @param This A pointer to the EFI_HII_PROTOCOL instance.
300 @param Packages A pointer to an EFI_HII_PACKAGES package instance.
301 @param Handle A pointer to the FRAMEWORK_EFI_HII_HANDLE instance.
303 @retval EFI_SUCCESS Data was extracted from Packages, the database
304 was updated with the data, and Handle returned successfully.
305 @retval EFI_INVALID_PARAMETER The content of Packages was invalid.
310 (EFIAPI
*FRAMEWORK_EFI_HII_NEW_PACK
)(
311 IN EFI_HII_PROTOCOL
*This
,
312 IN EFI_HII_PACKAGES
*Packages
,
313 OUT FRAMEWORK_EFI_HII_HANDLE
*Handle
317 Removes a package from the HII database.
319 @param This A pointer to the EFI_HII_PROTOCOL instance.
320 @param Handle The handle that was registered to the data that is requested
323 @retval EFI_SUCCESS The data associated with the Handle was removed
324 from the HII database.
325 @retval EFI_INVALID_PARAMETER The Handle was not valid.
330 (EFIAPI
*FRAMEWORK_EFI_HII_REMOVE_PACK
)(
331 IN EFI_HII_PROTOCOL
*This
,
332 IN FRAMEWORK_EFI_HII_HANDLE Handle
336 Determines the handles that are currently active in the database.
338 @param This A pointer to the EFI_HII_PROTOCOL instance.
339 @param HandleBufferLength On input, a pointer to the length of the handle
340 buffer. On output, the length of the handle buffer that is required
341 for the handles found.
342 @param Handle An array of FRAMEWORK_EFI_HII_HANDLE instances returned.
344 @retval EFI_SUCCESS Handle was updated successfully.
345 @retval EFI_BUFFER_TOO_SMALL The HandleBufferLength parameter indicates
346 that Handle is too small to support the number of handles.
351 (EFIAPI
*FRAMEWORK_EFI_HII_FIND_HANDLES
)(
352 IN EFI_HII_PROTOCOL
*This
,
353 IN OUT UINT16
*HandleBufferLength
,
354 OUT FRAMEWORK_EFI_HII_HANDLE
*Handle
358 Exports the contents of the database into a buffer.
360 @param This A pointer to the EFI_HII_PROTOCOL instance.
361 @param Handle An FRAMEWORK_EFI_HII_HANDLE that corresponds to the desired
362 handle to export. If the value is 0, the entire database will be exported.
363 In either case, the data will be exported in a format described by the
364 structure definition of EFI_HII_EXPORT_TABLE.
366 On input, a pointer to the length of the buffer. On output, the length
367 of the buffer that is required for the export data.
368 @param Buffer A pointer to a buffer that will contain the results of the export function.
370 @retval EFI_SUCCESS The buffer was successfully filled with BufferSize amount of data.
371 @retval EFI_BUFFER_TOO_SMALL The value in BufferSize was too small to contain the export data.
376 (EFIAPI
*FRAMEWORK_EFI_HII_EXPORT
)(
377 IN EFI_HII_PROTOCOL
*This
,
378 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
379 IN OUT UINTN
*BufferSize
,
384 Remove any new strings that were added after the initial string export
387 @param This A pointer to the EFI_HII_PROTOCOL instance.
388 @param Handle The handle on which the string resides.
390 @retval EFI_SUCCESS Remove strings from the handle successfully.
391 @retval EFI_INVALID_PARAMETER The Handle was unknown.
396 (EFIAPI
*FRAMEWORK_EFI_HII_RESET_STRINGS
)(
397 IN EFI_HII_PROTOCOL
*This
,
398 IN FRAMEWORK_EFI_HII_HANDLE Handle
402 Tests if all of the characters in a string have corresponding font characters.
404 @param This A pointer to the EFI_HII_PROTOCOL instance.
405 @param StringToTest A pointer to a Unicode string.
406 @param FirstMissing A pointer to an index into the string. On input,
407 the index of the first character in the StringToTest to examine. On exit,
408 the index of the first character encountered for which a glyph is unavailable.
409 If all glyphs in the string are available, the index is the index of the
410 terminator of the string.
411 @param GlyphBufferSize A pointer to a value. On output, if the function
412 returns EFI_SUCCESS, it contains the amount of memory that is required to
413 store the string's glyph equivalent.
415 @retval EFI_SUCCESS All glyphs are available. Note that an empty string
416 always returns this value.
417 @retval EFI_NOT_FOUND A glyph was not found for a character.
422 (EFIAPI
*FRAMEWORK_EFI_HII_TEST_STRING
) (
423 IN EFI_HII_PROTOCOL
*This
,
424 IN CHAR16
*StringToTest
,
425 IN OUT UINT32
*FirstMissing
,
426 OUT UINT32
*GlyphBufferSize
430 Translates a Unicode character into the corresponding font glyph.
432 @param This A pointer to the EFI_HII_PROTOCOL instance.
433 @param Source A pointer to a Unicode string.
434 @param Index On input, the offset into the string from which to fetch
435 the character.On successful completion, the index is updated to the first
436 character past the character(s) making up the just extracted glyph.
437 @param GlyphBuffer Pointer to an array where the glyphs corresponding
438 to the characters in the source may be stored. GlyphBuffer is assumed
439 to be wide enough to accept a wide glyph character.
440 @param BitWidth If EFI_SUCCESS was returned, the UINT16 pointed to by
441 this value is filled with the length of the glyph in pixels. It is unchanged
442 if the call was unsuccessful.
443 @param InternalStatus The cell pointed to by this parameter must be
444 initialized to zero prior to invoking the call the first time for any string.
446 @retval EFI_SUCCESS It worked.
447 @retval EFI_NOT_FOUND A glyph for a character was not found.
452 (EFIAPI
*FRAMEWORK_EFI_HII_GET_GLYPH
)(
453 IN EFI_HII_PROTOCOL
*This
,
455 IN OUT UINT16
*Index
,
456 OUT UINT8
**GlyphBuffer
,
457 OUT UINT16
*BitWidth
,
458 IN OUT UINT32
*InternalStatus
462 Translates a glyph into the format required for input to the Universal
463 Graphics Adapter (UGA) Block Transfer (BLT) routines.
465 @param This A pointer to the EFI_HII_PROTOCOL instance.
466 @param GlyphBuffer A pointer to the buffer that contains glyph data.
467 @param Foreground The foreground setting requested to be used for the
468 generated BltBuffer data.
469 @param Background The background setting requested to be used for the
470 generated BltBuffer data.
471 @param Count The entry in the BltBuffer upon which to act.
472 @param Width The width in bits of the glyph being converted.
473 @param Height The height in bits of the glyph being converted
474 @param BltBuffer A pointer to the buffer that contains the data that is
475 ready to be used by the UGA BLT routines.
477 @retval EFI_SUCCESS It worked.
478 @retval EFI_NOT_FOUND A glyph for a character was not found.
479 @note: Inconsistent with specification here:
480 In Framework Spec,HII spec 0.92. The type of 3rd, 4th and 8th parameter is EFI_UGA_PIXEL.
481 Here the definition use the EFI_GRAPHICS_OUTPUT_BLT_PIXEL which defined in UEFI2.1 spec
485 (EFIAPI
*FRAMEWORK_EFI_HII_GLYPH_TO_BLT
)(
486 IN EFI_HII_PROTOCOL
*This
,
487 IN UINT8
*GlyphBuffer
,
488 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Foreground
,
489 IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL Background
,
493 IN OUT EFI_GRAPHICS_OUTPUT_BLT_PIXEL
*BltBuffer
497 Allows a new string to be added to an already existing string package.
499 @param This A pointer to the EFI_HII_PROTOCOL instance.
500 @param Pointer to a NULL-terminated string containing a single ISO 639-2
501 language identifier, indicating the language in which the string is translated.
502 @param Handle The handle of the language pack to which the string is to be added.
503 @param Reference The identifier of the string to be added. If the reference
504 value is zero, then the string will be assigned a new identifier on that
505 handle for the language specified. Otherwise, the string will be updated
506 with the NewString Value.
507 @param NewString The string to be added.
509 @retval EFI_SUCCESS The string was effectively registered.
510 @retval EFI_INVALID_PARAMETER The Handle was unknown.
515 (EFIAPI
*FRAMEWORK_EFI_HII_NEW_STRING
)(
516 IN EFI_HII_PROTOCOL
*This
,
518 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
519 IN OUT STRING_REF
*Reference
,
524 Allows a program to determine the primary languages that are supported
527 @param This A pointer to the EFI_HII_PROTOCOL instance.
528 @param Handle The handle on which the strings reside.
529 @param LanguageString A string allocated by GetPrimaryLanguages() that
530 contains a list of all primary languages registered on the handle.
532 @retval EFI_SUCCESS LanguageString was correctly returned.
533 @retval EFI_INVALID_PARAMETER The Handle was unknown.
538 (EFIAPI
*FRAMEWORK_EFI_HII_GET_PRI_LANGUAGES
)(
539 IN EFI_HII_PROTOCOL
*This
,
540 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
541 OUT EFI_STRING
*LanguageString
545 Allows a program to determine which secondary languages are supported
546 on a given handle for a given primary language.
548 @param This A pointer to the EFI_HII_PROTOCOL instance.
549 @param Handle The handle on which the strings reside.
550 @param PrimaryLanguage Pointer to a NULL-terminated string containing a single
551 ISO 639-2 language identifier, indicating the primary language.
552 @param LanguageString A string allocated by GetSecondaryLanguages()
553 containing a list of all secondary languages registered on the handle.
555 @retval EFI_SUCCESS LanguageString was correctly returned.
556 @retval EFI_INVALID_PARAMETER The Handle was unknown.
561 (EFIAPI
*FRAMEWORK_EFI_HII_GET_SEC_LANGUAGES
)(
562 IN EFI_HII_PROTOCOL
*This
,
563 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
564 IN CHAR16
*PrimaryLanguage
,
565 OUT EFI_STRING
*LanguageString
569 Extracts a string from a package already registered with the EFI HII database.
571 @param This A pointer to the EFI_HII_PROTOCOL instance.
572 @param Handle The handle on which the string resides.
573 @param Token The string token assigned to the string.
574 @param Raw If TRUE, the string is returned unedited in the internal
575 storage format described above. If false, the string returned is edited
576 by replacing <cr> with <space> and by removing special characters such
577 as the <wide> prefix.
578 @param LanguageString Pointer to a NULL-terminated string containing a
579 single ISO 639-2 language identifier, indicating the language to print.
580 If the LanguageString is empty (starts with a NULL), the default system
581 language will be used to determine the language.
582 @param BufferLength Length of the StringBuffer.
583 @param StringBuffer The buffer designed to receive the characters in the string.
585 @retval EFI_SUCCESS StringBuffer is filled with a NULL-terminated string.
586 @retval EFI_INVALID_PARAMETER The handle or string token is unknown.
587 @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough to
588 allow the entire string to be stored.
593 (EFIAPI
*FRAMEWORK_EFI_HII_GET_STRING
)(
594 IN EFI_HII_PROTOCOL
*This
,
595 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
598 IN CHAR16
*LanguageString
,
599 IN OUT UINTN
*BufferLength
,
600 OUT EFI_STRING StringBuffer
604 Allows a program to extract a part of a string of not more than a given width.
606 @param This A pointer to the EFI_HII_PROTOCOL instance.
607 @param Handle The handle on which the string resides.
608 @param Token The string token assigned to the string.
609 @param Index On input, the offset into the string where the line is to start.
610 On output, the index is updated to point to beyond the last character returned
612 @param LineWidth The maximum width of the line in units of narrow glyphs.
613 @param LanguageString Pointer to a NULL-terminated string containing a
614 single ISO 639-2 language identifier, indicating the language to print.
615 @param BufferLength Pointer to the length of the StringBuffer.
616 @param StringBuffer The buffer designed to receive the characters in the string.
618 @retval EFI_SUCCESS StringBuffer filled with characters that will fit on the line.
619 @retval EFI_NOT_FOUND The font glyph for at least one of the characters in
620 the string is not in the font database.
621 @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough
622 to allow the entire string to be stored.
627 (EFIAPI
*FRAMEWORK_EFI_HII_GET_LINE
)(
628 IN EFI_HII_PROTOCOL
*This
,
629 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
631 IN OUT UINT16
*Index
,
633 IN CHAR16
*LanguageString
,
634 IN OUT UINT16
*BufferLength
,
635 OUT EFI_STRING StringBuffer
639 Allows a program to extract a form or form package that has previously
640 been registered with the HII database.
642 @param This A pointer to the EFI_HII_PROTOCOL instance.
643 @param Handle Handle on which the form resides.
644 @param FormId The ID of the form to return. If the ID is zero,
645 the entire form package is returned.
646 @param BufferLength On input, the length of the Buffer. On output,
647 the length of the returned buffer,
648 @param Buffer The buffer designed to receive the form(s).
650 @retval EFI_SUCCESS Buffer filled with the requested forms. BufferLength
652 @retval EFI_INVALID_PARAMETER The handle is unknown.
653 @retval EFI_NOT_FOUND A form on the requested handle cannot be found with
654 the requested FormId.
655 @retval EFI_BUFFER_TOO_SMALL The buffer provided was not large enough
656 to allow the form to be stored.
661 (EFIAPI
*FRAMEWORK_EFI_HII_GET_FORMS
)(
662 IN EFI_HII_PROTOCOL
*This
,
663 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
664 IN EFI_FORM_ID FormId
,
665 IN OUT UINTN
*BufferLength
,
670 Extracts the defaults that are associated with a given handle in the HII database.
672 @param This A pointer to the EFI_HII_PROTOCOL instance.
673 @param Handle The HII handle from which will have default data retrieved.
674 @param DefaultMask The mask used to specify some type of default override when extracting
675 the default image data.
676 @param VariablePackList A indirect pointer to the first entry of a link list with
677 type EFI_HII_VARIABLE_PACK_LIST.
679 @retval EFI_SUCCESS The VariablePackList was populated with the appropriate
680 default setting data.
681 @retval EFI_NOT_FOUND The IFR does not have any explicit or default map(s).
682 @retval EFI_INVALID_PARAMETER The HII database entry associated with Handle
683 contain invalid data.
688 (EFIAPI
*FRAMEWORK_EFI_HII_GET_DEFAULT_IMAGE
)(
689 IN EFI_HII_PROTOCOL
*This
,
690 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
691 IN UINTN DefaultMask
,
692 OUT EFI_HII_VARIABLE_PACK_LIST
**VariablePackList
696 Allows the caller to update a form or form package that has previously been
697 registered with the EFI HII database.
699 @param This A pointer to the EFI_HII_PROTOCOL instance.
700 @param Handle Handle of the package where the form to be updated resides.
701 @param Label The label inside the form package where the update is to take place.
702 @param AddData If TRUE, adding data at a given Label; otherwise,
703 if FALSE, removing data at a given Label.
704 @param Data The buffer containing the new tags to insert after the Label
706 @retval EFI_SUCCESS The form was updated with the new tags.
707 @retval EFI_INVALID_PARAMETER The buffer for the buffer length does not
708 contain an integral number of tags.
709 @retval EFI_NOT_FOUND The Handle, Label, or FormId was not found.
714 (EFIAPI
*FRAMEWORK_EFI_HII_UPDATE_FORM
)(
715 IN EFI_HII_PROTOCOL
*This
,
716 IN FRAMEWORK_EFI_HII_HANDLE Handle
,
717 IN EFI_FORM_LABEL Label
,
719 IN FRAMEWORK_EFI_HII_UPDATE_DATA
*Data
723 Retrieves the current keyboard layout.
725 @param This A pointer to the EFI_HII_PROTOCOL instance.
726 @param DescriptorCount A pointer to the number of Descriptor entries being
727 described in the keyboard layout being retrieved.
728 @param Descriptor A pointer to a buffer containing an array of FRAMEWORK_EFI_KEY_DESCRIPTOR
729 entries. Each entry will reflect the definition of a specific physical key.
731 @retval EFI_SUCCESS The keyboard layout was retrieved successfully.
736 (EFIAPI
*FRAMEWORK_EFI_HII_GET_KEYBOARD_LAYOUT
)(
737 IN EFI_HII_PROTOCOL
*This
,
738 OUT UINT16
*DescriptorCount
,
739 OUT FRAMEWORK_EFI_KEY_DESCRIPTOR
*Descriptor
743 The HII Protocol manages the HII database, which is a repository for data
744 having to do with fonts, strings, forms, keyboards, and other future human
747 struct _EFI_HII_PROTOCOL
{
749 /// Extracts the various packs from a package list.
751 FRAMEWORK_EFI_HII_NEW_PACK NewPack
;
754 /// Removes a package from the HII database.
756 FRAMEWORK_EFI_HII_REMOVE_PACK RemovePack
;
759 /// Determines the handles that are currently active in the database.
761 FRAMEWORK_EFI_HII_FIND_HANDLES FindHandles
;
764 /// Export the entire contents of the database to a buffer.
766 FRAMEWORK_EFI_HII_EXPORT ExportDatabase
;
769 /// Tests if all of the characters in a string have corresponding font characters.
771 FRAMEWORK_EFI_HII_TEST_STRING TestString
;
774 /// Translates a Unicode character into the corresponding font glyph.
776 FRAMEWORK_EFI_HII_GET_GLYPH GetGlyph
;
779 /// Converts a glyph value into a format that is ready for a UGA BLT command.
781 FRAMEWORK_EFI_HII_GLYPH_TO_BLT GlyphToBlt
;
784 /// Allows a new string to be added to an already existing string package.
786 FRAMEWORK_EFI_HII_NEW_STRING NewString
;
789 /// Allows a program to determine the primary languages that are supported
790 /// on a given handle.
792 FRAMEWORK_EFI_HII_GET_PRI_LANGUAGES GetPrimaryLanguages
;
795 /// Allows a program to determine which secondary languages are supported
796 /// on a given handle for a given primary language.
798 FRAMEWORK_EFI_HII_GET_SEC_LANGUAGES GetSecondaryLanguages
;
801 /// Extracts a string from a package that is already registered with the
802 /// EFI HII database.
804 FRAMEWORK_EFI_HII_GET_STRING GetString
;
807 /// Remove any new strings that were added after the initial string export
810 FRAMEWORK_EFI_HII_RESET_STRINGS ResetStrings
;
813 /// Allows a program to extract a part of a string of not more than a given width.
815 FRAMEWORK_EFI_HII_GET_LINE GetLine
;
818 /// Allows a program to extract a form or form package that has been previously registered.
820 FRAMEWORK_EFI_HII_GET_FORMS GetForms
;
823 /// Allows a program to extract the nonvolatile image that represents the default storage image.
825 FRAMEWORK_EFI_HII_GET_DEFAULT_IMAGE GetDefaultImage
;
828 /// Allows a program to update a previously registered form.
830 FRAMEWORK_EFI_HII_UPDATE_FORM UpdateForm
;
833 /// Allows a program to extract the current keyboard layout.
835 FRAMEWORK_EFI_HII_GET_KEYBOARD_LAYOUT GetKeyboardLayout
;
838 extern EFI_GUID gEfiHiiProtocolGuid
;
839 extern EFI_GUID gEfiHiiCompatibilityProtocolGuid
;