diff options
author | eric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524> | 2009-06-03 01:43:47 +0000 |
---|---|---|
committer | eric_tian <eric_tian@6f19259b-4bc3-4df7-8a09-765794883524> | 2009-06-03 01:43:47 +0000 |
commit | 35c218d7e6d542bb770858719676431b79ca1244 (patch) | |
tree | b486eff3b73e611677356738d03f56c098fa60f7 /MdeModulePkg | |
parent | 071b7221a550eba89800493e01861a1e7d72b2b4 (diff) | |
download | edk2-platforms-35c218d7e6d542bb770858719676431b79ca1244.tar.xz |
fix the HiiStrIdToImage sct failure, which is caused by wrong algorithm of finding right-most line break opportunity.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8446 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'MdeModulePkg')
-rw-r--r-- | MdeModulePkg/Universal/HiiDatabaseDxe/Font.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c b/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c index 4bb72c81d4..2fd355029d 100644 --- a/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c +++ b/MdeModulePkg/Universal/HiiDatabaseDxe/Font.c @@ -1766,6 +1766,7 @@ HiiStringToImage ( // It forces a line break that ends this row.
//
Index++;
+ LineBreak = TRUE;
break;
}
@@ -1842,6 +1843,12 @@ HiiStringToImage ( Index = Index1 + 1;
break;
}
+ //
+ // If don't find a line break opportunity from EndIndex to StartIndex,
+ // then jump out.
+ //
+ if (Index1 == RowInfo[RowIndex].StartIndex)
+ break;
}
}
//
@@ -1968,9 +1975,9 @@ HiiStringToImage ( Index++;
RowIndex++;
- if (Flags & EFI_HII_IGNORE_LINE_BREAK) {
+ if (!LineBreak) {
//
- // If setting IGNORE_LINE_BREAK attribute, only render one line to image
+ // If there is not a mandatory line break or line break opportunity, only render one line to image
//
break;
}
|