Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Toolkit Pro
  New Posts New Posts RSS Feed - Markup parsing
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Markup parsing

 Post Reply Post Reply
Author
Message
gpm1 View Drop Down
Groupie
Groupie
Avatar

Joined: 06 June 2006
Status: Offline
Points: 54
Post Options Post Options   Thanks (0) Thanks(0)   Quote gpm1 Quote  Post ReplyReply Direct Link To This Post Topic: Markup parsing
    Posted: 12 June 2008 at 12:15pm
Hello,

In the file XTPMarkupDrawingContext.cpp there is next method:

CXTPMarkupObject* CXTPMarkupPoint::ConvertFrom(CXTPMarkupObject* pObject) const
{
    if (IsStringObject(pObject))
    {
        LPCWSTR lpszValue = *(CXTPMarkupString*)pObject;

        float x = 0 , y = 0;
        if (WSCANF_S(lpszValue, L"%f,%f", &x, &y) != 2)
            return FALSE;

        return new CXTPMarkupPoint(x, y);
    }
    return FALSE;
}

While parsing that block of xaml:

<LinearGradientBrush StartPoint="0, 0" EndPoint="0, 1">
 
on a PC with locales where decimal symbol is , parsing is failed. For correct parsing there shouldn't be decimal point the same.

Pavel
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 13 June 2008 at 6:28am

Hi,

Do you see it with our MarkupPad sample ?
I changed it in regional settings, but it works. 
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
gpm1 View Drop Down
Groupie
Groupie
Avatar

Joined: 06 June 2006
Status: Offline
Points: 54
Post Options Post Options   Thanks (0) Thanks(0)   Quote gpm1 Quote  Post ReplyReply Direct Link To This Post Posted: 13 June 2008 at 7:08am
Hi,

Try to set in App
setlocale( LC_ALL, "" );
and then open, with  , as decimal symbol.
Back to Top
Oleg View Drop Down
Senior Member
Senior Member


Joined: 21 May 2003
Location: United States
Status: Offline
Points: 11234
Post Options Post Options   Thanks (0) Thanks(0)   Quote Oleg Quote  Post ReplyReply Direct Link To This Post Posted: 18 June 2008 at 6:42am
Thanks. fixed for 12.0.1
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.031 seconds.