Add project files.

This commit is contained in:
Ankitkumar Satapara
2026-04-17 22:31:58 +05:30
commit 21aaef6776
473 changed files with 50152 additions and 0 deletions

283
Nodify/Themes/Brushes.xaml Normal file
View File

@@ -0,0 +1,283 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:o="http://schemas.microsoft.com/winfx/2006/xaml/presentation/options"
xmlns:local="clr-namespace:Nodify">
<!--DEFAULT CONNECTION FOCUS VISUAL-->
<Pen x:Key="{x:Static local:BaseConnection.FocusVisualPenKey}"
o:Freeze="True"
Thickness="1"
Brush="{DynamicResource {x:Static SystemColors.ControlTextBrushKey}}">
<Pen.DashStyle>
<DashStyle Dashes="0.5,3" />
</Pen.DashStyle>
</Pen>
<!--NODIFY EDITOR-->
<SolidColorBrush x:Key="NodifyEditor.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.BackgroundColor}" />
<SolidColorBrush x:Key="NodifyEditor.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.ForegroundColor}" />
<SolidColorBrush x:Key="NodifyEditor.SelectionRectangleStrokeBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.SelectionRectangleColor}" />
<SolidColorBrush x:Key="NodifyEditor.SelectionRectangleBackgroundBrush"
o:Freeze="True"
Opacity="0.1"
Color="{DynamicResource NodifyEditor.SelectionRectangleColor}" />
<SolidColorBrush x:Key="NodifyEditor.PushedAreaStrokeBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.PushedAreaColor}" />
<SolidColorBrush x:Key="NodifyEditor.PushedAreaBackgroundBrush"
o:Freeze="True"
Opacity="0.2"
Color="{DynamicResource NodifyEditor.PushedAreaColor}" />
<SolidColorBrush x:Key="NodifyEditor.CuttingLineStrokeBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.CuttingLineColor}" />
<SolidColorBrush x:Key="NodifyEditor.CuttingLineBackgroundBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.CuttingLineColor}" />
<!--ITEM CONTAINER-->
<SolidColorBrush x:Key="ItemContainer.BorderBrush"
o:Freeze="True"
Color="{DynamicResource ItemContainer.BorderColor}" />
<DrawingBrush x:Key="ItemContainer.HighlightBrush"
o:Freeze="True"
Viewport="0 0 24 24"
ViewportUnits="Absolute"
TileMode="Tile">
<DrawingBrush.Drawing>
<DrawingGroup>
<GeometryDrawing Brush="{StaticResource ItemContainer.BorderBrush}">
<GeometryDrawing.Geometry>
<GeometryGroup>
<RectangleGeometry Rect="0 0 50 50" />
<RectangleGeometry Rect="50 50 50 50" />
</GeometryGroup>
</GeometryDrawing.Geometry>
</GeometryDrawing>
</DrawingGroup>
</DrawingBrush.Drawing>
</DrawingBrush>
<SolidColorBrush x:Key="ItemContainer.SelectedBrush"
o:Freeze="True"
Color="{DynamicResource ItemContainer.SelectedColor}" />
<!--NODE-->
<SolidColorBrush x:Key="Node.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource Node.BackgroundColor}" />
<SolidColorBrush x:Key="Node.ContentBrush"
o:Freeze="True"
Color="{DynamicResource Node.ContentColor}" />
<SolidColorBrush x:Key="Node.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource Node.ForegroundColor}" />
<SolidColorBrush x:Key="Node.HeaderForegroundBrush"
o:Freeze="True"
Color="{DynamicResource Node.HeaderForegroundColor}" />
<SolidColorBrush x:Key="Node.BorderBrush"
o:Freeze="True"
Color="{DynamicResource Node.BorderColor}" />
<SolidColorBrush x:Key="Node.HeaderBrush"
o:Freeze="True"
Color="{DynamicResource Node.HeaderColor}" />
<SolidColorBrush x:Key="Node.FooterBrush"
o:Freeze="True"
Color="{DynamicResource Node.FooterColor}" />
<!--STATE NODE-->
<SolidColorBrush x:Key="StateNode.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource StateNode.BackgroundColor}" />
<SolidColorBrush x:Key="StateNode.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource StateNode.ForegroundColor}" />
<SolidColorBrush x:Key="StateNode.BorderBrush"
o:Freeze="True"
Color="{DynamicResource StateNode.BorderColor}" />
<SolidColorBrush x:Key="StateNode.HighlightBrush"
o:Freeze="True"
Color="{DynamicResource StateNode.HighlightColor}" />
<!--GROUPING NODE-->
<SolidColorBrush x:Key="GroupingNode.BackgroundBrush"
o:Freeze="True"
Opacity=".5"
Color="{DynamicResource GroupingNode.BackgroundColor}" />
<SolidColorBrush x:Key="GroupingNode.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource GroupingNode.ForegroundColor}" />
<SolidColorBrush x:Key="GroupingNode.HeaderBrush"
o:Freeze="True"
Color="{DynamicResource GroupingNode.HeaderColor}" />
<SolidColorBrush x:Key="GroupingNode.BorderBrush"
o:Freeze="True"
Color="{DynamicResource GroupingNode.BorderColor}" />
<!--KNOT NODE-->
<SolidColorBrush x:Key="KnotNode.BackgroundBrush"
o:Freeze="True"
Opacity=".5"
Color="{DynamicResource KnotNode.BackgroundColor}" />
<SolidColorBrush x:Key="KnotNode.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource KnotNode.ForegroundColor}" />
<SolidColorBrush x:Key="KnotNode.BorderBrush"
o:Freeze="True"
Color="{DynamicResource KnotNode.BorderColor}" />
<!--CONNECTOR-->
<SolidColorBrush x:Key="Connector.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource Connector.BackgroundColor}" />
<SolidColorBrush x:Key="Connector.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource Connector.ForegroundColor}" />
<SolidColorBrush x:Key="Connector.BorderBrush"
o:Freeze="True"
Color="{DynamicResource Connector.BorderColor}" />
<!--NODE INPUT-->
<SolidColorBrush x:Key="NodeInput.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource NodeInput.BackgroundColor}" />
<SolidColorBrush x:Key="NodeInput.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource NodeInput.ForegroundColor}" />
<SolidColorBrush x:Key="NodeInput.BorderBrush"
o:Freeze="True"
Color="{DynamicResource NodeInput.BorderColor}" />
<!--NODE OUTPUT-->
<SolidColorBrush x:Key="NodeOutput.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource NodeOutput.BackgroundColor}" />
<SolidColorBrush x:Key="NodeOutput.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource NodeOutput.ForegroundColor}" />
<SolidColorBrush x:Key="NodeOutput.BorderBrush"
o:Freeze="True"
Color="{DynamicResource NodeOutput.BorderColor}" />
<!--CONNECTION-->
<SolidColorBrush x:Key="Connection.StrokeBrush"
o:Freeze="True"
Color="{DynamicResource Connection.StrokeColor}" />
<!--LINE CONNECTION-->
<SolidColorBrush x:Key="LineConnection.StrokeBrush"
o:Freeze="True"
Color="{DynamicResource LineConnection.StrokeColor}" />
<!--CIRCUIT CONNECTION-->
<SolidColorBrush x:Key="CircuitConnection.StrokeBrush"
o:Freeze="True"
Color="{DynamicResource CircuitConnection.StrokeColor}" />
<!--STEP CONNECTION-->
<SolidColorBrush x:Key="StepConnection.StrokeBrush"
o:Freeze="True"
Color="{DynamicResource StepConnection.StrokeColor}" />
<!--PENDING CONNECTION-->
<SolidColorBrush x:Key="PendingConnection.StrokeBrush"
o:Freeze="True"
Color="{DynamicResource PendingConnection.StrokeColor}" />
<SolidColorBrush x:Key="PendingConnection.BorderBrush"
o:Freeze="True"
Color="{DynamicResource PendingConnection.BorderColor}" />
<SolidColorBrush x:Key="PendingConnection.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource PendingConnection.ForegroundColor}" />
<SolidColorBrush x:Key="PendingConnection.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource PendingConnection.BackgroundColor}" />
<!--MINIMAP-->
<SolidColorBrush x:Key="Minimap.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource Minimap.BackgroundColor}"
Opacity="0.7" />
<SolidColorBrush x:Key="Minimap.ViewportStrokeBrush"
o:Freeze="True"
Color="{DynamicResource Minimap.ViewportStrokeColor}" />
<SolidColorBrush x:Key="Minimap.ViewportBackgroundBrush"
o:Freeze="True"
Color="{DynamicResource Minimap.ViewportBackgroundColor}"
Opacity="0.2" />
<SolidColorBrush x:Key="MinimapItem.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource MinimapItem.BackgroundColor}"
Opacity="0.8" />
<!--HOT KEYS-->
<SolidColorBrush x:Key="HotKey.BackgroundBrush"
o:Freeze="True"
Color="{DynamicResource HotKey.BackgroundColor}" />
<SolidColorBrush x:Key="HotKey.ForegroundBrush"
o:Freeze="True"
Color="{DynamicResource HotKey.ForegroundColor}" />
<SolidColorBrush x:Key="HotKey.BorderBrush"
o:Freeze="True"
Color="{DynamicResource HotKey.BorderColor}" />
</ResourceDictionary>

