locked
How to highlight the words with transparent color

    Question

  • have no experience in this area on how to highlight words on document with color such that you can see the words behind the color. I think this must be transparent color.

    Here what I have done:

    1. I display a PDF file

    2. I use Ink to do the line drawing. The size of the line can be adjustable say size 20.

    Problem:

    When I draw (highlight) on the words, it covers the words such that words can not be seen.

    How to make color transparent so that words can be seen after highlighting?

    Thanks

    Thursday, November 27, 2014 3:07 AM

Answers

  • Hi FireDance,

    >> How to make color transparent so that words can be seen after highlighting?

    I assume you are using Drawing Line object at runtime. You can set the Storke property of Line object to set its color. Use the following code snippet.

    Line line = new Line();

                line.Stroke = new SolidColorBrush(Colors.Transparent);

    I have something more to mention, normally, we don’t use the transparent color for highlighting content. We change the background and content foreground color like the following image.

    I would recommend you use the same way.

    If it doesn’t help, please feel free to let me know. Post more information about your scenario, such as how you display the PDF or send me a repro project for reproduction.

    Regards,


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place. Click HERE to participate the survey.

    Friday, November 28, 2014 2:17 AM
    Moderator