From 6c2cd9c7289fcfe19d5c112371d6125f4763655e Mon Sep 17 00:00:00 2001
From: Sebastião Guerra <sebastiao.luiz.guerra@gmail.com>
Date: Sun, 20 Sep 2026 18:06:14 -0300
Subject: Replace zero pointer constants with nullptr
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Sebastião Guerra <sebastiao.luiz.guerra@gmail.com>
---
 lib/libchmfile/libchmfileimpl.cpp      |  22 +--
 lib/libchmfile/libchmtextencoding.cpp  | 272 ++++++++++++++++-----------------
 lib/tdeio-msits/msits.cpp              |   6 +-
 src/iconstorage.cpp                    |   4 +-
 src/kchmbookmarkwindow.cpp             |   4 +-
 src/kchmbookmarkwindow.h               |   2 +-
 src/kchmcontentswindow.cpp             |   4 +-
 src/kchmcontentswindow.h               |   2 +-
 src/kchmdialogchooseurlfromlist.cpp    |   2 +-
 src/kchmindexwindow.cpp                |   4 +-
 src/kchmindexwindow.h                  |   2 +-
 src/kchmkeyeventfilter.cpp             |   2 +-
 src/kchmmainwindow.cpp                 |  28 ++--
 src/kchmsearchengine.cpp               |  12 +-
 src/kchmsearchengine_impl.cpp          |   8 +-
 src/kchmsearchtoolbar.cpp              |   6 +-
 src/kchmsearchwindow.cpp               |   8 +-
 src/kchmsearchwindow.h                 |   2 +-
 src/kchmsetupdialog_impl.h             |   2 +-
 src/kchmsourcefactory.cpp              |   2 +-
 src/kchmtreeviewitem.cpp               |  18 +--
 src/kchmviewwindow.cpp                 |   4 +-
 src/kchmviewwindow_qtextbrowser.cpp    |   4 +-
 src/kchmviewwindowmgr.cpp              |   2 +-
 src/kchmviewwindowmgr.h                |   2 +-
 src/tde-tqt.cpp                        |   4 +-
 src/tde-tqt.h                          |   8 +-
 src/tde/kchmdcopiface.h                |   2 +-
 src/tde/kchmviewwindow_tdehtmlpart.cpp |   6 +-
 29 files changed, 222 insertions(+), 222 deletions(-)

diff --git a/lib/libchmfile/libchmfileimpl.cpp b/lib/libchmfile/libchmfileimpl.cpp
index 682483c..cff9840 100644
--- a/lib/libchmfile/libchmfileimpl.cpp
+++ b/lib/libchmfile/libchmfileimpl.cpp
@@ -60,10 +60,10 @@ LCHMFileImpl::LCHMFileImpl( )
 	m_chmFile = nullptr;
 	m_home = m_filename = m_home = m_topicsFile = m_indexFile = m_font = TQString();
 	m_entityDecodeMap.clear();
-	m_textCodec = 0;
-	m_textCodecForSpecialFiles = 0;
+	m_textCodec = nullptr;
+	m_textCodecForSpecialFiles = nullptr;
 	m_detectedLCID = 0;
-	m_currentEncoding = 0;
+	m_currentEncoding = nullptr;
 }
 
 
@@ -94,9 +94,9 @@ bool LCHMFileImpl::loadFile( const TQString & archiveName )
 	m_filename = filename;
 	
 	// Reset encoding
-	m_textCodec = 0;
-	m_textCodecForSpecialFiles = 0;
-	m_currentEncoding = 0;
+	m_textCodec = nullptr;
+	m_textCodecForSpecialFiles = nullptr;
+	m_currentEncoding = nullptr;
 	
 	// Get information from /#WINDOWS and /#SYSTEM files (encoding, title, context file and so)
 	// and guess the encoding
@@ -135,10 +135,10 @@ void LCHMFileImpl::closeAll( )
 	m_chmFile = nullptr;
 	m_home = m_filename = m_home = m_topicsFile = m_indexFile = m_font = TQString();
 	m_entityDecodeMap.clear();
-	m_textCodec = 0;
-	m_textCodecForSpecialFiles = 0;
+	m_textCodec = nullptr;
+	m_textCodecForSpecialFiles = nullptr;
 	m_detectedLCID = 0;
-	m_currentEncoding = 0;
+	m_currentEncoding = nullptr;
 }
 
 
