Date: prev next · Thread: first prev next last
2015 Archives by date, by thread · List index


Hi,

I agree that these examples are really useful. Could you provide also some examples for the other functions dealing with DBCS (LEFTB, RIGHTB, LENB)?
If so, I will add them to the Help text.

Thanks!
Stanislav


Dne 19.1.2015 v 16:11 Jesper Hertel napsal(a):
2015-01-19 15:32 GMT+01:00 Kevin Suo <suokunlong@126.com>:

A1 = "中国"
B1 = MIDB(A1,1,1) returns ""
B1 = MIDB(A1,1,2) returns "中"
B1 = MIDB(A1,1,3) returns "中"
B1 = MIDB(A1,1,4) returns "中国"


Thanks for the examples, Kevin! I was afraid they wouldn't go through the
maling list system, so that was why I didn't supply any. But yours are even
better than the ones I would have thought of providing.


I think it is better up to the localizer to translate this help text
according to their needs, for example Japanese team may show how this works
with Japanese chars.


I agree that the specific translation is up to the localizers. But even
people using a non-DBCS user interface language, such as English or Danish,
could want to use that function and could want to know what it is about and
how to use it; they could work with Japanese or another DBCS language
without having the user interface in that language. So I still believe the
English text could be improved. Both regarding the earlier mentioned
sentence and regarding the addition of several actual DBCS examples similar
to the good ones you provided. Maybe just worded and expanded like this to
show that the position argument is also counted in bytes and not in
character positions:

MIDB("中国",1,1) returns "" (1 byte is only half a character and it is
therefore discarded).
MIDB("中国",1,2) returns "中" (2 bytes are one complete character).
MIDB("中国",1,3) returns "中" (3 bytes are one character and a half; the last
byte is discarded).
MIDB("中国",1,4) returns "中国" (4 bytes are two complete characters).
MIDB("中国",2,1) returns "" (byte position 2 is not at the beginning of a
character).
MIDB("中国",2,2) returns "" (byte position 2 is not at the beginning of a
character).
MIDB("中国",3,1) returns "" (byte position 3 is at the beginning of a
character, but 1 byte is only half a character and is therefore discarded).
MIDB("中国",3,2) returns "国".


And yes, I do believe that this rather large amount of examples are
necessary to make it completely clear how this rather technical function
works, and that the Help should be the place for such an explanation.

Whether my explanations in parentheses are understandable or relevant I
don't know. It is an attempt to explain what is happening to the
not-so-technical users, but even also to technical users that want to be
sure they understood it right.


Jesper


--
To unsubscribe e-mail to: l10n+unsubscribe@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/l10n/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.