Commit 6efdc3db authored by 潘栩锋's avatar 潘栩锋 🚴

修改全部字体为 Arial

parent 3d8e7538
...@@ -61,7 +61,7 @@ ...@@ -61,7 +61,7 @@
<Setter Property="Foreground" Value="#FF3B3B3B" /> <Setter Property="Foreground" Value="#FF3B3B3B" />
<Setter Property="FontWeight" Value="Bold" /> <Setter Property="FontWeight" Value="Bold" />
<Setter Property="FontSize" Value="36" /> <Setter Property="FontSize" Value="36" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
<Setter Property="TextAlignment" Value="Left" /> <Setter Property="TextAlignment" Value="Left" />
</Style> </Style>
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
<Setter Property="Foreground" Value="#FF3B3B3B" /> <Setter Property="Foreground" Value="#FF3B3B3B" />
<Setter Property="FontWeight" Value="Bold" /> <Setter Property="FontWeight" Value="Bold" />
<Setter Property="FontSize" Value="36" /> <Setter Property="FontSize" Value="36" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
<Setter Property="TextAlignment" Value="Left" /> <Setter Property="TextAlignment" Value="Left" />
<Setter Property="MinWidth" Value="30" /> <Setter Property="MinWidth" Value="30" />
</Style> </Style>
...@@ -80,7 +80,7 @@ ...@@ -80,7 +80,7 @@
<Style TargetType="TextBlock" x:Key="TextBlockStyle_FieldContent_mm_interval"> <Style TargetType="TextBlock" x:Key="TextBlockStyle_FieldContent_mm_interval">
<Setter Property="Foreground" Value="#FF888888" /> <Setter Property="Foreground" Value="#FF888888" />
<Setter Property="FontSize" Value="36" /> <Setter Property="FontSize" Value="36" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
<Setter Property="TextAlignment" Value="Left" /> <Setter Property="TextAlignment" Value="Left" />
<Setter Property="VerticalAlignment" Value="Bottom" /> <Setter Property="VerticalAlignment" Value="Bottom" />
</Style> </Style>
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
<Style TargetType="TextBlock" x:Key="TextBlockStyle_FieldContent_mm"> <Style TargetType="TextBlock" x:Key="TextBlockStyle_FieldContent_mm">
<Setter Property="Foreground" Value="#FF888888" /> <Setter Property="Foreground" Value="#FF888888" />
<Setter Property="FontSize" Value="22" /> <Setter Property="FontSize" Value="22" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
<Setter Property="TextAlignment" Value="Left" /> <Setter Property="TextAlignment" Value="Left" />
<Setter Property="VerticalAlignment" Value="Bottom" /> <Setter Property="VerticalAlignment" Value="Bottom" />
</Style> </Style>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
<SolidColorBrush x:Key="Color_dark" Color="#8e9aa8"/> <SolidColorBrush x:Key="Color_dark" Color="#8e9aa8"/>
<Style TargetType="TextBlock" x:Key="TextBlockStyle_abc"> <Style TargetType="TextBlock" x:Key="TextBlockStyle_abc">
<Setter Property="FontSize" Value="20" /> <Setter Property="FontSize" Value="20" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
</Style> </Style>
<Style TargetType="Button" x:Key="ButtonStyle_key"> <Style TargetType="Button" x:Key="ButtonStyle_key">
<Setter Property="Margin" Value="3"/> <Setter Property="Margin" Value="3"/>
......
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
<SolidColorBrush x:Key="Color_dark" Color="#8e9aa8"/> <SolidColorBrush x:Key="Color_dark" Color="#8e9aa8"/>
<Style TargetType="TextBlock" x:Key="TextBlockStyle_abc"> <Style TargetType="TextBlock" x:Key="TextBlockStyle_abc">
<Setter Property="FontSize" Value="20" /> <Setter Property="FontSize" Value="20" />
<Setter Property="FontFamily" Value="Microsoft Sans Serif" /> <Setter Property="FontFamily" Value="Arial" />
</Style> </Style>
<Style TargetType="Button" x:Key="ButtonStyle_key"> <Style TargetType="Button" x:Key="ButtonStyle_key">
<Setter Property="Margin" Value="3"/> <Setter Property="Margin" Value="3"/>
......
...@@ -38,11 +38,16 @@ namespace FObjBase ...@@ -38,11 +38,16 @@ namespace FObjBase
} }
public virtual int SendPacket(byte[] buffer) public virtual int SendPacket(byte[] buffer)
{
lock (out_buffer)
{ {
int len = buffer.Length; int len = buffer.Length;
out_buffer.AddRange(buffer); out_buffer.AddRange(buffer);
return len; return len;
} }
}
protected virtual int GetRecvInfoPacket() // return length of the packet protected virtual int GetRecvInfoPacket() // return length of the packet
{ {
...@@ -123,10 +128,11 @@ namespace FObjBase ...@@ -123,10 +128,11 @@ namespace FObjBase
} }
int Send_Poll() int Send_Poll()
{ {
int cnt_total = 0;
if (out_buffer.Count() == 0)//没数据,直接返回 if (out_buffer.Count() == 0)//没数据,直接返回
return 0; return 0;
lock (out_buffer) {
int cnt_total = 0;
while (out_buffer.Count() > 0)//只有有数据发送,且能发送,没有 block, 就会一直循环 while (out_buffer.Count() > 0)//只有有数据发送,且能发送,没有 block, 就会一直循环
{ {
int cnt; int cnt;
...@@ -153,6 +159,7 @@ namespace FObjBase ...@@ -153,6 +159,7 @@ namespace FObjBase
} }
return cnt_total;//返回总发送量 return cnt_total;//返回总发送量
} }
}
int Receive_Poll() int Receive_Poll()
{ {
...@@ -269,7 +276,10 @@ namespace FObjBase ...@@ -269,7 +276,10 @@ namespace FObjBase
logger.Error("TCPConn OnPoll 连接断开,清空接收缓存区"); logger.Error("TCPConn OnPoll 连接断开,清空接收缓存区");
in_buffer.Clear(); in_buffer.Clear();
lock(out_buffer)
{
out_buffer.Clear(); out_buffer.Clear();
}
Enable = false; Enable = false;
} }
return ret; return ret;
......
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