Версия для печати темы

Нажмите сюда для просмотра этой темы в обычном формате

Форум на CrossPlatform.RU _ Обсуждение исходников с сайта _ clienteODBC

Автор: ViGOur 26.3.2009, 12:45

Цитата
clienteODBC является приложением для соединения с базами данных MS SQL Server посредством ODBC. Оно написано на Qt 4.5 Opensource edition.
http://www.crossplatform.ru/node/877

Автор: el_chaman 27.3.2009, 22:27

Цитата(ViGOur @ 26.3.2009, 12:45) *
Цитата
clienteODBC является приложением для соединения с базами данных MS SQL Server посредством ODBC. Оно написано на Qt 4.5 Opensource edition.
http://www.crossplatform.ru/node/877


Hi:

I'm the original author of clienteODBC. Thanks for downloading my application. I'm looking for translators. Someone to translate into russian? :)

Sorry for write in english, I'm from Spain and just speak spanish and english (and not very well as you can see :) ).

Greetings from Spain

Автор: ViGOur 27.3.2009, 23:25

Hola.
Escriba lo que hay que hacer.
Creo que la medida de lo posible para ayudar.

:)

lo siento por mi español

Автор: el_chaman 28.3.2009, 2:08

Hola:

Acabo de subir la documentación en inglés y español a Sourceforge.
I've just posted the documentation release at Sourceforge: https://sourceforge.net/project/showfiles.php?group_id=257203&package_id=315336

Es HTML plano./ Its plain HTML

Tal vez, antes de empezar a traducir la aplicación, sería bueno traducir los documentos html. /
Maybe it's a good idea start to translate de HTML doc before translate de program.

Estos tienen la siguiente estructura:
HTML docs have this structure in his names:

name_language.html

Donde nombre (name) es el nombre del archivo e idioma (language) es la especificación del idioma.
Where name is the file's name and language tthe language specification.

Así que si por ejemplo desea traducir del español al ruso index_es.hmlt, debe de creae un archivo llamado index_ru.html.
So if you want to translate from spanish into russian index_es.html for example, you have to create a file called index_ru.html.

....

En cuanto a la traducción de la aplicación el procedimiento es el siguiente:
If we talk about application translation, the procedure is: http://library.forum.nokia.com/index.jsp?topic=/Qt_for_S60_Developers_Library/GUID-ECBE8350-9D54-48D1-B777-264B895B9063/i18n.html


Thank you very much.
Muchas gracias.

P.S.: Te aseguro que tu espaol es muchísimo mejor que mi ruso. :)

Автор: Litkevich Yuriy 28.3.2009, 2:56

Цитата(Гость_el_chaman_* @ 28.3.2009, 5:08) *
P.S.: Te aseguro que tu espanol es muchнsimo mejor que mi ruso.
ViGOur, cool! :lol:

Автор: Litkevich Yuriy 28.3.2009, 6:15

el_chaman, їY cуmo ser con la traducciуn de la interfaz de usuario?

main.cpp:

#include <QtGui/QApplication>
#include <QLocale>
#include <QTranslator>
#include "mainwindow.h"
#include "dsneditor.h"
#include "dsn.h"
#include "parserxml.h"

int main(int argc, char *argv[])
{
    QString archivo;
    QApplication a(argc, argv);
    
    // Establecer la traducciуn / Устанавливаем перевод / Setting up translation
    QString resourceDir = QLibraryInfo::location(QLibraryInfo::TranslationsPath);
    QTranslator translator(0);
    qDebug() << "location - PrefixPath:" << QLibraryInfo::location(QLibraryInfo::PrefixPath);
    qDebug() << "location - TranslationsPath:" << resourceDir;
    bool loadOk = translator.load(QLatin1String("app_") + QLocale::system().name(), resourceDir);
    qDebug() << "Load translation?" << loadOk;
    qApp->installTranslator(&translator);

    
    Q_INIT_RESOURCE(iconos);
    MainWindow w;


    // En LINUX pongo como archivo de configuraciуn
    // uno oculto en el directorio HOME
#ifdef Q_OS_LINUX
    archivo = getenv("HOME");
    archivo.append( "/.dsn.xml");
#else
#ifdef Q_OS_WIN32
    archivo = getenv("USERPROFILE");
    archivo.append("\\dsn.xml");
#else
    archivo = "dsn.xml";
#endif
#endif

    ParserXml parser;

    if (!parser.leerArchivo(archivo)){
        // Si no existe archivo de configuraciуn, lanzamos
        // el diбlogo de configuraciуn;

    }else{
        // Si existe, lo cargamos en la ventana principal
        w.setListaDSN(parser.getDSNs());

    }
    w.show();
    return a.exec();
}

