code: def go_to_next_buffer(self, _previous=False):
          
          if self.active_editor_buffer:
              # Find the active opened buffer.
              index = self.editor_buffers.index(self.active_editor_buffer)
  
              # Get index of new buffer.
              if _previous:
                  new_index = (len(self.editor_buffers) + index - 1) % len(self.editor_buffers)
              else:
                  new_index = (index + 1) % len(self.editor_buffers)
  
              # Open new buffer in active tab.
              self.active_tab.show_editor_buffer(self.editor_buffers[new_index])
  
              # Clean up buffers.
              self._auto_close_new_empty_buffers()
docs: Open next buffer in active window.