Browse Source

testing OK

master
nfa 3 years ago
commit
5ac03d0180
  1. 25
      nocr.sln
  2. 66
      nocr/BaiduOcr.cs
  3. 191
      nocr/Form1.Designer.cs
  4. 148
      nocr/Form1.cs
  5. 115
      nocr/Form1.resx
  6. 55
      nocr/Form2.Designer.cs
  7. 100
      nocr/Form2.cs
  8. 60
      nocr/Form2.resx
  9. 132
      nocr/Form3.Designer.cs
  10. 54
      nocr/Form3.cs
  11. 60
      nocr/Form3.resx
  12. 209
      nocr/IniFile.cs
  13. 17
      nocr/Program.cs
  14. 12
      nocr/Properties/PublishProfiles/FolderProfile.pubxml
  15. 9
      nocr/Properties/PublishProfiles/FolderProfile.pubxml.user
  16. 63
      nocr/Properties/Resources.Designer.cs
  17. 120
      nocr/Properties/Resources.resx
  18. BIN
      nocr/bin/Debug/net6.0-windows/Newtonsoft.Json.dll
  19. 41
      nocr/bin/Debug/net6.0-windows/nocr.deps.json
  20. BIN
      nocr/bin/Debug/net6.0-windows/nocr.dll
  21. BIN
      nocr/bin/Debug/net6.0-windows/nocr.exe
  22. BIN
      nocr/bin/Debug/net6.0-windows/nocr.pdb
  23. 15
      nocr/bin/Debug/net6.0-windows/nocr.runtimeconfig.json
  24. 3
      nocr/bin/Debug/net6.0-windows/settings.ini
  25. BIN
      nocr/bin/Debug/nocr.1.0.0.nupkg
  26. BIN
      nocr/bin/Release/net6.0-windows/Newtonsoft.Json.dll
  27. 41
      nocr/bin/Release/net6.0-windows/nocr.deps.json
  28. BIN
      nocr/bin/Release/net6.0-windows/nocr.dll
  29. BIN
      nocr/bin/Release/net6.0-windows/nocr.exe
  30. BIN
      nocr/bin/Release/net6.0-windows/nocr.pdb
  31. 18
      nocr/bin/Release/net6.0-windows/nocr.runtimeconfig.json
  32. BIN
      nocr/bin/Release/net6.0-windows/publish/Newtonsoft.Json.dll
  33. 41
      nocr/bin/Release/net6.0-windows/publish/nocr.deps.json
  34. BIN
      nocr/bin/Release/net6.0-windows/publish/nocr.dll
  35. BIN
      nocr/bin/Release/net6.0-windows/publish/nocr.exe
  36. BIN
      nocr/bin/Release/net6.0-windows/publish/nocr.pdb
  37. 18
      nocr/bin/Release/net6.0-windows/publish/nocr.runtimeconfig.json
  38. 3
      nocr/bin/Release/net6.0-windows/settings.ini
  39. BIN
      nocr/favicon16.ico
  40. BIN
      nocr/favicon48.ico
  41. BIN
      nocr/favicon64.ico
  42. 35
      nocr/nocr.csproj
  43. 17
      nocr/nocr.csproj.user
  44. 4
      nocr/obj/Debug/net6.0-windows/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs
  45. BIN
      nocr/obj/Debug/net6.0-windows/TempPE/Properties.Resources.Designer.cs.dll
  46. BIN
      nocr/obj/Debug/net6.0-windows/apphost.exe
  47. 25
      nocr/obj/Debug/net6.0-windows/nocr.AssemblyInfo.cs
  48. 1
      nocr/obj/Debug/net6.0-windows/nocr.AssemblyInfoInputs.cache
  49. BIN
      nocr/obj/Debug/net6.0-windows/nocr.Form1.resources
  50. BIN
      nocr/obj/Debug/net6.0-windows/nocr.Form2.resources
  51. BIN
      nocr/obj/Debug/net6.0-windows/nocr.Form3.resources
  52. 16
      nocr/obj/Debug/net6.0-windows/nocr.GeneratedMSBuildEditorConfig.editorconfig
  53. 10
      nocr/obj/Debug/net6.0-windows/nocr.GlobalUsings.g.cs
  54. BIN
      nocr/obj/Debug/net6.0-windows/nocr.Properties.Resources.resources
  55. BIN
      nocr/obj/Debug/net6.0-windows/nocr.assets.cache
  56. BIN
      nocr/obj/Debug/net6.0-windows/nocr.csproj.AssemblyReference.cache
  57. 0
      nocr/obj/Debug/net6.0-windows/nocr.csproj.BuildWithSkipAnalyzers
  58. 0
      nocr/obj/Debug/net6.0-windows/nocr.csproj.CopyComplete
  59. 1
      nocr/obj/Debug/net6.0-windows/nocr.csproj.CoreCompileInputs.cache
  60. 22
      nocr/obj/Debug/net6.0-windows/nocr.csproj.FileListAbsolute.txt
  61. BIN
      nocr/obj/Debug/net6.0-windows/nocr.csproj.GenerateResource.cache
  62. 28
      nocr/obj/Debug/net6.0-windows/nocr.designer.deps.json
  63. 22
      nocr/obj/Debug/net6.0-windows/nocr.designer.runtimeconfig.json
  64. BIN
      nocr/obj/Debug/net6.0-windows/nocr.dll
  65. 1
      nocr/obj/Debug/net6.0-windows/nocr.genruntimeconfig.cache
  66. BIN
      nocr/obj/Debug/net6.0-windows/nocr.pdb
  67. BIN
      nocr/obj/Debug/net6.0-windows/ref/nocr.dll
  68. BIN
      nocr/obj/Debug/net6.0-windows/refint/nocr.dll
  69. 23
      nocr/obj/Debug/nocr.1.0.0.nuspec
  70. 4
      nocr/obj/Release/net6.0-windows/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs
  71. 6
      nocr/obj/Release/net6.0-windows/PublishOutputs.1964e136d2.txt
  72. BIN
      nocr/obj/Release/net6.0-windows/apphost.exe
  73. 25
      nocr/obj/Release/net6.0-windows/nocr.AssemblyInfo.cs
  74. 1
      nocr/obj/Release/net6.0-windows/nocr.AssemblyInfoInputs.cache
  75. BIN
      nocr/obj/Release/net6.0-windows/nocr.Form1.resources
  76. BIN
      nocr/obj/Release/net6.0-windows/nocr.Form2.resources
  77. BIN
      nocr/obj/Release/net6.0-windows/nocr.Form3.resources
  78. 16
      nocr/obj/Release/net6.0-windows/nocr.GeneratedMSBuildEditorConfig.editorconfig
  79. 10
      nocr/obj/Release/net6.0-windows/nocr.GlobalUsings.g.cs
  80. BIN
      nocr/obj/Release/net6.0-windows/nocr.Properties.Resources.resources
  81. BIN
      nocr/obj/Release/net6.0-windows/nocr.assets.cache
  82. BIN
      nocr/obj/Release/net6.0-windows/nocr.csproj.AssemblyReference.cache
  83. 0
      nocr/obj/Release/net6.0-windows/nocr.csproj.CopyComplete
  84. 1
      nocr/obj/Release/net6.0-windows/nocr.csproj.CoreCompileInputs.cache
  85. 22
      nocr/obj/Release/net6.0-windows/nocr.csproj.FileListAbsolute.txt
  86. BIN
      nocr/obj/Release/net6.0-windows/nocr.csproj.GenerateResource.cache
  87. 28
      nocr/obj/Release/net6.0-windows/nocr.designer.deps.json
  88. 23
      nocr/obj/Release/net6.0-windows/nocr.designer.runtimeconfig.json
  89. BIN
      nocr/obj/Release/net6.0-windows/nocr.dll
  90. 1
      nocr/obj/Release/net6.0-windows/nocr.genruntimeconfig.cache
  91. BIN
      nocr/obj/Release/net6.0-windows/nocr.pdb
  92. BIN
      nocr/obj/Release/net6.0-windows/ref/nocr.dll
  93. BIN
      nocr/obj/Release/net6.0-windows/refint/nocr.dll
  94. 71
      nocr/obj/nocr.csproj.nuget.dgspec.json
  95. 15
      nocr/obj/nocr.csproj.nuget.g.props
  96. 2
      nocr/obj/nocr.csproj.nuget.g.targets
  97. 116
      nocr/obj/project.assets.json
  98. 10
      nocr/obj/project.nuget.cache
  99. 3
      settings.ini

