Welcome to MSDN Blogs Sign in | Join | Help

Lester's WPF blog


Simple, easy & beautiful

News

New WPF Features: CaretBrush\SelectionBrush

This is part of a series on New WPF Features

There have been quite a few asks for changing the selection color and the caret color. We have now provide 2 properties to make this possible

  • CaretBrush
  • SelectionBrush  

An example usage would be like

  • SelectionBrush="RED"
  • SelectionOpacity="0.3"  (Default value is 0.6)
  • CaretBrush="Red"

 

These properties are avaialble on controls that allow selection\caret.

Share this post

 

Posted: Tuesday, October 27, 2009 2:12 PM by llester

Comments

Denis Vuyka said:

Thanks for sharing this info! This is a very needed feature indeed

# October 28, 2009 12:09 AM

Doug said:

Can you also use a transparent brush for the caret?

# November 6, 2009 5:47 PM

llester said:

Doug, any brush should work..

# November 6, 2009 9:21 PM

Doug said:

Thank you for the information as well as your blog!

:)

# December 15, 2009 10:31 AM
Leave a Comment

(required) 

(required) 

(optional)

(required) 

  
Enter Code Here: Required

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Page view tracker