anchor.diff:      procedure   DrawRow(line: integer; const AItemFocused: boolean); virtual;
       function    ItemHeight(mi: TfpgMenuItem): integer; virtual;
       procedure   PrepareToShow;
  +    procedure   DoKeyShortcut(const AOrigin: TfpgWidget; const keycode: word; const shiftstate: TShiftState; var consumed: boolean; const IsChildOfOrigin: boolean = False); override;
     public
       OpenerPopup: TfpgPopupMenu;
       OpenerMenuBar: TfpgMenuBar;
  
positive.code:     if i <> -1 then
      begin
        consumed := True;
  //      writeln('Selected ', VisibleItem(i).Text);
        FFocusItem := i;
        DoSelect;
      end;
    end;
    inherited HandleKeyPress(keycode, shiftstate, consumed);
  end;
  
  procedure TfpgMenuBar.HandlePaint;
  
negative.code:   uFocusedPopupMenu := self;
  end;
  
  procedure TfpgPopupMenu.DoKeyShortcut(const AOrigin: TfpgWidget;
    const keycode: word; const shiftstate: TShiftState; var consumed: boolean; const IsChildOfOrigin: boolean = False);
  var
    s: TfpgString;
    i: integer;
    mi: TfpgMenuItem;
  begin
    s := KeycodeToText(keycode, shiftstate);
    for i := 0 to ComponentCount-1 do
    begin
      if Components[i] is TfpgMenuItem then
      begin
        mi := Components[i] as TfpgMenuItem;
        if mi.Separator then
          Continue;
        if mi.Visible and mi.Enabled then
        begin
          { process the sub menus }
          if mi.SubMenu <> nil then
            mi.SubMenu.DoKeyShortcut(nil, keycode, shiftstate, consumed)
          else if mi.HotKeyDef = s then
          begin
            consumed := True;
            mi.Click;
          end;
          if consumed then
            Exit;
        end;
      end;
    end;
  
  end;
  
  function TfpgPopupMenu.CalcMouseRow(y: integer): integer;
  var
    h: integer;
  