parameters: (self, event=None)
docstring: Show clicked context line at top of editor.
  
          If a selection was made, don't jump; allow copying.
          If no visible context, show the top line of the file.
docstring_summary: Show clicked context line at top of editor.
docstring_tokens: Show clicked context line at top of editor .
function: def jumptoline(self, event=None):
          """ Show clicked context line at top of editor.
  
          If a selection was made, don't jump; allow copying.
          If no visible context, show the top line of the file.
          """
          try:
              self.context.index("sel.first")
          except tkinter.TclError:
              lines = len(self.info)
              if lines == 1:  # No context lines are showing.
                  newtop = 1
              else:
                  # Line number clicked.
                  contextline = int(float(self.context.index('insert')))
                  # Lines not displayed due to maxlines.
                  offset = max(1, lines - self.context_depth) - 1
                  newtop = self.info[offset + contextline][0]
              self.text.yview(f'{newtop}.0')
              self.update_code_context()
function_tokens: def jumptoline ( self , event = None ) : try : self . context . index ( "sel.first" ) except tkinter . TclError : lines = len ( self . info ) if lines == 1 : # No context lines are showing. newtop = 1 else : # Line number clicked. contextline = int ( float ( self . context . index ( 'insert' ) ) ) # Lines not displayed due to maxlines. offset = max ( 1 , lines - self . context_depth ) - 1 newtop = self . info [ offset + contextline ] [ 0 ] self . text . yview ( f'{newtop}.0' ) self . update_code_context ( )