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

Method DefAttributeProc

SOUI/src/control/SRichEdit.cpp:1001–1134  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

999}
1000
1001HRESULT SRichEdit::DefAttributeProc(const SStringW & strAttribName,const SStringW & strValue, BOOL bLoading)
1002{
1003 HRESULT hRet=S_FALSE;
1004 DWORD dwBit=0,dwMask=0;
1005 //hscrollbar
1006 if(strAttribName.CompareNoCase(L"hscrollBar")==0)
1007 {
1008 if(strValue==L"0")
1009 m_dwStyle&=~WS_HSCROLL;
1010 else
1011 m_dwStyle|=WS_HSCROLL;
1012 dwBit|=TXTBIT_SCROLLBARCHANGE;
1013 dwMask|=TXTBIT_SCROLLBARCHANGE;
1014 }
1015 //vscrollbar
1016 else if(strAttribName.CompareNoCase(L"vscrollBar")==0)
1017 {
1018 if(strValue==L"0")
1019 m_dwStyle&=~WS_VSCROLL;
1020 else
1021 m_dwStyle|=WS_VSCROLL;
1022 dwBit|=TXTBIT_SCROLLBARCHANGE;
1023 dwMask|=TXTBIT_SCROLLBARCHANGE;
1024 }
1025 //auto hscroll
1026 else if(strAttribName.CompareNoCase(L"autoHscroll")==0)
1027 {
1028 if(strValue==L"0")
1029 m_dwStyle&=~ES_AUTOHSCROLL;
1030 else
1031 m_dwStyle|=ES_AUTOHSCROLL;
1032 dwBit|=TXTBIT_SCROLLBARCHANGE;
1033 dwMask|=TXTBIT_SCROLLBARCHANGE;
1034 }
1035 //auto hscroll
1036 else if(strAttribName.CompareNoCase(L"autoVscroll")==0)
1037 {
1038 if(strValue==L"0")
1039 m_dwStyle&=~ES_AUTOVSCROLL;
1040 else
1041 m_dwStyle|=ES_AUTOVSCROLL;
1042 dwBit|=TXTBIT_SCROLLBARCHANGE;
1043 dwMask|=TXTBIT_SCROLLBARCHANGE;
1044 }
1045 //multilines
1046 else if(strAttribName.CompareNoCase(L"multiLines")==0)
1047 {
1048 if(strValue==L"0")
1049 m_dwStyle&=~ES_MULTILINE;
1050 else
1051 m_dwStyle|=ES_MULTILINE,dwBit|=TXTBIT_MULTILINE;
1052 dwMask|=TXTBIT_MULTILINE;
1053 }
1054 //readonly
1055 else if(strAttribName.CompareNoCase(L"readOnly")==0)
1056 {
1057 if(strValue==L"0")
1058 m_dwStyle&=~ES_READONLY;

Callers

nothing calls this directly

Calls 1

CompareNoCaseMethod · 0.80

Tested by

no test coverage detected