25
nocr.sln

@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 17
VisualStudioVersion = 17.1.32228.430
MinimumVisualStudioVersion = 10.0.40219.1
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "nocr", "nocr\nocr.csproj", "{18A9FC9D-F69C-4FFE-A19D-285C9DA82924}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{18A9FC9D-F69C-4FFE-A19D-285C9DA82924}.Debug|Any CPU.ActiveCfg = Release|Any CPU
{18A9FC9D-F69C-4FFE-A19D-285C9DA82924}.Debug|Any CPU.Build.0 = Release|Any CPU
{18A9FC9D-F69C-4FFE-A19D-285C9DA82924}.Release|Any CPU.ActiveCfg = Release|Any CPU
{18A9FC9D-F69C-4FFE-A19D-285C9DA82924}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {12FCBF5C-B6C0-4EE8-B21D-E13EDA726F72}
EndGlobalSection
EndGlobal

66
nocr/BaiduOcr.cs

@ -0,0 +1,66 @@
using System;
using System.Collections.Generic;
using System.Text;
using System.IO;
using System.Net;
using System.Web;
namespace nocr
{
public class GeneralBasic
{
// 通用文字识别
public static string generalBasic(String token, String picFile)
{
// string token = "[调用鉴权接口获取的token]";
string host = "https://aip.baidubce.com/rest/2.0/ocr/v1/general_basic?access_token=" + token;
Encoding encoding = Encoding.Default;
HttpWebRequest request = (HttpWebRequest)WebRequest.Create(host);
request.Method = "post";
request.KeepAlive = true;
// 图片的base64编码
string base64 = getFileBase64(picFile);
String str = "image=" + HttpUtility.UrlEncode(base64);
byte[] buffer = encoding.GetBytes(str);
request.ContentLength = buffer.Length;
request.GetRequestStream().Write(buffer, 0, buffer.Length);
HttpWebResponse response = (HttpWebResponse)request.GetResponse();
StreamReader reader = new StreamReader(response.GetResponseStream(), Encoding.Default);
string result = reader.ReadToEnd();
Console.WriteLine("通用文字识别:");
Console.WriteLine(result);
return result;
}
public static String getFileBase64(String fileName)
{
FileStream filestream = new FileStream(fileName, FileMode.Open);
byte[] arr = new byte[filestream.Length];
filestream.Read(arr, 0, (int)filestream.Length);
string baser64 = Convert.ToBase64String(arr);
filestream.Close();
return baser64;
}
}
public static class AccessToken
{
// 调用getAccessToken()获取的 access_token建议根据expires_in 时间 设置缓存
// 返回token示例
public static String TOKEN = "24.adda70c11b9786206253ddb70affdc46.2592000.1493524354.282335-1234567";
public static String getAccessToken(String clientId, String clientSecret)
{
String authHost = "https://aip.baidubce.com/oauth/2.0/token";
HttpClient client = new HttpClient();
List<KeyValuePair<String, String>> paraList = new List<KeyValuePair<string, string>>();
paraList.Add(new KeyValuePair<string, string>("grant_type", "client_credentials"));
paraList.Add(new KeyValuePair<string, string>("client_id", clientId));
paraList.Add(new KeyValuePair<string, string>("client_secret", clientSecret));
HttpResponseMessage response = client.PostAsync(authHost, new FormUrlEncodedContent(paraList)).Result;
String result = response.Content.ReadAsStringAsync().Result;
Console.WriteLine(result);
return result;
}
}
}

191
nocr/Form1.Designer.cs

@ -0,0 +1,191 @@
namespace nocr
{
partial class Form1
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(Form1));
this.btn_start = new System.Windows.Forms.Button();
this.btn_cfg = new System.Windows.Forms.Button();
this.isConj = new System.Windows.Forms.CheckBox();
this.resultTXT = new System.Windows.Forms.RichTextBox();
this.notifyIcon1 = new System.Windows.Forms.NotifyIcon(this.components);
this.contextMenuStrip1 = new System.Windows.Forms.ContextMenuStrip(this.components);
this.ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripSeparator();
this.退ToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.panel1 = new System.Windows.Forms.Panel();
this.panel2 = new System.Windows.Forms.Panel();
this.contextMenuStrip1.SuspendLayout();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.SuspendLayout();
//
// btn_start
//
this.btn_start.Location = new System.Drawing.Point(28, 12);
this.btn_start.Name = "btn_start";
this.btn_start.Size = new System.Drawing.Size(55, 23);
this.btn_start.TabIndex = 0;
this.btn_start.Text = "截图";
this.btn_start.UseVisualStyleBackColor = true;
this.btn_start.Click += new System.EventHandler(this.btn_start_Click);
//
// btn_cfg
//
this.btn_cfg.Location = new System.Drawing.Point(100, 12);
this.btn_cfg.Name = "btn_cfg";
this.btn_cfg.Size = new System.Drawing.Size(55, 23);
this.btn_cfg.TabIndex = 1;
this.btn_cfg.Text = "配置";
this.btn_cfg.UseVisualStyleBackColor = true;
this.btn_cfg.Click += new System.EventHandler(this.btn_cfg_Click);
//
// isConj
//
this.isConj.AutoSize = true;
this.isConj.Location = new System.Drawing.Point(175, 14);
this.isConj.Name = "isConj";
this.isConj.Size = new System.Drawing.Size(75, 21);
this.isConj.TabIndex = 2;
this.isConj.Text = "段落整合";
this.isConj.UseVisualStyleBackColor = true;
//
// resultTXT
//
this.resultTXT.Dock = System.Windows.Forms.DockStyle.Fill;
this.resultTXT.Location = new System.Drawing.Point(0, 0);
this.resultTXT.Name = "resultTXT";
this.resultTXT.Size = new System.Drawing.Size(384, 217);
this.resultTXT.TabIndex = 3;
this.resultTXT.Text = "";
//
// notifyIcon1
//
this.notifyIcon1.ContextMenuStrip = this.contextMenuStrip1;
this.notifyIcon1.Icon = ((System.Drawing.Icon)(resources.GetObject("notifyIcon1.Icon")));
this.notifyIcon1.Text = "截图识字";
this.notifyIcon1.Visible = true;
this.notifyIcon1.Click += new System.EventHandler(this.notifyIcon1_Click);
//
// contextMenuStrip1
//
this.contextMenuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.ToolStripMenuItem,
this.ToolStripMenuItem,
this.toolStripMenuItem1,
this.退ToolStripMenuItem});
this.contextMenuStrip1.Name = "contextMenuStrip1";
this.contextMenuStrip1.Size = new System.Drawing.Size(147, 76);
//
// 截图ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "截图ToolStripMenuItem";
this.ToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.T)));
this.ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.ToolStripMenuItem.Text = "截图";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// 配置ToolStripMenuItem
//
this.ToolStripMenuItem.Name = "配置ToolStripMenuItem";
this.ToolStripMenuItem.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.G)));
this.ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.ToolStripMenuItem.Text = "配置";
this.ToolStripMenuItem.Click += new System.EventHandler(this.ToolStripMenuItem_Click);
//
// toolStripMenuItem1
//
this.toolStripMenuItem1.Name = "toolStripMenuItem1";
this.toolStripMenuItem1.Size = new System.Drawing.Size(143, 6);
//
// 退出ToolStripMenuItem
//
this.退ToolStripMenuItem.Name = "退出ToolStripMenuItem";
this.退ToolStripMenuItem.Size = new System.Drawing.Size(146, 22);
this.退ToolStripMenuItem.Text = "退出";
this.退ToolStripMenuItem.Click += new System.EventHandler(this.退ToolStripMenuItem_Click);
//
// panel1
//
this.panel1.Controls.Add(this.btn_start);
this.panel1.Controls.Add(this.btn_cfg);
this.panel1.Controls.Add(this.isConj);
this.panel1.Dock = System.Windows.Forms.DockStyle.Top;
this.panel1.Location = new System.Drawing.Point(0, 0);
this.panel1.Name = "panel1";
this.panel1.Size = new System.Drawing.Size(384, 44);
this.panel1.TabIndex = 4;
//
// panel2
//
this.panel2.Controls.Add(this.resultTXT);
this.panel2.Dock = System.Windows.Forms.DockStyle.Fill;
this.panel2.Location = new System.Drawing.Point(0, 44);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(384, 217);
this.panel2.TabIndex = 5;
//
// Form1
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(384, 261);
this.Controls.Add(this.panel2);
this.Controls.Add(this.panel1);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));
this.Name = "Form1";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "截图识字";
this.Load += new System.EventHandler(this.Form1_Load);
this.SizeChanged += new System.EventHandler(this.Form1_SizeChanged);
this.contextMenuStrip1.ResumeLayout(false);
this.panel1.ResumeLayout(false);
this.panel1.PerformLayout();
this.panel2.ResumeLayout(false);
this.ResumeLayout(false);
}
#endregion
private Button btn_start;
private Button btn_cfg;
private CheckBox isConj;
private RichTextBox resultTXT;
private NotifyIcon notifyIcon1;
private ContextMenuStrip contextMenuStrip1;
private ToolStripMenuItem ToolStripMenuItem;
private ToolStripMenuItem ToolStripMenuItem;
private ToolStripSeparator toolStripMenuItem1;
private ToolStripMenuItem 退ToolStripMenuItem;
private Panel panel1;
private Panel panel2;
}
}