@@ -1171,9 +1171,9 @@ bool LCHMFileImpl::setCurrentEncoding( const LCHMTextEncoding * encoding )
 
 bool LCHMFileImpl::guessTextEncoding( )
 {
-	const LCHMTextEncoding * enc = 0;
+	const LCHMTextEncoding * enc = nullptr;
 
-	if ( !m_detectedLCID || (enc = lookupByLCID (m_detectedLCID)) == 0 )
+	if ( !m_detectedLCID || (enc = lookupByLCID (m_detectedLCID)) == nullptr )
 		tqFatal ("Could not detect text encoding by LCID");
 	
 	if ( changeFileEncoding (enc->qtcodec) )
diff --git a/lib/libchmfile/libchmtextencoding.cpp b/lib/libchmfile/libchmtextencoding.cpp
index 9ba35ee..3bc9df8 100644
--- a/lib/libchmfile/libchmtextencoding.cpp
+++ b/lib/libchmfile/libchmtextencoding.cpp
@@ -24,141 +24,141 @@
 
 static const LCHMTextEncoding text_encoding_table [] = 
 {
-	{	"Afrikaans",0,			0x0436,	1252,	0,		"CP1252"	},
-	{	"Albanian",	0,			0x041C,	1250,	238,	"CP1250"	},
-	{	"Arabic",	"Algeria",	0x1401,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Bahrain",	0x3C01,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Egypt",	0x0C01,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Iraq",		0x0801,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Jordan",	0x2C01,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Kuwait",	0x3401,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Lebanon",	0x3001,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Libya",	0x1001,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Morocco",	0x1801,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Oman",		0x2001,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Qatar",	0x4001,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Saudi Arabia",	0x0401,	1256,	0,	"CP1256"	},
-	{	"Arabic",	"Syria",	0x2801,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"Tunisia",	0x1C01,	1256,	0,		"CP1256"	},
-	{	"Arabic",	"United Arab Emirates",	0x3801,	1256,	178,	"CP1256"	},
-	{	"Arabic",	"Yemen",	0x2401,	1256,	0,		"CP1256"	},
-	{	"Armenian",	0,			0x042B,	0,		0,		"Latin1"	},
-	{	"Azeri",	"Cyrillic",	0x082C,	1251,	0,		"CP1251"	},
-	{	"Azeri",	"Latin",	0x042C,	1254,	162,	"CP1254"	},
-	{	"Basque",	0,			0x042D,	1252,	0,		"CP1252"	},
-	{	"Belarusian",	0,		0x0423,	1251,	0,		"CP1251"	},
-	{	"Bulgarian",	0,		0x0402,	1251,	0,		"CP1251"	},
-	{	"Catalan",	0,	0x0403,	1252,	0,	"CP1252"	},
-	{	"Chinese",	"China",	0x0804,	936,	134,	"GBK"		},
-	{	"Chinese",	"Hong Kong SAR",	0x0C04,	950,	136,	"Big5"	},
-	{	"Chinese",	"Macau SAR",	0x1404,	950,	136,	"Big5"	},
-	{	"Chinese",	"Singapore",	0x1004,	936,	134,	"GB2313"	},
-	{	"Chinese",	"Taiwan",	0x0404,	950,	136,	"Big5"	}, // traditional
-	{	"Chinese",	"Taiwan - Big5-HKSCS",	0x0404,	950,	136,	"Big5-HKSCS"	},
-	{	"Chinese",	"Taiwan - GB18030",	0x0404,	950,	136,	"GB18030"	},
-	{	"Croatian",	0,	0x041A,	1250,	238,	"CP1250"	},
-	{	"Czech",	0,	0x0405,	1250,	238,	"CP1250"	},
-	{	"Danish",	0,	0x0406,	1252,	0,	"CP1252"	},
-	{	"Dutch",	"Belgium",	0x0813,	1252,	0,	"CP1252"	},
-	{	"Dutch",	"The Netherlands",	0x0413,	1252,	0,	"CP1252"	},
-	{	"English",	"Australia",	0x0C09,	1252,	0,	"CP1252"	},
-	{	"English",	"Belize",	0x2809,	1252,	0,	"CP1252"	},
-	{	"English",	"Canada",	0x1009,	1252,	0,	"CP1252"	},
-	{	"English",	"Caribbean",	0x2409,	1252,	0,	"CP1252"	},
-	{	"English",	"Ireland",	0x1809,	1252,	0,	"CP1252"	},
-	{	"English",	"Jamaica",	0x2009,	1252,	0,	"CP1252"	},
-	{	"English",	"New Zealand",	0x1409,	1252,	0,	"CP1252"	},
-	{	"English",	"Phillippines",	0x3409,	1252,	0,	"CP1252"	},
-	{	"English",	"South Africa",	0x1C09,	1252,	0,	"CP1252"	},
-	{	"English",	"Trinidad",	0x2C09,	1252,	0,	"CP1252"	},
-	{	"English",	"United Kingdom",	0x0809,	1252,	0,	"CP1252"	},
-	{	"English",	"United States",	0x0409,	1252,	0,	"CP1252"	},
-	{	"Estonian",	0,	0x0425,	1257,	186,	"CP1257"	},
-	{	"FYRO Macedonian",	0,	0x042F,	1251,	0,		"CP1251"	},
-	{	"Faroese",	0,	0x0438,	1252,	0,	"CP1252"	},
-	{	"Farsi",	0,	0x0429,	1256,	178,	"CP1256"	},
-	{	"Finnish",	0,	0x040B,	1252,	0,	"CP1252"	},
-	{	"French",	"Belgium",	0x080C,	1252,	0,	"CP1252"	},
-	{	"French",	"Canada",	0x0C0C,	1252,	0,	"CP1252"	},
-	{	"French",	"France",	0x040C,	1252,	0,	"CP1252"	},
-	{	"French",	"Luxembourg",	0x140C,	1252,	0,	"CP1252"	},
-	{	"French",	"Switzerland",	0x100C,	1252,	0,	"CP1252"	},
-	{	"German",	"Austria",	0x0C07,	1252,	0,	"CP1252"	},
-	{	"German",	"Germany",	0x0407,	1252,	0,	"CP1252"	},
-	{	"German",	"Liechtenstein",	0x1407,	1252,	0,	"CP1252"	},
-	{	"German",	"Luxembourg",	0x1007,	1252,	0,	"CP1252"	},
-	{	"German",	"Switzerland",	0x0807,	1252,	0,	"CP1252"	},
-	{	"Greek",	0,	0x0408,	1253,	161,	"CP1253"	},
-	{	"Hebrew",	0,	0x040D,	1255,	177,	"CP1255"	},
-	{	"Hindi",	0,	0x0439,	0,	0,	"Latin1"	},
-	{	"Hungarian",	0,	0x040E,	1250,	238,	"CP1250"	},
-	{	"Icelandic",	0,	0x040F,	1252,	0,	"CP1252"	},
-	{	"Indonesian",	0,	0x0421,	1252,	0,	"CP1252"	},
-	{	"Italian",	"Italy",	0x0410,	1252,	0,	"CP1252"	},
-	{	"Italian",	"Switzerland",	0x0810,	1252,	0,	"CP1252"	},
-	{	"Japanese",	"Shift-JIS",	0x0411,	932,	128,	"Shift-JIS"	},
-	{	"Japanese",	"JIS7",	0x0411,	932,	128,	"JIS7"	},
-	{	"Japanese",	"eucJP",	0x0411,	932,	128,	"eucJP"	},
-	{	"Korean",	0,	0x0412,	949,	129,	"eucKR"	},
-	{	"Latvian",	0,	0x0426,	1257,	186,	"CP1257"	},
-	{	"Lithuanian",	0,	0x0427,	1257,	186,	"CP1257"	},
-	{	"Malay",	"Brunei",	0x083E,	1252,	0,	"CP1252"	},
-	{	"Malay",	"Malaysia",	0x043E,	1252,	0,	"CP1252"	},
-	{	"Maltese",	0,	0x043A,	0,	0,	"Latin1"	},
-	{	"Marathi",	0,	0x044E,	0,	0,	"Latin1"	},
-	{	"Norwegian",	"Bokmal",	0x0414,	1252,	0,	"CP1252"	},
-	{	"Norwegian",	"Nynorsk",	0x0814,	1252,	0,	"CP1252"	},
-	{	"Polish",	0,	0x0415,	1250,	238,	"CP1250"	},
-	{	"Portuguese",	"Brazil",	0x0416,	1252,	0,	"CP1252"	},
-	{	"Portuguese",	"Portugal",	0x0816,	1252,	0,	"CP1252"	},
-	{	"Romanian",	"Romania",	0x0418,	1250,	238,	"CP1250"	},
-	{	"Russian",	"Cyrillic",	0x0419,	1251,	204,	"CP1251"	},
-	{	"Russian",	"KOI-8",	0x7001,	2251,	204,	"KOI8-R"	},
-	{	"Russian",	"KOI-8 (TOC 1251)",	0x7002,	3251,	0,	"CP1251/KOI8-R"	},
-	{	"Russian",	"Cyrillic (TOC KOI8)",	0x7003,	3251,	0,	"KOI8-R/CP1251"	},
-	{	"Sanskrit",	0,	0x044F,	0,	0,	"Latin1"	},
-	{	"Serbian",	"Cyrillic",	0x0C1A,	1251,	0,		"CP1251"	},
-	{	"Serbian",	"Latin",	0x081A,	1250,	238,	"CP1250"	},
-	{	"Setsuana",	0,	0x0432,	1252,	0,	"CP1252"	},
-	{	"Slovak",	0,	0x041B,	1250,	238,	"CP1250"	},
-	{	"Slovenian",	0,	0x0424,	1250,	238,	"CP1250"	},
-	{	"Spanish",	"Argentina",	0x2C0A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Bolivia",	0x400A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Chile",	0x340A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Colombia",	0x240A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Costa Rica",	0x140A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Dominican Republic",	0x1C0A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Ecuador",	0x300A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"El Salvador",	0x440A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Guatemala",	0x100A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Honduras",	0x480A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Mexico",	0x080A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Nicaragua",	0x4C0A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Panama",	0x180A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Paraguay",	0x3C0A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Peru",	0x280A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Puerto Rico",	0x500A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Spain",	0x0C0A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Uruguay",	0x380A,	1252,	0,	"CP1252"	},
-	{	"Spanish",	"Venezuela",	0x200A,	1252,	0,	"CP1252"	},
-	{	"Swahili",	0,	0x0441,	1252,	0,	"CP1252"	},
-	{	"Swedish",	"Finland",	0x081D,	1252,	0,	"CP1252"	},
-	{	"Swedish",	"Sweden",	0x041D,	1252,	0,	"CP1252"	},
-	{	"Tamil",	0,	0x0449,	0,	0,	"TSCII"	},
-	{	"Tatar",	0,	0x0444,	1251,	204,	"CP1251"	},
-	{	"Thai",	0,	0x041E,	874,	222,	"TIS-620"	},
-	{	"Turkish",	0,	0x041F,	1254,	162,	"CP1254"	},
-	{	"Ukrainian",	"Cyrillic",	0x0422,	1251,	0,	"CP1251"	},
-	{	"Ukrainian",	"KOI-8",	0x8422,	2251,	204,	"KOI8-U"	},
-	{	"Unicode",	"UTF-8",	0x7010,	0,	0,	"UTF-8"	},
-	{	"Unicode",	"UTF-16",	0x7011,	0,	0,	"UTF-16"	},
-	{	"Urdu",	0,	0x0420,	1256,	178,	"CP1256"	},
-	{	"Uzbek",	"Cyrillic",	0x0843,	1251,	0,	"CP1251"	},
-	{	"Uzbek",	"Latin",	0x0443,	1254,	162,	"CP1254"	},
-	{	"Vietnamese",	0,	0x042A,	1258,	163,	"CP1258"	},
-	{	"Xhosa",	0,	0x0434,	1252,	0,	"CP1252"	},
-	{	"Zulu",	0,	0x0435,	1252,	0,	"CP1252"	},
-	{	0,		0,	0,		0,	0,	0	}
+	{ "Afrikaans",       nullptr,                0x0436, 1252, 0,   "CP1252" },
+	{ "Albanian",        nullptr,                0x041C, 1250, 238, "CP1250" },
+	{ "Arabic",          "Algeria",              0x1401, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Bahrain",              0x3C01, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Egypt",                0x0C01, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Iraq",                 0x0801, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Jordan",               0x2C01, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Kuwait",               0x3401, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Lebanon",              0x3001, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Libya",                0x1001, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Morocco",              0x1801, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Oman",                 0x2001, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Qatar",                0x4001, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Saudi Arabia",         0x0401, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Syria",                0x2801, 1256, 0,   "CP1256" },
+	{ "Arabic",          "Tunisia",              0x1C01, 1256, 0,   "CP1256" },
+	{ "Arabic",          "United Arab Emirates", 0x3801, 1256, 178, "CP1256" },
+	{ "Arabic",          "Yemen",                0x2401, 1256, 0,   "CP1256" },
+	{ "Armenian",        nullptr,                0x042B, 0,    0,   "Latin1" },
+	{ "Azeri",           "Cyrillic",             0x082C, 1251, 0,   "CP1251" },
+	{ "Azeri",           "Latin",                0x042C, 1254, 162, "CP1254" },
+	{ "Basque",          nullptr,                0x042D, 1252, 0,   "CP1252" },
+	{ "Belarusian",      nullptr,                0x0423, 1251, 0,   "CP1251" },
+	{ "Bulgarian",       nullptr,                0x0402, 1251, 0,   "CP1251" },
+	{ "Catalan",         nullptr,                0x0403, 1252, 0,   "CP1252" },
+	{ "Chinese",         "China",                0x0804, 936,  134, "GBK" },
+	{ "Chinese",         "Hong Kong SAR",        0x0C04, 950,  136, "Big5" },
+	{ "Chinese",         "Macau SAR",            0x1404, 950,  136, "Big5" },
+	{ "Chinese",         "Singapore",            0x1004, 936,  134, "GB2313" },
+	{ "Chinese",         "Taiwan",               0x0404, 950,  136, "Big5" }, // traditional
+	{ "Chinese",         "Taiwan - Big5-HKSCS",  0x0404, 950,  136, "Big5-HKSCS" },
+	{ "Chinese",         "Taiwan - GB18030",     0x0404, 950,  136, "GB18030" },
+	{ "Croatian",        nullptr,                0x041A, 1250, 238, "CP1250" },
+	{ "Czech",           nullptr,                0x0405, 1250, 238, "CP1250" },
+	{ "Danish",          nullptr,                0x0406, 1252, 0,   "CP1252" },
+	{ "Dutch",           "Belgium",              0x0813, 1252, 0,   "CP1252" },
+	{ "Dutch",           "The Netherlands",      0x0413, 1252, 0,   "CP1252" },
+	{ "English",         "Australia",            0x0C09, 1252, 0,   "CP1252" },
+	{ "English",         "Belize",               0x2809, 1252, 0,   "CP1252" },
+	{ "English",         "Canada",               0x1009, 1252, 0,   "CP1252" },
+	{ "English",         "Caribbean",            0x2409, 1252, 0,   "CP1252" },
+	{ "English",         "Ireland",              0x1809, 1252, 0,   "CP1252" },
+	{ "English",         "Jamaica",              0x2009, 1252, 0,   "CP1252" },
+	{ "English",         "New Zealand",          0x1409, 1252, 0,   "CP1252" },
+	{ "English",         "Phillippines",         0x3409, 1252, 0,   "CP1252" },
+	{ "English",         "South Africa",         0x1C09, 1252, 0,   "CP1252" },
+	{ "English",         "Trinidad",             0x2C09, 1252, 0,   "CP1252" },
+	{ "English",         "United Kingdom",       0x0809, 1252, 0,   "CP1252" },
+	{ "English",         "United States",        0x0409, 1252, 0,   "CP1252" },
+	{ "Estonian",        nullptr,                0x0425, 1257, 186, "CP1257" },
+	{ "FYRO Macedonian", nullptr,                0x042F, 1251, 0,   "CP1251" },
+	{ "Faroese",         nullptr,                0x0438, 1252, 0,   "CP1252" },
+	{ "Farsi",           nullptr,                0x0429, 1256, 178, "CP1256" },
+	{ "Finnish",         nullptr,                0x040B, 1252, 0,   "CP1252" },
+	{ "French",          "Belgium",              0x080C, 1252, 0,   "CP1252" },
+	{ "French",          "Canada",               0x0C0C, 1252, 0,   "CP1252" },
+	{ "French",          "France",               0x040C, 1252, 0,   "CP1252" },
+	{ "French",          "Luxembourg",           0x140C, 1252, 0,   "CP1252" },
+	{ "French",          "Switzerland",          0x100C, 1252, 0,   "CP1252" },
+	{ "German",          "Austria",              0x0C07, 1252, 0,   "CP1252" },
+	{ "German",          "Germany",              0x0407, 1252, 0,   "CP1252" },
+	{ "German",          "Liechtenstein",        0x1407, 1252, 0,   "CP1252" },
+	{ "German",          "Luxembourg",           0x1007, 1252, 0,   "CP1252" },
+	{ "German",          "Switzerland",          0x0807, 1252, 0,   "CP1252" },
+	{ "Greek",           nullptr,                0x0408, 1253, 161, "CP1253" },
+	{ "Hebrew",          nullptr,                0x040D, 1255, 177, "CP1255" },
+	{ "Hindi",           nullptr,                0x0439, 0,    0,   "Latin1" },
+	{ "Hungarian",       nullptr,                0x040E, 1250, 238, "CP1250" },
+	{ "Icelandic",       nullptr,                0x040F, 1252, 0,   "CP1252" },
+	{ "Indonesian",      nullptr,                0x0421, 1252, 0,   "CP1252" },
+	{ "Italian",         "Italy",                0x0410, 1252, 0,   "CP1252" },
+	{ "Italian",         "Switzerland",          0x0810, 1252, 0,   "CP1252" },
+	{ "Japanese",        "Shift-JIS",            0x0411, 932,  128, "Shift-JIS" },
+	{ "Japanese",        "JIS7",                 0x0411, 932,  128, "JIS7" },
+	{ "Japanese",        "eucJP",                0x0411, 932,  128, "eucJP" },
+	{ "Korean",          nullptr,                0x0412, 949,  129, "eucKR" },
+	{ "Latvian",         nullptr,                0x0426, 1257, 186, "CP1257" },
+	{ "Lithuanian",      nullptr,                0x0427, 1257, 186, "CP1257" },
+	{ "Malay",           "Brunei",               0x083E, 1252, 0,   "CP1252" },
+	{ "Malay",           "Malaysia",             0x043E, 1252, 0,   "CP1252" },
+	{ "Maltese",         nullptr,                0x043A, 0,    0,   "Latin1" },
+	{ "Marathi",         nullptr,                0x044E, 0,    0,   "Latin1" },
+	{ "Norwegian",       "Bokmal",               0x0414, 1252, 0,   "CP1252" },
+	{ "Norwegian",       "Nynorsk",              0x0814, 1252, 0,   "CP1252" },
+	{ "Polish",          nullptr,                0x0415, 1250, 238, "CP1250" },
+	{ "Portuguese",      "Brazil",               0x0416, 1252, 0,   "CP1252" },
+	{ "Portuguese",      "Portugal",             0x0816, 1252, 0,   "CP1252" },
+	{ "Romanian",        "Romania",              0x0418, 1250, 238, "CP1250" },
+	{ "Russian",         "Cyrillic",             0x0419, 1251, 204, "CP1251" },
+	{ "Russian",         "KOI-8",                0x7001, 2251, 204, "KOI8-R" },
+	{ "Russian",         "KOI-8 (TOC 1251)",     0x7002, 3251, 0,   "CP1251/KOI8-R" },
+	{ "Russian",         "Cyrillic (TOC KOI8)",  0x7003, 3251, 0,   "KOI8-R/CP1251" },
+	{ "Sanskrit",        nullptr,                0x044F, 0,    0,   "Latin1" },
+	{ "Serbian",         "Cyrillic",             0x0C1A, 1251, 0,   "CP1251" },
+	{ "Serbian",         "Latin",                0x081A, 1250, 238, "CP1250" },
+	{ "Setsuana",        nullptr,                0x0432, 1252, 0,   "CP1252" },
+	{ "Slovak",          nullptr,                0x041B, 1250, 238, "CP1250" },
+	{ "Slovenian",       nullptr,                0x0424, 1250, 238, "CP1250" },
+	{ "Spanish",         "Argentina",            0x2C0A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Bolivia",              0x400A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Chile",                0x340A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Colombia",             0x240A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Costa Rica",           0x140A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Dominican Republic",   0x1C0A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Ecuador",              0x300A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "El Salvador",          0x440A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Guatemala",            0x100A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Honduras",             0x480A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Mexico",               0x080A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Nicaragua",            0x4C0A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Panama",               0x180A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Paraguay",             0x3C0A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Peru",                 0x280A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Puerto Rico",          0x500A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Spain",                0x0C0A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Uruguay",              0x380A, 1252, 0,   "CP1252" },
+	{ "Spanish",         "Venezuela",            0x200A, 1252, 0,   "CP1252" },
+	{ "Swahili",         nullptr,                0x0441, 1252, 0,   "CP1252" },
+	{ "Swedish",         "Finland",              0x081D, 1252, 0,   "CP1252" },
+	{ "Swedish",         "Sweden",               0x041D, 1252, 0,   "CP1252" },
+	{ "Tamil",           nullptr,                0x0449, 0,    0,   "TSCII" },
+	{ "Tatar",           nullptr,                0x0444, 1251, 204, "CP1251" },
+	{ "Thai",            nullptr,                0x041E, 874,  222, "TIS-620" },
+	{ "Turkish",         nullptr,                0x041F, 1254, 162, "CP1254" },
+	{ "Ukrainian",       "Cyrillic",             0x0422, 1251, 0,   "CP1251" },
+	{ "Ukrainian",       "KOI-8",                0x8422, 2251, 204, "KOI8-U" },
+	{ "Unicode",         "UTF-8",                0x7010, 0,    0,   "UTF-8" },
+	{ "Unicode",         "UTF-16",               0x7011, 0,    0,   "UTF-16" },
+	{ "Urdu",            nullptr,                0x0420, 1256, 178, "CP1256" },
+	{ "Uzbek",           "Cyrillic",             0x0843, 1251, 0,   "CP1251" },
+	{ "Uzbek",           "Latin",                0x0443, 1254, 162, "CP1254" },
+	{ "Vietnamese",      nullptr,                0x042A, 1258, 163, "CP1258" },
+	{ "Xhosa",           nullptr,                0x0434, 1252, 0,   "CP1252" },
+	{ "Zulu",            nullptr,                0x0435, 1252, 0,   "CP1252" },
+	{ nullptr,           nullptr,                0,      0,    0,   nullptr }
 };
 
 
@@ -173,7 +173,7 @@ const LCHMTextEncoding * LCHMFileImpl::lookupByLCID( short lcid )
 		if ( t->winlcid == lcid )
 			return t;
 			
-	return 0;
+	return nullptr;
 }
 
 /*
diff --git a/lib/tdeio-msits/msits.cpp b/lib/tdeio-msits/msits.cpp
index c61216c..8a89d80 100644
--- a/lib/tdeio-msits/msits.cpp
+++ b/lib/tdeio-msits/msits.cpp
@@ -63,7 +63,7 @@ TDE_EXPORT int kdemain( int argc, char **argv )
 ProtocolMSITS::ProtocolMSITS (const TQCString &pool_socket, const TQCString &app_socket)
 	: SlaveBase ("tdeio_msits", pool_socket, app_socket)
 {
-	m_chmFile = 0;
+	m_chmFile = nullptr;
 }
 
 ProtocolMSITS::~ProtocolMSITS()
@@ -72,7 +72,7 @@ ProtocolMSITS::~ProtocolMSITS()
 		return;
 
 	chm_close (m_chmFile);
-	m_chmFile = 0;
+	m_chmFile = nullptr;
 }
 
 // A simple stat() wrapper
@@ -173,7 +173,7 @@ bool ProtocolMSITS::parseLoadAndLookup ( const KURL& url, TQString& abspath )
 	// First try to open a temporary file
 	chmFile * tmpchm;
 
-	if ( (tmpchm = chm_open ( TQFile::encodeName (filename))) == 0 )
+	if ( (tmpchm = chm_open ( TQFile::encodeName (filename))) == nullptr )
 	{
 		error( TDEIO::ERR_COULD_NOT_READ, url.prettyURL() );
         return false;
diff --git a/src/iconstorage.cpp b/src/iconstorage.cpp
index 7427156..71eef99 100644
--- a/src/iconstorage.cpp
+++ b/src/iconstorage.cpp
@@ -1266,8 +1266,8 @@ const TQPixmap * KCHMIconStorage::getCloseWindowIcon( )
 
 KCHMIconStorage::KCHMIconStorage( )
 {
-	m_iconApplication = 0;
-	m_iconCloseWindow = 0;
+	m_iconApplication = nullptr;
+	m_iconCloseWindow = nullptr;
 }
 
 
diff --git a/src/kchmbookmarkwindow.cpp b/src/kchmbookmarkwindow.cpp
index dc1b3e4..b0e6c53 100644
--- a/src/kchmbookmarkwindow.cpp
+++ b/src/kchmbookmarkwindow.cpp
@@ -74,8 +74,8 @@ KCHMBookmarkWindow::KCHMBookmarkWindow(TQWidget *parent, const char *name)
 			 this, 
 			 TQ_SLOT( slotContextMenuRequested ( TQListViewItem *, const TQPoint &, int ) ) );
 
-	m_menuBookmarks = 0;
-	m_contextMenu = 0;
+	m_menuBookmarks = nullptr;
+	m_contextMenu = nullptr;
 	m_listChanged = false;
 }
 
diff --git a/src/kchmbookmarkwindow.h b/src/kchmbookmarkwindow.h
index 40d1c19..ab6cc84 100644
--- a/src/kchmbookmarkwindow.h
+++ b/src/kchmbookmarkwindow.h
@@ -34,7 +34,7 @@ class KCHMBookmarkWindow : public TQWidget
 	TQ_OBJECT
   
 	public:
-		KCHMBookmarkWindow(TQWidget *parent = 0, const char *name = 0);
+		KCHMBookmarkWindow(TQWidget *parent = nullptr, const char *name = nullptr);
 		virtual ~KCHMBookmarkWindow() {};
 	
 		void 	createMenu( KCHMMainWindow * parent );
diff --git a/src/kchmcontentswindow.cpp b/src/kchmcontentswindow.cpp
index eeaef20..24e0000 100644
--- a/src/kchmcontentswindow.cpp
+++ b/src/kchmcontentswindow.cpp
@@ -33,7 +33,7 @@
 KCHMContentsWindow::KCHMContentsWindow(TQWidget *parent, const char *name)
 	: KQListView(parent, name)
 {
-	m_contextMenu = 0;
+	m_contextMenu = nullptr;
 	
 	addColumn( "Contents" ); // no i18n - this column is hidden
 	setSorting(-1);
@@ -89,7 +89,7 @@ KCHMIndTocItem * KCHMContentsWindow::getTreeItem( const TQString & url )
 	TQMap<TQString, KCHMIndTocItem*>::const_iterator it = m_urlListMap.find( fixedstr );
 	
 	if ( it == m_urlListMap.end() )
-		return 0;
+		return nullptr;
 		
 	return *it;
 }
diff --git a/src/kchmcontentswindow.h b/src/kchmcontentswindow.h
index 83b27db..da20e0e 100644
--- a/src/kchmcontentswindow.h
+++ b/src/kchmcontentswindow.h
@@ -33,7 +33,7 @@ class KCHMContentsWindow : public KQListView
 	TQ_OBJECT
   
 	public:
-    	KCHMContentsWindow( TQWidget *parent = 0, const char *name = 0 );
+	KCHMContentsWindow( TQWidget *parent = nullptr, const char *name = nullptr );
 		~KCHMContentsWindow();
 		
 		TQRect	tip( const TQPoint & p );
diff --git a/src/kchmdialogchooseurlfromlist.cpp b/src/kchmdialogchooseurlfromlist.cpp
index a6b7738..225a096 100644
--- a/src/kchmdialogchooseurlfromlist.cpp
+++ b/src/kchmdialogchooseurlfromlist.cpp
@@ -25,7 +25,7 @@
 #include "kchmtreeviewitem.h"
 
 KCHMDialogChooseUrlFromList::KCHMDialogChooseUrlFromList(const TQStringList& urls, const TQStringList& titles, TQWidget* parent)
-	: TQDialog(parent, 0, true)
+	: TQDialog(parent, nullptr, true)
 {
 	TQVBoxLayout * layout = new TQVBoxLayout (this);
 	layout->setMargin (5);
diff --git a/src/kchmindexwindow.cpp b/src/kchmindexwindow.cpp
index 061ad86..dd67502 100644
--- a/src/kchmindexwindow.cpp
+++ b/src/kchmindexwindow.cpp
@@ -72,8 +72,8 @@ KCHMIndexWindow::KCHMIndexWindow ( TQWidget * parent, const char * name, WFlags
 			 TQ_SLOT( slotContextMenuRequested ( TQListViewItem *, const TQPoint &, int ) ) );
 
 	m_indexListFilled = false;
-	m_lastSelectedItem = 0;
-	m_contextMenu = 0;
+	m_lastSelectedItem = nullptr;
+	m_contextMenu = nullptr;
 	
 	new KCHMListItemTooltip( m_indexList );
 }
diff --git a/src/kchmindexwindow.h b/src/kchmindexwindow.h
index 69ce64c..bd3c271 100644
--- a/src/kchmindexwindow.h
+++ b/src/kchmindexwindow.h
@@ -35,7 +35,7 @@ class KCHMIndexWindow : public TQWidget
 	TQ_OBJECT
   
 	public:
-		KCHMIndexWindow ( TQWidget * parent = 0, const char * name = 0, WFlags f = 0 );
+		KCHMIndexWindow ( TQWidget * parent = nullptr, const char * name = nullptr, WFlags f = 0 );
 	
 		void	invalidate();
 		void	search( const TQString& index );
diff --git a/src/kchmkeyeventfilter.cpp b/src/kchmkeyeventfilter.cpp
index ef7dc9a..dedf640 100644
--- a/src/kchmkeyeventfilter.cpp
+++ b/src/kchmkeyeventfilter.cpp
@@ -35,7 +35,7 @@ bool KCHMKeyEventFilter::eventFilter( TQObject *, TQEvent *e )
 	// Handle KeyPress and KeyRelease events
 	if ( e->type() == TQEvent::KeyPress || e->type() == TQEvent::KeyRelease )
 	{
-		bool * ptr = 0;
+		bool * ptr = nullptr;
 		TQKeyEvent *k = (TQKeyEvent *) e;
 		
 		// We're interested only in Shift and Control
diff --git a/src/kchmmainwindow.cpp b/src/kchmmainwindow.cpp
index 0abfdb7..194b9c0 100644
--- a/src/kchmmainwindow.cpp
+++ b/src/kchmmainwindow.cpp
@@ -59,19 +59,19 @@
 
 
 KCHMMainWindow::KCHMMainWindow()
-    : KQMainWindow ( 0, "KCHMMainWindow", WDestructiveClose )
+    : KQMainWindow ( nullptr, "KCHMMainWindow", WDestructiveClose )
 {
 	const unsigned int WND_X_SIZE = 700;
 	const unsigned int WND_Y_SIZE = 500;
 	const unsigned int SPLT_X_SIZE = 200;
 
 	m_FirstTimeShow = true;
-	m_chmFile = 0;
+	m_chmFile = nullptr;
 	
-	m_indexWindow = 0;
-	m_searchWindow = 0;
-	m_contentsWindow = 0;
-	m_viewWindowMgr = 0;
+	m_indexWindow = nullptr;
+	m_searchWindow = nullptr;
+	m_contentsWindow = nullptr;
+	m_viewWindowMgr = nullptr;
 
 	m_tabContextPage = -1;
 	m_tabIndexPage = -1;
@@ -607,7 +607,7 @@ void KCHMMainWindow::closeEvent ( TQCloseEvent * e )
 	{
 		closeChmFile( );
 		delete m_chmFile;
-		m_chmFile = 0;
+		m_chmFile = nullptr;
 	}
 
 	TQMainWindow::closeEvent ( e );
@@ -848,7 +848,7 @@ void KCHMMainWindow::setupSignals( )
 #endif
 	
 	sa.sa_handler = SIG_IGN;
-	sigaction (SIGCHLD, &sa, (struct sigaction *)0);
+	sigaction (SIGCHLD, &sa, nullptr);
 #else /* !HAVE_SIGACTION */
 	signal (SIGCHLD, SIG_IGN);
 #endif /* HAVE_SIGACTION */
@@ -905,7 +905,7 @@ void KCHMMainWindow::showOrHideContextWindow( int tabindex )
 		{
 			m_tabWidget->removePage (m_contentsWindow);
 			delete m_contentsWindow;
-			m_contentsWindow = 0;
+			m_contentsWindow = nullptr;
 		}
 	}
 	else
@@ -939,7 +939,7 @@ void KCHMMainWindow::showOrHideIndexWindow( int tabindex )
 		{
 			m_tabWidget->removePage (m_indexWindow);
 			delete m_indexWindow;
-			m_indexWindow = 0;
+			m_indexWindow = nullptr;
 		}
 	}
 	else
@@ -962,7 +962,7 @@ void KCHMMainWindow::showOrHideSearchWindow( int tabindex )
 		{
 			m_tabWidget->removePage (m_searchWindow);
 			delete m_searchWindow;
-			m_searchWindow = 0;
+			m_searchWindow = nullptr;
 		}
 	}
 	else
@@ -1030,7 +1030,7 @@ void KCHMMainWindow::slotLocateInContentWindow( )
 		{
 			KCHMIndTocItem * itemparent = treeitem;
 			
-			while ( (itemparent = (KCHMIndTocItem*) itemparent->parent()) != 0 )
+			while ( (itemparent = (KCHMIndTocItem*) itemparent->parent()) != nullptr )
 				itemparent->setOpen(true);
 			
 			m_contentsWindow->setCurrentItem (treeitem);
@@ -1168,7 +1168,7 @@ void KCHMMainWindow::locateInContentTree( const TQString & url )
 	if ( treeitem )
 	{
 		KCHMIndTocItem * itemparent = treeitem;
-		while ( (itemparent = (KCHMIndTocItem*) itemparent->parent()) != 0 )
+		while ( (itemparent = (KCHMIndTocItem*) itemparent->parent()) != nullptr )
 			itemparent->setOpen(true);
 			
 		m_contentsWindow->setCurrentItem (treeitem);
@@ -1264,7 +1264,7 @@ void KCHMMainWindow::runAutoTest()
 		break; // allow to finish the initialization sequence
 		
 	case STATE_CONTENTS_OPENNEXTPAGE:
-		if ( (item = (KCHMIndTocItem *) m_autotestlistiterator.current()) != 0 )
+		if ( (item = (KCHMIndTocItem *) m_autotestlistiterator.current()) != nullptr )
 		{
 			openPage( item->getUrl(), OPF_CONTENT_TREE | OPF_ADD2HISTORY );
 			m_autotestlistiterator++;
diff --git a/src/kchmsearchengine.cpp b/src/kchmsearchengine.cpp
index 7ef266f..e75b5c4 100644
--- a/src/kchmsearchengine.cpp
+++ b/src/kchmsearchengine.cpp
@@ -35,8 +35,8 @@
 
 KCHMSearchEngine::KCHMSearchEngine()
 {
-	m_Index = 0;
-	m_progressDlg = 0;
+	m_Index = nullptr;
+	m_progressDlg = nullptr;
 }
 
 
@@ -73,7 +73,7 @@ bool KCHMSearchEngine::loadOrGenerateIndex( )
 	m_Index->setDictionaryFile( indexfiledict );
 	m_Index->setDocListFile( indexfiledoc );
 
-	m_progressDlg = new TQProgressDialog( 0 );
+	m_progressDlg = new TQProgressDialog( nullptr );
 	connect( m_progressDlg, TQ_SIGNAL( canceled() ), this, TQ_SLOT( cancelButtonPressed() ) );
 	
 	connect( m_Index, TQ_SIGNAL( indexingProgress( int ) ),  this, TQ_SLOT( setIndexingProgress( int ) ) );
@@ -97,7 +97,7 @@ bool KCHMSearchEngine::loadOrGenerateIndex( )
 		if ( !::mainWindow->chmFile()->enumerateFiles( &alldocuments ) )
 		{
 			delete m_progressDlg;
-			m_progressDlg = 0;
+			m_progressDlg = nullptr;
 			return false;
 		}
 		
@@ -126,7 +126,7 @@ bool KCHMSearchEngine::loadOrGenerateIndex( )
 	
 	::mainWindow->statusBar()->message( tr( "Done" ), 3000 );
 	delete m_progressDlg;
-	m_progressDlg = 0;
+	m_progressDlg = nullptr;
 	
 	return true;
 }
@@ -243,7 +243,7 @@ bool KCHMSearchEngine::searchQuery( const TQString & query, TQStringList * resul
 	
 	if ( keeper.isInPhrase() )
 	{
-		TQMessageBox::warning( 0, i18n( "Search" ), i18n( "A closing quote character is missing." ) );
+		TQMessageBox::warning( nullptr, i18n( "Search" ), i18n( "A closing quote character is missing." ) );
 		return false;
 	}
 	
diff --git a/src/kchmsearchengine_impl.cpp b/src/kchmsearchengine_impl.cpp
index 0536626..9d8364e 100644
--- a/src/kchmsearchengine_impl.cpp
+++ b/src/kchmsearchengine_impl.cpp
@@ -69,7 +69,7 @@ TQDataStream &operator<<( TQDataStream &s, const Document &l )
 }
 
 Index::Index( const TQString &dp, const TQString & )
-	: TQObject( 0, 0 ), dict( 8999 ), docPath( dp )
+	: TQObject( nullptr, nullptr ), dict( 8999 ), docPath( dp )
 {
 	lastWindowClosed = false;
 	connect( tqApp, TQ_SIGNAL( lastWindowClosed() ),
@@ -77,7 +77,7 @@ Index::Index( const TQString &dp, const TQString & )
 }
 
 Index::Index( const TQStringList &dl, const TQString & )
-	: TQObject( 0, 0 ), dict( 20011 )
+	: TQObject( nullptr, nullptr ), dict( 20011 )
 {
 	docList = dl;
 	lastWindowClosed = false;
@@ -138,7 +138,7 @@ bool Index::makeIndex()
 
 void Index::insertInDict( const TQString &str, int docNum )
 {
-	Entry *e = 0;
+	Entry *e = nullptr;
 	if ( dict.count() )
 		e = dict[ str ];
 	
@@ -422,7 +422,7 @@ TQStringList Index::query( const TQStringList &terms, const TQStringList &termSe
 	TQStringList::ConstIterator it = terms.begin();
 	for ( it = terms.begin(); it != terms.end(); ++it )
 	{
-		Entry *e = 0;
+		Entry *e = nullptr;
 		
 		if ( dict[ *it ] )
 		{
diff --git a/src/kchmsearchtoolbar.cpp b/src/kchmsearchtoolbar.cpp
index a600f36..29d59cd 100644
--- a/src/kchmsearchtoolbar.cpp
+++ b/src/kchmsearchtoolbar.cpp
@@ -173,7 +173,7 @@ KCHMSearchAndViewToolbar::KCHMSearchAndViewToolbar( KCHMMainWindow * parent )
 		
 	// Create the language selection menu.
     menu_langlist = new KTQPopupMenu( parent );
-	KTQPopupMenu * menu_sublang = 0;
+	KTQPopupMenu * menu_sublang = nullptr;
 
 	// Because the encoding menu is very large, it is not reasonable to have a slot for every item.
 	// It is simplier just to use a single slot for any menu item of this submenu.
@@ -211,7 +211,7 @@ KCHMSearchAndViewToolbar::KCHMSearchAndViewToolbar( KCHMMainWindow * parent )
 		{
 			menu_sublang->insertItem( item->sublanguage, idx );
 			menu_langlist->insertItem( item->language, menu_sublang );
-			menu_sublang = 0;
+			menu_sublang = nullptr;
 		}
 		else
 			menu_langlist->insertItem( item->language, idx );
@@ -304,7 +304,7 @@ void KCHMSearchAndViewToolbar::onBtnViewSource( )
 
 	if ( appConfig.m_advUseInternalEditor )
 	{
-		TQTextEdit * editor = new TQTextEdit ( 0 );
+		TQTextEdit * editor = new TQTextEdit ( nullptr );
 		editor->setTextFormat ( TQt::PlainText );
 		editor->setText (text);
 		editor->setCaption ( TQString(APP_NAME) + " - view HTML source of " + ::mainWindow->currentBrowser()->getOpenedPage() );
diff --git a/src/kchmsearchwindow.cpp b/src/kchmsearchwindow.cpp
index 2143e74..fe80966 100644
--- a/src/kchmsearchwindow.cpp
+++ b/src/kchmsearchwindow.cpp
@@ -91,8 +91,8 @@ KCHMSearchWindow::KCHMSearchWindow( TQWidget * parent, const char * name, WFlags
 	layout->addWidget (m_searchList);
 	
 	new KCHMListItemTooltip( m_searchList );
-	m_contextMenu = 0;
-	m_searchEngine = 0;
+	m_contextMenu = nullptr;
+	m_searchEngine = nullptr;
 }
 
 void KCHMSearchWindow::invalidate( )
@@ -102,7 +102,7 @@ void KCHMSearchWindow::invalidate( )
 	m_searchQuery->lineEdit()->clear();
 	
 	delete m_searchEngine;
-	m_searchEngine = 0;
+	m_searchEngine = nullptr;
 }
 
 void KCHMSearchWindow::onReturnPressed( )
@@ -198,7 +198,7 @@ bool KCHMSearchWindow::initSearchEngine( )
 	if ( !m_searchEngine->loadOrGenerateIndex() )
 	{
 		delete m_searchEngine;
-		m_searchEngine = 0;
+		m_searchEngine = nullptr;
 		return false;
 	}
 	
diff --git a/src/kchmsearchwindow.h b/src/kchmsearchwindow.h
index c9a553f..1eb8b3d 100644
--- a/src/kchmsearchwindow.h
+++ b/src/kchmsearchwindow.h
@@ -57,7 +57,7 @@ class KCHMSearchWindow : public TQWidget
 	TQ_OBJECT
   
 	public:
-		KCHMSearchWindow ( TQWidget * parent = 0, const char * name = 0, WFlags f = 0 );
+	KCHMSearchWindow ( TQWidget * parent = nullptr, const char * name = nullptr, WFlags f = 0 );
 	
 		void	invalidate();
 		void	restoreSettings (const KCHMSettings::search_saved_settings_t& settings);
diff --git a/src/kchmsetupdialog_impl.h b/src/kchmsetupdialog_impl.h
index a978040..8cb0f23 100644
--- a/src/kchmsetupdialog_impl.h
+++ b/src/kchmsetupdialog_impl.h
@@ -25,7 +25,7 @@ class KCHMSetupDialog_impl : public KCHMSetupDialog
     TQ_OBJECT
 
 public:
-    KCHMSetupDialog_impl( TQWidget* parent = 0, const char* name = 0, bool modal = false, WFlags fl = 0 );
+    KCHMSetupDialog_impl( TQWidget* parent = nullptr, const char* name = nullptr, bool modal = false, WFlags fl = 0 );
 
 public slots:
     void slotShowHelp();
diff --git a/src/kchmsourcefactory.cpp b/src/kchmsourcefactory.cpp
index 92d6db1..af9ce21 100644
--- a/src/kchmsourcefactory.cpp
+++ b/src/kchmsourcefactory.cpp
@@ -47,7 +47,7 @@ const TQMimeSource * KCHMSourceFactory::data( const TQString & abs_name ) const
 	 LCHMFile * chm = ::mainWindow->chmFile();
 
 	if ( !chm )
-		return 0;
+		return nullptr;
 
 	int pos = path.find ('#');
 	if ( pos != -1 )
diff --git a/src/kchmtreeviewitem.cpp b/src/kchmtreeviewitem.cpp
index c7ae8dc..d4e2a05 100644
--- a/src/kchmtreeviewitem.cpp
+++ b/src/kchmtreeviewitem.cpp
@@ -42,7 +42,7 @@ const TQPixmap * KCHMIndTocItem::pixmap( int i ) const
 	int imagenum;
 
 	if ( i || image_number == LCHMBookIcons::IMAGE_NONE || image_number == LCHMBookIcons::IMAGE_INDEX )
-        return 0;
+        return nullptr;
 
 	if ( firstChild () )
 	{
@@ -153,10 +153,10 @@ void kchmFillListViewWithParsedData( TQListView * list, const TQValueVector< LCH
 		if ( indent >= lastchild.size() )
 		{
 			lastchild.resize( indent + 1 );
-			lastchild[indent] = 0;
+			lastchild[indent] = nullptr;
 		
 			rootentry.resize( indent + 1 );
-			rootentry[indent] = 0;
+			rootentry[indent] = nullptr;
 		}
 	
 		// Create the node
@@ -169,7 +169,7 @@ void kchmFillListViewWithParsedData( TQListView * list, const TQValueVector< LCH
 		{
 			// New non-root entry. It is possible (for some buggy CHMs) that there is no previous entry: previoous entry had indent 1,
 			// and next entry has indent 3. Backtracking it up, creating missing entries.
-			if ( rootentry[indent-1] == 0 )
+			if ( rootentry[indent-1] == nullptr )
 				tqFatal("Child entry indented as %d with no root entry!", indent);
 
 			item = new KCHMIndTocItem( rootentry[indent-1], lastchild[indent], data[i].name, url, data[i].imageid );
@@ -253,15 +253,15 @@ void kchmFillListViewWithParsedData( TQListView * list, const TQValueVector< LCH
 			if ( ++indent >= MAX_NEST_DEPTH )
 				tqFatal("CHMFile::ParseAndFillTopicsTree: max nest depth (%d) is reached, error in help file", MAX_NEST_DEPTH);
 
-			lastchild[indent] = 0;
-			rootentry[indent] = 0;
+			lastchild[indent] = nullptr;
+			rootentry[indent] = nullptr;
 			
 			// This intended to fix <ul><ul>, which was seen in some buggy chm files,
 			// and brokes rootentry[indent-1] check
 			int real_indent = indent - root_indent_offset;
 			if ( real_indent > 1
-						  && rootentry[real_indent - 1] == 0
-						  && rootentry[real_indent - 2] != 0 )
+					  && rootentry[real_indent - 1] == nullptr
+					  && rootentry[real_indent - 2] != nullptr )
 			{
 				rootentry[real_indent - 1] = rootentry[real_indent - 2];
 				tqWarning("Broken CHM index/content: tree autocorrection enabled.");
@@ -274,7 +274,7 @@ void kchmFillListViewWithParsedData( TQListView * list, const TQValueVector< LCH
 			if ( --indent < root_indent_offset )
 				indent = root_indent_offset;
 
-			rootentry[indent] = 0;
+			rootentry[indent] = nullptr;
 			DEBUGPARSER(("</ul>: new intent is %d\n", indent - root_indent_offset));
 		}
 
diff --git a/src/kchmviewwindow.cpp b/src/kchmviewwindow.cpp
index 5edca53..992c05a 100644
--- a/src/kchmviewwindow.cpp
+++ b/src/kchmviewwindow.cpp
@@ -38,8 +38,8 @@
 KCHMViewWindow::KCHMViewWindow( TQTabWidget * parent )
 {
 	invalidate();
-	m_contextMenu = 0;
-	m_contextMenuLink = 0;
+	m_contextMenu = nullptr;
+	m_contextMenuLink = nullptr;
 	m_historyMaxSize = 25;
 	
 	m_parentTabWidget = parent;
diff --git a/src/kchmviewwindow_qtextbrowser.cpp b/src/kchmviewwindow_qtextbrowser.cpp
index 6ea8b20..f8ab05a 100644
--- a/src/kchmviewwindow_qtextbrowser.cpp
+++ b/src/kchmviewwindow_qtextbrowser.cpp
@@ -43,7 +43,7 @@ KCHMViewWindow_QTextBrowser::KCHMViewWindow_QTextBrowser( TQTabWidget * parent )
 	: TQTextBrowser ( parent ), KCHMViewWindow ( parent )
 {
 	m_zoomfactor = 0;
-	m_sourcefactory = 0;
+	m_sourcefactory = nullptr;
 	invalidate();
 	
 	setTextFormat ( TQt::RichText );
@@ -264,7 +264,7 @@ TQPopupMenu * KCHMViewWindow_QTextBrowser::createPopupMenu( const TQPoint & pos
 {
 	KTQPopupMenu * menu = getContextMenu( anchorAt( pos ), this );
 	menu->exec( mapToGlobal( contentsToViewport( pos ) ) );
-	return 0;
+	return nullptr;
 }
 
 #include "kchmviewwindow_qtextbrowser.moc"
diff --git a/src/kchmviewwindowmgr.cpp b/src/kchmviewwindowmgr.cpp
index ea66069..63babaf 100644
--- a/src/kchmviewwindowmgr.cpp
+++ b/src/kchmviewwindowmgr.cpp
@@ -37,7 +37,7 @@
 KCHMViewWindowMgr::KCHMViewWindowMgr( TQWidget *parent )
 	: TQTabWidget( parent ) //TQTabWidget
 {
-	m_MenuWindow = 0;
+	m_MenuWindow = nullptr;
 	
 	// on current tab changed
 	connect( this, TQ_SIGNAL( currentChanged(TQWidget *) ), this, TQ_SLOT( onTabChanged(TQWidget *) ) );
diff --git a/src/kchmviewwindowmgr.h b/src/kchmviewwindowmgr.h
index c2f6fc6..8122fda 100644
--- a/src/kchmviewwindowmgr.h
+++ b/src/kchmviewwindowmgr.h
@@ -33,7 +33,7 @@ class KCHMViewWindowMgr : public TQTabWidget
 	TQ_OBJECT
   
 	public:
-    	KCHMViewWindowMgr( TQWidget *parent = 0 );
+	KCHMViewWindowMgr( TQWidget *parent = nullptr );
 		~KCHMViewWindowMgr( );
 		
 		// Returns a handle to a currently viewed window.
diff --git a/src/tde-tqt.cpp b/src/tde-tqt.cpp
index f668466..fa84a6d 100644
--- a/src/tde-tqt.cpp
+++ b/src/tde-tqt.cpp
@@ -33,7 +33,7 @@ KQListView::KQListView( TQWidget * parent, const char * name, int f )
 
 #if defined (USE_KDE)
 KTQProgressModalDialog::KTQProgressModalDialog ( const TQString & captionText, const TQString & labelText, const TQString & cancelButtonText, int totalSteps, TQWidget * creator )
-	: KProgressDialog( creator, 0, captionText, labelText, true )
+	: KProgressDialog( creator, nullptr, captionText, labelText, true )
 {
 	setAllowCancel( true );
 	showCancelButton( true );
@@ -44,7 +44,7 @@ KTQProgressModalDialog::KTQProgressModalDialog ( const TQString & captionText, c
 }
 #else
 KTQProgressModalDialog::KTQProgressModalDialog ( const TQString & captionText, const TQString & labelText, const TQString & cancelButtonText, int totalSteps, TQWidget * creator )
-	: TQProgressDialog( labelText, cancelButtonText, totalSteps, creator, 0, false )
+	: TQProgressDialog( labelText, cancelButtonText, totalSteps, creator, nullptr, false )
 {
 	setCaption( captionText );
 	setMinimumDuration( 1 );
diff --git a/src/tde-tqt.h b/src/tde-tqt.h
index a449cf0..37c2633 100644
--- a/src/tde-tqt.h
+++ b/src/tde-tqt.h
@@ -96,14 +96,14 @@ public:
 class KQListView : public TDEQ_CLASSNAME(ListView)
 {
 public:
-	KQListView(TQWidget *parent = 0, const char *name = 0, int f = 0);
+	KQListView(TQWidget *parent = nullptr, const char *name = nullptr, int f = 0);
 };
 
 
 class KTQProgressModalDialog : public KQ_CLASSNAME(ProgressDialog)
 {
 	public:
-		KTQProgressModalDialog ( const TQString & captionText, const TQString & labelText, const TQString & cancelButtonText, int totalSteps, TQWidget * creator = 0 );
+		KTQProgressModalDialog ( const TQString & captionText, const TQString & labelText, const TQString & cancelButtonText, int totalSteps, TQWidget * creator = nullptr );
 		
 		// Seems like people have fun making classes incompatible
 #if defined (USE_KDE)		
@@ -117,14 +117,14 @@ class KTQProgressModalDialog : public KQ_CLASSNAME(ProgressDialog)
 class KTQTabWidget : public KQ_CLASSNAME(TabWidget)
 {
 public:
-	KTQTabWidget (TQWidget *parent = 0, const char *name = 0, int f = 0)
+	KTQTabWidget (TQWidget *parent = nullptr, const char *name = nullptr, int f = 0)
 		: KQ_CLASSNAME(TabWidget) (parent, name, f) {};
 };
 
 class KTQPopupMenu : public TDEQ_CLASSNAME(PopupMenu)
 {
 public:
-	KTQPopupMenu (TQWidget *parent = 0 )
+	KTQPopupMenu (TQWidget *parent = nullptr )
 		: TDEQ_CLASSNAME(PopupMenu) (parent) {};
 };
 
diff --git a/src/tde/kchmdcopiface.h b/src/tde/kchmdcopiface.h
index 1fd2ff2..5891a02 100644
--- a/src/tde/kchmdcopiface.h
+++ b/src/tde/kchmdcopiface.h
@@ -34,7 +34,7 @@ class KCHMDCOPIface : public TQObject, public DCOPObject
 	K_DCOP
 			
 	public:
-    	KCHMDCOPIface( TQObject *parent = 0, const char *name = 0 );
+	KCHMDCOPIface( TQObject *parent = nullptr, const char *name = nullptr );
 		~KCHMDCOPIface();
 		
 	k_dcop:
diff --git a/src/tde/kchmviewwindow_tdehtmlpart.cpp b/src/tde/kchmviewwindow_tdehtmlpart.cpp
index fc6a3ad..7ca6c09 100644
--- a/src/tde/kchmviewwindow_tdehtmlpart.cpp
+++ b/src/tde/kchmviewwindow_tdehtmlpart.cpp
@@ -37,11 +37,12 @@ TQWidget * KCHMViewWindow_TDEHTMLPart::getTQWidget()
 	 return view();
 }
 
+
 KCHMViewWindow_TDEHTMLPart::KCHMViewWindow_TDEHTMLPart( TQTabWidget * parent )
 	: TDEHTMLPart ( parent ), KCHMViewWindow ( parent )
 {
 	m_zoomfactor = 0;
-	m_currentEncoding = 0;
+	m_currentEncoding = nullptr;
 	m_searchForward = true;
 
 	invalidate();
@@ -123,7 +124,7 @@ void KCHMViewWindow_TDEHTMLPart::searchWord( const TQString & word, bool forward
 		m_searchText = word;
 		m_searchForward = forward;
 		
-		findText ( word, forward ? 0 : KFindDialog::FindBackwards, ::mainWindow, 0 );
+		findText ( word, forward ? 0 : KFindDialog::FindBackwards, ::mainWindow, nullptr );
 	}
 	
 	findTextNext ();
@@ -160,4 +161,3 @@ void  KCHMViewWindow_TDEHTMLPart::onPopupMenu ( const TQString &url, const TQPoi
 	KTQPopupMenu * menu = getContextMenu( url, view() );
 	menu->exec( point );
 }
-
-- 
cgit v1.2.3

