Program: 44827
Project: 44827
Buggy source:
public TextEditor(){
  textViewerDelegate=new TextViewer(textEditorImpl=new TextEditorImpl(true)){
    @Override protected void addComponentToPresent(    JComponent component){
      TextEditor.this.addComponentToPresent(component);
    }
    @Override protected void showLineNumbers(    boolean show){
      TextEditor.this.setRowHeaderView(show ? new TextLineNumbersPanel(textEditorImpl.getTextArea()) : null);
    }
    @Override protected void initMenuBarItems(){
      editMenu=new JMenu(Translator.get("String_Node_Str"));
      MnemonicHelper menuItemMnemonicHelper=new MnemonicHelper();
      copyItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      cutItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      pasteItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      selectAllItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      editMenu.addSeparator();
      findItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F,KeyEvent.CTRL_DOWN_MASK),TextEditor.this);
      findNextItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F3,0),TextEditor.this);
      findPreviousItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F3,KeyEvent.SHIFT_DOWN_MASK),TextEditor.this);
      viewMenu=new JMenu(Translator.get("String_Node_Str"));
      toggleWordWrapItem=MenuToolkit.addCheckBoxMenuItem(viewMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      toggleWordWrapItem.setSelected(textEditorImpl.isWrap());
      toggleLineNumbersItem=MenuToolkit.addCheckBoxMenuItem(viewMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      toggleLineNumbersItem.setSelected(TextEditor.this.getRowHeader().getView() != null);
    }
  }
;
  addComponentToPresent(textEditorImpl.getTextArea());
}

Fixed version (ground truth):
public TextEditor(){
  textViewerDelegate=new TextViewer(textEditorImpl=new TextEditorImpl(true)){
    @Override protected void setComponentToPresent(    JComponent component){
      TextEditor.this.setComponentToPresent(component);
    }
    @Override protected void showLineNumbers(    boolean show){
      TextEditor.this.setRowHeaderView(show ? new TextLineNumbersPanel(textEditorImpl.getTextArea()) : null);
    }
    @Override protected void initMenuBarItems(){
      editMenu=new JMenu(Translator.get("String_Node_Str"));
      MnemonicHelper menuItemMnemonicHelper=new MnemonicHelper();
      copyItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      cutItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      pasteItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      selectAllItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      editMenu.addSeparator();
      findItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F,KeyEvent.CTRL_DOWN_MASK),TextEditor.this);
      findNextItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F3,0),TextEditor.this);
      findPreviousItem=MenuToolkit.addMenuItem(editMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,KeyStroke.getKeyStroke(KeyEvent.VK_F3,KeyEvent.SHIFT_DOWN_MASK),TextEditor.this);
      viewMenu=new JMenu(Translator.get("String_Node_Str"));
      toggleWordWrapItem=MenuToolkit.addCheckBoxMenuItem(viewMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      toggleWordWrapItem.setSelected(textEditorImpl.isWrap());
      toggleLineNumbersItem=MenuToolkit.addCheckBoxMenuItem(viewMenu,Translator.get("String_Node_Str"),menuItemMnemonicHelper,null,TextEditor.this);
      toggleLineNumbersItem.setSelected(TextEditor.this.getRowHeader().getView() != null);
    }
  }
;
  setComponentToPresent(textEditorImpl.getTextArea());
}