271
Nodify/Themes/Controls.xaml Normal file
View File

@@ -0,0 +1,271 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Brushes.xaml" />
</ResourceDictionary.MergedDictionaries>
<!--NODIFY EDITOR-->
<Style x:Key="NodifyEditor.SelectionRectangleStyle"
TargetType="Rectangle">
<Setter Property="StrokeThickness"
Value="1" />
<Setter Property="Stroke"
Value="{StaticResource NodifyEditor.SelectionRectangleStrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource NodifyEditor.SelectionRectangleBackgroundBrush}" />
</Style>
<Style x:Key="NodifyEditor.PushedAreaStyle"
TargetType="Rectangle">
<Setter Property="StrokeThickness"
Value="1" />
<Setter Property="Stroke"
Value="{StaticResource NodifyEditor.PushedAreaStrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource NodifyEditor.PushedAreaBackgroundBrush}" />
</Style>
<Style TargetType="{x:Type local:NodifyEditor}"
BasedOn="{StaticResource {x:Type local:NodifyEditor}}">
<Setter Property="Background"
Value="{StaticResource NodifyEditor.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource NodifyEditor.ForegroundBrush}" />
<Setter Property="SelectionRectangleStyle"
Value="{StaticResource NodifyEditor.SelectionRectangleStyle}" />
<Setter Property="PushedAreaStyle"
Value="{StaticResource NodifyEditor.PushedAreaStyle}" />
</Style>
<!--ITEM CONTAINER-->
<Style TargetType="{x:Type local:ItemContainer}"
BasedOn="{StaticResource {x:Type local:ItemContainer}}">
<Setter Property="HighlightBrush"
Value="{StaticResource ItemContainer.HighlightBrush}" />
<Setter Property="BorderBrush"
Value="{DynamicResource ItemContainer.BorderBrush}" />
<Setter Property="SelectedBrush"
Value="{DynamicResource ItemContainer.SelectedBrush}" />
</Style>
<!--DECORATOR CONTAINER-->
<Style TargetType="{x:Type local:DecoratorContainer}"
BasedOn="{StaticResource {x:Type local:DecoratorContainer}}" />
<!--NODE-->
<Style TargetType="{x:Type local:Node}"
BasedOn="{StaticResource {x:Type local:Node}}">
<Setter Property="Background"
Value="{StaticResource Node.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource Node.ForegroundBrush}" />
<Setter Property="ContentBrush"
Value="{StaticResource Node.ContentBrush}" />
<Setter Property="HeaderBrush"
Value="{StaticResource Node.HeaderBrush}" />
<Setter Property="FooterBrush"
Value="{StaticResource Node.FooterBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource Node.BorderBrush}" />
<Style.Triggers>
<Trigger Property="HasHeader"
Value="True">
<Setter Property="Foreground"
Value="{StaticResource Node.HeaderForegroundBrush}" />
</Trigger>
</Style.Triggers>
</Style>
<!--STATE NODE-->
<Style TargetType="{x:Type local:StateNode}"
BasedOn="{StaticResource {x:Type local:StateNode}}">
<Setter Property="Background"
Value="{StaticResource StateNode.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource StateNode.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource StateNode.BorderBrush}" />
<Setter Property="HighlightBrush"
Value="{StaticResource StateNode.HighlightBrush}" />
</Style>
<!--GROUPING NODE-->
<Style TargetType="{x:Type local:GroupingNode}"
BasedOn="{StaticResource {x:Type local:GroupingNode}}">
<Setter Property="Background"
Value="{StaticResource GroupingNode.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource GroupingNode.ForegroundBrush}" />
<Setter Property="HeaderBrush"
Value="{StaticResource GroupingNode.HeaderBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource GroupingNode.BorderBrush}" />
</Style>
<!--KNOT NODE-->
<Style TargetType="{x:Type local:KnotNode}"
BasedOn="{StaticResource {x:Type local:KnotNode}}">
<Setter Property="Background"
Value="{StaticResource KnotNode.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource KnotNode.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource KnotNode.BorderBrush}" />
</Style>
<!--CONNECTOR-->
<Style TargetType="{x:Type local:Connector}"
BasedOn="{StaticResource {x:Type local:Connector}}">
<Setter Property="Background"
Value="{StaticResource Connector.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource Connector.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource Connector.BorderBrush}" />
</Style>
<!--NODE INPUT-->
<Style TargetType="{x:Type local:NodeInput}"
BasedOn="{StaticResource {x:Type local:NodeInput}}">
<Setter Property="Background"
Value="{StaticResource NodeInput.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource NodeInput.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource NodeInput.BorderBrush}" />
</Style>
<!--NODE OUTPUT-->
<Style TargetType="{x:Type local:NodeOutput}"
BasedOn="{StaticResource {x:Type local:NodeOutput}}">
<Setter Property="Background"
Value="{StaticResource NodeOutput.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource NodeOutput.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource NodeOutput.BorderBrush}" />
</Style>
<!--CONNECTION-->
<Style TargetType="{x:Type local:Connection}"
BasedOn="{StaticResource {x:Type local:Connection}}">
<Setter Property="Stroke"
Value="{StaticResource Connection.StrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource Connection.StrokeBrush}" />
</Style>
<!--LINE CONNECTION-->
<Style TargetType="{x:Type local:LineConnection}"
BasedOn="{StaticResource {x:Type local:LineConnection}}">
<Setter Property="Stroke"
Value="{StaticResource LineConnection.StrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource LineConnection.StrokeBrush}" />
</Style>
<!--CIRCUIT CONNECTION-->
<Style TargetType="{x:Type local:CircuitConnection}"
BasedOn="{StaticResource {x:Type local:CircuitConnection}}">
<Setter Property="Stroke"
Value="{StaticResource CircuitConnection.StrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource CircuitConnection.StrokeBrush}" />
</Style>
<!--STEP CONNECTION-->
<Style TargetType="{x:Type local:StepConnection}"
BasedOn="{StaticResource {x:Type local:StepConnection}}">
<Setter Property="Stroke"
Value="{StaticResource StepConnection.StrokeBrush}" />
<Setter Property="Fill"
Value="{StaticResource StepConnection.StrokeBrush}" />
</Style>
<!--PENDING CONNECTION-->
<Style TargetType="{x:Type local:PendingConnection}"
BasedOn="{StaticResource {x:Type local:PendingConnection}}">
<Setter Property="Stroke"
Value="{StaticResource PendingConnection.StrokeBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource PendingConnection.BorderBrush}" />
<Setter Property="Foreground"
Value="{StaticResource PendingConnection.ForegroundBrush}" />
<Setter Property="Background"
Value="{StaticResource PendingConnection.BackgroundBrush}" />
</Style>
<!--CUTTING LINE-->
<Style TargetType="{x:Type local:CuttingLine}"
BasedOn="{StaticResource {x:Type local:CuttingLine}}">
<Setter Property="Fill"
Value="{StaticResource NodifyEditor.CuttingLineBackgroundBrush}" />
<Setter Property="Stroke"
Value="{StaticResource NodifyEditor.CuttingLineStrokeBrush}" />
</Style>
<!--MINIMAP-->
<Style x:Key="Minimap.ViewportStyle"
TargetType="Rectangle">
<Setter Property="Stroke"
Value="{StaticResource Minimap.ViewportStrokeBrush}" />
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Fill"
Value="{StaticResource Minimap.ViewportBackgroundBrush}" />
<Setter Property="StrokeLineJoin"
Value="Round" />
<Setter Property="StrokeEndLineCap"
Value="Round" />
<Setter Property="StrokeStartLineCap"
Value="Round" />
</Style>
<Style TargetType="{x:Type local:Minimap}"
BasedOn="{StaticResource {x:Type local:Minimap}}">
<Setter Property="Background"
Value="{StaticResource Minimap.BackgroundBrush}" />
<Setter Property="ViewportStyle"
Value="{StaticResource Minimap.ViewportStyle}" />
</Style>
<Style TargetType="{x:Type local:MinimapItem}"
BasedOn="{StaticResource {x:Type local:MinimapItem}}">
<Setter Property="Background"
Value="{StaticResource MinimapItem.BackgroundBrush}" />
</Style>
<!--HOT KEYS-->
<Style TargetType="{x:Type local:HotKeyControl}"
BasedOn="{StaticResource {x:Type local:HotKeyControl}}">
<Setter Property="Background"
Value="{StaticResource HotKey.BackgroundBrush}" />
<Setter Property="Foreground"
Value="{StaticResource HotKey.ForegroundBrush}" />
<Setter Property="BorderBrush"
Value="{StaticResource HotKey.BorderBrush}" />
<Setter Property="BorderThickness"
Value="1" />
</Style>
</ResourceDictionary>