2) Crear un directorio "translations"
3) Aсadir en el archivo de proyecto de estas lнneas:
clienteODBC.pro:

.
.
.
#======== Translation ===============
TRANSLATIONS = ./translations/app_ru.ts

#======== Convenient config ===============
CONFIG (debug, debug|release) {
CONFIG += console
}
4) lupdate clienteODBC.pro
5) Traducimos el archivo "./translations/app_ru.ts" al ruso. Transferido:  app_ru.zip ( 2.08 килобайт ) : 276

6) lrelease.exe ./translations/app_ru.ts

Автор: ViGOur 28.3.2009, 11:59

Цитата(Гость_el_chaman_* @ 28.3.2009, 2:08) *
P.S.: Te aseguro que tu espaol es muchísimo mejor que mi ruso.
Es no yo, es google.

Let's speak in English. :)

Автор: AD 28.3.2009, 17:45

:)
How do you know spanish? :)
:)

Автор: Litkevich Yuriy 28.3.2009, 18:02

AD, это ты к кому?

Автор: AD 28.3.2009, 18:15

Цитата(Litkevich Yuriy @ 28.3.2009, 18:02) *
AD, это ты к кому?

For all, who is from Russia!

Автор: ViGOur 28.3.2009, 20:42

Конечно, достаточно простой и односложный язык. :)

Цитата(ViGOur @ 28.3.2009, 11:59) *
Es no yo, es google.
попробуй догалайся, о чем это я сказал. ;)

Автор: AD 28.3.2009, 22:58

Цитата(ViGOur @ 28.3.2009, 20:42) *
Конечно, достаточно простой и односложный язык. :)

Цитата(ViGOur @ 28.3.2009, 11:59) *
Es no yo, es google.
попробуй догалайся, о чем это я сказал. ;)

Это не я, это Google!

Блин, вот не лень вам! :)))

Автор: el_chaman 29.3.2009, 1:14

Hi again!

I've finished the translation release (thans a lot Litkevich Yuriy, you are now in the credits section! (http//www.forum.crossplatform.ru crew too!)

You can now see a Russian capture in http://sourceforge.net/project/screenshots.php?group_id=257203&ssid=102216

English translation has been done as well..

Thanks a lot for your help.

You can download 0.4.1 release at http://sourceforge.net/project/showfiles.php?group_id=257203 now in russian.

Автор: Litkevich Yuriy 29.3.2009, 4:46

Now it's time the bad news.

Problem with encoding when using the database.
I have a database in Win-1251 encoding (OS encoding). (http://lit-uriy.narod.ru/temp/ODBC_Con_bug_1.png)
And I have to solve the following way (in main.cpp):

...
    qApp->installTranslator(&translator);

    QTextCodec::setCodecForCStrings(QTextCodec::codecForLocale()); // Add line
    
    Q_INIT_RESOURCE(iconos);
...
(http://lit-uriy.narod.ru/temp/ODBC_Con_good_1.png)

P.S. Perhaps this is bad, is not universal, method. But I have no other thought.

-----------
A little bit of use the program, I found an error in translation. Here is a corrected version of ts-file:  codbc_ru.zip ( 2.35 килобайт ) : 266

Автор: el_chaman 29.3.2009, 4:46

Hi Litkevich Yuriy:

Yes, I have a similar problem in spanish when accesing from linux client to windows machines (both in spanish, but with different codifications [UTF-8/UTF-16]). I'm working on it, because maybe it's a plobrem related to unixodbc

If you wish we can keep traking these errors at clienteODBC forum ( http://sourceforge.net/forum/forum.php?forum_id=932910)

I thank you all the giving help at http://www.forum.crossplatform.ru/, but I think that it could be more interesting for other users/developpers to have a centraliced place to go.

If you wish I can add all volunteers to the project so we can work toguether.

It's a SVN repository too, so we can have a track of all changes made.
You can get the last SVN revision from http://sourceforge.net/scm/?type=svn&group_id=257203

Автор: Гость 29.3.2009, 5:02

After aplying your changes it works fine for spanish too!

I can write &euro;, íííí, óóóó, úúú, áááá, ñññññ, etc without problem.

I have submited the changes to the SVN version.

Tomorrow I'will prepare an executable for windows (today we have one hour less in Spain due to spring time date change). Now here its 04:01 and its time to go to sleep.


Than you very much

Форум Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)