Last change
on this file since 13777 was
12762,
checked in by aballeit, 9 years ago
|
#2283 GUI updates, Tree-chart, MCTS Version 2 (prune leaves)
|
File size:
1.2 KB
|
Rev | Line | |
---|
[12762] | 1 | using System;
|
---|
| 2 | using System.Xml;
|
---|
| 3 | using System.Linq;
|
---|
| 4 | using System.Text;
|
---|
| 5 | using System.Windows;
|
---|
| 6 | using System.Windows.Media;
|
---|
| 7 | using System.Collections.Generic;
|
---|
| 8 |
|
---|
| 9 | using SharpVectors.Dom.Svg;
|
---|
| 10 | using SharpVectors.Dom.Css;
|
---|
| 11 |
|
---|
| 12 | namespace SharpVectors.Renderers.Wpf
|
---|
| 13 | {
|
---|
| 14 | public abstract class WpfFill : DependencyObject
|
---|
| 15 | {
|
---|
| 16 | #region Constructors and Destructor
|
---|
| 17 |
|
---|
| 18 | protected WpfFill()
|
---|
| 19 | {
|
---|
| 20 | }
|
---|
| 21 |
|
---|
| 22 | #endregion
|
---|
| 23 |
|
---|
| 24 | #region Public Methods
|
---|
| 25 |
|
---|
| 26 | public abstract Brush GetBrush(WpfDrawingContext context);
|
---|
| 27 |
|
---|
| 28 | public static WpfFill CreateFill(SvgDocument document, string absoluteUri)
|
---|
| 29 | {
|
---|
| 30 | XmlNode node = document.GetNodeByUri(absoluteUri);
|
---|
| 31 |
|
---|
| 32 | SvgGradientElement gradientNode = node as SvgGradientElement;
|
---|
| 33 | if (gradientNode != null)
|
---|
| 34 | {
|
---|
| 35 | return new WpfGradientFill(gradientNode);
|
---|
| 36 | }
|
---|
| 37 |
|
---|
| 38 | SvgPatternElement patternNode = node as SvgPatternElement;
|
---|
| 39 | if (patternNode != null)
|
---|
| 40 | {
|
---|
| 41 | return new WpfPatternFill(patternNode);
|
---|
| 42 | }
|
---|
| 43 |
|
---|
| 44 | return null;
|
---|
| 45 | }
|
---|
| 46 |
|
---|
| 47 | #endregion
|
---|
| 48 | }
|
---|
| 49 | }
|
---|
Note: See
TracBrowser
for help on using the repository browser.