]> git.proxmox.com Git - mirror_edk2.git/blobdiff - EdkCompatibilityPkg/Foundation/Efi/Protocol/HiiFont/HiiFont.h
Sync all bug fixes between EDK1.04 and EDK1.06 into EdkCompatibilityPkg.
[mirror_edk2.git] / EdkCompatibilityPkg / Foundation / Efi / Protocol / HiiFont / HiiFont.h
index 36f5a872eb6f83f7424b3795aae5b48a0d9413a3..46c922cf123b6c2a8ac0525654724e01624e30a5 100644 (file)
@@ -1,6 +1,6 @@
 /*++\r
 \r
 /*++\r
 \r
-Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>\r
+Copyright (c) 2007 - 2010, Intel Corporation. All rights reserved.<BR>\r
 This program and the accompanying materials                          \r
 are licensed and made available under the terms and conditions of the BSD License         \r
 which accompanies this distribution.  The full text of the license may be found at        \r
 This program and the accompanying materials                          \r
 are licensed and made available under the terms and conditions of the BSD License         \r
 which accompanies this distribution.  The full text of the license may be found at        \r
@@ -53,9 +53,9 @@ typedef struct _EFI_HII_ROW_INFO {
 } EFI_HII_ROW_INFO;\r
 \r
 typedef struct {\r
 } EFI_HII_ROW_INFO;\r
 \r
 typedef struct {\r
-  UINT32 FontStyle;\r
-  UINT16 FontSize; // character cell size in pixels\r
-  CHAR16 FontName[1];\r
+  EFI_HII_FONT_STYLE FontStyle;\r
+  UINT16             FontSize; // character cell height in pixels\r
+  CHAR16             FontName[1];\r
 } EFI_FONT_INFO;\r
 \r
 typedef struct _EFI_FONT_DISPLAY_INFO {\r
 } EFI_FONT_INFO;\r
 \r
 typedef struct _EFI_FONT_DISPLAY_INFO {\r
@@ -65,25 +65,25 @@ typedef struct _EFI_FONT_DISPLAY_INFO {
   EFI_FONT_INFO                 FontInfo;  \r
 } EFI_FONT_DISPLAY_INFO;\r
 \r
   EFI_FONT_INFO                 FontInfo;  \r
 } EFI_FONT_DISPLAY_INFO;\r
 \r
-#define EFI_HII_OUT_FLAG_CLIP        0x00000001\r
-#define EFI_HII_OUT_FLAG_WRAP        0x00000002\r
-#define EFI_HII_OUT_FLAG_CLEAN_Y     0x00000004\r
-#define EFI_HII_OUT_FLAG_CLEAN_X     0x00000008\r
-#define EFI_HII_OUT_FLAG_TRANSPARENT 0x00000010\r
-#define EFI_HII_IGNORE_IF_NO_GLYPH   0x00000020\r
-#define EFI_HII_IGNORE_LINE_BREAK    0x00000040\r
-#define EFI_HII_DIRECT_TO_SCREEN     0x00000080\r
-\r
-#define EFI_FONT_INFO_SYS_FONT       0x00000001\r
-#define EFI_FONT_INFO_SYS_SIZE       0x00000002\r
-#define EFI_FONT_INFO_SYS_STYLE      0x00000004\r
-#define EFI_FONT_INFO_SYS_FORE_COLOR 0x00000010\r
-#define EFI_FONT_INFO_SYS_BACK_COLOR 0x00000020\r
-#define EFI_FONT_INFO_RESIZE         0x00001000\r
-#define EFI_FONT_INFO_RESTYLE        0x00002000\r
-#define EFI_FONT_INFO_ANY_FONT       0x00010000\r
-#define EFI_FONT_INFO_ANY_SIZE       0x00020000\r
-#define EFI_FONT_INFO_ANY_STYLE      0x00040000\r
+#define EFI_HII_OUT_FLAG_CLIP         0x00000001\r
+#define EFI_HII_OUT_FLAG_WRAP         0x00000002\r
+#define EFI_HII_OUT_FLAG_CLIP_CLEAN_Y 0x00000004\r
+#define EFI_HII_OUT_FLAG_CLIP_CLEAN_X 0x00000008\r
+#define EFI_HII_OUT_FLAG_TRANSPARENT  0x00000010\r
+#define EFI_HII_IGNORE_IF_NO_GLYPH    0x00000020\r
+#define EFI_HII_IGNORE_LINE_BREAK     0x00000040\r
+#define EFI_HII_DIRECT_TO_SCREEN      0x00000080\r
+\r
+#define EFI_FONT_INFO_SYS_FONT        0x00000001\r
+#define EFI_FONT_INFO_SYS_SIZE        0x00000002\r
+#define EFI_FONT_INFO_SYS_STYLE       0x00000004\r
+#define EFI_FONT_INFO_SYS_FORE_COLOR  0x00000010\r
+#define EFI_FONT_INFO_SYS_BACK_COLOR  0x00000020\r
+#define EFI_FONT_INFO_RESIZE          0x00001000\r
+#define EFI_FONT_INFO_RESTYLE         0x00002000\r
+#define EFI_FONT_INFO_ANY_FONT        0x00010000\r
+#define EFI_FONT_INFO_ANY_SIZE        0x00020000\r
+#define EFI_FONT_INFO_ANY_STYLE       0x00040000\r
 \r
 typedef\r
 EFI_STATUS\r
 \r
 typedef\r
 EFI_STATUS\r
@@ -109,7 +109,7 @@ EFI_STATUS
     Flags             - Describes how the string is to be drawn.                 \r
     String            - Points to the null-terminated string to be displayed.\r
     StringInfo        - Points to the string output information, including the color and font. \r
     Flags             - Describes how the string is to be drawn.                 \r
     String            - Points to the null-terminated string to be displayed.\r
     StringInfo        - Points to the string output information, including the color and font. \r
-                        If NULL, then the string will be output in the default system font and color.                             \r
+                        If NULL, then the string will be output in the default system font and color.\r
     Blt               - If this points to a non-NULL on entry, this points to the image, which is Width pixels  \r
                         wide and Height pixels high. The string will be drawn onto this image and               \r
                         EFI_HII_OUT_FLAG_CLIP is implied. If this points to a NULL on entry, then a             \r
     Blt               - If this points to a non-NULL on entry, this points to the image, which is Width pixels  \r
                         wide and Height pixels high. The string will be drawn onto this image and               \r
                         EFI_HII_OUT_FLAG_CLIP is implied. If this points to a NULL on entry, then a             \r
@@ -132,7 +132,8 @@ EFI_STATUS
   Returns:\r
     EFI_SUCCESS           - The string was successfully rendered.                           \r
     EFI_OUT_OF_RESOURCES  - Unable to allocate an output buffer for RowInfoArray or Blt.\r
   Returns:\r
     EFI_SUCCESS           - The string was successfully rendered.                           \r
     EFI_OUT_OF_RESOURCES  - Unable to allocate an output buffer for RowInfoArray or Blt.\r
-    EFI_INVALID_PARAMETER - The String was NULL.    \r
+    EFI_INVALID_PARAMETER - The String or Blt was NULL.\r
+    EFI_INVALID_PARAMETER - Flags were invalid combination.\r
         \r
 --*/\r
 ;\r
         \r
 --*/\r
 ;\r
