Results 1 to 11 of 11

Thread: öüä not working in qt4-apps on linux

  1. #1
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default öüä not working in qt4-apps on linux

    Hello,

    I'm using Qt 4.2.2 on Gentoo Linux. My problem is that I can't insert öüä characters in textboxes. Characters like é Ã* (using ´+e) work.

    I have no problems in all KDE-Applications.

    Any tipps how I can find the cause of this problem?

    thanks, niko

    PS: This is my very simple test-code:
    Qt Code:
    1. #include <QtGui>
    2. int main(int argc, char** argv) {
    3. QApplication app(argc, argv);
    4. QLineEdit lineEdit;
    5. lineEdit.show();
    6. return app.exec();
    7. }
    To copy to clipboard, switch view to plain text mode 

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,373
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    3
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: öüä not working in qt4-apps on linux

    Are you able to copy & paste those characters into the lineedit?

  3. #3
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default Re: öüä not working in qt4-apps on linux

    no - doesn't work either.
    i copied the title of this thread in it and go the attached result.

    tanks for your help...
    niko
    Attached Images Attached Images
    Last edited by niko; 4th April 2007 at 20:09. Reason: spelling error

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,373
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    3
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: öüä not working in qt4-apps on linux

    The problem is probably with your system then. I can paste the characters fine here on Linux. Maybe you're using a font that doesn't have these glyphs?

  5. #5
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default Re: öüä not working in qt4-apps on linux

    i didn't change default fonts anywhere.
    qtconfig says "Sans Serif"
    and in kde sans serif has these characters.

    I tried the same thing on another desktop (also gentoo) - no problem there!

  6. #6
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default Re: öüä not working in qt4-apps on linux

    I changed the default font to Times New Roman in qtconfig.
    No change.

  7. #7
    Join Date
    May 2006
    Posts
    788
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows
    Thanks
    49
    Thanked 48 Times in 46 Posts

    Default Re: öüä not working in qt4-apps on linux

    Quote Originally Posted by niko View Post
    I changed the default font to Times New Roman in qtconfig.
    No change.
    Ist this QT build from your self? on system locale latin utf-8 ... sample german utf-8?
    Or ist this an emerge gentoo ready package... ? configured on only utf-8?


    wahts happen wenn you start èèèè char as argumen 1 and 2

    ./app üöäüöä öäìüöä

    on this ....
    on pro file...
    CONFIG += console
    Qt Code:
    1. #include <QApplication>
    2. #include <QtGui>
    3. #include <QtCore>
    4. #include <QDebug>
    5.  
    6. int main(int argc, char** argv) {
    7.  
    8. QApplication app(argc, argv);
    9.  
    10. QString argument_1, argument_2;
    11. argument_1 = QString::fromLatin1(argv[1]);
    12. argument_2 = argv[2];
    13. qDebug() << "fargument_1 -> " << argument_1;
    14. qDebug() << "argument_2 -> " << argument_2;
    15.  
    16.  
    17. QLineEdit lineEdit;
    18. lineEdit.setText (argument_1+argument_2);
    19.  
    20. lineEdit.show();
    21. return 0;
    22. }
    To copy to clipboard, switch view to plain text mode 

  8. #8
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,373
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Thanks
    3
    Thanked 5,019 Times in 4,795 Posts
    Wiki edits
    10

    Default Re: öüä not working in qt4-apps on linux

    Can you run the character map example (bundled with Qt) and see if the glyphs you seek are present there?

  9. #9
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default Re: öüä not working in qt4-apps on linux

    Quote Originally Posted by patrik08 View Post
    Ist this QT build from your self? on system locale latin utf-8 ... sample german utf-8?
    Or ist this an emerge gentoo ready package... ? configured on only utf-8?
    It is the current stable gentoo-package built with:
    [ebuild R ] x11-libs/qt-4.2.2 USE="cups dbus debug doc examples gif jpeg opengl png qt3support sqlite xinerama zlib -accessibility -firebird -glib -mng -mysql -nas -nis -odbc -pch -postgres -sqlite3" INPUT_DEVICES="-wacom" 0 kB
    nothing else is special configured.

    my /etc/locale.gen file:
    Qt Code:
    1. en_US ISO-8859-1
    2. en_US.UTF-8 UTF-8
    3. de_DE ISO-8859-1
    4. de_DE@euro ISO-8859-15
    5. de_DE.UTF-8 UTF-8
    6. de_AT ISO-8859-1
    7. de_AT@euro ISO-8859-15
    8. de_AT.UTF-8 UTF-8
    To copy to clipboard, switch view to plain text mode 

    Where else can I configure something?
    (I don't remember I did)

    Qt Code:
    1. ./app testüöäüöätest testöäìüöätest
    To copy to clipboard, switch view to plain text mode 
    gives me this:
    Qt Code:
    1. fargument_1 -> "testtest"
    2. argument_2 -> "testtest"
    To copy to clipboard, switch view to plain text mode 


    Can you run the character map example (bundled with Qt) and see if the glyphs you seek are present there?
    see screenshot - i think these are the right ones. (qt4 on the left, kcharselect on the right)

    thanks,
    niko
    Attached Images Attached Images
    Last edited by jacek; 6th April 2007 at 17:16. Reason: changed [code] to [quote]

  10. #10
    Join Date
    May 2006
    Posts
    788
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows
    Thanks
    49
    Thanked 48 Times in 46 Posts

    Default Re: öüä not working in qt4-apps on linux

    Quote Originally Posted by niko View Post
    It is the current stable gentoo-package built with:
    [code][ebuild R ] x11-libs/qt-4.2.2 USE="cups dbus debug doc examples gif
    my /etc/locale.gen file:
    Qt Code:
    1. en_US ISO-8859-1
    2. en_US.UTF-8 UTF-8
    3. de_DE ISO-8859-1
    4. de_DE@euro ISO-8859-15
    5. de_DE.UTF-8 UTF-8
    6. de_AT ISO-8859-1
    7. de_AT@euro ISO-8859-15
    8. de_AT.UTF-8 UTF-8
    To copy to clipboard, switch view to plain text mode 

    Qt Code:
    1. ./app testüöäüöätest testöäìüöätest
    To copy to clipboard, switch view to plain text mode 
    gives me this:
    Qt Code:
    1. fargument_1 -> "testtest"
    2. argument_2 -> "testtest"
    To copy to clipboard, switch view to plain text mode 
    niko
    this is my result on XUBUNTU Linux feysy or so....

    Qt Code:
    1. ./app testüöäüöätest testöäìüöätest
    2. fargument_1 -> "testüöäüöätest"
    3. argument_2 -> "testöäìüöätest"
    To copy to clipboard, switch view to plain text mode 

    utf-8 out ...


    Your default font locale not speak utf-8?? configured to qt... and bypass unknow char....

    QFont f( QApplication::font () );
    qDebug() << "### default font -> " << f.family (); /* this font is buggy */

    ### default font -> "Sans Serif" work on my OS


    i am sure if you rebuild qt4.2 from normal method .... all running ...
    whitout emerge or so....

  11. #11
    Join Date
    Jan 2006
    Posts
    105
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows
    Thanks
    21
    Thanked 2 Times in 2 Posts

    Default Re: öüä not working in qt4-apps on linux

    I found the issue, I did't have LANG set and so this bug effected me:
    http://www.trolltech.com/developer/t...ntry&id=136174

    solution: upgrade to 4.2.3
    or set LANG enviroment variable

    thanks for your help!
    niko

Similar Threads

  1. Opacity in Linux OS
    By shyam prasad in forum Qt Programming
    Replies: 2
    Last Post: 22nd May 2007, 05:59
  2. Replies: 2
    Last Post: 12th January 2007, 11:19
  3. QT 3 (linux) to 4(windows XP)
    By deekayt in forum Qt Programming
    Replies: 1
    Last Post: 17th October 2006, 18:30
  4. Crosscompile Qt in Linux
    By Morea in forum General Discussion
    Replies: 4
    Last Post: 13th April 2006, 18:19
  5. QProcess / system call not working under linux. Why?
    By johnny_sparx in forum Qt Programming
    Replies: 12
    Last Post: 11th March 2006, 00:32

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.