91
Nodify/Themes/Dark.xaml Normal file
View File

@@ -0,0 +1,91 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Controls.xaml" />
</ResourceDictionary.MergedDictionaries>
<!--NODIFY EDITOR-->
<Color x:Key="NodifyEditor.BackgroundColor">#1E1E1E</Color>
<Color x:Key="NodifyEditor.ForegroundColor">White</Color>
<Color x:Key="NodifyEditor.SelectionRectangleColor">DodgerBlue</Color>
<Color x:Key="NodifyEditor.PushedAreaColor">#74747c</Color>
<Color x:Key="NodifyEditor.CuttingLineColor">Red</Color>
<!--ITEM CONTAINER-->
<Color x:Key="ItemContainer.BorderColor">DodgerBlue</Color>
<Color x:Key="ItemContainer.SelectedColor">Orange</Color>
<!--NODE-->
<Color x:Key="Node.BackgroundColor">#2D2D30</Color>
<Color x:Key="Node.ContentColor">#2D2D30</Color>
<Color x:Key="Node.ForegroundColor">White</Color>
<Color x:Key="Node.HeaderForegroundColor">White</Color>
<Color x:Key="Node.HeaderColor">#1E1E1E</Color>
<Color x:Key="Node.FooterColor">#1E1E1E</Color>
<Color x:Key="Node.BorderColor">Transparent</Color>
<!--STATE NODE-->
<Color x:Key="StateNode.BackgroundColor">#171717</Color>
<Color x:Key="StateNode.ForegroundColor">White</Color>
<Color x:Key="StateNode.BorderColor">#484848</Color>
<Color x:Key="StateNode.HighlightColor">#D6D3D6</Color>
<!--GROUPING NODE-->
<Color x:Key="GroupingNode.BackgroundColor">#3E3E42</Color>
<Color x:Key="GroupingNode.ForegroundColor">White</Color>
<Color x:Key="GroupingNode.HeaderColor">#1E1E1E</Color>
<Color x:Key="GroupingNode.BorderColor">Transparent</Color>
<!--KNOT NODE-->
<Color x:Key="KnotNode.BackgroundColor">Transparent</Color>
<Color x:Key="KnotNode.ForegroundColor">DodgerBlue</Color>
<Color x:Key="KnotNode.BorderColor">Transparent</Color>
<!--CONNECTOR-->
<Color x:Key="Connector.BackgroundColor">Transparent</Color>
<Color x:Key="Connector.ForegroundColor">White</Color>
<Color x:Key="Connector.BorderColor">DodgerBlue</Color>
<!--NODE INPUT-->
<Color x:Key="NodeInput.BackgroundColor">#2D2D30</Color>
<Color x:Key="NodeInput.ForegroundColor">White</Color>
<Color x:Key="NodeInput.BorderColor">DodgerBlue</Color>
<!--NODE OUTPUT-->
<Color x:Key="NodeOutput.BackgroundColor">#2D2D30</Color>
<Color x:Key="NodeOutput.ForegroundColor">White</Color>
<Color x:Key="NodeOutput.BorderColor">DodgerBlue</Color>
<!--CONNECTION-->
<Color x:Key="Connection.StrokeColor">DodgerBlue</Color>
<!--LINE CONNECTION-->
<Color x:Key="LineConnection.StrokeColor">DodgerBlue</Color>
<!--CIRCUIT CONNECTION-->
<Color x:Key="CircuitConnection.StrokeColor">DodgerBlue</Color>
<!--STEP CONNECTION-->
<Color x:Key="StepConnection.StrokeColor">DodgerBlue</Color>
<!--PENDING CONNECTION-->
<Color x:Key="PendingConnection.StrokeColor">DodgerBlue</Color>
<Color x:Key="PendingConnection.BorderColor">Black</Color>
<Color x:Key="PendingConnection.ForegroundColor">White</Color>
<Color x:Key="PendingConnection.BackgroundColor">#121212</Color>
<!--MINIMAP-->
<Color x:Key="Minimap.BackgroundColor">#121212</Color>
<Color x:Key="Minimap.ViewportStrokeColor">#74747c</Color>
<Color x:Key="Minimap.ViewportBackgroundColor">#74747c</Color>
<Color x:Key="MinimapItem.BackgroundColor">DodgerBlue</Color>
<!--HOT KEYS-->
<Color x:Key="HotKey.BackgroundColor">White</Color>
<Color x:Key="HotKey.ForegroundColor">Black</Color>
<Color x:Key="HotKey.BorderColor">DodgerBlue</Color>
</ResourceDictionary>

View File

@@ -0,0 +1,77 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:o="http://schemas.microsoft.com/winfx/2006/xaml/presentation/options"
xmlns:local="clr-namespace:Nodify">
<Color x:Key="NodifyEditor.FocusVisualColor">#FD5618</Color>
<SolidColorBrush x:Key="NodifyEditor.FocusVisualBrush"
o:Freeze="True"
Color="{DynamicResource NodifyEditor.FocusVisualColor}" />
<Style x:Key="EditorFocusVisualStyle">
<Setter Property="Control.Template">
<Setter.Value>
<ControlTemplate>
<Rectangle StrokeThickness="1"
StrokeDashArray="2"
Margin="-2"
RadiusX="3"
RadiusY="3"
Stroke="{StaticResource NodifyEditor.FocusVisualBrush}" />
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:NodifyEditor}"
BasedOn="{StaticResource {x:Type local:NodifyEditor}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:ItemContainer}"
BasedOn="{StaticResource {x:Type local:ItemContainer}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:DecoratorContainer}"
BasedOn="{StaticResource {x:Type local:DecoratorContainer}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:Connector}"
BasedOn="{StaticResource {x:Type local:Connector}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:NodeInput}"
BasedOn="{StaticResource {x:Type local:NodeInput}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:NodeOutput}"
BasedOn="{StaticResource {x:Type local:NodeOutput}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Style TargetType="{x:Type local:Minimap}"
BasedOn="{StaticResource {x:Type local:Minimap}}">
<Setter Property="FocusVisualStyle"
Value="{StaticResource EditorFocusVisualStyle}" />
</Style>
<Pen x:Key="{x:Static local:BaseConnection.FocusVisualPenKey}"
Thickness="1"
Brush="{StaticResource NodifyEditor.FocusVisualBrush}">
<Pen.DashStyle>
<DashStyle Dashes="0.5,3" />
</Pen.DashStyle>
</Pen>
</ResourceDictionary>

View File

@@ -0,0 +1,8 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="pack://application:,,,/Nodify;component/Themes/Styles/Controls.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>

91
Nodify/Themes/Light.xaml Normal file
View File

