The project I am currently working on is a text editor type app. I am wondering how I can handle custom view options. eg. font family, size, bold, colors for myTextBox
. My Editor Tab is a EditorTabViewModel
within the View is a custom user control MarkdownEditor
. Its basically a text box with some buttons for bold/italic etc. I am wondering how can I somehow set options for the custom usercontrol/editor from like a OptionsView
of my app?
the way I am rendering the editor is
<Window.Resources>
<DataTemplate DataType="{x:Type vm:EditorTabViewModel}">
<me:MarkdownEditor />
</DataTemplate>
</Window.Resources>
MarkdownEditor
is a user control that exposes public display properties for setting fonts, colors etc.
UPDATE: also since there can be many MarkdownEditor
s in the app, I want the options to be global