×

Discussion Board

Results 1 to 4 of 4
  1. #1
    Registered User
    Join Date
    Feb 2008
    Posts
    3

    No accents in the console

    Hi !

    It seems that the console does not like accents.
    For example if you run the following code (iso-8859-1 or utf-8 encoding):

    Code:
    print 'a'
    print 'é'
    print 'b'
    You'll only see 'a'. The accent seems to screw the console (pys60 1.4.2 on a 6630).

    Ludo.

    PS: Is there a way to change a S60 GUI language to english with a 'special' reflash ?

  2. #2
    Regular Contributor
    Join Date
    Mar 2003
    Location
    UK
    Posts
    125

    Re: No accents in the console

    Quote Originally Posted by ldrolez View Post
    It seems that the console does not like accents.
    Confirmed. The command...

    Code:
    >>> print 'caf\xe9'
    ...seems to crash the console, whereas...

    Code:
    >>> print u'caf\xe9'
    café
    ...works file. The inclusion of the Unicode delimiter may be a documented caveat.

  3. #3
    Registered User
    Join Date
    Feb 2008
    Posts
    3

    Re: No accents in the console

    In fact I found this bug by running 'print time.ctime(time.time())' because in my locale the current month is 'février'.

    So, should I always convert to unicode like this ?
    print unicode(time.ctime(time.time(), 'latin-1')

    Bug or feature :-) ?

  4. #4
    Regular Contributor
    Join Date
    Mar 2003
    Location
    UK
    Posts
    125

    Re: No accents in the console

    Quote Originally Posted by ldrolez View Post
    So, should I always convert to unicode like this ?
    print unicode(time.ctime(time.time(), 'latin-1')
    Well, for now, you don't seem to have any other choice.

    Quote Originally Posted by ldrolez View Post
    Bug or feature :-) ?
    No idea. Feels like a bug to me. Check to see if it has been reported on the SourceForge bug tracker, and, if not, report it.

    http://sourceforge.net/tracker/?atid...55&func=browse

Similar Threads

  1. Re-Installation Issue with console exe
    By neekasa in forum Symbian
    Replies: 3
    Last Post: 2007-12-27, 12:31
  2. Replies: 3
    Last Post: 2007-11-28, 19:07
  3. PyS60 Python Console step-by-step on Mac OSX
    By notpeter in forum Symbian
    Replies: 1
    Last Post: 2007-09-22, 07:56
  4. Replies: 3
    Last Post: 2006-11-02, 21:58
  5. Replies: 5
    Last Post: 2006-10-25, 01:40

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
×