148
nocr/Form1.cs

@ -0,0 +1,148 @@
namespace nocr
{
using Newtonsoft.Json;
public partial class Form1 : Form
{
private String apikey;
private String skey;
private String token;
IniFile cfgfile;
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
try
{
cfgfile = new IniFile("settings.ini");
apikey = cfgfile.ReadString("account", "apikey", "");
skey = cfgfile.ReadString("account", "secretkey", "");
//MessageBox.Show(appid + ":" + skey);
update_Token(apikey, skey);
}
catch(Exception ex)
{
MessageBox.Show(ex.Message);
}
}
private void update_Token(String apikey, String secretkey)
{
// 获取token
String tk = null;
try
{
String tkstr = AccessToken.getAccessToken(apikey, skey);
if (tkstr.IndexOf("error") > 0)
{
MessageBox.Show("token未获取,请检查网络或配置参数!");
}
else if (tkstr.IndexOf("access_token") > 0)
{
JsonSerializerSettings settings = new JsonSerializerSettings();
var tkjson = JsonConvert.DeserializeObject<dynamic>(tkstr, settings);
token = tkjson.access_token.ToString();
// Console.WriteLine(tkstr);
}
}
catch
{
}
}
private void notifyIcon1_Click(object sender, EventArgs e)
{
this.contextMenuStrip1.Show(MousePosition.X, MousePosition.Y);
}
private void Form1_SizeChanged(object sender, EventArgs e)
{
if (this.WindowState == FormWindowState.Minimized)
{
this.Hide();
this.notifyIcon1.Visible = true;
}
}
private void 退ToolStripMenuItem_Click(object sender, EventArgs e)
{
Application.Exit();
}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{
this.btn_start_Click(sender, e);
}
private void btn_cfg_Click(object sender, EventArgs e)
{
Form cfgfm = new Form3();
cfgfm.FormClosed += new FormClosedEventHandler(cfgfm_FormClosed);
cfgfm.Show();
}
private void ToolStripMenuItem_Click(object sender, EventArgs e)
{
this.btn_cfg_Click(sender, e);
}
private void btn_start_Click(object sender, EventArgs e)
{
this.Hide();
this.notifyIcon1.Visible = true;
Form2 fm2 = new Form2();
fm2.FormClosed += new FormClosedEventHandler(fm2_FormClosed);
fm2.Show();
//MessageBox.Show("start capture!");
}
void fm2_FormClosed(object sender, FormClosedEventArgs e)
{
this.Show();
// 加载图片,上传识别
this.resultTXT.Clear();
String ocrtxt = "";
String result = GeneralBasic.generalBasic(token, Path.Combine(Path.GetTempPath(), "nscreenshot.jpg"));
if (result.IndexOf("error_code") > 0 && (result.IndexOf("110") > 0 || result.IndexOf("111") > 0))
{
// token过期,更新token
update_Token(apikey, skey);
}
else
{
try
{
JsonSerializerSettings settings = new JsonSerializerSettings();
var rsjson = JsonConvert.DeserializeObject<dynamic>(result, settings);
if (rsjson != null && (int)rsjson.words_result_num > 0)
{
for(int i = 0; i < (int)rsjson.words_result_num; i++)
{
ocrtxt = ocrtxt + rsjson.words_result[i].words.ToString() + "\n";
}
if (isConj.Checked)
{
ocrtxt = ocrtxt.Replace("\n", "");
}
}
}
catch
{
MessageBox.Show("服务请求失败,请稍后重试。");
}
}
this.resultTXT.Text = ocrtxt;
this.WindowState = FormWindowState.Normal;
}
void cfgfm_FormClosed(object sender, FormClosedEventArgs e)
{
// 读取配置文件,更新配置参数
}
}
}

115
nocr/Form1.resx

@ -0,0 +1,115 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="notifyIcon1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<metadata name="contextMenuStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>135, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="notifyIcon1.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAQAABMLAAATCwAAAAAAAAAA
AAAZIqgFEh2MPg8Zel8PGXpfDhdyWgcKMSIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAHDDpMxgv4rYYLt+pGS/kpBkv4pUXJrgeJDv/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAABwx7kgXLNWnERZvJCQz+gwjMe4LJTHwAiQx8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAcMe5IFyzUpAgIKhcMD0IAAgFLAggIZgIJCW4CCQluAAkJbgEJCW4DCQluAQkJ
bgIJCW4BCQluAAAAAAAAAAAAHDDsRRku4JMOD0wMAQBsAQkJbjwJCW5pCQluQwkJbgAJCW4KCQluTAkJ
bokJCW5yCQluEAkJbgAAAAAAAAAAAB4w6hEdMOoiLC/qAQwNfAAJCW4OCQlucgkJbiIJCW4ACQluAAkJ
bjgJCW6/CQluSQkJbgAJCW4AAAAAAAAAAAAAAAAAAAAAAAAAAAAJCW4ACQluAAkJbjgJCW4wCQluBwkJ
bg0JCW5mCQlupQkJbgsJCW4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkJbgAJCW4TCQlucgkJ
blQJCW5fCQlupgkJbmUJCW4ACQluAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAJCW4ACQluAQkJ
bkcJCW4YCQluRgkJbrQJCW4iCQluAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkJ
bgAJCW4mCQluQwkJbn4JCW6NCQluAQkJbgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAJCW4ACQluCQkJbmUJCW6yCQluRQkJbgAAAAAADAoyAAAAAAAFBBQNAQEDFAAAAAAAAAAAAAAAAAAA
AAAAAAAACQluAAkJbhkJCW6MCQluqwkJbg8JCW4AAAAAACQv5gAkMvQIGCvScw4WbUQAAAAAAAAAAAAA
AAAAAAAAAAAAAAkJbgAJCW4FCQluJgkJbiYJCW4ACQluAAAAAAAkL+kAIjDuDRkv5KURHY5SAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFRZwADY5/wAJCS4RBAQWJQwQUTEYLdyrEh6TTwAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAB8v5gAfMOoNGS3cgxcr0KgXK9KrGC/ktRgn
vC4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAhMOoAIDDqBhwx7DwcMe5IHDHuSBww
6zIiL+YEAf8AAAP/AAAD/wAAEAcAAAAHAAARjwAA+A8AAPgfAAD4HwAA/B8AAPw8AAD8OAAA/DgAAP/A
AAD/wAAA/8AAAA==
</value>
</data>
<data name="$this.Icon" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAQAABMLAAATCwAAAAAAAAAA
AAAZIqgFEh2MPg8Zel8PGXpfDhdyWgcKMSIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAHDDpMxgv4rYYLt+pGS/kpBkv4pUXJrgeJDv/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAABwx7kgXLNWnERZvJCQz+gwjMe4LJTHwAiQx8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAcMe5IFyzUpAgIKhcMD0IAAgFLAggIZgIJCW4CCQluAAkJbgEJCW4DCQluAQkJ
bgIJCW4BCQluAAAAAAAAAAAAHDDsRRku4JMOD0wMAQBsAQkJbjwJCW5pCQluQwkJbgAJCW4KCQluTAkJ
bokJCW5yCQluEAkJbgAAAAAAAAAAAB4w6hEdMOoiLC/qAQwNfAAJCW4OCQlucgkJbiIJCW4ACQluAAkJ
bjgJCW6/CQluSQkJbgAJCW4AAAAAAAAAAAAAAAAAAAAAAAAAAAAJCW4ACQluAAkJbjgJCW4wCQluBwkJ
bg0JCW5mCQlupQkJbgsJCW4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkJbgAJCW4TCQlucgkJ
blQJCW5fCQlupgkJbmUJCW4ACQluAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAJCW4ACQluAQkJ
bkcJCW4YCQluRgkJbrQJCW4iCQluAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAkJ
bgAJCW4mCQluQwkJbn4JCW6NCQluAQkJbgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
AAAJCW4ACQluCQkJbmUJCW6yCQluRQkJbgAAAAAADAoyAAAAAAAFBBQNAQEDFAAAAAAAAAAAAAAAAAAA
AAAAAAAACQluAAkJbhkJCW6MCQluqwkJbg8JCW4AAAAAACQv5gAkMvQIGCvScw4WbUQAAAAAAAAAAAAA
AAAAAAAAAAAAAAkJbgAJCW4FCQluJgkJbiYJCW4ACQluAAAAAAAkL+kAIjDuDRkv5KURHY5SAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFRZwADY5/wAJCS4RBAQWJQwQUTEYLdyrEh6TTwAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAB8v5gAfMOoNGS3cgxcr0KgXK9KrGC/ktRgn
vC4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAhMOoAIDDqBhwx7DwcMe5IHDHuSBww
6zIiL+YEAf8AAAP/AAAD/wAAEAcAAAAHAAARjwAA+A8AAPgfAAD4HwAA/B8AAPw8AAD8OAAA/DgAAP/A
AAD/wAAA/8AAAA==
</value>
</data>
</root>

