FireFox Posted February 21, 2009 Share Posted February 21, 2009 Hi,I use RichEdit UDF because I want an Input where I can put color and format of text where I want...I found this functions :_GUICtrlRichEdit_SetBold_GUICtrlRichEdit_SetItalic_GUICtrlRichEdit_SetUnderlineBut the problem is that function only set Bold; Italics; Underlined to all the text; but I want to set only parts of text...Another problem :At start when you create your RichEdit input, the font and weight are big, so i place this code :_GUICtrlRichEdit_SetFontName($mt, 'Arial') _GUICtrlRichEdit_SetFontSize($mt, 8) _GUICtrlRichEdit_SetBold($mt, False)I works at start, but when I change the text of the RichEdit, it returns to the big font and I can't change it Thanks for anyhelp Cheers, FireFox. Link to comment Share on other sites More sharing options...
ProgAndy Posted February 21, 2009 Share Posted February 21, 2009 The funcs set the style to the selected text. To set default font, you have to specify FALSE as third parameter: _GUICtrlRichEdit_SetBold($mt, False,False) *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes Link to comment Share on other sites More sharing options...
FireFox Posted February 21, 2009 Author Share Posted February 21, 2009 (edited) @ProgAndyhm...it doesn't work for _GUICtrlRichEdit_SetBold($mt, False,False) because when I use _GUICtrlRichEdit_SetTextEx, the font is reset...The funcs set the style to the selected text.the problem is that I want to set the color to RichEdit input without to select anything...Example : 'RichEdit' to 'RichEdit'Cheers, FireFox. Edited February 21, 2009 by FireFox Link to comment Share on other sites More sharing options...
ProgAndy Posted February 21, 2009 Share Posted February 21, 2009 You have to use set the selection and then the style or use RTF-tags. Why the default font-setting doesn't work, i don't know. I'm not that familiar with the RichEdit-functions. *GERMAN* [note: you are not allowed to remove author / modified info from my UDFs]My UDFs:[_SetImageBinaryToCtrl] [_TaskDialog] [AutoItObject] [Animated GIF (GDI+)] [ClipPut for Image] [FreeImage] [GDI32 UDFs] [GDIPlus Progressbar] [Hotkey-Selector] [Multiline Inputbox] [MySQL without ODBC] [RichEdit UDFs] [SpeechAPI Example] [WinHTTP]UDFs included in AutoIt: FTP_Ex (as FTPEx), _WinAPI_SetLayeredWindowAttributes Link to comment Share on other sites More sharing options...
FireFox Posted February 21, 2009 Author Share Posted February 21, 2009 @ProgAndy ok... Cheers, FireFox. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now