@@ -0,0 +1,91 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Controls.xaml" />
</ResourceDictionary.MergedDictionaries>
<!--NODIFY EDITOR-->
<Color x:Key="NodifyEditor.BackgroundColor">White</Color>
<Color x:Key="NodifyEditor.ForegroundColor">Black</Color>
<Color x:Key="NodifyEditor.SelectionRectangleColor">DodgerBlue</Color>
<Color x:Key="NodifyEditor.PushedAreaColor">#5c6a98</Color>
<Color x:Key="NodifyEditor.CuttingLineColor">Red</Color>
<!--ITEM CONTAINER-->
<Color x:Key="ItemContainer.BorderColor">#7EB4EA</Color>
<Color x:Key="ItemContainer.SelectedColor">Orange</Color>
<!--NODE-->
<Color x:Key="Node.BackgroundColor">#CBCCDF</Color>
<Color x:Key="Node.ContentColor">#CBCCDF</Color>
<Color x:Key="Node.ForegroundColor">Black</Color>
<Color x:Key="Node.HeaderForegroundColor">White</Color>
<Color x:Key="Node.HeaderColor">#5C6A98</Color>
<Color x:Key="Node.FooterColor">#5C6A98</Color>
<Color x:Key="Node.BorderColor">Transparent</Color>
<!--STATE NODE-->
<Color x:Key="StateNode.BackgroundColor">#5C6A98</Color>
<Color x:Key="StateNode.ForegroundColor">White</Color>
<Color x:Key="StateNode.BorderColor">#CBCCDF</Color>
<Color x:Key="StateNode.HighlightColor">#B1C5FF</Color>
<!--GROUPING NODE-->
<Color x:Key="GroupingNode.BackgroundColor">#CBCCDF</Color>
<Color x:Key="GroupingNode.ForegroundColor">White</Color>
<Color x:Key="GroupingNode.HeaderColor">#5C6A98</Color>
<Color x:Key="GroupingNode.BorderColor">Transparent</Color>
<!--KNOT NODE-->
<Color x:Key="KnotNode.BackgroundColor">#CBCCDF</Color>
<Color x:Key="KnotNode.ForegroundColor">White</Color>
<Color x:Key="KnotNode.BorderColor">Transparent</Color>
<!--CONNECTOR-->
<Color x:Key="Connector.BackgroundColor">#B1C5FF</Color>
<Color x:Key="Connector.ForegroundColor">White</Color>
<Color x:Key="Connector.BorderColor">#7EB4EA</Color>
<!--NODE INPUT-->
<Color x:Key="NodeInput.BackgroundColor">Transparent</Color>
<Color x:Key="NodeInput.ForegroundColor">Black</Color>
<Color x:Key="NodeInput.BorderColor">#4B91B8</Color>
<!--NODE OUTPUT-->
<Color x:Key="NodeOutput.BackgroundColor">Transparent</Color>
<Color x:Key="NodeOutput.ForegroundColor">Black</Color>
<Color x:Key="NodeOutput.BorderColor">#4B91B8</Color>
<!--CONNECTION-->
<Color x:Key="Connection.StrokeColor">#5CA2C9</Color>
<!--LINE CONNECTION-->
<Color x:Key="LineConnection.StrokeColor">#5CA2C9</Color>
<!--CIRCUIT CONNECTION-->
<Color x:Key="CircuitConnection.StrokeColor">#5CA2C9</Color>
<!--STEP CONNECTION-->
<Color x:Key="StepConnection.StrokeColor">#5CA2C9</Color>
<!--PENDING CONNECTION-->
<Color x:Key="PendingConnection.StrokeColor">#5CA2C9</Color>
<Color x:Key="PendingConnection.BorderColor">Black</Color>
<Color x:Key="PendingConnection.ForegroundColor">White</Color>
<Color x:Key="PendingConnection.BackgroundColor">#5C6A98</Color>
<!--MINIMAP-->
<Color x:Key="Minimap.BackgroundColor">#f2f3f5</Color>
<Color x:Key="Minimap.ViewportStrokeColor">DodgerBlue</Color>
<Color x:Key="Minimap.ViewportBackgroundColor">DodgerBlue</Color>
<Color x:Key="MinimapItem.BackgroundColor">#5c6a98</Color>
<!--HOT KEYS-->
<Color x:Key="HotKey.BackgroundColor">White</Color>
<Color x:Key="HotKey.ForegroundColor">Black</Color>
<Color x:Key="HotKey.BorderColor">#7EB4EA</Color>
</ResourceDictionary>

91
Nodify/Themes/Nodify.xaml Normal file
View File

@@ -0,0 +1,91 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Controls.xaml" />
</ResourceDictionary.MergedDictionaries>
<!--NODIFY EDITOR-->
<Color x:Key="NodifyEditor.BackgroundColor">#332155</Color>
<Color x:Key="NodifyEditor.ForegroundColor">#E8E1F3</Color>
<Color x:Key="NodifyEditor.SelectionRectangleColor">#FD5618</Color>
<Color x:Key="NodifyEditor.PushedAreaColor">#9b44dd</Color>
<Color x:Key="NodifyEditor.CuttingLineColor">Red</Color>
<!--ITEM CONTAINER-->
<Color x:Key="ItemContainer.BorderColor">#662D91</Color>
<Color x:Key="ItemContainer.SelectedColor">#FD5618</Color>
<!--NODE-->
<Color x:Key="Node.BackgroundColor">#662D91</Color>
<Color x:Key="Node.ContentColor">#662D91</Color>
<Color x:Key="Node.ForegroundColor">#E8E1F3</Color>
<Color x:Key="Node.HeaderForegroundColor">#E8E1F3</Color>
<Color x:Key="Node.HeaderColor">#451E63</Color>
<Color x:Key="Node.FooterColor">#451E63</Color>
<Color x:Key="Node.BorderColor">Transparent</Color>
<!--STATE NODE-->
<Color x:Key="StateNode.BackgroundColor">#451E63</Color>
<Color x:Key="StateNode.ForegroundColor">#E8E1F3</Color>
<Color x:Key="StateNode.BorderColor">#662D91</Color>
<Color x:Key="StateNode.HighlightColor">#D6D3D6</Color>
<!--GROUPING NODE-->
<Color x:Key="GroupingNode.BackgroundColor">#2C1D4A</Color>
<Color x:Key="GroupingNode.ForegroundColor">#E8E1F3</Color>
<Color x:Key="GroupingNode.HeaderColor">#451E63</Color>
<Color x:Key="GroupingNode.BorderColor">Transparent</Color>
<!--KNOT NODE-->
<Color x:Key="KnotNode.BackgroundColor">Transparent</Color>
<Color x:Key="KnotNode.ForegroundColor">#662D91</Color>
<Color x:Key="KnotNode.BorderColor">Transparent</Color>
<!--CONNECTOR-->
<Color x:Key="Connector.BackgroundColor">Transparent</Color>
<Color x:Key="Connector.ForegroundColor">#E8E1F3</Color>
<Color x:Key="Connector.BorderColor">#FD5618</Color>
<!--NODE INPUT-->
<Color x:Key="NodeInput.BackgroundColor">#662D91</Color>
<Color x:Key="NodeInput.ForegroundColor">#E8E1F3</Color>
<Color x:Key="NodeInput.BorderColor">#FD5618</Color>
<!--NODE OUTPUT-->
<Color x:Key="NodeOutput.BackgroundColor">#662D91</Color>
<Color x:Key="NodeOutput.ForegroundColor">#E8E1F3</Color>
<Color x:Key="NodeOutput.BorderColor">#FD5618</Color>
<!--CONNECTION-->
<Color x:Key="Connection.StrokeColor">#FD5618</Color>
<!--LINE CONNECTION-->
<Color x:Key="LineConnection.StrokeColor">#FD5618</Color>
<!--CIRCUIT CONNECTION-->
<Color x:Key="CircuitConnection.StrokeColor">#FD5618</Color>
<!--STEP CONNECTION-->
<Color x:Key="StepConnection.StrokeColor">#FD5618</Color>
<!--PENDING CONNECTION-->
<Color x:Key="PendingConnection.StrokeColor">#FD5618</Color>
<Color x:Key="PendingConnection.BorderColor">#451E63</Color>
<Color x:Key="PendingConnection.ForegroundColor">#E8E1F3</Color>
<Color x:Key="PendingConnection.BackgroundColor">#2A1B47</Color>
<!--MINIMAP-->
<Color x:Key="Minimap.BackgroundColor">#2A1B47</Color>
<Color x:Key="Minimap.ViewportStrokeColor">#9b44dd</Color>
<Color x:Key="Minimap.ViewportBackgroundColor">#9b44dd</Color>
<Color x:Key="MinimapItem.BackgroundColor">#FD5618</Color>
<!--HOT KEYS-->
<Color x:Key="HotKey.BackgroundColor">White</Color>
<Color x:Key="HotKey.ForegroundColor">Black</Color>
<Color x:Key="HotKey.BorderColor">#FD5618</Color>
</ResourceDictionary>

