Re: [website] templates: More protocol relative urls

2013-09-28 Thread Jactry Zeng
Hi André,

This patch seem let some urls in non-english version broken.
Such as some urls in this page in Chinese:
http://www.winehq.org/site/forums

>-[http://www.winehq.org/mailman/listinfo/wine-announce
">(取消)订阅]
>-[http://www.winehq.org/pipermail/wine-announce/";>存档 1]
>+   [(取消)订阅]
>+   [存档 1]

You will find there is a quotation mark in the end of some urls in this
page.
We may need to remove the / in the end?

>- Wine 将会永远是http://www.winehq.org/license"title="Wine
licensing">自由软件。
>+ Wine 将会永远是自由软件。

And the about page in Chinese, the urls of "自由软件" (Free Software) also been
broken.
There seem need a space or a enter between  the url and 'title'.

Thanks for your work!


2013/9/23 André Hentschel 

> ---
>  templates/he/about.template |  2 +-
>  templates/he/forums.template| 46
> +++
>  templates/he/help.template  |  8 +++
>  templates/he/home.template  |  4 ++--
>  templates/he/license.template   |  6 +++---
>  templates/he/resources.template |  6 +++---
>  templates/pl/forums.template|  2 +-
>  templates/pt/about.template |  4 ++--
>  templates/pt/forums.template| 48
> -
>  templates/pt/help.template  |  8 +++
>  templates/pt/home.template  |  4 ++--
>  templates/zh-cn/about.template  |  6 +++---
>  templates/zh-cn/forums.template | 44 ++---
>  templates/zh-cn/help.template   |  8 +++
>  templates/zh-cn/home.template   |  4 ++--
>  templates/zh-cn/irc.template|  4 ++--
>  16 files changed, 102 insertions(+), 102 deletions(-)
>
>
>
>
>
>


-- 
Regards,
Jactry Zeng



Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 5)

2013-09-27 Thread Jactry Zeng
Hi all,

I see this patch is in 'pending' now, are there anything needs to be
improved?
Please give me some advice.

Thank you.

-- 
Regards,
Jactry Zeng



Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 5)

2013-09-14 Thread Jactry Zeng
Hi Nikolay,
2013/9/13 Nikolay Sivov 
>
> Does it actually accept any other value besides CP_ACP or 1200?
Documentation is unclear here, and makes impression that only two these
values are valid.

Did you mean EM_SETTEXTEX?
I had some tests today. And I found native EM_SETTEXTEX can accept almost
all the codepage[0].
But when we use a "wrong"(such as 1201) codepage to open a ISO-8859 text it
will deal it with codepage 28591.

It is sure that EM_SETTEXTEX can appect CP_ACP, 1200 and CP_UTF8. CP_UTF8
was used to open a
UTF8 text which without BOM. I aslo tested this with native riched20.dll.

So I think let ME_ToUnicode can accept all the codepage is a good way to
add a UTF8 support for
EM_SETTEXTEX.

I appreciate for any comment. :-)

[0]
http://msdn.microsoft.com/en-us/library/windows/desktop/dd317756(v=vs.85).aspx
--
Regards,
Jactry Zeng



Re: [PATCH 3/3] riched20: Add UTF8 support for EM_SETTEXTEX. (try 6)

2013-09-13 Thread Jactry Zeng
Hi Nikolay,
2013/9/13 Nikolay Sivov 
>
> On 9/13/2013 15:05, Jactry Zeng wrote:
>>
>>   bUnicode = !bRtf && pStruct->codepage == CP_UNICODE;
>> +bUTF8 = (lParam && (!strncmp((char *)lParam, utf8_bom, 3)));
>
> What will happen if both of these are true? This needs a test with BOM
and 'codepage' set to 1200.

Thanks for your review.
The test showed that bUnicode have a higher priority that BOM.
I will try it again.


--
Regards,
Jactry Zeng



Re: [PATCH 3/3] riched20: Add UTF8 support for EM_SETTEXTEX. (try 5)

2013-09-13 Thread Jactry Zeng
2013/9/13 Alexandre Julliard 
>
> > @@ -3313,6 +3315,10 @@ LRESULT ME_HandleMessage(ME_TextEditor *editor,
UINT msg, WPARAM wParam,
> >  len = lParam ? strlen((char *)lParam) : 0;
> >}
> >  } else {
> > +  if(bUTF8) {
> > +lParam = lParam + 3;
> > +pStruct->codepage = CP_UTF8;
> > +  }
>
> That struct belongs to the caller, you can't change it.

Thank you for the review!
I have sent another try.

--
Regards,
Jactry Zeng



riched20/tests: Add tests for ITextDocument_Save. (try 2)

2013-09-11 Thread Jactry Zeng
Update: Add todo_wine
From 8f464b1ffa384ffba25af5041065c23d21ede041 Mon Sep 17 00:00:00 2001
From: Jactry Zeng 
Date: Wed, 11 Sep 2013 18:06:02 +0800
Subject: riched20/tests: Add tests for ITextDocument_Save.
To: wine-patches 
Reply-To: wine-devel 

---
 dlls/riched20/tests/richole.c |  102 +
 1 file changed, 102 insertions(+)

diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c
index 1bd0be9..71e456e 100644
--- a/dlls/riched20/tests/richole.c
+++ b/dlls/riched20/tests/richole.c
@@ -93,6 +93,22 @@ static void release_interfaces(HWND *w, IRichEditOle 
**reOle, ITextDocument **tx
   ITextSelection_Release(*txtSel);
 }
 
+static BOOL compare_text_with_file(LPWSTR filename, const CHAR *str, LPSTR 
*chBuffer)
+{
+  int size;
+  HANDLE hFile;
+  DWORD dwReadSize;
+
+  hFile = CreateFileW(filename, GENERIC_READ, FILE_SHARE_READ, NULL, 
OPEN_EXISTING,
+  FILE_ATTRIBUTE_NORMAL, NULL);
+  size = GetFileSize(hFile, NULL);
+  *chBuffer = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size+2);
+  ReadFile(hFile, *chBuffer, size+2, &dwReadSize, NULL);
+  CloseHandle(hFile);
+
+  return strcmp(*chBuffer, str);
+}
+
 static void test_Interfaces(void)
 {
   IRichEditOle *reOle = NULL;
@@ -331,6 +347,91 @@ static void test_ITextDocument_Open(void)
   DeleteFileW(filename);
 }
 