55
nocr/Form2.Designer.cs

@ -0,0 +1,55 @@
namespace nocr
{
partial class Form2
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.SuspendLayout();
//
// Form2
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(584, 361);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
this.Name = "Form2";
this.Text = "Form2";
this.WindowState = System.Windows.Forms.FormWindowState.Maximized;
this.FormClosed += new System.Windows.Forms.FormClosedEventHandler(this.Form2_FormClosed);
this.Load += new System.EventHandler(this.Form2_Load);
this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.Form2_KeyDown);
this.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.Form2_MouseDoubleClick);
this.MouseDown += new System.Windows.Forms.MouseEventHandler(this.Form2_MouseDown);
this.MouseMove += new System.Windows.Forms.MouseEventHandler(this.Form2_MouseMove);
this.MouseUp += new System.Windows.Forms.MouseEventHandler(this.Form2_MouseUp);
this.ResumeLayout(false);
}
#endregion
}
}

100
nocr/Form2.cs

@ -0,0 +1,100 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.IO;
namespace nocr
{
public partial class Form2 : Form
{
private bool down = false;
private Point firstPoint;
private Pen p = new Pen(Color.Red, 2);
private Graphics gra;
private Rectangle rectangle; //存储用户截取的矩形
public Form2()
{
InitializeComponent();
}
private void Form2_Load(object sender, EventArgs e)
{
Image img = new Bitmap(Screen.PrimaryScreen.Bounds.Width, Screen.PrimaryScreen.Bounds.Height);
Graphics g = Graphics.FromImage(img);
this.Opacity = 0.01;
g.CopyFromScreen(new Point(0, 0), new Point(0, 0), Screen.PrimaryScreen.Bounds.Size);
// img.Save(@"D:\test.jpg");
this.BackgroundImage = img;
this.Opacity = 1;
//this.FormBorderStyle = FormBorderStyle.None;
//this.Bounds = Screen.PrimaryScreen.Bounds;
gra = this.CreateGraphics(); // 在主背景下加一层绘制选区
}
public void Form2_FormClosed(object sender, FormClosedEventArgs e)
{
this.Dispose();
}
private void Form2_MouseDown(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Left)
{
down = true;
firstPoint = e.Location;
}
else if(e.Button == MouseButtons.Right)
{
// 点击鼠标右键退回Form1
this.Close();
}
}
private void Form2_MouseUp(object sender, MouseEventArgs e)
{
if (e.Button == MouseButtons.Left)
{
down = false;
}
}
private void Form2_MouseMove(object sender, MouseEventArgs e)
{
if (down)
{
gra.DrawImage(this.BackgroundImage, 0, 0);
rectangle = new Rectangle(Math.Min(firstPoint.X, e.X), Math.Min(e.Y, firstPoint.Y), Math.Abs(e.X - firstPoint.X), Math.Abs(e.Y - firstPoint.Y));
gra.DrawRectangle(p, rectangle);
}
}
private void Form2_KeyDown(object sender, KeyEventArgs e)
{
if(e.KeyCode == Keys.Escape)
{
this.Close();
}
}
private void Form2_MouseDoubleClick(object sender, MouseEventArgs e)
{
if (rectangle.Width != 0 && rectangle.Height != 0)
{
gra.DrawImage(this.BackgroundImage, 0, 0);
Image im = new Bitmap(rectangle.Width, rectangle.Height);
Graphics g = Graphics.FromImage(im);
g.CopyFromScreen(rectangle.Location, new Point(0, 0), rectangle.Size);
im.Save(Path.Combine(Path.GetTempPath(), "nscreenshot.jpg"));
// Clipboard.SetImage(im);
this.Close();
}
}
}
}

60
nocr/Form2.resx

@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

132
nocr/Form3.Designer.cs

@ -0,0 +1,132 @@
namespace nocr
{
partial class Form3
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.apikey = new System.Windows.Forms.TextBox();
this.label2 = new System.Windows.Forms.Label();
this.secretkey = new System.Windows.Forms.TextBox();
this.label3 = new System.Windows.Forms.Label();
this.btn_save = new System.Windows.Forms.Button();
this.btn_close = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(0, 0);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(128, 17);
this.label1.TabIndex = 0;
this.label1.Text = "百度开发者账号授权码";
//
// apikey
//
this.apikey.Location = new System.Drawing.Point(73, 21);
this.apikey.Name = "apikey";
this.apikey.Size = new System.Drawing.Size(213, 23);
this.apikey.TabIndex = 1;
//
// label2
//
this.label2.AutoSize = true;
this.label2.Location = new System.Drawing.Point(9, 23);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(52, 17);
this.label2.TabIndex = 2;
this.label2.Text = "API Key";
//
// secretkey
//
this.secretkey.Location = new System.Drawing.Point(73, 50);
this.secretkey.Name = "secretkey";
this.secretkey.Size = new System.Drawing.Size(213, 23);
this.secretkey.TabIndex = 3;
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(0, 53);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(69, 17);
this.label3.TabIndex = 4;
this.label3.Text = "Secret Key";
//
// btn_save
//
this.btn_save.Location = new System.Drawing.Point(73, 83);
this.btn_save.Name = "btn_save";
this.btn_save.Size = new System.Drawing.Size(75, 23);
this.btn_save.TabIndex = 5;
this.btn_save.Text = "设 置";
this.btn_save.UseVisualStyleBackColor = true;
this.btn_save.Click += new System.EventHandler(this.btn_save_Click);
//
// btn_close
//
this.btn_close.Location = new System.Drawing.Point(165, 83);
this.btn_close.Name = "btn_close";
this.btn_close.Size = new System.Drawing.Size(75, 23);
this.btn_close.TabIndex = 6;
this.btn_close.Text = "关 闭";
this.btn_close.UseVisualStyleBackColor = true;
this.btn_close.Click += new System.EventHandler(this.btn_close_Click);
//
// Form3
//
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 17F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(298, 118);
this.Controls.Add(this.btn_close);
this.Controls.Add(this.btn_save);
this.Controls.Add(this.label3);
this.Controls.Add(this.secretkey);
this.Controls.Add(this.label2);
this.Controls.Add(this.apikey);
this.Controls.Add(this.label1);
this.Name = "Form3";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "参数配置";
this.Load += new System.EventHandler(this.Form3_Load);
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private Label label1;
private TextBox apikey;
private Label label2;
private TextBox secretkey;
private Label label3;
private Button btn_save;
private Button btn_close;
}
}

54
nocr/Form3.cs