View File

@@ -0,0 +1,68 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<Style TargetType="{x:Type local:BaseConnection}">
<Style.Triggers>
<Trigger Property="local:CuttingLine.IsOverElement"
Value="True">
<Setter Property="Opacity"
Value="0.4" />
</Trigger>
<Trigger Property="IsSelectable"
Value="True">
<Setter Property="Cursor"
Value="Hand" />
</Trigger>
</Style.Triggers>
</Style>
<Style TargetType="{x:Type local:Connection}"
BasedOn="{StaticResource {x:Type local:BaseConnection}}">
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="Fill"
Value="DodgerBlue" />
<Setter Property="Spacing"
Value="20" />
</Style>
<Style TargetType="{x:Type local:LineConnection}"
BasedOn="{StaticResource {x:Type local:BaseConnection}}">
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="Fill"
Value="DodgerBlue" />
<Setter Property="Spacing"
Value="30" />
</Style>
<Style TargetType="{x:Type local:CircuitConnection}"
BasedOn="{StaticResource {x:Type local:BaseConnection}}">
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="Fill"
Value="DodgerBlue" />
<Setter Property="Spacing"
Value="30" />
</Style>
<Style TargetType="{x:Type local:StepConnection}"
BasedOn="{StaticResource {x:Type local:BaseConnection}}">
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="Fill"
Value="DodgerBlue" />
<Setter Property="Spacing"
Value="30" />
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,73 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<Style TargetType="{x:Type local:Connector}">
<Setter Property="BorderBrush"
Value="DodgerBlue" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Width"
Value="14" />
<Setter Property="Height"
Value="14" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:Connector}">
<Ellipse x:Name="Connector"
Width="{TemplateBinding Width}"
Height="{TemplateBinding Height}"
Stroke="{TemplateBinding BorderBrush}"
Fill="Transparent"
StrokeThickness="2" />
<ControlTemplate.Triggers>
<Trigger Property="IsConnected"
Value="True">
<Setter TargetName="Connector"
Property="Ellipse.Fill"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter TargetName="Connector"
Property="Ellipse.Fill"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:HotKeyControl}">
<Setter Property="BorderBrush"
Value="DodgerBlue" />
<Setter Property="Background"
Value="White" />
<Setter Property="Foreground"
Value="Black" />
<Setter Property="Width"
Value="16" />
<Setter Property="Height"
Value="16" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:HotKeyControl}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
CornerRadius="3"
BorderThickness="{TemplateBinding BorderThickness}"
Width="{TemplateBinding Width}"
Height="{TemplateBinding Height}">
<TextBlock Text="{Binding Number, RelativeSource={RelativeSource TemplatedParent}}"
VerticalAlignment="Center"
HorizontalAlignment="Center" />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,23 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<ResourceDictionary.MergedDictionaries>
<!--NODES-->
<ResourceDictionary Source="Node.xaml" />
<ResourceDictionary Source="KnotNode.xaml" />
<ResourceDictionary Source="GroupingNode.xaml" />
<ResourceDictionary Source="StateNode.xaml" />
<ResourceDictionary Source="Connector.xaml" />
<ResourceDictionary Source="NodeInput.xaml" />
<ResourceDictionary Source="NodeOutput.xaml" />
<ResourceDictionary Source="Connection.xaml" />
<ResourceDictionary Source="PendingConnection.xaml" />
<ResourceDictionary Source="CuttingLine.xaml" />
<!--CORE-->
<ResourceDictionary Source="ItemContainer.xaml" />
<ResourceDictionary Source="DecoratorContainer.xaml" />
<ResourceDictionary Source="NodifyEditor.xaml" />
<!--WIDGETS-->
<ResourceDictionary Source="Minimap.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>

View File

