ShellPkg: Added the Ctrl based hot key and changed text editor's UI.
* Add Ctrl-E hotkey for help * Add Ctrl based hotkey alternatives to function hotkeys * Don't show hotkey help on the main screen * Change the file buffer's row count for display to adjust the new screen format * Change the edit status bar location, the new edit status bar is in the last line * Change the location of the edit bar, the new edit input bar is in the last line Signed-off-by: kidzyoung reviewed-by: jcarsey reviewed-by: jljusten reviewed-by: jiang git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@12036 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
@ -832,7 +832,7 @@ HBufferImageRefresh (
|
||||
//
|
||||
FStartRow = HBufferImage.LowVisibleRow;
|
||||
StartRow = 2;
|
||||
EndRow = (HMainEditor.ScreenSize.Row - 4);
|
||||
EndRow = (HMainEditor.ScreenSize.Row - 1);
|
||||
}
|
||||
//
|
||||
// no line
|
||||
@ -1404,7 +1404,7 @@ HUnderCurrentScreen (
|
||||
IN UINTN FileRow
|
||||
)
|
||||
{
|
||||
if (FileRow > HBufferImage.LowVisibleRow + (HMainEditor.ScreenSize.Row - 5) - 1) {
|
||||
if (FileRow > HBufferImage.LowVisibleRow + (HMainEditor.ScreenSize.Row - 2) - 1) {
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@ -1712,8 +1712,8 @@ HBufferImagePageDown (
|
||||
//
|
||||
// has next page
|
||||
//
|
||||
if (HBufferImage.NumLines >= FRow + (HMainEditor.ScreenSize.Row - 5)) {
|
||||
Gap = (HMainEditor.ScreenSize.Row - 5);
|
||||
if (HBufferImage.NumLines >= FRow + (HMainEditor.ScreenSize.Row - 2)) {
|
||||
Gap = (HMainEditor.ScreenSize.Row - 2);
|
||||
} else {
|
||||
//
|
||||
// MOVE CURSOR TO LAST LINE
|
||||
@ -1764,8 +1764,8 @@ HBufferImagePageUp (
|
||||
//
|
||||
// has previous page
|
||||
//
|
||||
if (FRow > (HMainEditor.ScreenSize.Row - 5)) {
|
||||
Gap = (HMainEditor.ScreenSize.Row - 5);
|
||||
if (FRow > (HMainEditor.ScreenSize.Row - 2)) {
|
||||
Gap = (HMainEditor.ScreenSize.Row - 2);
|
||||
} else {
|
||||
//
|
||||
// the first line of file will displayed on the first line of screen
|
||||
@ -2392,12 +2392,12 @@ HBufferImageAdjustMousePosition (
|
||||
// check whether new mouse row position is beyond screen
|
||||
// if not, adjust it
|
||||
//
|
||||
if (TempY >= 2 && TempY <= (HMainEditor.ScreenSize.Row - 4)) {
|
||||
if (TempY >= 2 && TempY <= (HMainEditor.ScreenSize.Row - 1)) {
|
||||
HBufferImage.MousePosition.Row = TempY;
|
||||
} else if (TempY < 2) {
|
||||
HBufferImage.MousePosition.Row = 2;
|
||||
} else if (TempY > (HMainEditor.ScreenSize.Row - 4)) {
|
||||
HBufferImage.MousePosition.Row = (HMainEditor.ScreenSize.Row - 4);
|
||||
} else if (TempY > (HMainEditor.ScreenSize.Row - 1)) {
|
||||
HBufferImage.MousePosition.Row = (HMainEditor.ScreenSize.Row - 1);
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user