QScintilla/QsciScintillaCompat.py

branch
Py2 comp.
changeset 3515
1b8381afe38f
parent 3484
645c12de6b0c
parent 3493
71f15675e89f
child 3591
2f2a4a76dd22
equal deleted inserted replaced
3506:d85fadb263a0 3515:1b8381afe38f
264 utf8Len = 4 264 utf8Len = 4
265 elif (ch[0] & 0xE0) == 0xE0: 265 elif (ch[0] & 0xE0) == 0xE0:
266 utf8Len = 3 266 utf8Len = 3
267 elif (ch[0] & 0xC0) == 0xC0: 267 elif (ch[0] & 0xC0) == 0xC0:
268 utf8Len = 2 268 utf8Len = 2
269 else:
270 utf8Len = 1
269 while len(ch) < utf8Len: 271 while len(ch) < utf8Len:
270 pos += 1 272 pos += 1
271 ch += self.byteAt(pos) 273 ch += self.byteAt(pos)
272 return ch.decode('utf8') 274 return ch.decode('utf8')
273 else: 275 else:

eric ide

mercurial