@@ -0,0 +1,16 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<Style TargetType="{x:Type local:CuttingLine}">
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="StrokeDashArray"
Value="2 1" />
<Setter Property="Stroke"
Value="Red" />
<Setter Property="Fill"
Value="Red" />
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,25 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<local:UnscaleTransformConverter x:Key="UnscaleTransformConverter" />
<Style TargetType="{x:Type local:DecoratorContainer}">
<Setter Property="RenderTransform"
Value="{Binding ViewportTransform, RelativeSource={RelativeSource AncestorType=local:NodifyEditor}, Converter={StaticResource UnscaleTransformConverter}}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:DecoratorContainer}">
<Border Background="{TemplateBinding Background}"
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
Padding="{TemplateBinding Padding}"
CornerRadius="3">
<ContentPresenter />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,79 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<Style TargetType="{x:Type local:GroupingNode}">
<Setter Property="Background">
<Setter.Value>
<SolidColorBrush Color="#3E3E42"
Opacity=".5" />
</Setter.Value>
</Setter>
<Setter Property="Foreground"
Value="White" />
<Setter Property="HeaderBrush"
Value="#1E1E1E" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="Padding"
Value="7 3" />
<Setter Property="VerticalAlignment"
Value="Center" />
<Setter Property="HorizontalAlignment"
Value="Center" />
<Setter Property="MinHeight"
Value="30" />
<Setter Property="MinWidth"
Value="150" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:GroupingNode}">
<Border BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
CornerRadius="3">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto"
MinHeight="30" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<Border Background="{TemplateBinding HeaderBrush}"
Cursor="SizeAll"
CornerRadius="3 3 0 0"
x:Name="PART_Header">
<ContentPresenter ContentSource="Header"
Margin="{TemplateBinding Padding}" />
</Border>
<Grid Grid.Row="1"
Background="{TemplateBinding Background}">
<ContentPresenter x:Name="PART_Content"
ContentSource="Content" />
<Thumb x:Name="PART_ResizeThumb"
HorizontalAlignment="Right"
VerticalAlignment="Bottom"
Margin="0 0 2 2"
MinHeight="20"
Cursor="SizeNWSE"
Foreground="{TemplateBinding Foreground}"
Visibility="{TemplateBinding CanResize, Converter={StaticResource BooleanToVisibilityConverter}}">
<Thumb.Template>
<ControlTemplate>
<TextBlock Text="p"
FontFamily="Marlett"
FontSize="18" />
</ControlTemplate>
</Thumb.Template>
</Thumb>
</Grid>
</Grid>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,89 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<SolidColorBrush x:Key="ItemContainer.HighlightColor"
Color="DodgerBlue" />
<DrawingBrush x:Key="ItemContainer.HighlightBrush"
Viewport="0 0 24 24"
ViewportUnits="Absolute"
TileMode="Tile">
<DrawingBrush.Drawing>
<DrawingGroup>
<GeometryDrawing Brush="{StaticResource ItemContainer.HighlightColor}">
<GeometryDrawing.Geometry>
<GeometryGroup>
<RectangleGeometry Rect="0 0 50 50" />
<RectangleGeometry Rect="50 50 50 50" />
</GeometryGroup>
</GeometryDrawing.Geometry>
</GeometryDrawing>
</DrawingGroup>
</DrawingBrush.Drawing>
</DrawingBrush>
<Style TargetType="{x:Type local:ItemContainer}">
<Setter Property="BorderThickness"
Value="1" />
<Setter Property="SelectedBorderThickness"
Value="2" />
<Setter Property="BorderBrush"
Value="DodgerBlue" />
<Setter Property="SelectedBrush"
Value="Orange" />
<Setter Property="HighlightBrush"
Value="{StaticResource ItemContainer.HighlightBrush}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:ItemContainer}">
<Border Background="{TemplateBinding Background}"
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
Padding="{TemplateBinding Padding}"
x:Name="Border"
CornerRadius="3">
<ContentPresenter />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="IsSelected"
Value="True" />
<Condition Property="IsPreviewingSelection"
Value="{x:Null}" />
</MultiTrigger.Conditions>
<MultiTrigger.Setters>
<Setter Property="BorderBrush"
Value="{Binding SelectedBrush, RelativeSource={RelativeSource Self}}" />
<Setter Property="Margin"
Value="{Binding SelectedMargin, RelativeSource={RelativeSource Self}}" />
<Setter Property="BorderThickness"
Value="{Binding SelectedBorderThickness, RelativeSource={RelativeSource Self}}" />
</MultiTrigger.Setters>
</MultiTrigger>
<Trigger Property="IsPreviewingSelection"
Value="True">
<Setter Property="BorderBrush"
Value="{Binding SelectedBrush, RelativeSource={RelativeSource Self}}" />
<Setter Property="Margin"
Value="{Binding SelectedMargin, RelativeSource={RelativeSource Self}}" />
<Setter Property="BorderThickness"
Value="{Binding SelectedBorderThickness, RelativeSource={RelativeSource Self}}" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter Property="BorderBrush"
Value="{Binding HighlightBrush, RelativeSource={RelativeSource Self}}" />
<Setter Property="Margin"
Value="{Binding SelectedMargin, RelativeSource={RelativeSource Self}}" />
<Setter Property="BorderThickness"
Value="{Binding SelectedBorderThickness, RelativeSource={RelativeSource Self}}" />
</Trigger>
</Style.Triggers>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,37 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<DataTemplate x:Key="DefaultConnectorTemplate">
<local:Connector Cursor="Arrow" />
</DataTemplate>
<Style TargetType="{x:Type local:KnotNode}">
<Setter Property="Background"
Value="Transparent" />
<Setter Property="Foreground"
Value="DodgerBlue" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="Padding"
Value="15 5" />
<Setter Property="Cursor"
Value="SizeAll" />
<Setter Property="ContentTemplate"
Value="{StaticResource DefaultConnectorTemplate}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:KnotNode}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}"
CornerRadius="3">
<ContentPresenter />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,101 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<local:SubtractConverter x:Key="SubtractConverter" />
<SolidColorBrush x:Key="MinimapBackground"
Color="#121212"
Opacity="0.7" />
<SolidColorBrush x:Key="MinimapItemBackground"
Color="DodgerBlue"
Opacity="0.8" />
<Style x:Key="ViewportRectStyle"
TargetType="Rectangle">
<Setter Property="Stroke"
Value="#74747c" />
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="Fill">
<Setter.Value>
<SolidColorBrush Color="#74747c"
Opacity="0.2" />
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:Minimap}">
<Setter Property="Padding"
Value="10" />
<Setter Property="Background"
Value="{StaticResource MinimapBackground}" />
<Setter Property="ViewportStyle"
Value="{StaticResource ViewportRectStyle}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:Minimap}">
<Border Background="{TemplateBinding Background}"
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
CornerRadius="3"
ClipToBounds="True">
<Viewbox Stretch="Uniform"
Margin="{TemplateBinding Padding}">
<Grid>
<local:MinimapPanel ViewportSize="{TemplateBinding ViewportSize}"
ViewportLocation="{TemplateBinding ViewportLocation}"
ResizeToViewport="{TemplateBinding ResizeToViewport}"
Extent="{Binding Extent, RelativeSource={RelativeSource TemplatedParent}, Mode=OneWayToSource}"
ItemsExtent="{Binding ItemsExtent, RelativeSource={RelativeSource TemplatedParent}, Mode=OneWayToSource}"
IsItemsHost="True"
x:Name="PART_ItemsHost" />
<Canvas>
<Rectangle Style="{TemplateBinding ViewportStyle}"
Width="{Binding ViewportSize.Width, RelativeSource={RelativeSource TemplatedParent}}"
Height="{Binding ViewportSize.Height, RelativeSource={RelativeSource TemplatedParent}}">
<Canvas.Top>
<MultiBinding Converter="{StaticResource SubtractConverter}">
<Binding Path="ViewportLocation.Y"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="Extent.Location.Y"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Canvas.Top>
<Canvas.Left>
<MultiBinding Converter="{StaticResource SubtractConverter}">
<Binding Path="ViewportLocation.X"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="Extent.Location.X"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Canvas.Left>
</Rectangle>
</Canvas>
</Grid>
</Viewbox>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:MinimapItem}">
<Setter Property="Background"
Value="{StaticResource MinimapItemBackground}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:MinimapItem}">
<Border Background="{TemplateBinding Background}"
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
Padding="{TemplateBinding Padding}"
CornerRadius="3">
<ContentPresenter />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,138 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<DataTemplate x:Key="DefaultInputConnectorTemplate">
<local:NodeInput />
</DataTemplate>
<DataTemplate x:Key="DefaultOutputConnectorTemplate">
<local:NodeOutput />
</DataTemplate>
<Style x:Key="DefaultHeaderContainerStyle"
TargetType="Border">
<Setter Property="CornerRadius"
Value="3 3 0 0" />
<Setter Property="Padding"
Value="6 4 6 4" />
</Style>
<Style x:Key="DefaultFooterContainerStyle"
TargetType="Border">
<Setter Property="CornerRadius"
Value="0 0 3 3" />
<Setter Property="Padding"
Value="6 4 6 4" />
</Style>
<Style TargetType="{x:Type local:Node}">
<Setter Property="Background"
Value="#2D2D30" />
<Setter Property="ContentBrush"
Value="#2D2D30" />
<Setter Property="HeaderBrush"
Value="#1E1E1E" />
<Setter Property="FooterBrush"
Value="#1E1E1E" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="BorderBrush"
Value="Transparent" />
<Setter Property="MinHeight"
Value="15" />
<Setter Property="MinWidth"
Value="15" />
<Setter Property="VerticalAlignment"
Value="Top" />
<Setter Property="HorizontalAlignment"
Value="Center" />
<Setter Property="VerticalContentAlignment"
Value="Center" />
<Setter Property="HorizontalContentAlignment"
Value="Center" />
<Setter Property="InputConnectorTemplate"
Value="{StaticResource DefaultInputConnectorTemplate}" />
<Setter Property="OutputConnectorTemplate"
Value="{StaticResource DefaultOutputConnectorTemplate}" />
<Setter Property="HeaderContainerStyle"
Value="{StaticResource DefaultHeaderContainerStyle}" />
<Setter Property="FooterContainerStyle"
Value="{StaticResource DefaultFooterContainerStyle}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:Node}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
Padding="{TemplateBinding Padding}"
CornerRadius="3">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="*" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<!--Header-->
<Border Visibility="{TemplateBinding HasHeader, Converter={StaticResource BooleanToVisibilityConverter}}"
Background="{TemplateBinding HeaderBrush}"
Style="{TemplateBinding HeaderContainerStyle}"
Grid.ColumnSpan="3">
<ContentPresenter ContentSource="Header" />
</Border>
<!--Body-->
<Border Style="{TemplateBinding ContentContainerStyle}"
Grid.Row="1">
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" />
</Grid.ColumnDefinitions>
<!--Data IN-->
<ItemsControl x:Name="PART_Input"
ItemsSource="{TemplateBinding Input}"
VerticalAlignment="{TemplateBinding VerticalAlignment}"
ItemTemplate="{TemplateBinding InputConnectorTemplate}"
Focusable="False" />
<!--Content-->
<Border Grid.Column="1"
Padding="16 0 16 0"
Background="{TemplateBinding ContentBrush}">
<ContentPresenter VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" />
</Border>
<!--Data OUT-->
<ItemsControl x:Name="PART_Output"
ItemsSource="{TemplateBinding Output}"
ItemTemplate="{TemplateBinding OutputConnectorTemplate}"
VerticalAlignment="{TemplateBinding VerticalAlignment}"
HorizontalContentAlignment="Right"
Grid.Column="2"
Focusable="False" />
</Grid>
</Border>
<!--Footer-->
<Border Visibility="{TemplateBinding HasFooter, Converter={StaticResource BooleanToVisibilityConverter}}"
Background="{TemplateBinding FooterBrush}"
Style="{TemplateBinding FooterContainerStyle}"
Grid.Row="2"
Grid.ColumnSpan="3">
<ContentPresenter ContentSource="Footer" />
</Border>
</Grid>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,118 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<ControlTemplate x:Key="ConnectorThumbTemplate"
TargetType="Control">
<Ellipse Width="14"
Height="14"
Stroke="{TemplateBinding BorderBrush}"
Fill="{TemplateBinding Background}"
StrokeThickness="2" />
</ControlTemplate>
<LinearGradientBrush x:Key="FadeOpacityMask"
StartPoint="0 0"
EndPoint="1 0">
<GradientStop Color="#22FFFFFF"
Offset="0" />
<GradientStop Color="#88FFFFFF"
Offset="0.3" />
<GradientStop Color="#88FFFFFF"
Offset="0.7" />
<GradientStop Color="#22FFFFFF"
Offset="1" />
</LinearGradientBrush>
<LinearGradientBrush x:Key="FadeOpacityMaskVertical"
StartPoint="0 0"
EndPoint="0 1">
<GradientStop Color="#22FFFFFF"
Offset="0" />
<GradientStop Color="#88FFFFFF"
Offset="0.3" />
<GradientStop Color="#88FFFFFF"
Offset="0.7" />
<GradientStop Color="#22FFFFFF"
Offset="1" />
</LinearGradientBrush>
<Style TargetType="{x:Type local:NodeInput}">
<Setter Property="BorderBrush"
Value="DodgerBlue" />
<Setter Property="Background"
Value="#2D2D30" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="Padding"
Value="4 2" />
<Setter Property="ConnectorTemplate"
Value="{StaticResource ConnectorThumbTemplate}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:NodeInput}">
<Grid Background="{TemplateBinding Background}">
<Border Visibility="Collapsed"
x:Name="Highlight"
OpacityMask="{StaticResource FadeOpacityMask}"
Background="{TemplateBinding BorderBrush}" />
<StackPanel Orientation="{TemplateBinding Orientation}"
Margin="{TemplateBinding Padding}">
<Control x:Name="PART_Connector"
Focusable="False"
Margin="0 0 5 0"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Background="Transparent"
BorderBrush="{TemplateBinding BorderBrush}"
Template="{TemplateBinding ConnectorTemplate}" />
<ContentPresenter ContentSource="Header" />
</StackPanel>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="Orientation"
Value="Vertical">
<Setter TargetName="PART_Connector"
Property="Margin"
Value="0 0 0 5" />
<Setter Property="Padding"
Value="2 4" />
<Setter TargetName="Highlight"
Property="OpacityMask"
Value="{StaticResource FadeOpacityMaskVertical}" />
</Trigger>
<Trigger Property="IsConnected"
Value="True">
<Setter TargetName="PART_Connector"
Property="Background"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter TargetName="PART_Connector"
Property="Background"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Highlight"
Property="Visibility"
Value="Visible" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter TargetName="Highlight"
Property="Visibility"
Value="Visible" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,118 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<ControlTemplate x:Key="ConnectorThumbTemplate"
TargetType="Control">
<Ellipse Width="14"
Height="14"
Stroke="{TemplateBinding BorderBrush}"
Fill="{TemplateBinding Background}"
StrokeThickness="2" />
</ControlTemplate>
<LinearGradientBrush x:Key="FadeOpacityMask"
StartPoint="0 0"
EndPoint="1 0">
<GradientStop Color="#22FFFFFF"
Offset="0" />
<GradientStop Color="#88FFFFFF"
Offset="0.3" />
<GradientStop Color="#88FFFFFF"
Offset="0.7" />
<GradientStop Color="#22FFFFFF"
Offset="1" />
</LinearGradientBrush>
<LinearGradientBrush x:Key="FadeOpacityMaskVertical"
StartPoint="0 0"
EndPoint="0 1">
<GradientStop Color="#22FFFFFF"
Offset="0" />
<GradientStop Color="#88FFFFFF"
Offset="0.3" />
<GradientStop Color="#88FFFFFF"
Offset="0.7" />
<GradientStop Color="#22FFFFFF"
Offset="1" />
</LinearGradientBrush>
<Style TargetType="{x:Type local:NodeOutput}">
<Setter Property="BorderBrush"
Value="DodgerBlue" />
<Setter Property="Background"
Value="#2D2D30" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="Padding"
Value="4 2" />
<Setter Property="ConnectorTemplate"
Value="{StaticResource ConnectorThumbTemplate}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:NodeOutput}">
<Grid Background="{TemplateBinding Background}">
<Border Visibility="Collapsed"
x:Name="Highlight"
OpacityMask="{StaticResource FadeOpacityMask}"
Background="{TemplateBinding BorderBrush}" />
<StackPanel Orientation="{TemplateBinding Orientation}"
HorizontalAlignment="Right"
Margin="{TemplateBinding Padding}">
<ContentPresenter ContentSource="Header" />
<Control x:Name="PART_Connector"
Focusable="False"
Margin="5 0 0 0"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Background="Transparent"
BorderBrush="{TemplateBinding BorderBrush}"
Template="{TemplateBinding ConnectorTemplate}" />
</StackPanel>
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="Orientation"
Value="Vertical">
<Setter TargetName="PART_Connector"
Property="Margin"
Value="0 5 0 0" />
<Setter Property="Padding"
Value="2 4" />
<Setter TargetName="Highlight"
Property="OpacityMask"
Value="{StaticResource FadeOpacityMaskVertical}" />
</Trigger>
<Trigger Property="IsConnected"
Value="True">
<Setter TargetName="PART_Connector"
Property="Background"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter TargetName="PART_Connector"
Property="Background"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
<Trigger Property="IsMouseOver"
Value="True">
<Setter TargetName="Highlight"
Property="Visibility"
Value="Visible" />
</Trigger>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter TargetName="Highlight"
Property="Visibility"
Value="Visible" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,212 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<local:UnscaleTransformConverter x:Key="UnscaleTransformConverter" />
<local:ScaleDoubleConverter x:Key="ScaleDoubleConverter" />
<local:ScalePointConverter x:Key="ScalePointConverter" />
<DataTemplate x:Key="ConnectionTemplate">
<local:Connection Style="{DynamicResource {x:Type local:Connection}}" />
</DataTemplate>
<DataTemplate x:Key="PendingConnectionTemplate">
<local:PendingConnection IsTabStop="False"
IsHitTestVisible="False" />
</DataTemplate>
<Style x:Key="SelectionRectangleStyle"
TargetType="Rectangle">
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="StrokeThickness"
Value="1" />
<Setter Property="Fill">
<Setter.Value>
<SolidColorBrush Opacity="0.1"
Color="DodgerBlue" />
</Setter.Value>
</Setter>
</Style>
<Style x:Key="PushedAreaStyle"
TargetType="Rectangle">
<Setter Property="Stroke"
Value="#74747c" />
<Setter Property="StrokeThickness"
Value="1" />
<Setter Property="Fill">
<Setter.Value>
<SolidColorBrush Opacity="0.2"
Color="#74747c" />
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type local:NodifyEditor}">
<Setter Property="Foreground"
Value="White" />
<Setter Property="Background"
Value="#1E1E1E" />
<Setter Property="EnableRealtimeSelection"
Value="True" />
<Setter Property="DisplayConnectionsOnTop"
Value="False" />
<Setter Property="SelectionRectangleStyle"
Value="{StaticResource SelectionRectangleStyle}" />
<Setter Property="PushedAreaStyle"
Value="{StaticResource PushedAreaStyle}" />
<Setter Property="ConnectionTemplate"
Value="{StaticResource ConnectionTemplate}" />
<Setter Property="PendingConnectionTemplate"
Value="{StaticResource PendingConnectionTemplate}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:NodifyEditor}">
<Border Background="{TemplateBinding Background}"
BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
ClipToBounds="True">
<Canvas RenderTransform="{TemplateBinding ViewportTransform}">
<local:NodifyCanvas x:Name="PART_ItemsHost"
IsItemsHost="True"
Extent="{Binding ItemsExtent, Mode=OneWayToSource, RelativeSource={RelativeSource TemplatedParent}}" />
<local:ConnectionsMultiSelector x:Name="PART_ConnectionsHost"
ItemsSource="{TemplateBinding Connections}"
SelectedItem="{Binding SelectedConnection, RelativeSource={RelativeSource TemplatedParent}}"
SelectedItems="{TemplateBinding SelectedConnections}"
CanSelectMultipleItems="{TemplateBinding CanSelectMultipleConnections}"
ItemTemplate="{TemplateBinding ConnectionTemplate}"
IsTabStop="False">
<local:ConnectionsMultiSelector.Style>
<Style TargetType="local:ConnectionsMultiSelector">
<Setter Property="Panel.ZIndex"
Value="-1" />
<Style.Triggers>
<DataTrigger Binding="{Binding DisplayConnectionsOnTop, RelativeSource={RelativeSource TemplatedParent}}"
Value="True">
<Setter Property="Panel.ZIndex"
Value="0" />
</DataTrigger>
</Style.Triggers>
</Style>
</local:ConnectionsMultiSelector.Style>
<local:ConnectionsMultiSelector.ItemsPanel>
<ItemsPanelTemplate>
<Canvas />
</ItemsPanelTemplate>
</local:ConnectionsMultiSelector.ItemsPanel>
</local:ConnectionsMultiSelector>
<ContentPresenter ContentSource="PendingConnection" />
<Rectangle Style="{TemplateBinding SelectionRectangleStyle}"
RenderTransform="{Binding ViewportTransform, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource UnscaleTransformConverter}}"
Canvas.Top="{Binding SelectedArea.Y, RelativeSource={RelativeSource TemplatedParent}}"
Canvas.Left="{Binding SelectedArea.X, RelativeSource={RelativeSource TemplatedParent}}"
Visibility="{TemplateBinding IsSelecting, Converter={StaticResource BooleanToVisibilityConverter}}">
<Rectangle.Width>
<MultiBinding Converter="{StaticResource ScaleDoubleConverter}">
<Binding Path="SelectedArea.Width"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Rectangle.Width>
<Rectangle.Height>
<MultiBinding Converter="{StaticResource ScaleDoubleConverter}">
<Binding Path="SelectedArea.Height"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Rectangle.Height>
</Rectangle>
<Rectangle Style="{TemplateBinding PushedAreaStyle}"
RenderTransform="{Binding ViewportTransform, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource UnscaleTransformConverter}}"
Canvas.Top="{Binding PushedArea.Y, RelativeSource={RelativeSource TemplatedParent}}"
Canvas.Left="{Binding PushedArea.X, RelativeSource={RelativeSource TemplatedParent}}"
Visibility="{TemplateBinding IsPushingItems, Converter={StaticResource BooleanToVisibilityConverter}}">
<Rectangle.Width>
<MultiBinding Converter="{StaticResource ScaleDoubleConverter}">
<Binding Path="PushedArea.Width"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Rectangle.Width>
<Rectangle.Height>
<MultiBinding Converter="{StaticResource ScaleDoubleConverter}">
<Binding Path="PushedArea.Height"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</Rectangle.Height>
</Rectangle>
<local:CuttingLine Style="{TemplateBinding CuttingLineStyle}"
Visibility="{TemplateBinding IsCutting, Converter={StaticResource BooleanToVisibilityConverter}}"
RenderTransform="{Binding ViewportTransform, RelativeSource={RelativeSource TemplatedParent}, Converter={StaticResource UnscaleTransformConverter}}">
<local:CuttingLine.StartPoint>
<MultiBinding Converter="{StaticResource ScalePointConverter}">
<Binding Path="CuttingLineStart"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</local:CuttingLine.StartPoint>
<local:CuttingLine.EndPoint>
<MultiBinding Converter="{StaticResource ScalePointConverter}">
<Binding Path="CuttingLineEnd"
RelativeSource="{RelativeSource TemplatedParent}" />
<Binding Path="ViewportZoom"
RelativeSource="{RelativeSource TemplatedParent}" />
</MultiBinding>
</local:CuttingLine.EndPoint>
</local:CuttingLine>
<local:DecoratorsControl ItemsSource="{TemplateBinding Decorators}"
ItemContainerStyle="{TemplateBinding DecoratorContainerStyle}"
ItemTemplate="{TemplateBinding DecoratorTemplate}"
IsTabStop="False">
<local:DecoratorsControl.ItemsPanel>
<ItemsPanelTemplate>
<local:NodifyCanvas Extent="{Binding DecoratorsExtent, Mode=OneWayToSource, RelativeSource={RelativeSource AncestorType=local:NodifyEditor}}" />
</ItemsPanelTemplate>
</local:DecoratorsControl.ItemsPanel>
</local:DecoratorsControl>
</Canvas>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="IsPushingItems"
Value="True" />
<Condition Property="PushedAreaOrientation"
Value="Horizontal" />
</MultiTrigger.Conditions>
<Setter Property="Cursor"
Value="SizeWE" />
</MultiTrigger>
<MultiTrigger>
<MultiTrigger.Conditions>
<Condition Property="IsPushingItems"
Value="True" />
<Condition Property="PushedAreaOrientation"
Value="Vertical" />
</MultiTrigger.Conditions>
<Setter Property="Cursor"
Value="SizeNS" />
</MultiTrigger>
</Style.Triggers>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,61 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<Style TargetType="{x:Type local:PendingConnection}">
<Setter Property="Background"
Value="#121212" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="Stroke"
Value="DodgerBlue" />
<Setter Property="BorderBrush"
Value="Black" />
<Setter Property="EnablePreview"
Value="False" />
<Setter Property="StrokeThickness"
Value="3" />
<Setter Property="BorderThickness"
Value="1" />
<Setter Property="Visibility"
Value="Hidden" />
<Setter Property="StrokeDashArray"
Value="4 4" />
<Setter Property="Padding"
Value="5" />
<Setter Property="EnableSnapping"
Value="True" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:PendingConnection}">
<Canvas>
<local:LineConnection Source="{TemplateBinding SourceAnchor}"
Target="{TemplateBinding TargetAnchor}"
Stroke="{TemplateBinding Stroke}"
StrokeThickness="{TemplateBinding StrokeThickness}"
StrokeDashArray="{TemplateBinding StrokeDashArray}"
Direction="{TemplateBinding Direction}"
Spacing="0"
ArrowSize="0 0"
SourceOffsetMode="None"
TargetOffsetMode="None" />
<Border Background="{TemplateBinding Background}"
Canvas.Left="{Binding TargetAnchor.X, RelativeSource={RelativeSource TemplatedParent}}"
Canvas.Top="{Binding TargetAnchor.Y, RelativeSource={RelativeSource TemplatedParent}}"
Visibility="{TemplateBinding EnablePreview, Converter={StaticResource BooleanToVisibilityConverter}}"
Padding="{TemplateBinding Padding}"
BorderThickness="{TemplateBinding BorderThickness}"
BorderBrush="{TemplateBinding BorderBrush}"
CornerRadius="3"
Margin="15">
<ContentPresenter />
</Border>
</Canvas>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>

