Results 1 to 4 of 4

Thread: Problem at time compilation in traslation of language

  1. #1
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Question Problem at time compilation in traslation of language

    hi all
    i m working on Mac OSx using Qt4.2
    and trying to translate the language using QTranslator.
    but it is giving warnings errors (Mainly warnings)


    errors and warning on my terminal are following:



    Last login: Tue May 22 10:08:44 on console
    Welcome to Darwin!
    darpan-kambojs-Computer:~ root# cd /unicode
    darpan-kambojs-Computer:/unicode root# qmake -project
    darpan-kambojs-Computer:/unicode root# qmake -o makefile unicode.pro
    darpan-kambojs-Computer:/unicode root# qmake -spec macx-g++
    darpan-kambojs-Computer:/unicode root# qmake &&make
    /Developer/Tools/Qt/uic unicode.ui -o ui_unicode.h
    c++ -c -pipe -g -Wall -W -F/Library/Frameworks -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/local/Qt4.2/mkspecs/macx-g++ -I. -I/Library/Frameworks/QtCore.framework/Versions/4/Headers -I/usr/include/QtCore -I/Library/Frameworks/QtGui.framework/Versions/4/Headers -I/usr/include/QtGui -I/usr/include -I. -I. -I. -o main.o main.cpp
    c++ -c -pipe -g -Wall -W -F/Library/Frameworks -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/local/Qt4.2/mkspecs/macx-g++ -I. -I/Library/Frameworks/QtCore.framework/Versions/4/Headers -I/usr/include/QtCore -I/Library/Frameworks/QtGui.framework/Versions/4/Headers -I/usr/include/QtGui -I/usr/include -I. -I. -I. -o Unicode.o Unicode.cpp
    Unicode.cpp:1: error: stray '\254' in program
    Unicode.cpp:1: error: stray '\255' in program
    Unicode.cpp:1:3: warning: null character(s) ignored
    Unicode.cpp:1:5: warning: null character(s) ignored
    Unicode.cpp:1:7: warning: null character(s) ignored
    Unicode.cpp:2:1: warning: null character(s) ignored
    Unicode.cpp:2:5: warning: null character(s) ignored
    Unicode.cpp:2:11: warning: null character(s) ignored
    Unicode.cpp:2:13: warning: null character(s) ignored
    Unicode.cpp:10:4: error: invalid preprocessing directive #i
    Unicode.cpp:10:5: warning: null character(s) ignored
    Unicode.cpp:10:7: warning: null character(s) ignored
    Unicode.cpp:10:9: warning: null character(s) ignored
    Unicode.cpp:10:11: warning: null character(s) ignored
    Unicode.cpp:12:4: error: invalid preprocessing directive #i
    nicode.cpp:13:4: error: invalid preprocessing directive #i
    Unicode.cpp:13:5: warning: null character(s) ignored
    Unicode.cpp:13:7: warning: null character(s) ignored
    Unicode.cpp:13:23: warning: null character(s) ignored
    Unicode.cpp:14:1: warning: null character(s) ignored
    Unicode.cpp:14:3: warning: null character(s) ignored
    Unicode.cpp:14:4: error: invalid preprocessing directive #i
    Unicode.cpp:14:5: warning: null character(s) ignored
    Unicode.cpp:14:7: warning: null character(s) ignored
    Unicode.cpp:14:9: warning: null character(s) ignored
    Unicode.cpp:14:23: warning: null character(s) ignored
    Unicode.cpp:14:25: warning: null character(s) ignored
    Unicode.cpp:15:1: warning: null character(s) ignored
    Unicode.cpp:15:3: warning: null character(s) ignored
    Unicode.cpp:15:4: error: invalid preprocessing directive #i
    Unicode.cpp:15:5: warning: null character(s) ignored
    Unicode.cpp:16:3: warning: null character(s) ignored
    Unicode.cpp:16:4: error: invalid preprocessing directive #i
    Unicode.cpp:16:5: warning: null character(s) ignored
    Unicode.cpp:16:7: warning: null character(s) ignored
    Unicode.cpp:16:9: warning: null character(s) ignored
    Unicode.cpp:16:33: warning: null character(s) ignored
    Unicode.cpp:16:35: warning: null character(s) ignored
    Unicode.cpp:16:37: warning: null character(s) ignored
    Unicode.cpp:16:39: warning: null character(s) ignored
    Unicode.cpp:16:41: warning: null character(s) ignored
    Unicode.cpp:17:1: warning: null character(s) ignored
    Unicode.cpp:17:3: warning: null character(s) ignored
    Unicode.cpp:17:4: error: invalid preprocessing directive #i
    Unicode.cpp:17:5: warning: null character(s) ignored
    Unicode.cpp:17:7: warning: null character(s) ignored
    Unicode.cpp:17:9: warning: null character(s) ignored
    Unicode.cpp:17:11: warning: null character(s) ignored
    Unicode.cpp:17:13: warning: null character(s) ignored
    Unicode.cpp:17:35: warning: null character(s) ignored
    Unicode.cpp:18:1: warning: null character(s) ignored
    Unicode.cpp:18:3: warning: null character(s) ignored
    Unicode.cpp:18:4: error: invalid preprocessing directive #i
    Unicode.cpp:18:5: warning: null character(s) ignored
    Unicode.cpp:18:7: warning: null character(s) ignored
    Unicode.cpp:18:9: warning: null character(s) ignored
    Unicode.cpp:18:11: warning: null character(s) ignored
    Unicode.cpp:186:43: warning: null character(s) ignored
    Unicode.cpp:187:1: warning: null character(s) ignored
    Unicode.cpp:1: error: expected unqualified-id before '/' token
    Unicode.cpp:31: error: 'v' does not name a type
    Unicode.cpp:42: error: 'v' does not name a type
    Unicode.cpp:94: error: 'Q' does not name a type
    Unicode.cpp:95: error: 'v' does not name a type
    Unicode.cpp:101: error: 'v' does not name a type
    Unicode.cpp:107: error: 'v' does not name a type
    Unicode.cpp:113: error: 'v' does not name a type
    Unicode.cpp:119: error: expected unqualified-id before '/' token
    Unicode.cpp:125: error: 'v' does not name a type
    Unicode.cpp:131: error: 'v' does not name a type
    Unicode.cpp:137: error: 'v' does not name a type
    Unicode.cpp:143: error: 'v' does not name a type
    Unicode.cpp:149: error: 'v' does not name a type
    Unicode.cpp:155: error: 'v' does not name a type
    Unicode.cpp:161: error: 'v' does not name a type
    Unicode.cpp:167: error: expected unqualified-id before '/' token
    Unicode.cpp:167: error: expected constructor, destructor, or type conversion before '/' token
    Unicode.cpp:175: error: 'Q' does not name a type
    make: *** [Unicode.o] Error 1
    darpan-kambojs-Computer:/unicode root#


    please do tell what is it problem???

    thanks in advance

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

    Default Re: Problem at time compilation in traslation of language

    You're using Unicode in your source files. Don't do that. Use latin-1 or something simmilar and use Unicode in the translations (.ts files) only.

  3. #3
    Join Date
    Mar 2007
    Posts
    69
    Thanks
    14
    Qt products
    Qt3 Qt4
    Platforms
    MacOS X

    Question Re: Problem at time compilation in traslation of language

    thanks for your reply
    yes, i'm doing the same but still showing same warnings and errors
    see i basically wanna do like as same as the example given in qt assistant

    qt/examples/tools/i18n

    except on place of check box i m using comboBox

    can you please tell me any other alternative another than this i mean to say any anther way

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

    Default Re: Problem at time compilation in traslation of language

    Did you get rid of all the unicode from the source file? What does Unicode.cpp contain? Can we see it?

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
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.