11-19-2014, 06:13 AM
Quote:the rich editfield can not display .rtf files correctly, it shows the .rtf markup code in stead of the formatted textI cannot reproduce it. How do you populate the rich edit control? What QM and Windows versions?
The dialog is Unicode, therefore QM uses Unicode version of rich edit control, with W in classname.
tested with
Function Dialog151
\Dialog_Editor
str dd=
;BEGIN DIALOG
;1 "" 0x90C80AC8 0x0 0 0 282 168 "Dialog"
;3 RichEdit20W 0x54233044 0x200 0 0 284 110 ""
;1 Button 0x54030001 0x4 116 116 48 14 "OK"
;2 Button 0x54030000 0x4 168 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2040201 "*" "" "" ""
str controls = "3"
str re3
re3="&$desktop$\b.rtf"
if(!ShowDialog(dd &sub.DlgProc &controls)) ret
#sub DlgProc
function# hDlg message wParam lParam
sel message
,case WM_INITDIALOG
,case WM_DESTROY
,case WM_COMMAND goto messages2
ret
;messages2
sel wParam
,case IDOK
,case IDCANCEL
ret 1