MCPcopy Create free account
hub / github.com/cinience/RedisStudio / SetDefaultCharFormat

Method SetDefaultCharFormat

DuiLib/Control/UIRichEdit.cpp:1434–1448  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1432}
1433
1434bool CRichEditUI::SetDefaultCharFormat(CHARFORMAT2 &cf)
1435{
1436 if( !m_pTwh ) return false;
1437 cf.cbSize = sizeof(CHARFORMAT2);
1438 LRESULT lResult;
1439 TxSendMessage(EM_SETCHARFORMAT, 0, (LPARAM)&cf, &lResult);
1440 if( (BOOL)lResult == TRUE ) {
1441 CHARFORMAT2W cfw;
1442 cfw.cbSize = sizeof(CHARFORMAT2W);
1443 TxSendMessage(EM_GETCHARFORMAT, 1, (LPARAM)&cfw, 0);
1444 m_pTwh->SetCharFormat(cfw);
1445 return true;
1446 }
1447 return false;
1448}
1449
1450DWORD CRichEditUI::GetSelectionCharFormat(CHARFORMAT2 &cf) const
1451{

Callers

nothing calls this directly

Calls 1

SetCharFormatMethod · 0.80

Tested by

no test coverage detected