Author: tchemit Date: 2012-09-18 19:14:25 +0200 (Tue, 18 Sep 2012) New Revision: 3649 Url: http://chorem.org/repositories/revision/lima/3649 Log: refs #754: Possibilit?\195?\169 de s?\195?\169lectionner la langue anglaise alors que la traduction n'est pas pr?\195?\169sente (ajout onglet pour aider ?\195?\160 la traduction) Modified: trunk/lima-business/pom.xml trunk/lima-callao/pom.xml trunk/lima-swing/pom.xml trunk/lima-swing/src/main/assembly/bin.xml trunk/lima-swing/src/main/java/org/chorem/lima/ui/MainViewHandler.java trunk/lima-swing/src/main/resources/i18n/lima-swing_en_GB.properties trunk/lima-swing/src/main/resources/i18n/lima-swing_fr_FR.properties trunk/pom.xml Modified: trunk/lima-business/pom.xml =================================================================== --- trunk/lima-business/pom.xml 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-business/pom.xml 2012-09-18 17:14:25 UTC (rev 3649) @@ -137,7 +137,7 @@ <plugins> <plugin> <groupId>org.nuiton.i18n</groupId> - <artifactId>maven-i18n-plugin</artifactId> + <artifactId>i18n-maven-plugin</artifactId> <executions> <execution> <goals> Modified: trunk/lima-callao/pom.xml =================================================================== --- trunk/lima-callao/pom.xml 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-callao/pom.xml 2012-09-18 17:14:25 UTC (rev 3649) @@ -110,7 +110,7 @@ </plugin> <plugin> <groupId>org.nuiton.i18n</groupId> - <artifactId>maven-i18n-plugin</artifactId> + <artifactId>i18n-maven-plugin</artifactId> <executions> <execution> <goals> Modified: trunk/lima-swing/pom.xml =================================================================== --- trunk/lima-swing/pom.xml 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-swing/pom.xml 2012-09-18 17:14:25 UTC (rev 3649) @@ -191,7 +191,7 @@ <plugin> <groupId>org.nuiton.i18n</groupId> - <artifactId>maven-i18n-plugin</artifactId> + <artifactId>i18n-maven-plugin</artifactId> <executions> <execution> <id>scan-sources</id> @@ -212,6 +212,10 @@ <goals> <goal>bundle</goal> </goals> + <configuration> + <generateCsvFile>true</generateCsvFile> + <bundleCsvFile>${project.build.directory}/lima-i18n.csv</bundleCsvFile> + </configuration> </execution> </executions> </plugin> Modified: trunk/lima-swing/src/main/assembly/bin.xml =================================================================== --- trunk/lima-swing/src/main/assembly/bin.xml 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-swing/src/main/assembly/bin.xml 2012-09-18 17:14:25 UTC (rev 3649) @@ -86,5 +86,12 @@ <include>*.properties</include> </includes> </fileSet> + <fileSet> + <directory>target</directory> + <outputDirectory>i18n</outputDirectory> + <includes> + <include>lima-i18n.csv</include> + </includes> + </fileSet> </fileSets> </assembly> Modified: trunk/lima-swing/src/main/java/org/chorem/lima/ui/MainViewHandler.java =================================================================== --- trunk/lima-swing/src/main/java/org/chorem/lima/ui/MainViewHandler.java 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-swing/src/main/java/org/chorem/lima/ui/MainViewHandler.java 2012-09-18 17:14:25 UTC (rev 3649) @@ -58,10 +58,16 @@ import org.nuiton.util.DesktopUtil; import org.nuiton.widget.SwingSession; -import javax.swing.*; +import javax.swing.ImageIcon; +import javax.swing.JButton; +import javax.swing.JEditorPane; +import javax.swing.JScrollPane; +import javax.swing.JTabbedPane; +import javax.swing.JTextArea; +import javax.swing.UIManager; import javax.swing.border.LineBorder; import javax.swing.plaf.BorderUIResource; -import java.awt.*; +import java.awt.Component; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.io.File; @@ -111,7 +117,7 @@ } //Get xml lima state file - protected File getLimaStateFile(){ + protected File getLimaStateFile() { LimaConfig limaConfig = LimaConfig.getInstance(); @@ -236,6 +242,19 @@ about.setIconPath("/icons/lima.png"); about.setLicenseFile("META-INF/lima-LICENSE.txt"); about.setThirdpartyFile("META-INF/lima-THIRD-PARTY.txt"); + + JScrollPane component = new JScrollPane(); + JEditorPane translateArea = new JEditorPane(); + translateArea.setContentType("text/html"); + translateArea.setEditable(false); + if (translateArea.getFont() != null) { + translateArea.setFont(translateArea.getFont().deriveFont((float) 11)); + } + translateArea.setBorder(null); + String text = _("lima.about.translate.content"); + translateArea.setText(text); + component.getViewport().add(translateArea); + about.getTabs().add(_("lima.title.about.translate"), component); about.init(); about.showInDialog(ui, true); } Modified: trunk/lima-swing/src/main/resources/i18n/lima-swing_en_GB.properties =================================================================== --- trunk/lima-swing/src/main/resources/i18n/lima-swing_en_GB.properties 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-swing/src/main/resources/i18n/lima-swing_en_GB.properties 2012-09-18 17:14:25 UTC (rev 3649) @@ -2,6 +2,7 @@ -= lima-business.document.entrybooks= lima-business.document.generalentrybook= +lima.about.translate.content=<h3>How to translate Lima</h3>You can help us to translate or improve label in Lima.<br/><ul><li>Get the <strong>lima-i18n.csv</strong> file in the <strong>i18n</strong> directory</li><li>open it in Libre office (separator caracter is <strong>Tab</strong>)</li><li>Do you work \:)</li><li>At last, send us back the modified file</li></ul><br/>We will apply the patch before next release. lima.accountsreports.listerror=Can't get entries list lima.action.commandline.help=Show help in console lima.action.fullscreen=Full screen @@ -209,6 +210,7 @@ lima.table.voucher=Voucher lima.title.about=About Lima... lima.title.about.description=Open sources accounting software +lima.title.about.translate=Translate Lima lima.tooltip.filter=<html>Regular expression \:<br/>- accounts interval i..j <br/>- accounts list i,j,k <br/>- Exclude an account -i</html> lima.tooltip.lettering=<html>Add a letter on many entries <br/>Select many rows with combination ctrl + click</html> lima.ui.account.addaccount= Modified: trunk/lima-swing/src/main/resources/i18n/lima-swing_fr_FR.properties =================================================================== --- trunk/lima-swing/src/main/resources/i18n/lima-swing_fr_FR.properties 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/lima-swing/src/main/resources/i18n/lima-swing_fr_FR.properties 2012-09-18 17:14:25 UTC (rev 3649) @@ -2,6 +2,7 @@ -= lima-business.document.entrybooks= lima-business.document.generalentrybook= +lima.about.translate.content=<h2>Comment traduire Lima</h2>Vous pouvez nous aider à traduire Lima.<hr/><br/><ul><li>Récupérer le fichier <strong>lima-i18n.csv</strong> dans le répertoire <strong>i18n</strong></li><li>ouvrez le avec un tableur (le caractère séprateur est une Tabultation)</li><li>Traduisez, Améliorer, ...</li><li>Enfin renvoyez-le nous</li></ul><br/>Nous intégrerons vos modifications avant la prochaine version. lima.accountsreports.listerror=Erreur lors de la récupération des données de la liste lima.action.commandline.help=Afficher l'aide en console lima.action.fullscreen=Plein Ecran @@ -208,6 +209,7 @@ lima.table.voucher=Pièce comptable lima.title.about=À propos de Lima... lima.title.about.description=Logiciel de comptabilité Libre +lima.title.about.translate=traduire Lima lima.tooltip.filter=<html>Expression régulière \:<br/>- intervalle de compte i..j <br/>- liste de compte i,j,k <br/>- Exclure un compte -i</html> lima.tooltip.lettering=<html>Pour ajouter une lettre à plusieurs écritures <br/>Sélectionner plusieurs lignes avec la combinaison ctrl + click</html> lima.ui.account.addaccount=Nouveau compte Modified: trunk/pom.xml =================================================================== --- trunk/pom.xml 2012-09-18 16:05:43 UTC (rev 3648) +++ trunk/pom.xml 2012-09-18 17:14:25 UTC (rev 3649) @@ -387,7 +387,7 @@ <eugenePluginVersion>2.4.2</eugenePluginVersion> <topiaVersion>2.6.11</topiaVersion> <jaxxVersion>2.5.5</jaxxVersion> - <nuitonI18nVersion>2.4.1</nuitonI18nVersion> + <nuitonI18nVersion>2.5</nuitonI18nVersion> <openEjbVersion>4.0.0</openEjbVersion> <slf4jVersion>1.6.6</slf4jVersion> <swingxVersion>1.6.4</swingxVersion> @@ -410,7 +410,7 @@ <!-- plugin i18n --> <plugin> <groupId>org.nuiton.i18n</groupId> - <artifactId>maven-i18n-plugin</artifactId> + <artifactId>i18n-maven-plugin</artifactId> <version>${nuitonI18nVersion}</version> </plugin>