@ -0,0 +1,54 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace nocr
{
public partial class Form3 : Form
{
IniFile cfgfile;
public Form3()
{
InitializeComponent();
}
private void btn_close_Click(object sender, EventArgs e)
{
this.Close();
}
private void btn_save_Click(object sender, EventArgs e)
{
// 更新ini文件配置,修改Form1的appid和skey
if(apikey.Text != "" && secretkey.Text != "")
{
IniFile cfgfile = new IniFile("settings.ini");
cfgfile.WriteString("account", "apikey", apikey.Text.Trim());
cfgfile.WriteString("account", "secretkey", apikey.Text.Trim());
MessageBox.Show("参数设置完毕,应用重启后生效!");
}
}
private void Form3_Load(object sender, EventArgs e)
{
try
{
cfgfile = new IniFile("settings.ini");
String apikey = cfgfile.ReadString("account", "apikey", "");
String skey = cfgfile.ReadString("account", "secretkey", "");
this.apikey.Text = apikey;
this.secretkey.Text = skey;
}
catch (Exception ex)
{
MessageBox.Show("文件读取失败,请检查配置文件");
}
}
}
}

60
nocr/Form3.resx

@ -0,0 +1,60 @@
<root>
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

209
nocr/IniFile.cs

@ -0,0 +1,209 @@
using System;
using System.IO;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Text;
using System.Collections;
using System.Collections.Specialized;
namespace nocr
{
public class IniFile
{
public string FileName; //INI文件名
//声明读写INI文件的API函数
[DllImport("kernel32")]
private static extern bool WritePrivateProfileString(string section, string key, string val, string filePath);
[DllImport("kernel32")]
private static extern int GetPrivateProfileString(string section, string key, string def, byte[] retVal, int size, string filePath);
//类的构造函数,传递INI文件名
public IniFile(string AFileName)
{
// 判断文件是否存在
FileInfo fileInfo = new FileInfo(AFileName);
//Todo:搞清枚举的用法
if ((!fileInfo.Exists))
{ //|| (FileAttributes.Directory in fileInfo.Attributes))
//文件不存在,建立文件
System.IO.StreamWriter sw = new System.IO.StreamWriter(AFileName, false, System.Text.Encoding.Default);
try
{
sw.Write("#表格配置档案");
sw.Close();
}
catch
{
throw (new ApplicationException("Ini文件不存在"));
}
}
//必须是完全路径,不能是相对路径
FileName = fileInfo.FullName;
}
//写INI文件
public void WriteString(string Section, string Ident, string Value)
{
if (!WritePrivateProfileString(Section, Ident, Value, FileName))
{
throw (new ApplicationException("写Ini文件出错"));
}
}
//读取INI文件指定
public string ReadString(string Section, string Ident, string Default)
{
Byte[] Buffer = new Byte[65535];
int bufLen = GetPrivateProfileString(Section, Ident, Default, Buffer, Buffer.GetUpperBound(0), FileName);
//必须设定0(系统默认的代码页)的编码方式,否则无法支持中文
string s = Encoding.GetEncoding(0).GetString(Buffer);
s = s.Substring(0, bufLen);
return s.Trim();
}
//读整数
public int ReadInteger(string Section, string Ident, int Default)
{
string intStr = ReadString(Section, Ident, Convert.ToString(Default));
try
{
return Convert.ToInt32(intStr);
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
return Default;
}
}
//写整数
public void WriteInteger(string Section, string Ident, int Value)
{
WriteString(Section, Ident, Value.ToString());
}
//读布尔
public bool ReadBool(string Section, string Ident, bool Default)
{
try
{
return Convert.ToBoolean(ReadString(Section, Ident, Convert.ToString(Default)));
}
catch (Exception ex)
{
Console.WriteLine(ex.Message);
return Default;
}
}
//写Bool
public void WriteBool(string Section, string Ident, bool Value)
{
WriteString(Section, Ident, Convert.ToString(Value));
}
//从Ini文件中,将指定的Section名称中的所有Ident添加到列表中
public void ReadSection(string Section, StringCollection Idents)
{
Byte[] Buffer = new Byte[16384];
//Idents.Clear();
int bufLen = GetPrivateProfileString(Section, null, null, Buffer, Buffer.GetUpperBound(0),
FileName);
//对Section进行解析
GetStringsFromBuffer(Buffer, bufLen, Idents);
}
private void GetStringsFromBuffer(Byte[] Buffer, int bufLen, StringCollection Strings)
{
Strings.Clear();
if (bufLen != 0)
{
int start = 0;
for (int i = 0; i < bufLen; i++)
{
if ((Buffer[i] == 0) && ((i - start) > 0))
{
String s = Encoding.GetEncoding(0).GetString(Buffer, start, i - start);
Strings.Add(s);
start = i + 1;
}
}
}
}
//从Ini文件中,读取所有的Sections的名称
public void ReadSections(StringCollection SectionList)
{
//Note:必须得用Bytes来实现,StringBuilder只能取到第一个Section
byte[] Buffer = new byte[65535];
int bufLen = 0;
bufLen = GetPrivateProfileString(null, null, null, Buffer,
Buffer.GetUpperBound(0), FileName);
GetStringsFromBuffer(Buffer, bufLen, SectionList);
}
//读取指定的Section的所有Value到列表中
public void ReadSectionValues(string Section, NameValueCollection Values)
{
StringCollection KeyList = new StringCollection();
ReadSection(Section, KeyList);
Values.Clear();
foreach (string key in KeyList)
{
Values.Add(key, ReadString(Section, key, ""));
}
}
////读取指定的Section的所有Value到列表中,
//public void ReadSectionValues(string Section, NameValueCollection Values,char splitString)
//{  string sectionValue;
//  string[] sectionValueSplit;
//  StringCollection KeyList = new StringCollection();
//  ReadSection(Section, KeyList);
//  Values.Clear();
//  foreach (string key in KeyList)
//  {
//    sectionValue=ReadString(Section, key, "");
//    sectionValueSplit=sectionValue.Split(splitString);
//    Values.Add(key, sectionValueSplit[0].ToString(),sectionValueSplit[1].ToString());
//  }
//}
//清除某个Section
public void EraseSection(string Section)
{
//
if (!WritePrivateProfileString(Section, null, null, FileName))
{
throw (new ApplicationException("无法清除Ini文件中的Section"));
}
}
//删除某个Section下的键
public void DeleteKey(string Section, string Ident)
{
WritePrivateProfileString(Section, Ident, null, FileName);
}
//Note:对于Win9X,来说需要实现UpdateFile方法将缓冲中的数据写入文件
//在Win NT, 2000和XP上,都是直接写文件,没有缓冲,所以,无须实现UpdateFile
//执行完对Ini文件的修改之后,应该调用本方法更新缓冲区。
public void UpdateFile()
{
WritePrivateProfileString(null, null, null, FileName);
}
//检查某个Section下的某个键值是否存在
public bool ValueExists(string Section, string Ident)
{
//
StringCollection Idents = new StringCollection();
ReadSection(Section, Idents);
return Idents.IndexOf(Ident) > -1;
}
//确保资源的释放
~IniFile()
{
UpdateFile();
}
}
}

17
nocr/Program.cs

@ -0,0 +1,17 @@
namespace nocr
{
internal static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
// To customize application configuration such as set high DPI settings or default font,
// see https://aka.ms/applicationconfiguration.
ApplicationConfiguration.Initialize();
Application.Run(new Form1());
}
}
}

12
nocr/Properties/PublishProfiles/FolderProfile.pubxml

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project>
<PropertyGroup>
<Configuration>Release</Configuration>
<Platform>Any CPU</Platform>
<PublishDir>bin\Release\net6.0-windows\publish\</PublishDir>
<PublishProtocol>FileSystem</PublishProtocol>
</PropertyGroup>
</Project>

9
nocr/Properties/PublishProfiles/FolderProfile.pubxml.user

@ -0,0 +1,9 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
https://go.microsoft.com/fwlink/?LinkID=208121.
-->
<Project>
<PropertyGroup>
<History>True|2022-03-19T12:49:29.3031191Z;</History>
</PropertyGroup>
</Project>

63
nocr/Properties/Resources.Designer.cs

