Implementation for EFI_HII_FONT_PROTOCOL.\r
\r
\r
-Copyright (c) 2007 - 2009, Intel Corporation\r
-All rights reserved. This program and the accompanying materials\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
http://opensource.org/licenses/bsd-license.php\r
// It forces a line break that ends this row.\r
//\r
Index++;\r
+ LineBreak = TRUE;\r
break;\r
}\r
\r
Index = Index1 + 1;\r
break;\r
}\r
+ //\r
+ // If don't find a line break opportunity from EndIndex to StartIndex,\r
+ // then jump out.\r
+ //\r
+ if (Index1 == RowInfo[RowIndex].StartIndex)\r
+ break;\r
}\r
}\r
//\r
Index++;\r
RowIndex++;\r
\r
- if (Flags & EFI_HII_IGNORE_LINE_BREAK) {\r
+ if (!LineBreak) {\r
//\r
- // If setting IGNORE_LINE_BREAK attribute, only render one line to image\r
+ // If there is not a mandatory line break or line break opportunity, only render one line to image\r
//\r
break;\r
}\r
if (EFI_ERROR (Status)) {\r
goto Exit;\r
}\r
+ ASSERT (StringInfoOut != NULL);\r
FontInfo = &StringInfoOut->FontInfo;\r
Foreground = StringInfoOut->ForegroundColor;\r
Background = StringInfoOut->BackgroundColor;\r
InfoOut.BackgroundColor = SystemDefault->BackgroundColor;\r
}\r
\r
-\r
+ ASSERT (FontInfo != NULL);\r
FontInfo->FontSize = InfoOut.FontInfo.FontSize;\r
FontInfo->FontStyle = InfoOut.FontInfo.FontStyle;\r
\r