+static void test_ITextDocument_Save(void)
+{
+  IRichEditOle *reOle = NULL;
+  ITextDocument *txtDoc = NULL;
+  ITextSelection *txtSel = NULL;
+  HRESULT hres;
+  HWND w;
+  VARIANT testfile;
+  SETTEXTEX setText;
+  LPSTR chBuffer;
+  int result = 0;
+  WCHAR filename[] = {'t', 'e', 's', 't','.','t','x','t', 0};
+
+  static const int tomConstantsSingle[] =
+{
+  tomCreateAlways, tomOpenExisting, tomOpenAlways,
+  tomTruncateExisting
+};
+
+  int tomNumSingle =  sizeof(tomConstantsSingle)/sizeof(tomConstantsSingle[0]);
+  int i;
+  VariantInit(&testfile);
+  V_VT(&testfile) = VT_BSTR;
+  V_BSTR(&testfile) = SysAllocString(filename);
+
+  for(i=0; i < tomNumSingle; i++)
+{
+  touch_file(filename);
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  hres = ITextDocument_Save(txtDoc, &testfile, tomConstantsSingle[i], 
CP_ACP);
+  todo_wine ok(hres == S_OK, "ITextDocument_Save: Filename:test.txt 
Flags:0x%x Codepage:CP_ACP hres:0x%x\n",
+ tomConstantsSingle[i], hres);
+  release_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  DeleteFileW(filename);
+
+  touch_file(filename);
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  hres = ITextDocument_Save(txtDoc, &testfile, tomConstantsSingle[i], 
CP_UTF8);
+  todo_wine ok(hres == S_OK, "ITextDocument_Save: Filename:test.txt 
Flags:0x%x Codepage:CP_UTF8 hres:0x%x\n",
+ tomConstantsSingle[i], hres);
+  release_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  DeleteFileW(filename);
+}
+
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  setText.flags = 0;
+  setText.codepage = CP_UTF8;
+  SendMessage(w, EM_SETTEXTEX, (WPARAM)&setText, 
(LPARAM)"\xef\xbb\xbfTestUTF8WithBOM");
+  ITextDocument_Save(txtDoc, &testfile, tomCreateAlways, CP_ACP);
+  release_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  result = compare_text_with_file(filename, "TestUTF8WithBOM", &chBuffer);
+  todo_wine ok(result == 0, "ITextDocument_Save: Save UTF8 with BOM as ASCII 
got wrong text: %s\n", chBuffer);
+  DeleteFileW(filename);
+
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  setText.flags = 0;
+  setText.codepage = CP_UTF8;
+  SendMessage(w, EM_SETTEXTEX, (WPARAM)&setText, 
(LPARAM)"\xef\xbb\xbfTestUTF8WithBOM");
+  ITextDocument_Save(txtDoc, &testfile, tomCreateAlways, CP_UTF8);
+  release_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  result = compare_text_with_file(filename, "\xef\xbb\xbfTestUTF8WithBOM", 
&chBuffer);
+  todo_wine ok(result == 0, "ITextDocument_Save: Save UTF8 with BOM as UTF8 
with BOM got wrong text: %s\n", chBuffer);
+  DeleteFileW(filename);
+
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  setText.flags = 0;
+  setText.codepage = CP_ACP;
+  SendMessage(w, EM_SETTEXTEX, (WPARAM)&setText, (LPARAM)"TestUTF8WithBOM");
+  ITextDocument_Save(txtDoc, &testfile, tomCreateAlways, CP_ACP);
+  release_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  result = compare_text_with_file(filename, "TestUTF8WithBOM", &chBuffer);
+  todo_wine ok(result == 0, "ITextDocument_Save: Save ASCII as ASCII got wrong 
text: %s\n", chBuffer);
+  DeleteFileW(filename);
+
+  create_interfaces(&w, &reOle, &txtDoc, &txtSel);
+  setText

Implementation of ITextDocument_fnOpen needs some advice

2013-09-07 Thread Jactry Zeng
Hi folks,

  I need your advice or comment!

  Implement ITextDocument_fnOpen[0] (riched20) is a part of work to my
GSoC. The 'pencils down' date is
coming. And I think it is time to clear the code up.

  This series of patches is the implementation of ITextDocument_fnOpen. I
would like to improve it to be
enough good for sending to wine-patches and being accepted.

I split the implementation into six patches:
  - patch 0001 is just a simple implementation;
  - patch 0002 added the creation mode to let it support these
parameters: tomCreateNew, tomCreateAlways,
tomOpenExisting, tomOpenAlways, tomTruncateExisting;
  - patch 0003 added the access mode to let support tomReadOnly and any
combination of tomReadOnly and
tomShareDenyRead, tomShareDenyWrite, tomPasteFile;
  - patch 0004 added the support of RTF
  - patch 0005 added tomPasteFile support
  - patch 0006 added a UTF-16 support, with this patch you can open a UTF-6
text file without dependence of
the long CodePage parameter.

If you want to open a utf-8 text file with it, you may need these patch to
fix a bug of EM_SETTEXTEX:
http://source.winehq.org/patches/data/98574
http://source.winehq.org/patches/data/98575
http://source.winehq.org/patches/data/98576
http://source.winehq.org/patches/data/98577

  I appreciate for any comment! :)
  Thank you.


** Thanks my mentor Huw and Qian Hong for giving me a lot good advice.
Thanks other people for help! **



[0]
http://msdn.microsoft.com/en-us/library/windows/desktop/bb774093(v=vs.85).aspx
-- 
Regards,
Jactry Zeng
From 1d1cd63088503c171b4979d624ea03a3120a00e7 Mon Sep 17 00:00:00 2001
From: Jactry Zeng 
Date: Sat, 7 Sep 2013 16:29:46 +0800
Subject: [PATCH 1/6] riched20: Implement ITextDocument_fnOpen.

---
 dlls/riched20/richole.c   |   47 +++--
 dlls/riched20/tests/richole.c |8 +++
 2 files changed, 49 insertions(+), 6 deletions(-)

diff --git a/dlls/riched20/richole.c b/dlls/riched20/richole.c
index 6805873..e7da55f 100644
--- a/dlls/riched20/richole.c
+++ b/dlls/riched20/richole.c
@@ -582,8 +582,51 @@ ITextDocument_fnOpen(ITextDocument* me, VARIANT* pVar, 
LONG Flags,
 LONG CodePage)
 {
 IRichEditOleImpl *This = impl_from_ITextDocument(me);
-FIXME("stub %p\n",This);
-return E_NOTIMPL;
+
+HANDLE hFile;
+DWORD dwReadSize, size;
+SETTEXTEX settextex;
+LPSTR chBuffer;
+
+TRACE("(%p %p 0x%x %d)\n", me, pVar, Flags, CodePage);
+
+if(V_VT(pVar) != VT_BSTR) return E_INVALIDARG;
+
+hFile = CreateFileW(V_BSTR(pVar), GENERIC_READ|GENERIC_WRITE, 
FILE_SHARE_READ|
+FILE_SHARE_WRITE|FILE_SHARE_DELETE,
+NULL, OPEN_EXISTING, 0, NULL);
+
+if(hFile == INVALID_HANDLE_VALUE)
+return HRESULT_FROM_WIN32(GetLastError());
+
+settextex.codepage = CodePage;
+settextex.flags = ST_DEFAULT;
+
+size = GetFileSize(hFile, NULL);
+if(size == INVALID_FILE_SIZE)
+{
+CloseHandle(hFile);
+return HRESULT_FROM_WIN32(GetLastError());
+}
+
+chBuffer = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size+2);
+if(!chBuffer)
+{
+CloseHandle(hFile);
+return HRESULT_FROM_WIN32(GetLastError());
+}
+
+if(!ReadFile(hFile, chBuffer, size, &dwReadSize, NULL))
+{
+CloseHandle(hFile);
+HeapFree(GetProcessHeap(), 0, chBuffer);
+return HRESULT_FROM_WIN32(GetLastError());
+}
+
+SendMessageW(This->editor->hWnd, EM_SETTEXTEX, (int)&settextex, 
(LPARAM)chBuffer);
+CloseHandle(hFile);
+
+return S_OK;
 }
 
 static HRESULT WINAPI
diff --git a/dlls/riched20/tests/richole.c b/dlls/riched20/tests/richole.c
index 1bd0be9..6f2ed17 100644
--- a/dlls/riched20/tests/richole.c
+++ b/dlls/riched20/tests/richole.c
@@ -190,7 +190,7 @@ static void test_ITextDocument_Open(void)
   touch_file(filename);
   create_interfaces(&w, &reOle, &txtDoc, &txtSel);
   hres = ITextDocument_Open(txtDoc, &testfile, tomConstantsSingle[i], 
CP_ACP);
-  todo_wine ok(hres == S_OK, "ITextDocument_Open: Filename:test.txt 
Flags:0x%x Codepage:CP_ACP hres:0x%x\n",
+  ok(hres == S_OK, "ITextDocument_Open: Filename:test.txt Flags:0x%x 
Codepage:CP_ACP hres:0x%x\n",
  tomConstantsSingle[i], hres);
   release_interfaces(&w, &reOle, &txtDoc, &txtSel);
   DeleteFileW(filename);
@@ -198,7 +198,7 @@ static void test_ITextDocument_Open(void)
   touch_file(filename);
   create_interfaces(&w, &reOle, &txtDoc, &txtSel);
   hres = ITextDocument_Open(txtDoc, &testfile, tomConstantsSingle[i], 
CP_UTF8);
-  todo_wine ok(hres == S_OK, "ITextDocument_Open: Filename:test.txt 
Flags:0x%x Codepage:CP_UTF8 hres:0x%x\n",
+  ok(hres == S_OK, "ITextDocument_Open: Filename:test.txt Flags:0x%x 
Codepage:CP_UTF8 hres:0x%x\n",
  tomConstantsSingle[i], hres);
  

Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode. (try 2)

2013-09-04 Thread Jactry Zeng
Hi Nikolay,

2013/9/5 Nikolay Sivov 
>
> On 9/4/2013 07:17, Jactry Zeng wrote:
>>
>> -ME_EndToUnicode(unicode, wszText);
>> +ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText);
>
> It's still ugly to use magic numbers like that, in a similar situation I
had some time
> ago I use ~0 to mark WCHAR data encoding that does need special handling.
> Even with a value like ~0 it needs to be documented in code comments.
>

Thanks for your review!
But I still can't understand it. :(  Can you show me a commit as an example.

Thank you!

(sorry for forgeting cc wine-devel)
--
Regards,
Jactry Zeng



Re: [PATCH 1/3] riched20: Use codepage in ME_ToUnicode.

2013-09-03 Thread Jactry Zeng
Hi Phil,

2013/9/4 Phil Krylov 
>
> Hello,
>
> >-ME_EndToUnicode(unicode, wszText);
> >+unicode ? ME_EndToUnicode(1200, wszText) :
ME_EndToUnicode(CP_ACP, wszText);
>
> Personally I dislike this stuff in C code. Especially when you could
> make it shorter:
>
> ME_EndToUnicode(unicode ? 1200 : CP_ACP, wszText)

Thanks for your review and comment, I will try it again.
>
> -- Ph.
>
>



--
Regards,
Jactry Zeng



Re: po: update Simplified Chinese translation

2013-07-12 Thread Jactry Zeng
Thanks Qian Hong!
I sent a newer: http://source.winehq.org/patches/data/97285


-- 
Regards,
Jactry Zeng



po: update Simplified Chinese translation

2013-07-12 Thread Jactry Zeng

From df723cbfaf50152c1868481c2b3f80dc96ab2d28 Mon Sep 17 00:00:00 2001
From: Jactry 
Date: Fri, 12 Jul 2013 19:51:38 +0800
Subject: po: update Simplified Chinese translation.

---
 po/zh_CN.po | 90 -
 1 file changed, 29 insertions(+), 61 deletions(-)

diff --git a/po/zh_CN.po b/po/zh_CN.po
index ac1564e..8f30ab3 100644
--- a/po/zh_CN.po
+++ b/po/zh_CN.po
@@ -3338,16 +3338,12 @@ msgid "&Disable"
 msgstr "停用(&D)"
 
 #: joy.rc:37
-#, fuzzy
-#| msgid "&enable"
 msgid "&Enable"
 msgstr "启用(&E)"
 
 #: joy.rc:38
-#, fuzzy
-#| msgid "Disconnected"
 msgid "Connected"
-msgstr "连接断开"
+msgstr "已连接"
 
 #: joy.rc:40
 msgid "Disabled"
@@ -3372,10 +3368,8 @@ msgid "Test Force Feedback"
 msgstr ""
 
 #: joy.rc:64
-#, fuzzy
-#| msgid "Available formats"
 msgid "Available Effects"
-msgstr "可选格式"
+msgstr "可选效果"
 
 #: joy.rc:66
 msgid ""
@@ -3384,10 +3378,8 @@ msgid ""
 msgstr ""
 
 #: joy.rc:28
-#, fuzzy
-#| msgid "Create Control"
 msgid "Game Controllers"
-msgstr "建立控件"
+msgstr "游戏控制器"
 
 #: jscript.rc:25
 msgid "Error converting object to primitive type"
@@ -3526,10 +3518,8 @@ msgid "Number of fraction digits is out of range"
 msgstr ""
 
 #: jscript.rc:59
-#, fuzzy
-#| msgid "Print range"
 msgid "Precision is out of range"
-msgstr "打印范围"
+msgstr "精度超出范围"
 
 #: jscript.rc:60
 msgid "Array length must be a finite positive integer"
@@ -3568,9 +3558,8 @@ msgid "Invalid handle.\n"
 msgstr ""
 
 #: winerror.mc:61
-#, fuzzy
 msgid "Memory trashed.\n"
-msgstr "内存监视器。\n"
+msgstr "内存已回收。\n"
 
 #: winerror.mc:66
 msgid "Not enough memory.\n"
@@ -3666,16 +3655,15 @@ msgstr "读取错误。\n"
 
 #: winerror.mc:181
 msgid "General failure.\n"
-msgstr ""
+msgstr "一般性错误。\n"
 
 #: winerror.mc:186
 msgid "Sharing violation.\n"
-msgstr ""
+msgstr "非法共享。\n"
 
 #: winerror.mc:191
-#, fuzzy
 msgid "Lock violation.\n"
-msgstr "位置。\n"
+msgstr "非法锁定。\n"
 
 #: winerror.mc:196
 msgid "Wrong disk.\n"
@@ -4070,9 +4058,8 @@ msgid "Resource in use.\n"
 msgstr "资源已被占用。\n"
 
 #: winerror.mc:696
-#, fuzzy
 msgid "Cancel violation.\n"
-msgstr "信息。\n"
+msgstr "非法取消。\n"
 
 #: winerror.mc:701
 msgid "Atomic locks not supported.\n"
@@ -4539,9 +4526,8 @@ msgid "Driver failure cannot be detected.\n"
 msgstr ""
 
 #: winerror.mc:1281
-#, fuzzy
 msgid "Process abort cannot be detected.\n"
-msgstr "结束进程(&E)。\n"
+msgstr "进程中止未被检测到。\n"
 
 #: winerror.mc:1286
 msgid "No recovery program for service.\n"
@@ -5018,9 +5004,8 @@ msgid "The site does not exist.\n"
 msgstr "站点不存在。\n"
 
 #: winerror.mc:1881
-#, fuzzy
 msgid "The domain controller already exists.\n"
-msgstr "端口 %s 已经存在。\n"
+msgstr "该域控制器已存在。\n"
 
 #: winerror.mc:1886
 msgid "Supported only when connected.\n"
@@ -5259,9 +5244,8 @@ msgid "No such domain.\n"
 msgstr ""
 
 #: winerror.mc:2181
-#, fuzzy
 msgid "Domain already exists.\n"
-msgstr "端口 %s 已经存在。\n"
+msgstr "域名已存在。\n"
 
 #: winerror.mc:2186
 msgid "Domain limit exceeded.\n"
@@ -5437,9 +5421,8 @@ msgid "Invalid menu handle.\n"
 msgstr ""
 
 #: winerror.mc:2406
-#, fuzzy
 msgid "Invalid cursor handle.\n"
-msgstr "数字格式无效。\n"
+msgstr "无效光标句柄。\n"
 
 #: winerror.mc:2411
 msgid "Invalid accelerator table handle.\n"
@@ -5470,14 +5453,12 @@ msgid "Hotkey already registered.\n"
 msgstr "热键已被注册。\n"
 
 #: winerror.mc:2446
-#, fuzzy
 msgid "Class already exists.\n"
-msgstr "端口 %s 已经存在。\n"
+msgstr "该类已存在。\n"
 
 #: winerror.mc:2451
-#, fuzzy
 msgid "Class does not exist.\n"
-msgstr "路径不存在。\n"
+msgstr "该类不存在。\n"
 
 #: winerror.mc:2456
 #, fuzzy
@@ -5785,9 +5766,8 @@ msgid "Failed to open installation log file.\n"
 msgstr ""
 
 #: winerror.mc:2836
-#, fuzzy
 msgid "Installation language not supported.\n"
-msgstr "不支持 OLE 储存文件。\n"
+msgstr "不被支持的安装语言。\n"
 
 #: winerror.mc:2841
 msgid "Installation transform failed to apply.\n"
@@ -5930,14 +5910,12 @@ msgid "RPC server not listening.\n"
 msgstr ""
 
 #: winerror.mc:3011
-#, fuzzy
 msgid "Unknown manager type.\n"
-msgstr "不明类型。\n"
+msgstr "未知管理员类型。\n"
 
 #: winerror.mc:3016
-#, fuzzy
 msgid "Unknown interface.\n"
-msgstr "不明来源。\n"
+msgstr "未知界面。\n"
 
 #: winerror.mc:3021
 msgid "No bindings.\n"
@@ -6064,9 +6042,8 @@ msgid "Can't perform operation.\n"
 msgstr ""
 
 #: winerror.mc:3181
-#, fuzzy
 msgid "Endpoints not registered.\n"
-msgstr "退出注册表编辑器。\n"
+msgstr "终点尚未注册。\n"
 
 #: winerror.mc:3186
 msgid "Nothing to export.\n"
@@ -6388,9 +6365,8 @@ msgid "Wrong pipe version.\n"
 msgstr ""
 
 #: winerror.mc:3576
-#, fuzzy
 msgid "Group member not found.\n"
-msgstr "路径 %s 没找到。\n"
+msgstr "无法找到该群组成员。\n"
 
 #: winerror.mc:3581
 msgid "Can't create endpoint mapper DB.\n"
@@ -6429,9 +6405,8 @@ msgid "User must change password.\n"
 msgstr ""
 
 #: winerror.mc:3626
-#, fuzzy
 msgid "Domain controller not found.\n"
-msgstr "找不到文件。\n"
+msgstr "找不到域控制器。\n"
 
 #: winerror.mc:3631
 msgid "Account locked out.\n"
@@ -6500,29 +6475,24 @@ msgid "The interface could not be exported.\n"
 msgstr "不能导出接口。\n"
 
 #: winerror.mc:3711
-#, fuzzy
 msgid "The profile could not be added.\n"
-msgstr "找不到“%s”

Re: Should we translate the prompt

2013-07-09 Thread Jactry Zeng
Thanks Francois!
I will renew the Simplified Chinese translation in the next patch.


2013/7/8 Francois Gouget 

> On Sun, 7 Jul 2013, Jactry Zeng wrote:
> [...]
> > msgid "%1? (Yes|No)\n"
> [...]
> > When I discuss this with Qian Hong, he give a better idea. We may can
> just
> > make the origin text more apropos, just like:
> > msgid "%1? (Y)es|(N)o\n"
>
> I think this would look odd in English and that the original string is
> better.
>
>
> > So that we can translate it into Simplified Chinese:
> > msgid "%1?是(Y)|否(N)¥n"
>
> I think this translation would be ok, even for the original string. I
> see it as similar to the recommendation of following translated menu
> labels with with the original English hotkey in parentheses.
>
> We have very few places where we have this situation. As far as I
> know there is this message, the '(Yes|No|All)' version, and the
> following one:
>
> msgid ""
> "Is '%1' a filename or directory¥n"
> "on the target?¥n"
> "(F - File, D - Directory)¥n"
>
>
> Also, whichever way we go, I think it could apply equally well to
> the Traditional Chinese, Japanese and Korean translations too.
>
>
> --
> Francois Gouget   http://fgouget.free.fr/
>  The software said it requires Win95 or better, so I installed Linux.




-- 
Regards,
Jactry Zeng



Should we translate the prompt

2013-07-07 Thread Jactry Zeng
Hi everybody,

In po file there were some prompts as this:
#: xcopy.rc:35
msgid "%1? (Yes|No)\n"

I am not sure that should I translate them in po file for Simplified
Chinese. But they have been translated in po file for French and
Traditional Chinese.
As prompts in command line, I don't think translating them into another
language is good. It may make the users don't know what should them type
into.

When I discuss this with Qian Hong, he give a better idea. We may can just
make the origin text more apropos, just like:
msgid "%1? (Y)es|(N)o\n"

So that we can translate it into Simplified Chinese:
msgid "%1?是(Y)|否(N)\n"

Thanks for any comment.


-- 
Regards,
Jactry Zeng



Re: po: Update Simplified Chinese translation. (newer)

2013-07-05 Thread Jactry Zeng
2013/7/5 Andrew Eikum 
>
> It comes basically from the ERole enumeration in MMDevAPI:
>
http://msdn.microsoft.com/en-us/library/windows/desktop/dd370842%28v=vs.85%29.aspx
>
> The "Input device" maps to eConsole (and eMultimedia, which is
> identical to eConsole in modern Windows). The "Voice input device"
> maps to eCommunications.
>
> So, "human voice" is the intended meaning.
>
> Hope this clears it up!
Thanks Andrew.
I will add the new translation next time I sent a new patch.


-- 
Regards,
Jactry Zeng



Re: riched20: Added tests for ITextDocument::Open

2013-05-27 Thread Jactry Zeng
Thanks Nikolay and Alexandre, I will rewrite it and sent a improve version
later. :-)


On Tue, May 21, 2013 at 11:02 PM, Alexandre Julliard wrote:

> Jactry Zeng  writes:
>
> > diff --git a/dlls/riched20/tests/test.txt b/dlls/riched20/tests/test.txt
> > new file mode 100644
> > index 000..e69de29
>
> If you need an external file you have to create a temp file in the
> test. You can't rely on running from inside the source tree.
>
> --
> Alexandre Julliard
> julli...@winehq.org
>



-- 
Regards,
Jactry Zeng



Re: [website] Simplified Chinese translation for release 1.5.30

2013-05-11 Thread Jactry Zeng
Hi,

On Sat, May 11, 2013 at 3:28 PM, Qian Hong  wrote:
>
> 2013/5/11 Jactry Zeng :
> > + WinInet 对代理旁路的支持。
>
> This translation seems suspect, but I don't have a very good alternative
yet.
I also can think a word in Simplified China to describe it.
But I have found some documents about WinInet in Simplified Chinese[1], and
‘旁路' or '旁路列表'
was used to describe this process.


[1] http://baike.baidu.com/view/3077819.htm
 http://www.bcwhy.com/archiver/tid-4835.html
 http://www.4ucode.com/Study/Topic/1414214
>
> In 'Internet Options' setting of MSIE7, 'Bypass proxy server for local
> address' is translated to '跳过本地地址的代理服务器'
>
> Thanks for the work.


-- 
Regards,
Jactry Zeng



Re: Application for GSoC 2013 - improve Richedit

2013-04-23 Thread Jactry Zeng
2013/4/23 André Hentschel 
>
> Hi Jactry,
> thanks for the interest in Wine.
> I'm not that much familiar with Richedit, but as i understand you have
your own idea and it's not related to
> "Richedit - implement Windowless mode" from the ideas page. That's fine,
i'm just curious.
> Your idea sounds good and shows that you made your homework. In case it's
mostly implementing ITextDocument
> you should consider naming it something like "Implement/Improve
ITextDocument in Richedit".
> Today the Student application period opens, so be free to send in your
proposal.

Thanks André,
You are right, it is more accurate to name it as "Implement ITextDocument
in Richedit".
I submitted a appliction in GSoc's website .


-- 
Regards,
Jactry Zeng



Application for GSoC 2013 - improve Richedit

2013-04-22 Thread Jactry Zeng
Hi folks,

I am Jactry Zeng, a sophomore majoring in Electronic Science from China.
My nickname in #winehackers is Jactry.

I would like to apply for this year's GSoC to work for wine. I have
reported some bugs[1] of wine
and submitted a few easy patches[2] for wine. And I feel quite good to
study in wine community.

I am so interested in Richedit module[3]. Because a lot of software I
tested was blocked by bugs of
Richedit, such as wordpad, GTalk, QQ, Weibo Desktop and AliWangwang etc. I
would like to work for
this module during GSoC. I've reported a few bugs regarding Richedit[4].
And for bug 33191[5], I
have written a simple testcase to reproduce this bug.

And I found ITextDocument is just a stub now, I want to implement some
function of it, such as
ITextDocument::New, ITextDocument::Open, ITextDocument::Save,
ITextDocument::Range, ITextDocument
::GetName and ITextDocument::GetDefaultTabStop etc.
These functions are documented in MSDN[6], what's better, thanks to kind
people on codeproject[7],
there are some sample applications for study, which will give me a lot of
help on re-implementing
ITextDocument.

I think if I can finish this work, there are a lot of software will benefit
from it[8].

I appreciate for any comment.
Thank you. :-)


[1]
http://bugs.winehq.org/buglist.cgi?email1=jactry92%40gmail.com&emailtype1=exact&emailreporter1=1&list_id=103888
[2]http://source.winehq.org/git/wine.git/?a=search&h=HEAD&st=author&s=Jactry
[3]
http://bugs.winehq.org/buglist.cgi?cmdtype=runnamed&namedcmd=richedit&list_id=104361
[4]bug of Richedit I reported:
http://bugs.winehq.org/buglist.cgi?emailreporter1=1&emailtype1=exact&query_format=advanced&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=RESOLVED&email1=jactry92%40gmail.com&component=richedit&product=Wine&list_id=104257
[5]bug 33191: http://bugs.winehq.org/show_bug.cgi?id=33191
[6]http://social.msdn.microsoft.com/Search/en-US?query=ITextDocument&ac=4
[7]http://www.codeproject.com/search.aspx?q=ITextDocument&x=0&y=0&sbo=kw
[8]bug of ITextDocument:
http://bugs.winehq.org/buglist.cgi?quicksearch=ITextDocument&list_id=104255


-- 
Regards,
Jactry Zeng



Re: [PATCH 1/3] msvcrt: Added _mbsncoll and _mbsncoll_l implementation.

2013-04-19 Thread Jactry Zeng
Hi Akihiro,

2013/4/19 Akihiro Sagawa 
>
> According to MSDN, _mbsncoll_l receives a number of characters, but
> _mbsnbcoll_l receives a number of bytes. This is a big difference in
> multibyte code page.
> So you should properly handle this situation, or add FIXME message based
> on multibyte code page if your application just needs this function.

Thanks for your review. :-)
I will tried to improve it.