@ -0,0 +1,63 @@
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
namespace nocr.Properties {
using System;
/// <summary>
/// 一个强类型的资源类,用于查找本地化的字符串等。
/// </summary>
// 此类是由 StronglyTypedResourceBuilder
// 类通过类似于 ResGen 或 Visual Studio 的工具自动生成的。
// 若要添加或移除成员,请编辑 .ResX 文件,然后重新运行 ResGen
// (以 /str 作为命令选项),或重新生成 VS 项目。
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "17.0.0.0")]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
internal class Resources {
private static global::System.Resources.ResourceManager resourceMan;
private static global::System.Globalization.CultureInfo resourceCulture;
[global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
internal Resources() {
}
/// <summary>
/// 返回此类使用的缓存的 ResourceManager 实例。
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Resources.ResourceManager ResourceManager {
get {
if (object.ReferenceEquals(resourceMan, null)) {
global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("nocr.Properties.Resources", typeof(Resources).Assembly);
resourceMan = temp;
}
return resourceMan;
}
}
/// <summary>
/// 重写当前线程的 CurrentUICulture 属性,对
/// 使用此强类型资源类的所有资源查找执行重写。
/// </summary>
[global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
internal static global::System.Globalization.CultureInfo Culture {
get {
return resourceCulture;
}
set {
resourceCulture = value;
}
}
}
}

120
nocr/Properties/Resources.resx

@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

BIN
nocr/bin/Debug/net6.0-windows/Newtonsoft.Json.dll

Binary file not shown.

41
nocr/bin/Debug/net6.0-windows/nocr.deps.json

@ -0,0 +1,41 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"nocr/1.0.0": {
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"runtime": {
"nocr.dll": {}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
"libraries": {
"nocr/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

BIN
nocr/bin/Debug/net6.0-windows/nocr.dll

Binary file not shown.

BIN
nocr/bin/Debug/net6.0-windows/nocr.exe

Binary file not shown.

BIN
nocr/bin/Debug/net6.0-windows/nocr.pdb

Binary file not shown.

15
nocr/bin/Debug/net6.0-windows/nocr.runtimeconfig.json

@ -0,0 +1,15 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
}
]
}
}

3
nocr/bin/Debug/net6.0-windows/settings.ini

@ -0,0 +1,3 @@
[account]
apikey=zzMsFjeXqci8GTO2Trhz3He6
secretkey=cyFMhGEjw6OuCFMECmH5xzMff9sm8DpT

BIN
nocr/bin/Debug/nocr.1.0.0.nupkg

Binary file not shown.

BIN
nocr/bin/Release/net6.0-windows/Newtonsoft.Json.dll

Binary file not shown.

41
nocr/bin/Release/net6.0-windows/nocr.deps.json

@ -0,0 +1,41 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"nocr/1.0.0": {
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"runtime": {
"nocr.dll": {}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
"libraries": {
"nocr/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

BIN
nocr/bin/Release/net6.0-windows/nocr.dll

Binary file not shown.

BIN
nocr/bin/Release/net6.0-windows/nocr.exe

Binary file not shown.

BIN
nocr/bin/Release/net6.0-windows/nocr.pdb

Binary file not shown.

18
nocr/bin/Release/net6.0-windows/nocr.runtimeconfig.json

@ -0,0 +1,18 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
}
],
"configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false
}
}
}

BIN
nocr/bin/Release/net6.0-windows/publish/Newtonsoft.Json.dll

Binary file not shown.

41
nocr/bin/Release/net6.0-windows/publish/nocr.deps.json

@ -0,0 +1,41 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"nocr/1.0.0": {
"dependencies": {
"Newtonsoft.Json": "13.0.1"
},
"runtime": {
"nocr.dll": {}
}
},
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
"libraries": {
"nocr/1.0.0": {
"type": "project",
"serviceable": false,
"sha512": ""
},
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

BIN
nocr/bin/Release/net6.0-windows/publish/nocr.dll

Binary file not shown.

BIN
nocr/bin/Release/net6.0-windows/publish/nocr.exe

Binary file not shown.

BIN
nocr/bin/Release/net6.0-windows/publish/nocr.pdb

Binary file not shown.

18
nocr/bin/Release/net6.0-windows/publish/nocr.runtimeconfig.json

@ -0,0 +1,18 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
}
],
"configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false
}
}
}

3
nocr/bin/Release/net6.0-windows/settings.ini

@ -0,0 +1,3 @@
[account]
apikey=zzMsFjeXqci8GTO2Trhz3He6
secretkey=cyFMhGEjw6OuCFMECmH5xzMff9sm8DpT

BIN
nocr/favicon16.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

BIN
nocr/favicon48.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.4 KiB

BIN
nocr/favicon64.ico

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

35
nocr/nocr.csproj

@ -0,0 +1,35 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net6.0-windows</TargetFramework>
<Nullable>enable</Nullable>
<UseWindowsForms>true</UseWindowsForms>
<ImplicitUsings>enable</ImplicitUsings>
<ApplicationIcon>favicon48.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Content Include="favicon48.ico" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
</ItemGroup>
<ItemGroup>
<Compile Update="Properties\Resources.Designer.cs">
<DesignTime>True</DesignTime>
<AutoGen>True</AutoGen>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<EmbeddedResource Update="Properties\Resources.resx">
<Generator>ResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.cs</LastGenOutput>
</EmbeddedResource>
</ItemGroup>
</Project>

17
nocr/nocr.csproj.user

@ -0,0 +1,17 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<_LastSelectedProfileId>D:\code\nocr\nocr\nocr\Properties\PublishProfiles\FolderProfile.pubxml</_LastSelectedProfileId>
</PropertyGroup>
<ItemGroup>
<Compile Update="Form1.cs">
<SubType>Form</SubType>
</Compile>
<Compile Update="Form2.cs">
<SubType>Form</SubType>
</Compile>
<Compile Update="Form3.cs">
<SubType>Form</SubType>
</Compile>
</ItemGroup>
</Project>

4
nocr/obj/Debug/net6.0-windows/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs

@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = "")]

BIN
nocr/obj/Debug/net6.0-windows/TempPE/Properties.Resources.Designer.cs.dll

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/apphost.exe

Binary file not shown.

25
nocr/obj/Debug/net6.0-windows/nocr.AssemblyInfo.cs

@ -0,0 +1,25 @@
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("nocr")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("nocr")]
[assembly: System.Reflection.AssemblyTitleAttribute("nocr")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
[assembly: System.Runtime.Versioning.TargetPlatformAttribute("Windows7.0")]
[assembly: System.Runtime.Versioning.SupportedOSPlatformAttribute("Windows7.0")]
// 由 MSBuild WriteCodeFragment 类生成。

1
nocr/obj/Debug/net6.0-windows/nocr.AssemblyInfoInputs.cache

@ -0,0 +1 @@
d42bfbe80b879b1bfc92f8e96893459b3bcf63c9

BIN
nocr/obj/Debug/net6.0-windows/nocr.Form1.resources

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/nocr.Form2.resources

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/nocr.Form3.resources

Binary file not shown.

16
nocr/obj/Debug/net6.0-windows/nocr.GeneratedMSBuildEditorConfig.editorconfig

@ -0,0 +1,16 @@
is_global = true
build_property.ApplicationManifest =
build_property.StartupObject =
build_property.ApplicationDefaultFont =
build_property.ApplicationHighDpiMode =
build_property.ApplicationUseCompatibleTextRendering =
build_property.ApplicationVisualStyles =
build_property.TargetFramework = net6.0-windows
build_property.TargetPlatformMinVersion = 7.0
build_property.UsingMicrosoftNETSdkWeb =
build_property.ProjectTypeGuids =
build_property.InvariantGlobalization =
build_property.PlatformNeutralAssembly =
build_property._SupportedPlatformList = Linux,macOS,Windows
build_property.RootNamespace = nocr
build_property.ProjectDir = D:\code\nocr\nocr\nocr\

10
nocr/obj/Debug/net6.0-windows/nocr.GlobalUsings.g.cs

@ -0,0 +1,10 @@
// <auto-generated/>
global using global::System;
global using global::System.Collections.Generic;
global using global::System.Drawing;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Threading;
global using global::System.Threading.Tasks;
global using global::System.Windows.Forms;

BIN
nocr/obj/Debug/net6.0-windows/nocr.Properties.Resources.resources

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/nocr.assets.cache

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/nocr.csproj.AssemblyReference.cache

Binary file not shown.

0
nocr/obj/Debug/net6.0-windows/nocr.csproj.BuildWithSkipAnalyzers

0
nocr/obj/Debug/net6.0-windows/nocr.csproj.CopyComplete

1
nocr/obj/Debug/net6.0-windows/nocr.csproj.CoreCompileInputs.cache

@ -0,0 +1 @@
83cc939cbbdee80ab8a64e3853310dc646cae55e

22
nocr/obj/Debug/net6.0-windows/nocr.csproj.FileListAbsolute.txt

@ -0,0 +1,22 @@
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.exe
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.deps.json
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.runtimeconfig.json
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.dll
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.pdb
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.csproj.AssemblyReference.cache
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.Form1.resources
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.csproj.GenerateResource.cache
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.GeneratedMSBuildEditorConfig.editorconfig
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.AssemblyInfoInputs.cache
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.AssemblyInfo.cs
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.csproj.CoreCompileInputs.cache
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.dll
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\refint\nocr.dll
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.pdb
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.genruntimeconfig.cache
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\ref\nocr.dll
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.Form2.resources
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.Form3.resources
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.Properties.Resources.resources
D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\Newtonsoft.Json.dll
D:\code\nocr\nocr\nocr\obj\Debug\net6.0-windows\nocr.csproj.CopyComplete

BIN
nocr/obj/Debug/net6.0-windows/nocr.csproj.GenerateResource.cache

Binary file not shown.

28
nocr/obj/Debug/net6.0-windows/nocr.designer.deps.json

@ -0,0 +1,28 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
"libraries": {
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

22
nocr/obj/Debug/net6.0-windows/nocr.designer.runtimeconfig.json

@ -0,0 +1,22 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
}
],
"additionalProbingPaths": [
"C:\\Users\\Administrator\\.dotnet\\store\\|arch|\\|tfm|",
"C:\\Users\\Administrator\\.nuget\\packages"
],
"configProperties": {
"Microsoft.NETCore.DotNetHostPolicy.SetAppPaths": true
}
}
}

