From: Julian Taylor <jtaylor.debian@googlemail.com>
Date: Sat, 27 Oct 2018 13:36:23 +0200
Subject: enable local help

disable windows chm viewer and use x-www-browser to view docs
located as html files in "/usr/share/doc/keepass2/Chm/help/"
Forwarded: not-needed
---
 KeePass/App/AppHelp.cs | 30 +++++++++---------------------
 1 file changed, 9 insertions(+), 21 deletions(-)

Index: keepass2/KeePass/App/AppHelp.cs
===================================================================
--- keepass2.orig/KeePass/App/AppHelp.cs
+++ keepass2/KeePass/App/AppHelp.cs
@@ -67,7 +67,7 @@ namespace KeePass.App
 				{
 					string strFile = AppHelp.LocalHelpFile;
 					if(!string.IsNullOrEmpty(strFile))
-						return File.Exists(strFile);
+						return Directory.Exists("/usr/share/doc/keepass2/Chm/help/");
 				}
 				catch(Exception) { Debug.Assert(false); }
 
@@ -127,36 +127,24 @@ namespace KeePass.App
 			string strFile = AppHelp.LocalHelpFile;
 			if(string.IsNullOrEmpty(strFile)) { Debug.Assert(false); return; }
 
-			// Unblock CHM file for proper display of help contents
-			WinUtil.RemoveZoneIdentifier(strFile);
+			string strCmd = "/usr/share/doc/keepass2/Chm/help/";
 
-			string strCmd = "\"ms-its:" + strFile;
 			if(!string.IsNullOrEmpty(strTopic))
 			{
-				strCmd += "::/help/" + strTopic + ".html";
+				strCmd += strTopic + ".html";
 
 				if(!string.IsNullOrEmpty(strSection))
 					strCmd += "#" + strSection;
 			}
-			strCmd += "\"";
-
-			if(ShowHelpLocalKcv(strCmd)) return;
-
-			string strDisp = strCmd;
-			try
+			else
 			{
-				if(NativeLib.IsUnix())
-					NativeLib.StartProcess(strCmd.Trim('\"'));
-				else // Windows
-				{
-					strDisp = "HH.exe " + strDisp;
-					NativeLib.StartProcess(WinUtil.LocateSystemApp(
-						"hh.exe"), strCmd);
-				}
+				strCmd += "../index.html";
 			}
-			catch(Exception ex)
+
+			try { Process.Start("x-www-browser", strCmd); }
+			catch(Exception exStart)
 			{
-				MessageService.ShowWarning(strDisp, ex);
+				MessageService.ShowWarning("x-www-browser " + strCmd, exStart);
 			}
 		}
 
