问题描述:

I'm trying to add some personalised shortcuts to Pyroom, this is my function for moving the cursor one character forward:

def forward_one_char(self):

buf = self.buffers[self.current]

iter1 = buf.get_iter_at_mark(buf.get_mark('insert'))

iter1.forward_char()

buf.place_cursor(iter1)

this seems crazy complicated, is there a better way?

相关阅读:
Top