View File

@@ -0,0 +1,63 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Nodify">
<Style TargetType="{x:Type local:StateNode}">
<Setter Property="Padding"
Value="7 5" />
<Setter Property="BorderThickness"
Value="10" />
<Setter Property="BorderBrush"
Value="#484848" />
<Setter Property="Background"
Value="#171717" />
<Setter Property="Foreground"
Value="White" />
<Setter Property="HighlightBrush"
Value="#D6D3D6" />
<Setter Property="CornerRadius"
Value="3" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type local:StateNode}">
<Border x:Name="Border"
Padding="{TemplateBinding BorderThickness}"
Margin="{TemplateBinding Margin}"
CornerRadius="{TemplateBinding CornerRadius}">
<Border x:Name="PART_Content"
Background="{TemplateBinding Background}"
Padding="{TemplateBinding Padding}"
Cursor="SizeAll"
MinWidth="30"
MinHeight="30"
CornerRadius="{TemplateBinding CornerRadius}">
<ContentPresenter />
</Border>
<Border.Style>
<Style TargetType="Border">
<Setter Property="Background"
Value="{Binding BorderBrush, RelativeSource={RelativeSource TemplatedParent}}" />
<Style.Triggers>
<Trigger Property="IsMouseDirectlyOver"
Value="True">
<Setter Property="Background"
Value="{Binding HighlightBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
</Style.Triggers>
</Style>
</Border.Style>
</Border>
<ControlTemplate.Triggers>
<Trigger Property="local:PendingConnection.IsOverElement"
Value="True">
<Setter Property="Background"
TargetName="Border"
Value="{Binding HighlightBrush, RelativeSource={RelativeSource TemplatedParent}}" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>