[PATCH] [WinHelp]: make now richedit the default for rendering

Eric Pouech eric.pouech at orange.fr
Mon Apr 28 14:16:09 CDT 2008




A+
---

 programs/winhelp/winhelp.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)


diff --git a/programs/winhelp/winhelp.c b/programs/winhelp/winhelp.c
index fd605a9..62eb98f 100644
--- a/programs/winhelp/winhelp.c
+++ b/programs/winhelp/winhelp.c
@@ -251,7 +251,11 @@ int PASCAL WinMain(HINSTANCE hInstance, HINSTANCE prev, LPSTR cmdline, int show)
 
     Globals.hInstance = hInstance;
 
-    use_richedit = getenv("WINHELP_RICHEDIT") != NULL;
+    /* don't use richedit for rendering when WINHELP_RICHEDIT environment variable is 0 */
+    {
+        const char*     p = getenv("WINHELP_RICHEDIT");
+        use_richedit = !p || *p != '0';
+    }
     if (use_richedit && LoadLibrary("riched20.dll") == NULL)
         return MessageBox(0, MAKEINTRESOURCE(STID_NO_RICHEDIT),
                           MAKEINTRESOURCE(STID_WHERROR), MB_OK);





More information about the wine-patches mailing list