2025-08-20 12:10:35 +08:00
|
|
|
<ui:NeoWindow
|
2025-04-24 20:56:44 +08:00
|
|
|
x:Class="ShrlAlgoToolkit.RevitAddins.RvMEP.AnyConnectView"
|
2024-09-22 11:05:41 +08:00
|
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
2025-10-10 11:19:58 +08:00
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
2024-09-22 11:05:41 +08:00
|
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
2025-04-24 20:56:44 +08:00
|
|
|
xmlns:local="clr-namespace:ShrlAlgoToolkit.RevitAddins.RvMEP"
|
2024-09-22 11:05:41 +08:00
|
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
|
|
|
xmlns:system="clr-namespace:System;assembly=mscorlib"
|
2025-08-20 12:10:35 +08:00
|
|
|
xmlns:ui="https://github.com/ShrlAlgo/NeoUI"
|
2025-10-10 11:19:58 +08:00
|
|
|
Title="任意连接"
|
|
|
|
|
Width="270"
|
|
|
|
|
Height="350"
|
|
|
|
|
MinHeight="350"
|
|
|
|
|
d:DataContext="{d:DesignInstance Type=local:AnyConnectViewModel}"
|
|
|
|
|
Icon="{DynamicResource RevitIcon}"
|
|
|
|
|
SizeToContent="Height"
|
|
|
|
|
mc:Ignorable="d">
|
2024-09-22 11:05:41 +08:00
|
|
|
<Window.Resources>
|
2025-04-24 20:56:10 +08:00
|
|
|
<ResourceDictionary Source="pack://application:,,,/ShrlAlgoToolkit.RevitAddins;component/WPFUI.xaml" />
|
2024-09-22 11:05:41 +08:00
|
|
|
</Window.Resources>
|
2025-04-24 20:56:10 +08:00
|
|
|
<ui:StackPanel Margin="5" Spacing="5">
|
2025-08-20 12:10:35 +08:00
|
|
|
<!--<ui:InfoBar
|
2024-09-22 11:05:41 +08:00
|
|
|
IsOpen="{Binding ActiveSnackbar, Mode=OneWay}"
|
2025-04-24 20:56:44 +08:00
|
|
|
Message="{Binding Message}"
|
2025-08-20 12:10:35 +08:00
|
|
|
VerticalAlignment="Top" />-->
|
2024-09-22 11:05:41 +08:00
|
|
|
<GroupBox Header="角度" ToolTip="平行或垂直连接时生效">
|
|
|
|
|
<UniformGrid Columns="3">
|
|
|
|
|
<RadioButton Content="默认" ToolTip="根据当前位置自动连接">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>0</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="15°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>15</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="22.5°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>22.5</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="30°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>30</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="45°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>45</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="60°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>60</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
|
|
|
|
<RadioButton Content="90°">
|
|
|
|
|
<RadioButton.IsChecked>
|
|
|
|
|
<Binding Converter="{StaticResource ComparisonConverter}" Path="Angle">
|
|
|
|
|
<Binding.ConverterParameter>
|
|
|
|
|
<system:Double>90</system:Double>
|
|
|
|
|
</Binding.ConverterParameter>
|
|
|
|
|
</Binding>
|
|
|
|
|
</RadioButton.IsChecked>
|
|
|
|
|
</RadioButton>
|
2025-10-10 11:19:58 +08:00
|
|
|
<RadioButton x:Name="LbCustom" Content="自定义" />
|
2024-09-22 11:05:41 +08:00
|
|
|
<TextBox
|
2025-10-10 11:19:58 +08:00
|
|
|
VerticalAlignment="Center"
|
2024-09-22 11:05:41 +08:00
|
|
|
IsEnabled="{Binding IsChecked, ElementName=LbCustom}"
|
2025-10-10 11:19:58 +08:00
|
|
|
Text="{Binding Angle, UpdateSourceTrigger=PropertyChanged}" />
|
2024-09-22 11:05:41 +08:00
|
|
|
</UniformGrid>
|
|
|
|
|
</GroupBox>
|
|
|
|
|
<GroupBox Header="选择方式">
|
|
|
|
|
<UniformGrid Rows="1">
|
|
|
|
|
<RadioButton
|
|
|
|
|
Content="多选"
|
|
|
|
|
IsChecked="{Binding IsMultiSelect}"
|
|
|
|
|
ToolTip="选择后完成" />
|
|
|
|
|
<RadioButton
|
|
|
|
|
Content="框选"
|
|
|
|
|
IsChecked="{Binding IsMultiSelect, Converter={StaticResource InvertBooleanConverter}}"
|
|
|
|
|
ToolTip="矩形框框选" />
|
|
|
|
|
</UniformGrid>
|
|
|
|
|
</GroupBox>
|
2025-08-20 12:10:35 +08:00
|
|
|
<Button
|
2025-04-24 20:56:44 +08:00
|
|
|
HorizontalAlignment="Stretch"
|
2025-12-23 21:35:54 +08:00
|
|
|
ui:ControlAssist.Icon="{ui:Icon SymbolValue=PlugConnect}"
|
2025-10-10 11:19:58 +08:00
|
|
|
Command="{Binding ConnectCommand}"
|
|
|
|
|
Content="连接管线" />
|
2025-04-24 20:56:10 +08:00
|
|
|
</ui:StackPanel>
|
2025-08-20 12:10:35 +08:00
|
|
|
</ui:NeoWindow>
|