unindent changes chars
Status: Beta
Brought to you by:
riaan
When I have in string some national chars (one of few,
that works) and unindent some block of code, national
chars changes to us-ascii. This is does not appears,
when I unindent single line.
I think it is done by module cStringIO, but I don't
explore it too much.
Logged In: YES
user_id=1044977
Hi it is me again (now logged).
##### diff Views/PySourceView.py
136c136
< return ['%s%s'%(idntBlock, t) for t in textLst]
---
> return ['%s%s'%(idntBlock,
t.encode(sys.getdefaultencoding())) for t in textLst]
##### diff Views/SourceViews.py
14c14
< import time, os
---
> import time, os, sys
281c281
< self.ReplaceSelection(text)
---
>
self.ReplaceSelection(text.decode(sys.getdefaultencoding()))
this solve problem with displaying characters in editor, but
when document is saved, report error "invalid syntax" - with
unicode characters... :(
Logged In: YES
user_id=1044977
I was stupid. The error in save is my fault. This patch
works good.
I was error in indendation with my test file.