View | Details | Raw Unified | Return to issue 93503
Collapse All | Expand All

(-)a/svl/source/numbers/zformat.cxx (-8 / +44 lines)
Lines 1143-1148 short SvNumberformat::ImpNextSymbol(Stri Link Here
1143
                                 xub_StrLen& nPos,
1143
                                 xub_StrLen& nPos,
1144
                                 String& sSymbol)
1144
                                 String& sSymbol)
1145
{
1145
{
1146
    xub_StrLen pos;
1147
    if ( ( pos = rString.SearchAscii( "[$-", 0 ) ) != STRING_NOTFOUND )
1148
    {
1149
        if ( rString.GetChar(pos+10) == ']' )
1150
        {
1151
            if ( rString.GetChar(4) == '0' && rString.GetChar(5) == '7' )
1152
            {
1153
                rString.InsertAscii( "[~buddhist]", pos+11 );
1154
            }
1155
            if ( rString.GetChar(3) == 'D' )
1156
            {
1157
                rString.InsertAscii( "[NatNum1]", pos+11 );
1158
            }
1159
        }
1160
    }
1161
1146
    short eSymbolType = BRACKET_SYMBOLTYPE_FORMAT;
1162
    short eSymbolType = BRACKET_SYMBOLTYPE_FORMAT;
1147
    sal_Unicode cToken;
1163
    sal_Unicode cToken;
1148
    sal_Unicode cLetter = ' ';                               // Zwischenergebnis
1164
    sal_Unicode cLetter = ' ';                               // Zwischenergebnis
Lines 4209-4214 String SvNumberformat::GetMappedFormatst Link Here
4209
            nSem++;
4225
            nSem++;
4210
4226
4211
        String aPrefix;
4227
        String aPrefix;
4228
        bool LCIDInserted = FALSE;
4212
4229
4213
        if ( !bDefaults )
4230
        if ( !bDefaults )
4214
        {
4231
        {
Lines 4242-4255 String SvNumberformat::GetMappedFormatst Link Here
4242
        }
4259
        }
4243
4260
4244
        const SvNumberNatNum& rNum = NumFor[n].GetNatNum();
4261
        const SvNumberNatNum& rNum = NumFor[n].GetNatNum();
4245
        // The Thai T NatNum modifier during Xcl export.
4246
        if (rNum.IsSet() && rNum.GetNatNum() == 1 &&
4247
                rKeywords[NF_KEY_THAI_T].EqualsAscii( "T") &&
4248
                MsLangId::getRealLanguage( rNum.GetLang()) ==
4249
                LANGUAGE_THAI)
4250
        {
4251
            aPrefix += 't';     // must be lowercase, otherwise taken as literal
4252
        }
4253
4262
4254
        USHORT nAnz = NumFor[n].GetnAnz();
4263
        USHORT nAnz = NumFor[n].GetnAnz();
4255
        if ( nSem && (nAnz || aPrefix.Len()) )
4264
        if ( nSem && (nAnz || aPrefix.Len()) )
Lines 4309-4314 String SvNumberformat::GetMappedFormatst Link Here
4309
                                aStr += '"';
4318
                                aStr += '"';
4310
                            }
4319
                            }
4311
                            break;
4320
                            break;
4321
                        case NF_SYMBOLTYPE_CALDEL :
4322
                            if ( pStr[j+1].EqualsAscii("buddhist") )
4323
                            {
4324
                                aStr.InsertAscii( "[$-", aStr.Len() );
4325
                                if ( rNum.IsSet() && rNum.GetNatNum() == 1 &&
4326
                                        MsLangId::getRealLanguage( rNum.GetLang() ) ==
4327
                                        LANGUAGE_THAI )
4328
                                {
4329
                                    aStr.InsertAscii( "D07041E]", aStr.Len() );
4330
                                }
4331
                                else
4332
                                {
4333
                                    aStr.InsertAscii( "107041E]", aStr.Len() );
4334
                                }
4335
                                j = j+2;
4336
                            }
4337
                            LCIDInserted = TRUE;
4338
                        break;
4312
                        default:
4339
                        default:
4313
                            aStr += pStr[j];
4340
                            aStr += pStr[j];
4314
                    }
4341
                    }
Lines 4316-4321 String SvNumberformat::GetMappedFormatst Link Here
4316
                }
4343
                }
4317
            }
4344
            }
4318
        }
4345
        }
4346
        // The Thai T NatNum modifier during Xcl export.
4347
        if (rNum.IsSet() && rNum.GetNatNum() == 1 &&
4348
                rKeywords[NF_KEY_THAI_T].EqualsAscii( "T") &&
4349
                MsLangId::getRealLanguage( rNum.GetLang()) ==
4350
                LANGUAGE_THAI && !LCIDInserted )
4351
        {
4352
            
4353
            aStr.InsertAscii( "[$-D00041E]", 0 );
4354
        }
4319
    }
4355
    }
4320
    for ( ; nSub<4 && bDefault[nSub]; ++nSub )
4356
    for ( ; nSub<4 && bDefault[nSub]; ++nSub )
4321
    {   // append empty subformats
4357
    {   // append empty subformats

Return to issue 93503