BIN
nocr/obj/Debug/net6.0-windows/nocr.dll

Binary file not shown.

1
nocr/obj/Debug/net6.0-windows/nocr.genruntimeconfig.cache

@ -0,0 +1 @@
c26b02fd28522a82de0a6e294269639cad55da30

BIN
nocr/obj/Debug/net6.0-windows/nocr.pdb

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/ref/nocr.dll

Binary file not shown.

BIN
nocr/obj/Debug/net6.0-windows/refint/nocr.dll

Binary file not shown.

23
nocr/obj/Debug/nocr.1.0.0.nuspec

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2012/06/nuspec.xsd">
<metadata>
<id>nocr</id>
<version>1.0.0</version>
<authors>nocr</authors>
<description>Package Description</description>
<dependencies>
<group targetFramework="net6.0-windows7.0">
<dependency id="Newtonsoft.Json" version="13.0.1" exclude="Build,Analyzers" />
</group>
</dependencies>
<frameworkReferences>
<group targetFramework="net6.0-windows7.0">
<frameworkReference name="Microsoft.WindowsDesktop.App.WindowsForms" />
</group>
</frameworkReferences>
</metadata>
<files>
<file src="D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.runtimeconfig.json" target="lib\net6.0-windows7.0\nocr.runtimeconfig.json" />
<file src="D:\code\nocr\nocr\nocr\bin\Debug\net6.0-windows\nocr.dll" target="lib\net6.0-windows7.0\nocr.dll" />
</files>
</package>

4
nocr/obj/Release/net6.0-windows/.NETCoreApp,Version=v6.0.AssemblyAttributes.cs

@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v6.0", FrameworkDisplayName = "")]

6
nocr/obj/Release/net6.0-windows/PublishOutputs.1964e136d2.txt

@ -0,0 +1,6 @@
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\nocr.exe
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\nocr.dll
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\nocr.deps.json
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\nocr.runtimeconfig.json
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\nocr.pdb
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\publish\Newtonsoft.Json.dll

BIN
nocr/obj/Release/net6.0-windows/apphost.exe

Binary file not shown.

25
nocr/obj/Release/net6.0-windows/nocr.AssemblyInfo.cs

@ -0,0 +1,25 @@
//------------------------------------------------------------------------------
// <auto-generated>
// 此代码由工具生成。
// 运行时版本:4.0.30319.42000
//
// 对此文件的更改可能会导致不正确的行为,并且如果
// 重新生成代码,这些更改将会丢失。
// </auto-generated>
//------------------------------------------------------------------------------
using System;
using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("nocr")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Release")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0")]
[assembly: System.Reflection.AssemblyProductAttribute("nocr")]
[assembly: System.Reflection.AssemblyTitleAttribute("nocr")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
[assembly: System.Runtime.Versioning.TargetPlatformAttribute("Windows7.0")]
[assembly: System.Runtime.Versioning.SupportedOSPlatformAttribute("Windows7.0")]
// 由 MSBuild WriteCodeFragment 类生成。

1
nocr/obj/Release/net6.0-windows/nocr.AssemblyInfoInputs.cache

@ -0,0 +1 @@
cd8034ce82d74cd83f55792d72fdd3122f266937

BIN
nocr/obj/Release/net6.0-windows/nocr.Form1.resources

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/nocr.Form2.resources

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/nocr.Form3.resources

Binary file not shown.

16
nocr/obj/Release/net6.0-windows/nocr.GeneratedMSBuildEditorConfig.editorconfig

@ -0,0 +1,16 @@
is_global = true
build_property.ApplicationManifest =
build_property.StartupObject =
build_property.ApplicationDefaultFont =
build_property.ApplicationHighDpiMode =
build_property.ApplicationUseCompatibleTextRendering =
build_property.ApplicationVisualStyles =
build_property.TargetFramework = net6.0-windows
build_property.TargetPlatformMinVersion = 7.0
build_property.UsingMicrosoftNETSdkWeb =
build_property.ProjectTypeGuids =
build_property.InvariantGlobalization =
build_property.PlatformNeutralAssembly =
build_property._SupportedPlatformList = Linux,macOS,Windows
build_property.RootNamespace = nocr
build_property.ProjectDir = D:\code\nocr\nocr\nocr\

10
nocr/obj/Release/net6.0-windows/nocr.GlobalUsings.g.cs

@ -0,0 +1,10 @@
// <auto-generated/>
global using global::System;
global using global::System.Collections.Generic;
global using global::System.Drawing;
global using global::System.IO;
global using global::System.Linq;
global using global::System.Net.Http;
global using global::System.Threading;
global using global::System.Threading.Tasks;
global using global::System.Windows.Forms;

BIN
nocr/obj/Release/net6.0-windows/nocr.Properties.Resources.resources

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/nocr.assets.cache

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/nocr.csproj.AssemblyReference.cache

Binary file not shown.

0
nocr/obj/Release/net6.0-windows/nocr.csproj.CopyComplete

1
nocr/obj/Release/net6.0-windows/nocr.csproj.CoreCompileInputs.cache

@ -0,0 +1 @@
f4c101af840192e0b4d9a6d022eba70c146d6b87

22
nocr/obj/Release/net6.0-windows/nocr.csproj.FileListAbsolute.txt

@ -0,0 +1,22 @@
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\nocr.exe
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\nocr.deps.json
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\nocr.runtimeconfig.json
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\nocr.dll
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\nocr.pdb
D:\code\nocr\nocr\nocr\bin\Release\net6.0-windows\Newtonsoft.Json.dll
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.csproj.AssemblyReference.cache
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.Form1.resources
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.Form2.resources
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.Form3.resources
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.Properties.Resources.resources
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.csproj.GenerateResource.cache
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.GeneratedMSBuildEditorConfig.editorconfig
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.AssemblyInfoInputs.cache
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.AssemblyInfo.cs
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.csproj.CoreCompileInputs.cache
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.csproj.CopyComplete
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.dll
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\refint\nocr.dll
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.pdb
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\nocr.genruntimeconfig.cache
D:\code\nocr\nocr\nocr\obj\Release\net6.0-windows\ref\nocr.dll

BIN
nocr/obj/Release/net6.0-windows/nocr.csproj.GenerateResource.cache

Binary file not shown.

28
nocr/obj/Release/net6.0-windows/nocr.designer.deps.json

@ -0,0 +1,28 @@
{
"runtimeTarget": {
"name": ".NETCoreApp,Version=v6.0",
"signature": ""
},
"compilationOptions": {},
"targets": {
".NETCoreApp,Version=v6.0": {
"Newtonsoft.Json/13.0.1": {
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {
"assemblyVersion": "13.0.0.0",
"fileVersion": "13.0.1.25517"
}
}
}
}
},
"libraries": {
"Newtonsoft.Json/13.0.1": {
"type": "package",
"serviceable": true,
"sha512": "sha512-ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"path": "newtonsoft.json/13.0.1",
"hashPath": "newtonsoft.json.13.0.1.nupkg.sha512"
}
}
}

23
nocr/obj/Release/net6.0-windows/nocr.designer.runtimeconfig.json

