MCPcopy Create free account
hub / github.com/WinMerge/winmerge / SetCodepage

Method SetCodepage

Src/FileTextEncoding.cpp:29–47  ·  view source on GitHub ↗

* @brief Set codepage */

Source from the content-addressed store, hash-verified

27 * @brief Set codepage
28 */
29void FileTextEncoding::SetCodepage(int codepage)
30{
31 m_codepage = codepage;
32 switch (codepage)
33 {
34 case ucr::CP_UTF_8:
35 m_unicoding = ucr::UTF8;
36 break;
37 case ucr::CP_UCS2LE:
38 m_unicoding = ucr::UCS2LE;
39 break;
40 case ucr::CP_UCS2BE:
41 m_unicoding = ucr::UCS2BE;
42 break;
43 default:
44 m_unicoding = ucr::NONE;
45 break;
46 }
47}
48
49void FileTextEncoding::SetUnicoding(ucr::UNICODESET unicoding)
50{

Callers 15

ReadFileFunction · 0.45
ParseConflictFileFunction · 0.45
ApplyCodepageFunction · 0.45
DoFileNewMethod · 0.45
SanityCheckCodepageMethod · 0.45
GenerateReportMethod · 0.45
setCodepageMethod · 0.45
DoFileEncodingDialogMethod · 0.45
LoadFromFileMethod · 0.45
SaveToFileMethod · 0.45
GuessFunction · 0.45
GenerateReportMethod · 0.45

Calls

no outgoing calls

Tested by 1

TEST_PFunction · 0.36