0

What is use of Fill property in System.Windows.Shapes.Line in WPF?

<Line Fill="Red" Stroke="Black" X2="1"/>
Ankush Madankar
  • 3,689
  • 4
  • 40
  • 74
  • 3
    It seems useless in Line, in fact it's just an inherited member from `Shape`. Normally we use `Stroke`. There are some cases in which the inherited members are meaningless in the derived class, using those members does not have any effect. I may wonder why it's there as a member of Line but in fact it's of the base class `Shape`. – King King Oct 21 '15 at 12:39

1 Answers1

0

From King King comment, answer is:

It seems useless in Line, in fact it's just an inherited member from Shape. Normally we use Stroke. There are some cases in which the inherited members are meaningless in the derived class, using those members does not have any effect. I may wonder why it's there as a member of Line but in fact it's of the base class Shape.

Ankush Madankar
  • 3,689
  • 4
  • 40
  • 74