MCPcopy Create free account
hub / github.com/SOUI2/soui / AppendFormatText

Method AppendFormatText

controls.extend/SChatEdit.cpp:31–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29 }
30
31 BOOL SChatEdit::AppendFormatText(const SStringW & strMsg,BOOL bNewLine,BOOL bCanUndo)
32 {
33 BOOL bRet = FALSE;
34 SStringW strBuf= L"<msg>"+strMsg+L"</msg>";
35 LPWSTR pszBuf = strBuf.GetBuffer(strBuf.GetLength());
36 {
37 pugi::xml_document doc;
38 if(doc.load_buffer_inplace(pszBuf,strBuf.GetLength()*2,pugi::parse_default,pugi::encoding_utf16))
39 {
40 bRet = AppendFormatText(doc.child(L"msg"),bNewLine,bCanUndo);
41 }
42 }
43 strBuf.ReleaseBuffer();
44 return bRet;
45 }
46
47 BOOL SChatEdit::AppendFormatText(const pugi::xml_node xmlMsg,BOOL bNewLine,BOOL bCanUndo)
48 {

Callers 5

OnBtnAppendMsgMethod · 0.80
RunMethod · 0.80
OnEventThreadStartMethod · 0.80
OnEventThreadStopMethod · 0.80
OnEventThreadMethod · 0.80

Calls 5

ReleaseBufferMethod · 0.80
GetBufferMethod · 0.45
GetLengthMethod · 0.45
load_buffer_inplaceMethod · 0.45
childMethod · 0.45

Tested by

no test coverage detected