Ignore:
Timestamp:
Sep 5, 2020, 7:17:44 PM (5 years ago)
Author:
pr
Message:

Add BSUString copy constructor for codepaged C strings.
Substitute "(C)" for copyright symbol on unsupported codepages.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/cppbase/bs_string_conv.cpp

    r370 r449  
    4848#pragma hdrstop
    4949
    50 #define CP_UTF8         1208
     50#define CP_UTF8         1208
     51#define UNI_COPYRIGHT   0xA9
    5152
    5253DEFINE_CLASS(BSUniCodec, BSRoot);
     
    255256 *
    256257 *@@changed WarpIN V1.0.18 (2008-09-24) [pr]: added codepage 1208 support @@fixes 1127
     258 *@@changed WarpIN V1.0.25 (2020-09-05) [pr]: added copyright symbol substitution
    257259 */
    258260
     
    282284        {
    283285            if (us == 0xFFFF)
    284                 us = '?';
     286                if (ulUni == UNI_COPYRIGHT)
     287                {
     288                    xstrcat(&xstrNew, "(C)", 3);
     289                    continue;
     290                }
     291                else
     292                    us = '?';
    285293            else if (_fDouble)
    286294            {
Note: See TracChangeset for help on using the changeset viewer.