Author Topic: 3 localization plugin patches  (Read 6082 times)

Offline gd_on

  • Regular
  • ***
  • Posts: 412
3 localization plugin patches
« on: September 16, 2013, 07:11:55 pm »
3 small patches for localizing 3 plugins.

gd_on
« Last Edit: September 18, 2013, 09:15:37 am by gd_on »
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 10904
    • Travis build status
Re: 3 plugin patches
« Reply #1 on: September 18, 2013, 12:54:27 am »
All 5 are in svn. Next time please use a single topic and a more descriptive topic names if possible.

Thank you for the contribution.
Can I ask you to provide a patch which adds you to the "help -> about -> thanks to" dialog?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline gd_on

  • Regular
  • ***
  • Posts: 412
Re: 3 localization plugin patches
« Reply #2 on: September 18, 2013, 09:20:20 am »
Quote
Can I ask you to provide a patch which adds you to the "help -> about -> thanks to" dialog?
Why not, but my contributions are weak until now  :-\
Here is a new patch, complementary from a previous one (I forgot it yesterday  :-[).

gd_on
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 10904
    • Travis build status
Re: 3 localization plugin patches
« Reply #3 on: September 18, 2013, 10:25:41 am »
This patch won't be applied, because it tries to translate string that are commented or part of the output of cvs, which is not good.
I've also remove these parts from the other patch, too.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline gd_on

  • Regular
  • ***
  • Posts: 412
Re: 3 localization plugin patches
« Reply #4 on: September 18, 2013, 10:50:10 am »
Quote
This patch won't be applied, because it tries to translate string that are commented or part of the output of cvs, which is not good.
Sorry. I didn't thought this may be a problem. I just prepared for an eventual future translation if the lines were uncommented. Sorry again.

gd_on
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline gd_on

  • Regular
  • ***
  • Posts: 412
Re: 3 localization plugin patches
« Reply #5 on: September 20, 2013, 11:39:33 am »
Here is a corrected version : no translation in comments.
Hope it's OK now.

gd_on
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9447
Re: 3 localization plugin patches
« Reply #6 on: September 20, 2013, 02:21:35 pm »
Hope it's OK now.
I am not sure. The code you've patched is parses the output of a cvs command after calling the cvs executable. If you localise it, the parser is broken. I think in this file there really is nothing else to localise.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: http://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: http://wiki.codeblocks.org/index.php?title=FAQ

Offline gd_on

  • Regular
  • ***
  • Posts: 412
Re: 3 localization plugin patches
« Reply #7 on: September 20, 2013, 06:24:49 pm »
Sorry, but I don't understand what do you mean by "output of a cvs command".
On my PC, it works perfectly. Strings are translated as they should be and nothing seems to be broken: menus works as expected. Without this patch, they still appear in English.

gd_on
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 10904
    • Travis build status
Re: 3 localization plugin patches
« Reply #8 on: September 20, 2013, 06:38:53 pm »
He is talking about this change:
Code: [Select]
@@ -1798,17 +1798,17 @@
         VCSstate s;
         while(1)
         {
-            if(state==_T("Up-to-date"))
+            if(state==_("Up-to-date"))
             {
                 s.state=fvsVcUpToDate;
                 break;
             }
-            if(state==_T("Locally Modified"))
+            if(state==_("Locally Modified"))
             {
                 s.state=fvsVcModified;
                 break;
             }
-            if(state==_T("Locally Added"))
+            if(state==_("Locally Added"))
             {
                 s.state=fvsVcAdded;
                 break;

Can you try without it?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline gd_on

  • Regular
  • ***
  • Posts: 412
Re: 3 localization plugin patches
« Reply #9 on: September 20, 2013, 07:19:03 pm »
OK, I see now. Effectively it's not correct.
The problem now is that when I create a patch with Tortoise svn, I have some problems: I can't relly revert to the previous svn version, the one completly in english.
I tried to revert to a previous svn number, to delete the file, ... each time my previous modifications are still there and I'm not sure that the patch is correct. Strange!
I miss something ! ???

But may be I have nothing to do now because my errors have been corrected !

gd_on
« Last Edit: September 20, 2013, 07:29:05 pm by gd_on »
Windows 10 or 7, svn C::B (last version or almost!), WxWidgets 2.8.12, Compilers TDM 4.9.2 32 bits (gcc and gfortran installed in C:\MinGW32). Tests with C::B 64 bits and WxWidgets 2.8.12 or 3.1.1 (64 bits) compiled by TDM 4.9.2 in C:\MinGW64

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 10904
    • Travis build status
Re: 3 localization plugin patches
« Reply #10 on: September 20, 2013, 07:30:06 pm »
"svn revert file_path" should do it, if I remember correctly. I think there was a menu command, too.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]