[PATCH 29/45] [WinHelp]: set the alignment of paragraph in richedit

Eric Pouech eric.pouech at orange.fr
Sun Mar 23 04:20:15 CDT 2008




A+
---

 programs/winhelp/hlpfile.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)


diff --git a/programs/winhelp/hlpfile.c b/programs/winhelp/hlpfile.c
index 4c7943d..83ded3b 100644
--- a/programs/winhelp/hlpfile.c
+++ b/programs/winhelp/hlpfile.c
@@ -1047,7 +1047,15 @@ BOOL HLPFILE_BrowseParagraph(HLPFILE *hlpfile, struct RtfData* rd, BYTE *buf, BY
                 if (!HLPFILE_RtfAddControl(rd, tmp)) goto done;
             }
         }
-        /* 0x0400, 0x0800 and 0x1000 don't need space */
+        switch (bits & 0xc00)
+        {
+        default: WINE_FIXME("Unsupported alignment 0xC00\n"); break;
+        case 0: if (!HLPFILE_RtfAddControl(rd, "\\ql")) goto done; break;
+        case 0x400: if (!HLPFILE_RtfAddControl(rd, "\\qr")) goto done; break;
+        case 0x800: if (!HLPFILE_RtfAddControl(rd, "\\qc")) goto done; break;
+        }
+
+        /* 0x1000 doesn't need space */
         if ((bits & 0xE080) != 0) 
             WINE_FIXME("Unsupported bits %04x, potential trouble ahead\n", bits);
 





More information about the wine-patches mailing list