@@ -166,7 +167,7 @@ EFI_STATUS
     Language          - Points to the language for the retrieved string. If NULL, then the current system\r
                         language is used.                                                                \r
     StringInfo        - Points to the string output information, including the color and font. \r
     Language          - Points to the language for the retrieved string. If NULL, then the current system\r
                         language is used.                                                                \r
     StringInfo        - Points to the string output information, including the color and font. \r
-                        If NULL, then the string will be output in the default system font and color.                             \r
+                        If NULL, then the string will be output in the default system font and color.\r
     Blt               - If this points to a non-NULL on entry, this points to the image, which is Width pixels  \r
                         wide and Height pixels high. The string will be drawn onto this image and               \r
                         EFI_HII_OUT_FLAG_CLIP is implied. If this points to a NULL on entry, then a             \r
     Blt               - If this points to a non-NULL on entry, this points to the image, which is Width pixels  \r
                         wide and Height pixels high. The string will be drawn onto this image and               \r
                         EFI_HII_OUT_FLAG_CLIP is implied. If this points to a NULL on entry, then a             \r
@@ -187,9 +188,12 @@ EFI_STATUS
                         is possible when character display is normalized that some character cells overlap.           \r
                      \r
   Returns:\r
                         is possible when character display is normalized that some character cells overlap.           \r
                      \r
   Returns:\r