@ -0,0 +1,23 @@
{
"runtimeOptions": {
"tfm": "net6.0",
"frameworks": [
{
"name": "Microsoft.NETCore.App",
"version": "6.0.0"
},
{
"name": "Microsoft.WindowsDesktop.App",
"version": "6.0.0"
}
],
"additionalProbingPaths": [
"C:\\Users\\Administrator\\.dotnet\\store\\|arch|\\|tfm|",
"C:\\Users\\Administrator\\.nuget\\packages"
],
"configProperties": {
"System.Reflection.Metadata.MetadataUpdater.IsSupported": false,
"Microsoft.NETCore.DotNetHostPolicy.SetAppPaths": true
}
}
}

BIN
nocr/obj/Release/net6.0-windows/nocr.dll

Binary file not shown.

1
nocr/obj/Release/net6.0-windows/nocr.genruntimeconfig.cache

@ -0,0 +1 @@
78b042c1c9b54d1e71f81fa8a3a381becde20fa3

BIN
nocr/obj/Release/net6.0-windows/nocr.pdb

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/ref/nocr.dll

Binary file not shown.

BIN
nocr/obj/Release/net6.0-windows/refint/nocr.dll

Binary file not shown.

71
nocr/obj/nocr.csproj.nuget.dgspec.json

@ -0,0 +1,71 @@
{
"format": 1,
"restore": {
"D:\\code\\nocr\\nocr\\nocr\\nocr.csproj": {}
},
"projects": {
"D:\\code\\nocr\\nocr\\nocr\\nocr.csproj": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "D:\\code\\nocr\\nocr\\nocr\\nocr.csproj",
"projectName": "nocr",
"projectPath": "D:\\code\\nocr\\nocr\\nocr\\nocr.csproj",
"packagesPath": "C:\\Users\\Administrator\\.nuget\\packages\\",
"outputPath": "D:\\code\\nocr\\nocr\\nocr\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\Administrator\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"net6.0-windows7.0"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net6.0-windows7.0": {
"targetAlias": "net6.0-windows",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"net6.0-windows7.0": {
"targetAlias": "net6.0-windows",
"dependencies": {
"Newtonsoft.Json": {
"target": "Package",
"version": "[13.0.1, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
},
"Microsoft.WindowsDesktop.App.WindowsForms": {
"privateAssets": "none"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.201\\RuntimeIdentifierGraph.json"
}
}
}
}
}

15
nocr/obj/nocr.csproj.nuget.g.props

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<RestoreSuccess Condition=" '$(RestoreSuccess)' == '' ">True</RestoreSuccess>
<RestoreTool Condition=" '$(RestoreTool)' == '' ">NuGet</RestoreTool>
<ProjectAssetsFile Condition=" '$(ProjectAssetsFile)' == '' ">$(MSBuildThisFileDirectory)project.assets.json</ProjectAssetsFile>
<NuGetPackageRoot Condition=" '$(NuGetPackageRoot)' == '' ">$(UserProfile)\.nuget\packages\</NuGetPackageRoot>
<NuGetPackageFolders Condition=" '$(NuGetPackageFolders)' == '' ">C:\Users\Administrator\.nuget\packages\</NuGetPackageFolders>
<NuGetProjectStyle Condition=" '$(NuGetProjectStyle)' == '' ">PackageReference</NuGetProjectStyle>
<NuGetToolVersion Condition=" '$(NuGetToolVersion)' == '' ">6.1.0</NuGetToolVersion>
</PropertyGroup>
<ItemGroup Condition=" '$(ExcludeRestorePackageImports)' != 'true' ">
<SourceRoot Include="C:\Users\Administrator\.nuget\packages\" />
</ItemGroup>
</Project>

2
nocr/obj/nocr.csproj.nuget.g.targets

@ -0,0 +1,2 @@
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />

116
nocr/obj/project.assets.json

@ -0,0 +1,116 @@
{
"version": 3,
"targets": {
"net6.0-windows7.0": {
"Newtonsoft.Json/13.0.1": {
"type": "package",
"compile": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
},
"runtime": {
"lib/netstandard2.0/Newtonsoft.Json.dll": {}
}
}
}
},
"libraries": {
"Newtonsoft.Json/13.0.1": {
"sha512": "ppPFpBcvxdsfUonNcvITKqLl3bqxWbDCZIzDWHzjpdAHRFfZe0Dw9HmA0+za13IdyrgJwpkDTDA9fHaxOrt20A==",
"type": "package",
"path": "newtonsoft.json/13.0.1",
"files": [
".nupkg.metadata",
".signature.p7s",
"LICENSE.md",
"lib/net20/Newtonsoft.Json.dll",
"lib/net20/Newtonsoft.Json.xml",
"lib/net35/Newtonsoft.Json.dll",
"lib/net35/Newtonsoft.Json.xml",
"lib/net40/Newtonsoft.Json.dll",
"lib/net40/Newtonsoft.Json.xml",
"lib/net45/Newtonsoft.Json.dll",
"lib/net45/Newtonsoft.Json.xml",
"lib/netstandard1.0/Newtonsoft.Json.dll",
"lib/netstandard1.0/Newtonsoft.Json.xml",
"lib/netstandard1.3/Newtonsoft.Json.dll",
"lib/netstandard1.3/Newtonsoft.Json.xml",
"lib/netstandard2.0/Newtonsoft.Json.dll",
"lib/netstandard2.0/Newtonsoft.Json.xml",
"newtonsoft.json.13.0.1.nupkg.sha512",
"newtonsoft.json.nuspec",
"packageIcon.png"
]
}
},
"projectFileDependencyGroups": {
"net6.0-windows7.0": [
"Newtonsoft.Json >= 13.0.1"
]
},
"packageFolders": {
"C:\\Users\\Administrator\\.nuget\\packages\\": {}
},
"project": {
"version": "1.0.0",
"restore": {
"projectUniqueName": "D:\\code\\nocr\\nocr\\nocr\\nocr.csproj",
"projectName": "nocr",
"projectPath": "D:\\code\\nocr\\nocr\\nocr\\nocr.csproj",
"packagesPath": "C:\\Users\\Administrator\\.nuget\\packages\\",
"outputPath": "D:\\code\\nocr\\nocr\\nocr\\obj\\",
"projectStyle": "PackageReference",
"configFilePaths": [
"C:\\Users\\Administrator\\AppData\\Roaming\\NuGet\\NuGet.Config",
"C:\\Program Files (x86)\\NuGet\\Config\\Microsoft.VisualStudio.Offline.config"
],
"originalTargetFrameworks": [
"net6.0-windows7.0"
],
"sources": {
"C:\\Program Files (x86)\\Microsoft SDKs\\NuGetPackages\\": {},
"https://api.nuget.org/v3/index.json": {}
},
"frameworks": {
"net6.0-windows7.0": {
"targetAlias": "net6.0-windows",
"projectReferences": {}
}
},
"warningProperties": {
"warnAsError": [
"NU1605"
]
}
},
"frameworks": {
"net6.0-windows7.0": {
"targetAlias": "net6.0-windows",
"dependencies": {
"Newtonsoft.Json": {
"target": "Package",
"version": "[13.0.1, )"
}
},
"imports": [
"net461",
"net462",
"net47",
"net471",
"net472",
"net48"
],
"assetTargetFallback": true,
"warn": true,
"frameworkReferences": {
"Microsoft.NETCore.App": {
"privateAssets": "all"
},
"Microsoft.WindowsDesktop.App.WindowsForms": {
"privateAssets": "none"
}
},
"runtimeIdentifierGraphPath": "C:\\Program Files\\dotnet\\sdk\\6.0.201\\RuntimeIdentifierGraph.json"
}
}
}
}

10
nocr/obj/project.nuget.cache

@ -0,0 +1,10 @@
{
"version": 2,
"dgSpecHash": "rx4E4P1iKGjKUgRNh9X6UFFeM3uboL44gcK18rjJw4LlAaXjp7XIfPK+AB+cB9T/cD61MnwdplBBIJW5XU5mvw==",
"success": true,
"projectFilePath": "D:\\code\\nocr\\nocr\\nocr\\nocr.csproj",
"expectedPackageFiles": [
"C:\\Users\\Administrator\\.nuget\\packages\\newtonsoft.json\\13.0.1\\newtonsoft.json.13.0.1.nupkg.sha512"
],
"logs": []
}

3
settings.ini

@ -0,0 +1,3 @@
[account]
apikey=zzMsFjeXqci8GTO2Trhz3He6
secretkey=cyFMhGEjw6OuCFMECmH5xzMff9sm8DpT
Loading…
Cancel
Save