-- 
Regards,
Jactry Zeng



Re: Problem about declarations of strcoll functions

2013-04-01 Thread Jactry Zeng
Thanks Nikolay and Piotr.
Sorry for my poor english... :-(

2013/4/1 Piotr Caban 
>
> The functions should have been defined in headers. The order of
definitions is not important.
Piotr got what I wanted to express.
I have implemented a few of it and there are some still not. I think I can
define all of them in the next
time I sent a patch for other scoll functions.


-- 
Regards,
Jactry Zeng



Problem about declarations of strcoll functions

2013-03-31 Thread Jactry Zeng
Hi folks,

I tried to implement a lot of strcoll function these days, and I meet some
trouble when I added the declaration into include/msvcrt/*.h.

With "grep coll *.spec" in dlls/msvcrt/ we can find there was a lot of
strcoll function. Some of them was implemented
and some of them not:
@ cdecl ___lc_collate_cp_func()
@ stub __lc_collate
@ extern __lc_collate_cp MSVCRT___lc_collate_cp
@ cdecl _mbscoll(str str)
@ cdecl _mbscoll_l(str str ptr)
@ cdecl _mbsicoll(str str)
@ cdecl _mbsicoll_l(str str ptr)
@ cdecl _mbsnbcoll(str str long)
@ cdecl _mbsnbcoll_l(str str long ptr)
@ cdecl _mbsnbicoll(str str long)
@ cdecl _mbsnbicoll_l(str str long ptr)
@ stub _mbsncoll(str str long)
# stub _mbsncoll_l(str str long ptr)
@ stub _mbsnicoll(str str long)
# stub _mbsnicoll_l(str str long ptr)
@ cdecl _strcoll_l(str str ptr) MSVCRT_strcoll_l
@ cdecl _stricoll(str str) MSVCRT__stricoll
@ cdecl _stricoll_l(str str ptr) MSVCRT__stricoll_l
@ cdecl _strncoll(str str long) MSVCRT_strncoll_l
@ cdecl _strncoll_l(str str long ptr) MSVCRT_strncoll
@ cdecl _strnicoll(str str long) MSVCRT__strnicoll
@ cdecl _strnicoll_l(str str long ptr) MSVCRT__strnicoll_l
# stub _wcscoll_l(wstr wstr ptr)
@ cdecl _wcsicoll(wstr wstr) MSVCRT__wcsicoll
# stub _wcsicoll_l(wstr wstr ptr)
@ cdecl _wcsncoll(wstr wstr long) MSVCRT__wcsncoll
@ cdecl _wcsncoll_l(wstr wstr long ptr) MSVCRT__wcsncoll_l
@ cdecl _wcsnicoll(wstr wstr long) MSVCRT__wcsnicoll
# stub _wcsnicoll_l(wstr wstr long ptr)
@ cdecl strcoll(str str) MSVCRT_strcoll
@ cdecl wcscoll(wstr wstr) MSVCRT_wcscoll

With "grep coll *.h" in include/msvcrt/ we can find some declarations of
some strcoll function:
crtdefs.h:unsigned int lc_collate_cp;
mbstring.h:int__cdecl _mbscoll(const unsigned char*,const
unsigned char*);
mbstring.h:int__cdecl _mbsicoll(const unsigned char*,const
unsigned char*);
mbstring.h:int__cdecl _mbsnbcoll(const unsigned char*,const
unsigned char*,size_t);
mbstring.h:int__cdecl _mbsnbicoll(const unsigned char*,const
unsigned char*,size_t);
mbstring.h:int__cdecl _mbsncoll(const unsigned char*,const
unsigned char*,size_t);
mbstring.h:int__cdecl _mbsnicoll(const unsigned char*,const
unsigned char*,size_t);
string.h:int   __cdecl _stricoll(const char*,const char*);
string.h:int __cdecl strcoll(const char*,const char*);
string.h:int  __cdecl _wcsicoll(const wchar_t*,const wchar_t*);
string.h:int  __cdecl _wcsnicoll(const wchar_t*,const wchar_t*,size_t);
string.h:int  __cdecl wcscoll(const wchar_t*,const wchar_t*);
string.h:static inline int stricoll(const char* s1, const char* s2) {
return _stricoll(s1, s2); }
string.h:static inline int wcsicoll(const wchar_t* str1, const wchar_t*
str2) { return _wcsicoll(str1, str2); }
wchar.h:int  __cdecl _wcsicoll(const wchar_t*,const wchar_t*);
wchar.h:int  __cdecl _wcsnicoll(const wchar_t*,const wchar_t*,size_t);
wchar.h:int  __cdecl wcscoll(const wchar_t*,const wchar_t*);

As we can see, _strcoll_l and _mbsnbcoll_l were implemented but they were
not declared.
Should we declare all of them? And whether the sequence was important?

Thank you.
-- 
Regards,
Jactry Zeng



[website try2] Simplified Chinese translation for release 1.5.27

2013-03-30 Thread Jactry Zeng

From 72f3d5b7021472bf4a2aa6cc2c973319bbc786d4 Mon Sep 17 00:00:00 2001
From: Jactry Zeng 
Date: Sun, 31 Mar 2013 10:39:28 +0800
Subject: Simplified Chinese translation for release 1.5.27
To: wine-patches 
Reply-To: wine-devel 

---
 news/zh-cn/2013032901.xml | 15 +++
 1 file changed, 15 insertions(+)
 create mode 100644 news/zh-cn/2013032901.xml

diff --git a/news/zh-cn/2013032901.xml b/news/zh-cn/2013032901.xml
new file mode 100644
index 000..2e4e31b
--- /dev/null
+++ b/news/zh-cn/2013032901.xml
@@ -0,0 +1,15 @@
+
+三月 29, 2013
+Wine 1.5.27 发布
+
+ Wine 开发版 1.5.27 现在可以使用了。
+ 本次更新:
+
+  Mac 后端驱动对系统托盘的支持。
+  一些 C runtime 的改进。
+  为内建程序提供更高分辨率的图标。
+  各种 bug 修复。
+
+源代码可以从http://prdownloads.sourceforge.net/wine/wine-1.5.27.tar.bz2";>这里获取。
+二进制包正在构建中,稍后将出现在各自相应的下载位置。
+
-- 
1.8.1.3




Re: [website] Simplified Chinese translation for release 1.5.27

2013-03-30 Thread Jactry Zeng
2013/3/30 Hin-Tak Leung 
>
>
> I think both are terrible translations but could not think of a better
alternative off my head, so I went to consult google translate. It defaults
to �\行�r�� for "runtime library" but allow me to choose a few other
alternatives, among which is
>
> "�绦须A段程式��"
>
> Don't you think that's much better!?

Hi Hin-Tak,

Thanks for your review.

I also think both "运行时" or "运行时库" was not best translation. But I have seen
a lot of documents in
Simplified Chinese translated it in this way.
Maybe it was not too accurate...
And in my opinion, "运行时" meaning some function, "运行时库" meaning a runtime
library.


2013/3/30 Jactry Zeng 
>
> I translated it as "高质量" meaning a picture have hight resolution.
Here has a typo, hight -> higher 
-- 
Regards,
Jactry Zeng



Re: [website] Simplified Chinese translation for release 1.5.27

2013-03-30 Thread Jactry Zeng
2013/3/30 Qian Hong 
> 2013/3/30 Jactry Zeng :
> > + 一些 C 运行时的改进。
>
> I think it is better to translate "C runtime" to “C 运行时库“ rather than
> just ”C 运行时“。
>
> + 为内建程序提供更高质量的图标。
>
> Large icon means 大图标,not 高质量图标。You can verify this by the git commits。
In fact, I have verified it before I commit this patch.
I translated it as "高质量" meaning a picture have hight resolution.
For a example, programs/wordpad/wordpad.ico, had a 48x48 resolution before,
and now it is 256x256.

> Thanks for the work.

Thanks for your review. I will commit a newer patch. :-)


-- 
Regards,
Jactry Zeng



Re: [website] Simplified Chinese translation for release 1.5.24

2013-02-15 Thread Jactry Zeng
Oops...I made a mistake, this is the patch.
So sorry :-(
From 4d2eac6fae9614a7f8c20eb3de02b77d85b20d03 Mon Sep 17 00:00:00 2001
From: Jactry Zeng 
Date: Sat, 16 Feb 2013 11:35:41 +0800
Subject: Simplified Chinese translation for release 1.5.24
To: wine-patches 
Reply-To: wine-devel 

---
 news/zh-cn/2013021501.xml | 15 +++
 1 file changed, 15 insertions(+)
 create mode 100644 news/zh-cn/2013021501.xml

diff --git a/news/zh-cn/2013021501.xml b/news/zh-cn/2013021501.xml
new file mode 100644
index 000..ed83791
--- /dev/null
+++ b/news/zh-cn/2013021501.xml
@@ -0,0 +1,15 @@
+
+二月 15, 2013
+Wine 1.5.24 发布
+
+ Wine 开发版 1.5.24 现在可以使用了。
+ 本次更新:
+
+  Mac 后端驱动对键盘和鼠标滚轮的支持。
+  VB Script 对正则表达式的支持。
+  许多 RichEdit 代码的清理。
+  各种 bug 修复。
+
+源代码可以从http://prdownloads.sourceforge.net/wine/wine-1.5.24.tar.bz2";>这里获取。
+二进制包正在构建中,稍后将出现在各自相应的下载位置。
+
-- 
1.7.12.4 (Apple Git-37)




Re: Where to put Chinese translation of the Wine user guide?

2013-02-14 Thread Jactry Zeng
Thanks André. I will spend some time to push forward this work. :-)


2013/2/12 André Hentschel 

> Am 12.02.2013 13:10, schrieb Jactry Zeng:
> > Hi folks,
> >
> > A Chinese Wine user Liu Hongcong had translated [1] the Wine user guide
> > [2] to Chinese three years ago, the translation looks mostly good to me.
> > It  is a pity to leave his translation outside of the official wine
> website.
> > With his consent, I want to put his translation to winehq. But I can't
> find
> > where to add it into in website's source [3]. Or I should add it into
> wiki?
> >
> > Thanks for any comment!
> >
> > [1] http://blog.csdn.net/hongmy525/article/details/2238600
> > [2] http://www.winehq.org/docs/wineusr-guide/index
> > [3] http://source.winehq.org/git/website.git/
>
> It belongs here: http://source.winehq.org/git/docs.git/tree
> The guides have a po system it seems. see the "fr" folder for the french
> translation.
> It might make it a harder work than just copy&paste, though it's maybe a
> good idea that this get's touched again.
>
>
> --
>
> Best Regards, André Hentschel
>



Where to put Chinese translation of the Wine user guide?

2013-02-12 Thread Jactry Zeng
Hi folks,

A Chinese Wine user Liu Hongcong had translated [1] the Wine user guide
[2] to Chinese three years ago, the translation looks mostly good to me.
It  is a pity to leave his translation outside of the official wine website.
With his consent, I want to put his translation to winehq. But I can't find
where to add it into in website's source [3]. Or I should add it into wiki?

Thanks for any comment!

[1] http://blog.csdn.net/hongmy525/article/details/2238600
[2] http://www.winehq.org/docs/wineusr-guide/index
[3] http://source.winehq.org/git/website.git/