Richtext Box formating help in WPF using c#.net
开发者_JAVA技巧i am making a project for bulk emailing . In this I have added a richtext box . I want users to enter the email message body in it and want to give them the ability to format .Richtext box should be able to make the content bold, italics, underline, align it right left and center, increase font, decrease font, change color, change the font like Times New Roman depending on the click of the button.
How should i go about it and which references i should add to my project?
Take a look at this modified richtextbox http://www.codeproject.com/KB/miscctrl/richtextboxextended.aspx
You can use CommandBinding, and inside that binding, you have options to handle EditingCommands such as increasing font size, aligning text, and etc.
This would let you handle your own implementation instead of the default behavior. This way, you can say, well if MoveDownByParagraph was triggered by the agent, then, do this instead.
Examples:
http://msdn.microsoft.com/en-us/library/ms752308.aspx
http://www.switchonthecode.com/tutorials/wpf-tutorial-command-bindings-and-custom-commands
精彩评论