Commit bf94f167 authored by tsuji's avatar tsuji

TIFF出力パラメータと検版パラメータの前回設定値を初期値として表示するように改良

parent 938a4ded
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
<section name="CSRender.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
</sectionGroup>
</configSections>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
</startup>
<userSettings>
<CSRender.Properties.Settings>
<setting name="resolutionSetting" serializeAs="String">
<value />
</setting>
<setting name="formatSetting" serializeAs="String">
<value />
</setting>
<setting name="shiftPixelSetting" serializeAs="String">
<value />
</setting>
<setting name="colorMarginSetting" serializeAs="String">
<value />
</setting>
<setting name="removePointSetting" serializeAs="String">
<value />
</setting>
<setting name="shadingOffSetting" serializeAs="String">
<value />
</setting>
</CSRender.Properties.Settings>
</userSettings>
</configuration>
\ No newline at end of file
......@@ -89,6 +89,14 @@ namespace CSRender
FilePattern.Add((new ComboBoxSet { Id = 7, Item = "BMP" }));
FileSelect.ItemsSource = FilePattern;
//デフォルトに前回の設定値を表示
ResolutionBox.Text = Properties.Settings.Default.resolutionSetting;
FileSelect.Text = Properties.Settings.Default.formatSetting;
PositionBox.Text = Properties.Settings.Default.shiftPixelSetting;
GradationBox.Text = Properties.Settings.Default.colorMarginSetting;
SmallDiffBox.Text = Properties.Settings.Default.removePointSetting;
VisualBox.Text = Properties.Settings.Default.shadingOffSetting;
//ドラッグ&ドロップイベントの追加
targetBox.AddHandler(TextBox.DragOverEvent, new DragEventHandler(textBox_PreviewDragOver), true);
targetBox.AddHandler(TextBox.DropEvent, new DragEventHandler(TargetBox_Drop), true);
......@@ -185,6 +193,14 @@ namespace CSRender
//指定先にレポートを移動
CompareTIFF.moveReport(workBox.Text, workDir);
//パラメータを次回初期値用に保存
Properties.Settings.Default.resolutionSetting = ResolutionBox.Text;
Properties.Settings.Default.formatSetting = FileSelect.Text;
Properties.Settings.Default.shiftPixelSetting = PositionBox.Text;
Properties.Settings.Default.colorMarginSetting = GradationBox.Text;
Properties.Settings.Default.removePointSetting = SmallDiffBox.Text;
Properties.Settings.Default.shadingOffSetting = VisualBox.Text;
Properties.Settings.Default.Save();
}
//UIに検版結果を出力
......@@ -254,6 +270,11 @@ namespace CSRender
ResultConsole.Text += TIFFresult;
ResultConsole.Text += "\r\n<変換終了>\r\n";
ResultConsole.ScrollToEnd();
//パラメータを次回初期値用に保存
Properties.Settings.Default.resolutionSetting = ResolutionBox.Text;
Properties.Settings.Default.formatSetting = FileSelect.Text;
Properties.Settings.Default.Save();
}
}
......
//------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by a tool.
// Runtime Version:4.0.30319.42000
// このコードはツールによって生成されました。
// ランタイム バージョン:4.0.30319.42000
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// このファイルへの変更は、以下の状況下で不正な動作の原因になったり、
// コードが再生成されるときに損失したりします。
// </auto-generated>
//------------------------------------------------------------------------------
namespace CSRender.Properties
{
namespace CSRender.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "11.0.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
{
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "15.9.0.0")]
internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
public static Settings Default
{
get
{
public static Settings Default {
get {
return defaultInstance;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string resolutionSetting {
get {
return ((string)(this["resolutionSetting"]));
}
set {
this["resolutionSetting"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string formatSetting {
get {
return ((string)(this["formatSetting"]));
}
set {
this["formatSetting"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string shiftPixelSetting {
get {
return ((string)(this["shiftPixelSetting"]));
}
set {
this["shiftPixelSetting"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string colorMarginSetting {
get {
return ((string)(this["colorMarginSetting"]));
}
set {
this["colorMarginSetting"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string removePointSetting {
get {
return ((string)(this["removePointSetting"]));
}
set {
this["removePointSetting"] = value;
}
}
[global::System.Configuration.UserScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("")]
public string shadingOffSetting {
get {
return ((string)(this["shadingOffSetting"]));
}
set {
this["shadingOffSetting"] = value;
}
}
}
}
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="uri:settings" CurrentProfile="(Default)">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="CSRender.Properties" GeneratedClassName="Settings">
<Profiles />
<Settings>
<Setting Name="resolutionSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="formatSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="shiftPixelSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="colorMarginSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="removePointSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
<Setting Name="shadingOffSetting" Type="System.String" Scope="User">
<Value Profile="(Default)" />
</Setting>
</Settings>
</SettingsFile>
\ 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