Commit 47f3e79a authored by 潘栩锋's avatar 潘栩锋 🚴

添加 扫描测厚仪客户端开机加载 culture.json 选择语言

parent 30da64bf
......@@ -2,6 +2,6 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<SolidColorBrush x:Key="IconBackground" Color="#e89b7f"/>
<SolidColorBrush x:Key="IconForeground" Color="#5a2e1d"/>
<SolidColorBrush x:Key="IconForeground2" Color="Black"/>
</ResourceDictionary>
\ No newline at end of file
......@@ -4,7 +4,7 @@
xml:space="preserve">
<!--字符串换行 必须添加 xml:space="preserve" -->
<!--字符串换行 换行符 &#10; -->
<system:String x:Key="str.IBC.DynArea.IBC">IBC</system:String>
<system:String x:Key="str.IBC.DynArea.FilmWidth">折径</system:String>
<system:String x:Key="str.IBC.DynArea.InletAirFreq">进风</system:String>
<system:String x:Key="str.IBC.DynArea.OutletAirFreq">出风</system:String>
......
......@@ -4,7 +4,7 @@
xml:space="preserve">
<!--字符串换行 必须添加 xml:space="preserve" -->
<!--字符串换行 换行符 &#10; -->
<system:String x:Key="str.IBC.DynArea.IBC">IBC</system:String>
<system:String x:Key="str.IBC.DynArea.FilmWidth">Width</system:String>
<system:String x:Key="str.IBC.DynArea.InletAirFreq">I.Air</system:String>
<system:String x:Key="str.IBC.DynArea.OutletAirFreq">O.Air</system:String>
......
......@@ -6,34 +6,34 @@
<!--字符串换行 换行符 &#10; -->
<!--MainPanel.xaml-->
<system:String x:Key="str.IBC.MainPanel.Show">显示</system:String>
<system:String x:Key="str.IBC.MainPanel.Setting">设置</system:String>
<system:String x:Key="str.IBC.MainPanel.InletAir">进风</system:String>
<system:String x:Key="str.IBC.MainPanel.AirBlower">风机</system:String>
<system:String x:Key="str.IBC.MainPanel.OutletAir">出风</system:String>
<system:String x:Key="str.IBC.MainPanel.ExAir">外风</system:String>
<system:String x:Key="str.IBC.MainPanel.Off">停止</system:String>
<system:String x:Key="str.IBC.MainPanel.On">运行</system:String>
<system:String x:Key="str.IBC.MainPanel.FilmWidthShow">折径显示</system:String>
<system:String x:Key="str.IBC.MainPanel.FilmWidthSetting">折径设置</system:String>
<system:String x:Key="str.IBC.MainPanel.ErrorCorrection">误差校正</system:String>
<system:String x:Key="str.IBC.MainPanel.Auto">自动</system:String>
<system:String x:Key="str.IBC.MainPanel.Manual">手动</system:String>
<system:String x:Key="str.IBC.MainPanel.K123">膜泡校正</system:String>
<system:String x:Key="str.IBC.MainPanel.Show">Current</system:String>
<system:String x:Key="str.IBC.MainPanel.Setting">Set</system:String>
<system:String x:Key="str.IBC.MainPanel.InletAir">Inlet</system:String>
<system:String x:Key="str.IBC.MainPanel.AirBlower">Air</system:String>
<system:String x:Key="str.IBC.MainPanel.OutletAir">Outlet</system:String>
<system:String x:Key="str.IBC.MainPanel.ExAir">Ext.</system:String>
<system:String x:Key="str.IBC.MainPanel.Off">Off</system:String>
<system:String x:Key="str.IBC.MainPanel.On">On</system:String>
<system:String x:Key="str.IBC.MainPanel.FilmWidthShow">FilmWidth</system:String>
<system:String x:Key="str.IBC.MainPanel.FilmWidthSetting">Setting</system:String>
<system:String x:Key="str.IBC.MainPanel.ErrorCorrection">Correction</system:String>
<system:String x:Key="str.IBC.MainPanel.Auto">Auto</system:String>
<system:String x:Key="str.IBC.MainPanel.Manual">Manual</system:String>
<system:String x:Key="str.IBC.MainPanel.K123">Set K</system:String>
<system:String x:Key="str.IBC.MainPanel.IBC">IBC</system:String>
<!--IbcCtrlGraph.xaml-->
<system:String x:Key="str.IBC.IbcCtrlGraph.IbcProcess">IBC控制过程</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.Database">数据表</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.YTitle">进风-出风 (Hz)</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.Y2Title">折径显示 (mm)</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.FilmWidthAxisYTarget">折径设置值</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.IbcProcess">IBC Process</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.Database">Database</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.YTitle">Δ=Inlet-Outlet (Hz)</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.Y2Title">Width (mm)</system:String>
<system:String x:Key="str.IBC.IbcCtrlGraph.FilmWidthAxisYTarget">Setting</system:String>
<!--WdGraphSet.xaml-->
<system:String x:Key="str.IBC.WdGraphSet.IsLoading">更新中</system:String>
<system:String x:Key="str.IBC.WdGraphSet.Interval">间隔</system:String>
<system:String x:Key="str.IBC.WdGraphSet.AxisYRangeAuto">自动Y轴</system:String>
<system:String x:Key="str.IBC.WdGraphSet.FilmWidthAxisYRange">折径Y轴范围</system:String>
<system:String x:Key="str.IBC.WdGraphSet.DAxisYRange">差值Y轴范围</system:String>
<system:String x:Key="str.IBC.WdGraphSet.DAxisYTarget">差值Y轴中值</system:String>
<system:String x:Key="str.IBC.WdGraphSet.IsLoading">Loading</system:String>
<system:String x:Key="str.IBC.WdGraphSet.Interval">Interval</system:String>
<system:String x:Key="str.IBC.WdGraphSet.AxisYRangeAuto">Auto Y-Axis</system:String>
<system:String x:Key="str.IBC.WdGraphSet.FilmWidthAxisYRange">Width Y-Axis Range</system:String>
<system:String x:Key="str.IBC.WdGraphSet.DAxisYRange">Δ Y-Axis Range</system:String>
<system:String x:Key="str.IBC.WdGraphSet.DAxisYTarget">Δ Y-Axis Mid</system:String>
</ResourceDictionary>
\ No newline at end of file
......@@ -148,8 +148,8 @@
<StackPanel Orientation="Horizontal" Grid.Column="2" Background="{StaticResource Color_badgeBg}">
<StackPanel Orientation="Horizontal" Margin="7,3">
<TextBlock Text="出风" FontSize="{StaticResource FontSize_text_large}" Foreground="{StaticResource Color_badgeText}"/>
<TextBlock Text="风机" FontSize="{StaticResource FontSize_text_small}" Foreground="{StaticResource Color_badgeText}"/>
<TextBlock Text="{StaticResource str.IBC.MainPanel.OutletAir}" FontSize="{StaticResource FontSize_text_large}" Foreground="{StaticResource Color_badgeText}"/>
<TextBlock Text="{StaticResource str.IBC.MainPanel.AirBlower}" FontSize="{StaticResource FontSize_text_small}" Foreground="{StaticResource Color_badgeText}"/>
</StackPanel>
</StackPanel>
<TextBlock Grid.Row="1" Grid.Column="0" Margin="3,0"
......@@ -379,7 +379,7 @@
<TextBlock Text="{StaticResource str.IBC.MainPanel.K123}" Foreground="White" FontWeight="Bold" VerticalAlignment="Bottom" HorizontalAlignment="Center" Background="{StaticResource Color_theme_plus}" Margin="0,0,0,-10" FontSize="12" Padding="4,2"/>
</Grid>
</Button>
<flyctrl:ToggleButtonOnOff
<flyctrl:ToggleButtonOnOff Width="110"
OnLabel="{StaticResource str.IBC.MainPanel.Auto}" OnBrush="{StaticResource Color_on}"
OffLabel="{StaticResource str.IBC.MainPanel.Manual}" OffBrush="{StaticResource Color_off}"
Grid.Column="1" HorizontalAlignment="Right" Margin="{StaticResource ControlMargin}" VerticalAlignment="Top"
......
......@@ -12,7 +12,7 @@
<!--项目Style-->
<ResourceDictionary Source="pack://application:,,,/FLY.ControlLibrary;component/Themes/Styles.xaml"/>
<ResourceDictionary Source="pack://application:,,,/FLY.Thick.BlowingScan.UI.Client;component/Themes/StringResources/en/StringResource.xaml"/>
<ResourceDictionary Source="pack://application:,,,/FLY.Thick.BlowingScan.UI.Client;component/Themes/StringResources/StringResource.xaml"/>
</ResourceDictionary.MergedDictionaries>
<Style TargetType="GroupBox" />
......
using System;
using FLY.Thick.Base.UI;
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Threading.Tasks;
using System.Windows;
using Unity;
namespace FLY.Thick.BlowingScan.UI.Client
{
......@@ -28,23 +30,39 @@ namespace FLY.Thick.BlowingScan.UI.Client
MessageBox.Show("程序出现异常,请把下面信息拍照发给厂家" + Environment.NewLine + err,
"异常,联系厂家",
MessageBoxButton.OK, MessageBoxImage.Error);
};
this.Startup += (s, e) =>
{
var v = new Misc.Ver() { SrcType = typeof(App) };
this.Startup += App_Startup;
}
private void App_Startup(object sender, StartupEventArgs e)
{
//这一段,必须放在 Startup 执行。
//因为下面会加载页面,会调用 App.Resources 里面的 资源。
//当创建 App() , 在 注入 App.Resources 之前发生
Culture culture = new Culture();
if (!culture.Load())
culture.Save();
culture.LoadCulture(typeof(App));
var v = new Misc.Ver() { SrcType = typeof(App) };
this.MainWindow = new MultiLayout.MainWindow();
this.MainWindow.Title = $"中国塑控 China Plastic Control {v.V}-{v.BuildTime}";
this.MainWindow.Loaded += (_s, _e) =>
this.MainWindow = new MultiLayout.MainWindow();
this.MainWindow.Title = $"中国塑控 China Plastic Control {v.V}-{v.BuildTime}";
//container在MultiLayout.MainWindow内创建
var container = (IUnityContainer)Application.Current.Properties["container"];
container.RegisterInstance(culture);
this.MainWindow.Loaded += (_s, _e) =>
{
//启动Poll系统
FObjBase.PollModule.Current.Start();
};
this.MainWindow.Show();
};
}
}
}
}
......@@ -12,7 +12,21 @@
<system:String x:Key="str.H.IBC">IBC</system:String>
<system:String x:Key="str.H.Winder">收卷</system:String>
<system:String x:Key="str.H.Center">中心</system:String>
<system:String x:Key="str.H.Temp">温控</system:String>
<system:String x:Key="str.H.Manual">手动</system:String>
<system:String x:Key="str.H.Temp">温区</system:String>
<system:String x:Key="str.H.Weigh">称重</system:String>
<system:String x:Key="str.H.Suction">吸料</system:String>
<system:String x:Key="str.H.扫描">扫描</system:String>
<system:String x:Key="str.H.风环">风环</system:String>
<system:String x:Key="str.H.定点">定点</system:String>
<system:String x:Key="str.H.环型">环型</system:String>
<system:String x:Key="str.H.趋势">趋势</system:String>
<system:String x:Key="str.H.趋势2">趋势2</system:String>
<system:String x:Key="str.H.收卷">收卷</system:String>
<system:String x:Key="str.H.中心">中心</system:String>
<system:String x:Key="str.H.手动">手动</system:String>
<system:String x:Key="str.H.温区">温区</system:String>
<system:String x:Key="str.H.称重">称重</system:String>
<system:String x:Key="str.H.吸料">吸料</system:String>
</ResourceDictionary>
\ No newline at end of file
......@@ -12,7 +12,21 @@
<system:String x:Key="str.H.IBC">IBC</system:String>
<system:String x:Key="str.H.Winder">Winder</system:String>
<system:String x:Key="str.H.Center">Center</system:String>
<system:String x:Key="str.H.Manual">Manual</system:String>
<system:String x:Key="str.H.Temp">Temp</system:String>
<system:String x:Key="str.H.Weigh">Weigh</system:String>
<system:String x:Key="str.H.Suction">Suction</system:String>
<system:String x:Key="str.H.扫描">Scan</system:String>
<system:String x:Key="str.H.风环">AirRing</system:String>
<system:String x:Key="str.H.定点">Fix</system:String>
<system:String x:Key="str.H.环型">Radar</system:String>
<system:String x:Key="str.H.趋势">Trend</system:String>
<system:String x:Key="str.H.趋势2">Trend2</system:String>
<system:String x:Key="str.H.收卷">Winder</system:String>
<system:String x:Key="str.H.中心">Center</system:String>
<system:String x:Key="str.H.手动">Manual</system:String>
<system:String x:Key="str.H.温区">Temp</system:String>
<system:String x:Key="str.H.称重">Weigh</system:String>
<system:String x:Key="str.H.吸料">Suction</system:String>
</ResourceDictionary>
\ No newline at end of file
......@@ -36,9 +36,9 @@
<!--UcThicknessV4.xaml-->
<system:String x:Key="str.Weight.MainGraph.CurrentThickness">Current Thickness</system:String>
<system:String x:Key="str.Weight.MainGraph.CurrentVelocity">Current Speed</system:String>
<system:String x:Key="str.Weight.MainGraph.TargetVelocity">Target Velocity</system:String>
<system:String x:Key="str.Weight.MainGraph.CurrentThickness">Current THK</system:String>
<system:String x:Key="str.Weight.MainGraph.CurrentVelocity">Current V.</system:String>
<system:String x:Key="str.Weight.MainGraph.TargetVelocity">Target V.</system:String>
<system:String x:Key="str.Weight.MainGraph.TotalFlowSetting">Total Flow</system:String>
<system:String x:Key="str.Weight.MainGraph.ActFilmWidth">Winding Width</system:String>
<!--UcWeighterItemV0.xaml-->
......@@ -86,14 +86,14 @@
<!--WdThickness.xaml-->
<system:String x:Key="str.Weight.MainGraph.TotalFilmWidth">Total Width</system:String>
<system:String x:Key="str.Weight.MainGraph.RimWidth">Trimming Width</system:String>
<system:String x:Key="str.Weight.MainGraph.RimWidth">Trim Width</system:String>
<system:String x:Key="str.Weight.MainGraph.SetThickness">Target THK</system:String>
<system:String x:Key="str.Weight.MainGraph.IsRimNoRecycle">Trimming No Recy.</system:String>
<system:String x:Key="str.Weight.MainGraph.IsRimNoRecycle">Trim No Recy.</system:String>
<system:String x:Key="str.Weight.MainGraph.Error">Error</system:String>
<system:String x:Key="str.Weight.MainGraph.SetThicknessMustGreaterThan10">Target THK &gt; 10um</system:String>
<system:String x:Key="str.Weight.MainGraph.TotalFilmWidthMustGreaterThan300">Total Width &gt; 300um</system:String>
<system:String x:Key="str.Weight.MainGraph.RimWidthMustGreaterThan">Trimming Width *2 &gt; Total Width</system:String>
<system:String x:Key="str.Weight.MainGraph.RimWidthMustGreaterThan">Trim Width *2 &gt; Total Width</system:String>
<!--WdThicknessV4.xaml-->
<system:String x:Key="str.Weight.MainGraph.Density">Density</system:String>
......
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="Color.Dark.xaml"/>
<ResourceDictionary Source="Color.Light.xaml"/>
</ResourceDictionary.MergedDictionaries>
......
......@@ -3,7 +3,7 @@
xmlns:system="clr-namespace:System;assembly=mscorlib">
<!--字符串换行 必须添加 xml:space="preserve" -->
<!--字符串换行 换行符 &#10; -->
<!--PgLoading.xaml-->
<system:String x:Key="str.Winder.DynArea.Winder">收卷</system:String>
<system:String x:Key="str.Winder.DynArea.Speed">速度</system:String>
<system:String x:Key="str.Winder.DynArea.InsideWinder">内收卷</system:String>
<system:String x:Key="str.Winder.DynArea.OutsideWinder">外收卷</system:String>
......
......@@ -3,7 +3,7 @@
xmlns:system="clr-namespace:System;assembly=mscorlib">
<!--字符串换行 必须添加 xml:space="preserve" -->
<!--字符串换行 换行符 &#10; -->
<!--PgLoading.xaml-->
<system:String x:Key="str.Winder.DynArea.Winder">Winder</system:String>
<system:String x:Key="str.Winder.DynArea.Speed">Speed</system:String>
<system:String x:Key="str.Winder.DynArea.InsideWinder">Inside</system:String>
<system:String x:Key="str.Winder.DynArea.OutsideWinder">Outside</system:String>
......
Subproject commit 19187805c303c99b548452750462cc06626bfd4b
Subproject commit c5d889e4bd8bdc1f8b490d4e50cb1bc3e42153f7
......@@ -13,6 +13,8 @@
<register type="UserControl" mapTo="UcSectionOsk" name="osk" />
<register type="UserControl" mapTo="UcSectionServers" name="servers" />
<register type="UserControl" mapTo="UcSectionError" name="error" />
<register type="UserControl" mapTo="UcSectionLanguage" name="lang" />
<register type="UserControl" mapTo="UcSectionScanGraph" name="graph" />
</container>
</unity>
</configuration>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment