From: Manuel Nickschas Date: Tue, 9 Oct 2007 23:26:19 +0000 (+0000) Subject: Added basic stuff for localization/internationalization (i18n). X-Git-Tag: 0.1.0~137 X-Git-Url: https://git.quassel-irc.org/?p=quassel.git;a=commitdiff_plain;h=38bc59665a5b812b73cd1cca0bcc74c66981829e Added basic stuff for localization/internationalization (i18n). This is not yet supported by code (other than the commented test code in main.cpp), and it probably does not make sense to start translating stuff right now, but I wanted to test if and how linguist works... and it does! --- diff --git a/build/targets/qtgui.pro b/build/targets/qtgui.pro index f96c5a42..6fc10308 100644 --- a/build/targets/qtgui.pro +++ b/build/targets/qtgui.pro @@ -1,2 +1,4 @@ include(qtgui.pri) include(target.pri) + +TRANSLATIONS = quassel_de.ts diff --git a/build/targets/target.pri b/build/targets/target.pri index 8f4646fc..611b5c95 100644 --- a/build/targets/target.pri +++ b/build/targets/target.pri @@ -1,7 +1,11 @@ TEMPLATE = app +RESOURCES += ../../i18n/i18n.qrc \ + ../../src/images/icons.qrc + SRCPATH = ../../src OBJECTS_DIR = .$$TARGET +RCC_DIR = .$$TARGET for(mod, MODULES) { INCLUDEPATH *= $$SRCPATH/$$mod diff --git a/i18n/README b/i18n/README new file mode 100644 index 00000000..2f357224 --- /dev/null +++ b/i18n/README @@ -0,0 +1,4 @@ +To sync the source with a translation file for locale $LOC, run +> lupdate ../src -ts quassel_$LOC.ts + +If you add a new language, don't forget to edit i18n.qrc as well! diff --git a/i18n/i18n.qrc b/i18n/i18n.qrc new file mode 100644 index 00000000..5e992eee --- /dev/null +++ b/i18n/i18n.qrc @@ -0,0 +1,5 @@ + + + quassel_de.qm + + diff --git a/i18n/quassel_de.qm b/i18n/quassel_de.qm new file mode 100644 index 00000000..e429eda2 Binary files /dev/null and b/i18n/quassel_de.qm differ diff --git a/i18n/quassel_de.ts b/i18n/quassel_de.ts new file mode 100644 index 00000000..b9fa7bc7 --- /dev/null +++ b/i18n/quassel_de.ts @@ -0,0 +1,1492 @@ + + + + + AboutDlg + + + Dialog + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:11pt; font-weight:400; font-style:normal; text-decoration:none;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Quassel IRC </span>(pre-release)</p></body></html> + + + + + About + + + + + Authors + + + + + Licence Agreement + + + + + AccountManagementSettingsPage + + + Administration + + + + + Account Management + + + + + Form + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Trebuchet MS'; font-size:10pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Bitstream Vera Sans'; font-size:11pt;"><span style=" font-weight:600;">Account Management</span></p></body></html> + + + + + Add... + + + + + Remove + + + + + Rename + + + + + Password... + + + + + Admin + + + + + Buffer + + + Status Buffer + + + + + BufferManagementSettingsPage + + + Buffers + + + + + Buffer Management + + + + + Form + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:11pt; font-weight:400; font-style:normal; text-decoration:none;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Buffer Management</span></p></body></html> + + + + + Statistics + + + + + Created: 01.04.2007 +Lines: 1234 + + + + + + Defines how many messages the local Quassel client shows for this buffer. This is independent from the central backlog storage in the core. + + + + + Local Display + + + + + Override default display options + + + + + Show all messages + + + + + Show last + + + + + messages + + + + + Show messages from the last + + + + + days + + + + + Hide buffer locally + + + + + Save as default + + + + + Backlog Storage + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Bitstream Vera Sans'; font-size:11pt; font-weight:400; font-style:normal; text-decoration:none;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Warning:</span> This affects the global message storage (backlog) for the selected buffer!</p></body></html> + + + + + Override default storage settings + + + + + Keep all messages + + + + + Keep last + + + + + Keep messages from the last + + + + + Delete permanently + + + + + BufferTreeModel + + + Buffer + + + + + Network + + + + + BufferViewWidget + + + BufferView + + + + + BufferWidget + + + %1 Users + + + + + 1 User + + + + + %1 Operators + + + + + %1 Voiced + + + + + YourNickname #quassel Network: The Topic + + + + + ... + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Trebuchet MS'; font-size:14pt; font-weight:400; font-style:normal;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:11pt;"><span style=" font-size:89pt;">Yarrrrr!</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:49pt;"><span style=" font-size:22pt;">Avast, ye scurvy dogs!</span></p></body></html> + + + + + ChannelWidget + + + YourNickname #quassel Network: The Topic + + + + + ... + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Bitstream Vera Sans Mono'; font-size:8pt; font-weight:400; font-style:normal; text-decoration:none;"> +<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Nimbus Mono L';"></p></body></html> + + + + + 32 Users + + + + + @ Operators + + + + + New Sub Item + + + + + New Item + + + + + 4 Voiced + + + + + 19 Users + + + + + Client + + + Already connected to Core! + + + + + Connecting... + + + + + Synchronizing to core... + + + + + Invalid data received from core! + + + + + Requesting network states... + + + + + ConnectionSettingsPage + + + Behavior + + + + + Connection + + + + + Form + + + + + CoreConnectDlg + + + Create Account + + + + + In order to connect to a Quassel Core, you need to create an account.<br>Please enter a name for this account now: + + + + + Default + + + + + Please enter a name for the new account: + + + + + Account name already exists! + + + + + An account named '%1' already exists, and account names must be unique! + + + + + Delete account? + + + + + Do you really want to delete the data for the account '%1'?<br>Note that this only affects your local account settings and will not remove any data from the core. + + + + + Can't connect to internal core at the moment [serious breakage due to switch to dynamic signals]. Please check back later. + + + + + Can't connect to internal core, since we are running as a standalone GUI! + + + + + Connecting to internal core + + + + + Connecting to %1 + + + + + Invalid user or password. Pleasy try again.%1 + + + + + Connected to core. + + + + + Connection Error + + + + + <b>Could not connect to Quassel Core!</b><br> + + + + + + Connect to Quassel Core + + + + + Account Settings + + + + + Account: + + + + + ... + + + + + Host: + + + + + Use internal + + + + + Port: + + + + + User: + + + + + Password: + + + + + Remember + + + + + Always use this account + + + + + Connecting to... + + + + + Connecting... + + + + + GUI Profile: + + + + + New... + + + + + Always use this profile + + + + + New + + + + + Delete + + + + + Properties... + + + + + Select Core Account + + + + + Available Quassel Core accounts: + + + + + Connect + + + + + CoreConnectProgressDlg + + + Connection Error + + + + + <b>Could not connect to Quassel Core!</b><br> + + + + + + Connection Progress + + + + + Connecting... + + + + + CoreSettingsPage + + + Form + + + + + EditCoreAcctDlg + + + Missing information + + + + + Please enter all required information or discard changes to return to account selection. + + + + + Non-unique account name + + + + + Account names need to be unique. Please enter a different name or discard all changes to return to account selection. + + + + + Edit Core Account + + + + + Port: + + + + + Host: + + + + + Password: + + + + + Account: + + + + + User: + + + + + IdentitiesDlg + + + Default Identity + + + + + Data changed remotely! + + + + + <b>Some other GUI client changed the identities data!</b><br>Apply updated settings, losing all changes done locally? + + + + + Invalid Identity! + + + + + One or more of your identities do not contain all necessary information: + +%1 +Please fill in any missing information. + + + + + You have not set a real name. + + + + + You have to specify an Ident. + + + + + You haven't entered any nicknames. + + + + + [%1]%2 + + + + + + Edit Identity + + + + + Edit... + + + + + &General + + + + + Real Name + + + + + Ident + + + + + Nicknames + + + + + &Add... + + + + + &Edit... + + + + + De&lete + + + + + ... + + + + + &Away + + + + + Away Reason + + + + + Return Message + + + + + Away Nick + + + + + Auto Away + + + + + Enable Auto Away + + + + + Auto away after + + + + + minutes + + + + + &Messages + + + + + Part Reason + + + + + Quit Reason + + + + + Kick Reason + + + + + IdentitiesEditDlg + + + Default Identity + + + + + Delete Identity? + + + + + Do you really want to delete identity "%1"? +Networks using this identity will be reset to use the default identity. + + + + + &Delete + + + + + &Cancel + + + + + Edit Identities + + + + + &Add... + + + + + &Duplicate... + + + + + &Rename... + + + + + De&lete + + + + + MainWidget + + + Form + + + + + <html><head><meta name="qrichtext" content="1" /><style type="text/css"> +p, li { white-space: pre-wrap; } +</style></head><body style=" font-family:'Trebuchet MS'; font-size:14pt; font-weight:400; font-style:normal; text-decoration:none;"> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:10pt;"><span style=" font-size:6pt;">&lt;Sput&gt; So soll das hier dann mal ungefähr aussehen...</span></p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:6pt;">&lt;Foo&gt; aha, na allzuviel Text bekommt man da wahrscheinlich nicht unter.</p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:6pt;">&lt;Sput&gt; Man wird sehen müssen...</p> +<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:6pt;">&lt;Foo&gt; Das ist wohl wahr...</p></body></html> + + + + + MainWin + + + Waiting for core... + + + + + Not connected to core. + + + + + All Buffers + + + + + All Channels + + + + + All Queries + + + + + All Networks + + + + + Full Custom + + + + + MainWindow + + + + + Connection + Verbindung + + + + Settings + Einstellungen + + + + Views + Ansicht + + + + Help + Hilfe + + + + Debug + Debug + + + + Core + Core + + + + &Network List... + + + + + F2 + + + + + Quick &Connect... + + + + + Disconnect + + + + + Reconnect + + + + + Join Channel... + + + + + Set Away globally + + + + + Quit... + + + + + Edit Identities... + + + + + Configure Quassel... + + + + + F7 + + + + + Manage Views... + + + + + About Qt... + + + + + About Quassel IRC... + + + + + Import Backlog + + + + + Connect + + + + + Internal + + + + + Disconnect from Core + + + + + Connect to Core... + + + + + Message + + + %DT[%1] + + + + + %DS<%1> + + + + + %D0%1 + + + + + %Ds* + + + + + %Ds%1 + + + + + %De* + + + + + %De%1 + + + + + %Dj--> + + + + + %Dj%DN%DU%1%DU%DN %DH(%2@%3)%DH has joined %DC%DU%4%DU%DC + + + + + %Dp<-- + + + + + %Dp%DN%DU%1%DU%DN %DH(%2@%3)%DH has left %DC%DU%4%DU%DC + + + + + %Dq<-- + + + + + %Dq%DN%DU%1%DU%DN %DH(%2@%3)%DH has quit + + + + + %Dk<-* + + + + + %Dk%DN%DU%1%DU%DN has kicked %DN%DU%2%DU%DN from %DC%DU%3%DU%DC + + + + + %Dr<-> + + + + + %DrYou are now known as %DN%1%DN + + + + + %Dr%DN%1%DN is now known as %DN%DU%2%DU%DN + + + + + %Dm*** + + + + + %DmUser mode: %DM%1%DM + + + + + %DmMode %DM%1%DM by %DN%DU%2%DU%DN + + + + + %Da-*- + + + + + %Da%DN%DU%1%DU%DN %2 + + + + + %De[%1] + + + + + NetworkEditDlg + + + Default Identity + + + + + Invalid Network Settings! + + + + + <b>Your network settings are invalid!</b><br>%1 + + + + + Network name already exists. + + + + + You need to enter at least one server for this network. + + + + + Edit Network Settings + + + + + Identity: + + + + + Network: + + + + + Group: + + + + + Edit... + + + + + Comment: + + + + + Auto-connect on startup + + + + + Servers + + + + + &Add... + + + + + &Edit... + + + + + De&lete + + + + + Move &Up + + + + + Move &Down + + + + + Perform + + + + + These commands are executed after connect. + + + + + NickEditDlg + + + Edit Nick + + + + + Nickname: + + + + + RenameIdentityDlg + + + Edit Identity Name + + + + + Identity: + + + + + Server + + + %1 has changed topic for %2 to: "%3" + + + + + No topic is set for %1. + + + + + Topic for %1 is "%2" + + + + + Topic set by %1 on %2 + + + + + There is a nickname in your identity's nicklist which contains illegal characters + + + + + Due to a bug in Unreal IRCd (and maybe other irc-servers too) we're unable to determine the erroneous nick + + + + + Please use: /nick <othernick> to continue or clean up your nicklist + + + + + Nick %1 contains illegal characters + + + + + No free and valid nicks in nicklist found. use: /nick <othernick> to continue + + + + + Nick %1 is already taken + + + + + Received CTCP PING request by %1 + + + + + Received CTCP VERSION request by %1 + + + + + Received unknown CTCP %1 by %2 + + + + + ServerEditDlg + + + Enter Server Details + + + + + Server address: + + + + + Port: + + + + + ServerListDlg + + + Remove Network? + + + + + Are you sure you want to delete the selected network(s)? + + + + + Server List + + + + + &Add... + + + + + &Edit... + + + + + &Delete + + + + + &Show this dialog on startup + + + + + &Connect + + + + + C&lose + + + + + SettingsDlg + + + Dialog + + + + + Settings + + + + + SignalProxy + + + Device given for ProxyType == Server, ignoring... + + + + + Cannot add more than one peer to a SignalProxy in client mode! + + + + + SqliteStorage + + + Could not open backlog database: %1 + + + + + Disabling logging... + + + + + Could not create backlog table: %1 + + + + diff --git a/src/common/main.cpp b/src/common/main.cpp index 18503f25..897208f8 100644 --- a/src/common/main.cpp +++ b/src/common/main.cpp @@ -20,6 +20,7 @@ #include "settings.h" #include +#include #if defined BUILD_CORE #include @@ -75,6 +76,13 @@ int main(int argc, char **argv) { Global::runMode = Global::Monolithic; QApplication app(argc, argv); #endif + +/* Just for testing + QTranslator translator; + translator.load(":i18n/quassel_de"); + app.installTranslator(&translator); +*/ + QCoreApplication::setOrganizationDomain("quassel-irc.org"); QCoreApplication::setApplicationName("Quassel IRC"); QCoreApplication::setOrganizationName("Quassel IRC Development Team");