parameters: (self)
docstring: Return the current :class:`.SearchState`. (The one for the focused
          :class:`.BufferControl`.)
docstring_summary: Return the current :class:`.SearchState`. (The one for the focused
          :class:`.BufferControl`.)
docstring_tokens: Return the current : class : . SearchState . ( The one for the focused : class : . BufferControl . )
function: def current_search_state(self) -> SearchState:
          """
          Return the current :class:`.SearchState`. (The one for the focused
          :class:`.BufferControl`.)
          """
          ui_control = self.layout.current_control
          if isinstance(ui_control, BufferControl):
              return ui_control.search_state
          else:
              return SearchState()
function_tokens: def current_search_state ( self ) -> SearchState : ui_control = self . layout . current_control if isinstance ( ui_control , BufferControl ) : return ui_control . search_state else : return SearchState ( )