class_docstr: Widget used to display or control data from a hierarchy of Parameters
class_docstr_tok: ["Widget","used","to","display","or","control","data","from","a","hierarchy","of","Parameters"]
docstr: Give input focus to the next (or previous) item after *item*
          
docstr_tok: ["Give","input","focus","to","the","next","(","or","previous",")","item","after","*","item","*"]
code: def focusNext(self, item, forward=True):
      """Give input focus to the next (or previous) item after *item*"""
      while True:
          parent = item.parent()
          if parent is None:
              return
          nextItem = self.nextFocusableChild(
              parent, item, forward=forward
          )
          if nextItem is not None:
              nextItem.setFocus()
              self.setCurrentItem(nextItem)
              return
          item = parent
  
file_path: pyqtgraph/pyqtgraph/parametertree/ParameterTree.py
imports: from .parameterTypes import GroupParameterItem
  from ..Qt import QtCore, QtWidgets, mkQApp
  from ..widgets.TreeWidget import TreeWidget
  from .ParameterItem import ParameterItem
label_desc: Use image node_id 5 for calling the ParameterTree obj's underlying member method code with example usage: obj.focusNext(item, forward) without return types