Logo Search packages:      
Sourcecode: accerciser version File versions

def interface_view::_SectionText::_accEventText (   self,
  event 
) [private]

Callback for accessible text changes. Updates the text buffer accordingly.

@param event: Event that triggered thi callback.
@type event: Accessibility.Event

Definition at line 1472 of file interface_view.py.

01472                                 :
    '''
    Callback for accessible text changes. Updates the text buffer accordingly.
    
    @param event: Event that triggered thi callback.
    @type event: Accessibility.Event
    '''
    if self.node.acc != event.source:
      return

    if event.type.major == 'text-changed':
      text_iter = self.text_buffer.get_iter_at_offset(event.detail1)
      if event.type.minor == 'insert':
        call = (event.detail1, event.any_data, event.detail2)
        if self.outgoing_calls['itext_insert'].isCached(call):
          return
        self.text_buffer.handler_block(self._text_insert_handler)
        self.text_buffer.insert(text_iter, event.any_data)
        self.text_buffer.handler_unblock(self._text_insert_handler)
           
      elif event.type.minor == 'delete':
        call = (event.detail1, event.detail2)
        if self.outgoing_calls['itext_delete'].isCached(call):
          return
        text_iter_end = \
            self.text_buffer.get_iter_at_offset(event.detail1 + event.detail2)
        self.text_buffer.handler_block(self._text_delete_handler)
        self.text_buffer.delete(text_iter, text_iter_end)
        self.text_buffer.handler_unblock(self._text_delete_handler)
     
  def _onITextInsert(self, text_buffer, iter, text, length):


Generated by  Doxygen 1.6.0   Back to index