wpf color picker setting forecolor in richtextbox not working
private void ColorPicker_ColorChanged(object sender, RoutedPropertyChangedEventArgs<Color> e) { // richTextBox1.Foreground = ColorPicker.SelectedColor; }
<StackPanel Margin="109,0,207,0"><osc:SmallColorPicker x:Name="ColorPicker" SelectedColor="Black" ColorChanged="ColorPicker_ColorChanged" Width="48" Margin="4,4,0,4" HorizontalAlignment="Left"/><Rectangle Fill="{Binding SelectedBrush, ElementName=ColorPicker}" Stroke="Black" Margin="4" Width="48" Height="20" HorizontalAlignment="Left" ToolTip="Rectangle with binding to the ColorPicker.SelectedBrush property"/><Label Content="{Binding SelectedColor, ElementName=ColorPicker}" Margin="4" ToolTip="Label with binding to the ColorPicker"/></StackPanel>