-    EFI_SUCCESS           - The string was successfully rendered.                           \r
+    EFI_SUCCESS           - The string was successfully rendered.\r
     EFI_OUT_OF_RESOURCES  - Unable to allocate an output buffer for RowInfoArray or Blt.\r
     EFI_OUT_OF_RESOURCES  - Unable to allocate an output buffer for RowInfoArray or Blt.\r
-    EFI_INVALID_PARAMETER - The String was NULL.    \r
+    EFI_INVALID_PARAMETER - The Blt or PackageList was NULL.\r
+    EFI_INVALID_PARAMETER - Flags were invalid combination.\r
+    EFI_NOT_FOUND         - The specified PackageList is not in the Database or the stringid is not \r
+                            in the specified PackageList. \r
         \r
 --*/\r
 ;\r
         \r
 --*/\r
 ;\r
@@ -233,7 +237,7 @@ EFI_STATUS
 (EFIAPI *EFI_HII_GET_FONT_INFO) (\r
   IN  CONST EFI_HII_FONT_PROTOCOL    *This,\r
   IN  OUT   EFI_FONT_HANDLE          *FontHandle,\r
 (EFIAPI *EFI_HII_GET_FONT_INFO) (\r
   IN  CONST EFI_HII_FONT_PROTOCOL    *This,\r
   IN  OUT   EFI_FONT_HANDLE          *FontHandle,\r
-  IN  CONST EFI_FONT_DISPLAY_INFO    *StringInfoIn,\r
+  IN  CONST EFI_FONT_DISPLAY_INFO    *StringInfoIn, OPTIONAL\r
   OUT       EFI_FONT_DISPLAY_INFO    **StringInfoOut,\r
   IN  CONST EFI_STRING               String OPTIONAL\r
   )\r
   OUT       EFI_FONT_DISPLAY_INFO    **StringInfoOut,\r
   IN  CONST EFI_STRING               String OPTIONAL\r
   )\r
@@ -246,11 +250,13 @@ EFI_STATUS
     \r
   Arguments:          \r
     This              - A pointer to the EFI_HII_FONT_PROTOCOL instance.\r
     \r
   Arguments:          \r
     This              - A pointer to the EFI_HII_FONT_PROTOCOL instance.\r
-    FontHandle        - On entry, points to the font handle returned by a \r
-                        previous call to GetFontInfo() or NULL to start with the \r
+    FontHandle        - On entry, points to the font handle returned by a previous \r
+                        call to GetFontInfo() or points to NULL to start with the \r
                         first font. On return, points to the returned font handle or\r
                         first font. On return, points to the returned font handle or\r
-                        points to NULL if there are no more matching fonts.                                               \r
-    StringInfoIn      - Upon entry, points to the font to return information about.                        \r
+                        points to NULL if there are no more matching fonts.\r
+    StringInfoIn      - Upon entry, points to the font to return information about.\r
+                        If NULL, then the information about the system default \r
+                        font will be returned.\r
     StringInfoOut     - Upon return, contains the matching font's information. \r
                         If NULL, then no information is returned.\r
                         It's caller's responsibility to free this buffer.\r
     StringInfoOut     - Upon return, contains the matching font's information. \r
                         If NULL, then no information is returned.\r
                         It's caller's responsibility to free this buffer.\r
@@ -261,10 +267,10 @@ EFI_STATUS
   Returns:\r
     EFI_SUCCESS            - Matching font returned successfully.\r
     EFI_NOT_FOUND          - No matching font was found.\r
   Returns:\r
     EFI_SUCCESS            - Matching font returned successfully.\r
     EFI_NOT_FOUND          - No matching font was found.\r
-    EFI_INVALID_PARAMETER  - StringInfoIn is NULL.\r
+    EFI_INVALID_PARAMETER  - StringInfoIn->FontInfoMask is an invalid combination.\r
     EFI_OUT_OF_RESOURCES   - There were insufficient resources to complete the request.\r
             \r
     EFI_OUT_OF_RESOURCES   - There were insufficient resources to complete the request.\r
             \r
---*/     \r
+--*/\r
 ;\r
 \r
 \r
 ;\r
 \r
 \r