GeneralSettingDialog.cs 171 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824
  1. using PaintDotNet.Base.CommTool;
  2. using PaintDotNet.DbOpreate.DbBll;
  3. using PaintDotNet.Base.SettingModel;
  4. using System;
  5. using System.Drawing;
  6. using System.IO;
  7. using System.Text.RegularExpressions;
  8. using System.Windows.Forms;
  9. using System.Linq;
  10. using System.Collections;
  11. using PaintDotNet.Instrument;
  12. namespace PaintDotNet.Setting
  13. {
  14. /// <summary>
  15. /// 设置->常规设置
  16. /// </summary>
  17. internal partial class GeneralSettingDialog : PdnBaseForm
  18. {
  19. private UserInfoModel userInfo = Startup.instance.userInfo;
  20. private ConfigModel config = Startup.instance.configModel;
  21. private GroupBox groupBox10;
  22. private Button button8;
  23. private TextBox textBox6;
  24. private Button button7;
  25. private TextBox textBox5;
  26. private Button button6;
  27. private TextBox textBox4;
  28. private Label label20;
  29. private Label label19;
  30. private Label label18;
  31. private string pattern = @"^\d+(\.\d)?$";
  32. private ListView listView3;
  33. private Label label21;
  34. private Label label22;
  35. private Label label23;
  36. private Label label24;
  37. private Label label25;
  38. private Panel panel1;
  39. private RadioButton radioButton7;
  40. private RadioButton radioButton6;
  41. private Panel panel2;
  42. private RadioButton radioButton8;
  43. private RadioButton radioButton9;
  44. private Panel panel3;
  45. private RadioButton radioButton10;
  46. private RadioButton radioButton11;
  47. private Panel panel4;
  48. private RadioButton radioButton12;
  49. private RadioButton radioButton13;
  50. private Panel panel5;
  51. private RadioButton radioButton14;
  52. private RadioButton radioButton15;
  53. private GroupBox groupBox15;
  54. private GroupBox groupBox16;
  55. private Label label28;
  56. private Label label27;
  57. private Label label26;
  58. private NumericUpDown numericUpDown1;
  59. private ComboBox comboBox2;
  60. private Button panel6;
  61. private AppWorkspace appWorkspace;
  62. private Button button17;
  63. private Button button16;
  64. private Button button15;
  65. private Button button14;
  66. private GroupBox groupBox13;
  67. private Button button19;
  68. private Button button18;
  69. private GroupBox groupBox14;
  70. private GroupBox groupBox17;
  71. private Button button20;
  72. private Button button21;
  73. private GroupBox groupBoxCaptureSave;
  74. private GroupBox groupBox18;
  75. private Button button22;
  76. private CheckBox ckbSaveAndOpen;
  77. public GroupBox groupBox19;
  78. private Button btn_Del;
  79. private ComboBox comboBox_Name;
  80. private Label label29;
  81. private Button btn_SaveAs;
  82. private Button btn_Save;
  83. private TextBox textBox8;
  84. private TextBox textBox7;
  85. private Label label31;
  86. private Label label30;
  87. private RadioButton ckNotSave;
  88. private RadioButton ckAutoSave;
  89. private RadioButton ckbSave;
  90. private Button button23;
  91. private TextBox textBox9;
  92. private Label label32;
  93. public GroupBox groupBox20;
  94. private NumericUpDown numericUpDown3;
  95. private NumericUpDown numericUpDown2;
  96. private Label label35;
  97. private Label label34;
  98. private Label label33;
  99. private ComboBox comboBox3;
  100. private CheckBox checkBox10;
  101. PaintDotNet.ColorsForm colorsForm;
  102. public GeneralSettingDialog(AppWorkspace appWorkspace, int status = 0)
  103. {
  104. this.appWorkspace = appWorkspace;
  105. InitializeComponent();
  106. InitializeLanguageText();
  107. BasicSettings();
  108. UserInformation();
  109. NameRules();
  110. ChooseLanguage();
  111. LeftMenu(status);
  112. PointList();
  113. CameraSettings();
  114. OrientationSetting();
  115. GuideSetting();
  116. //
  117. //画板
  118. //
  119. this.colorsForm = new ColorsForm();
  120. this.colorsForm.StartPosition = FormStartPosition.CenterScreen;
  121. this.colorsForm.UserPrimaryColorChanged += new ColorEventHandler(this.colorsFormUserPrimaryColorChanged);
  122. this.comboBox3.DataSource = InvariantData.unitparameters.Values.ToList();
  123. //this.comboBox3.DisplayMember = "value";
  124. this.comboBox3.SelectedIndex = 1;
  125. numericUpDown3.Value = config.MaxHeight;
  126. numericUpDown2.Value = config.MaxWidth;
  127. comboBox3.SelectedIndex = config.MaxUnit;
  128. checkBox10.Checked = config.MaxLocked;
  129. }
  130. #region [左侧菜单]
  131. public void LeftMenu(int status = 0)
  132. {
  133. //
  134. // 设置Dialog属性
  135. //
  136. ShowInTaskbar = false;
  137. //
  138. // 设置listbox的集合和属性
  139. //
  140. listBox1.Items.AddRange(InvariantData.settingName);
  141. if (status == 1)
  142. {
  143. listBox1.SetSelected(2, true);
  144. }
  145. else
  146. {
  147. listBox1.SetSelected(0, true);
  148. }
  149. }
  150. #endregion
  151. #region [命名规则]
  152. public void NameRules()
  153. {
  154. //
  155. // 设置comboBox1的集合和属性
  156. //
  157. comboBox1.Items.AddRange(InvariantData.numberNum);
  158. comboBox_Name_SelectedIndex();
  159. //当前使用
  160. comboBox_Name_Refresh();
  161. #region [设置listView1]
  162. listView1.View = View.Details;
  163. listView1.Columns.Add("1", 0, HorizontalAlignment.Center);
  164. listView1.Columns.Add(PdnResources.GetString("Menu.Set.Generalsettings.format.text"), 60, HorizontalAlignment.Center);
  165. listView1.Columns.Add(PdnResources.GetString("Menu.instruction.text"), 316, HorizontalAlignment.Center);
  166. listView1.BeginUpdate();
  167. var dict = InvariantData.parameterList;
  168. foreach (var s in dict)
  169. {
  170. ListViewItem lvi1 = new ListViewItem();
  171. lvi1.Text = s.Key;
  172. lvi1.SubItems.Add(s.Key);
  173. lvi1.SubItems.Add(s.Value);
  174. listView1.Items.Add(lvi1);
  175. }
  176. listView1.EndUpdate();
  177. #endregion [设置listView1]
  178. }
  179. CreateNameDialog dialog;
  180. /// <summary>
  181. /// 命名空间另存
  182. /// </summary>
  183. /// <param name="sender"></param>
  184. /// <param name="e"></param>
  185. private void btn_SaveAs_Click(object sender, EventArgs e)
  186. {
  187. dialog = new CreateNameDialog(this);
  188. dialog.Text = PdnResources.GetString("Menu.Set.Watermarksettings.Newstyle.text");
  189. dialog.StartPosition = FormStartPosition.CenterParent;
  190. dialog.ShowDialog();
  191. }
  192. public override void GetCreateName(string name)
  193. {
  194. string[] lstName = config.LstNaming.Select(a => a.name).ToArray();
  195. bool exists = ((IList)lstName).Contains(name);
  196. if (exists)
  197. {
  198. MessageBox.Show("名称重复!");
  199. return;
  200. }
  201. if (Inspect()) return;
  202. NamingMethod namingMethod = new NamingMethod();
  203. namingMethod.name = name;
  204. namingMethod.NamePrefix = textBox1.Text;
  205. namingMethod.NameFormat = textBox2.Text;
  206. namingMethod.NumberNum = Convert.ToInt32(comboBox1.SelectedItem);
  207. namingMethod.NameStatus = radioButton1.Checked == true ? 1 : 2;
  208. namingMethod.ContinueNum = radioButton1.Checked ? Convert.ToInt32(textBox3.Text) : 1;
  209. namingMethod.CharZ1 = textBox7.Text;
  210. namingMethod.CharZ2 = textBox8.Text;
  211. config.LstNaming.Add(namingMethod);
  212. config.CurrentName = name;
  213. //string[] arrs = System.Text.RegularExpressions.Regex.Split(textBox2.Text.Trim(), "%");
  214. //if (((IList)arrs).Contains("T1")) config.customTxt = "T1";
  215. //else if (((IList)arrs).Contains("T2")) config.customTxt = "T2";
  216. //else if (((IList)arrs).Contains("T3")) config.customTxt = "T3";
  217. //else config.customTxt = "";
  218. //config.CurrentName = name;
  219. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  220. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  221. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  222. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  223. comboBox_Name_Refresh();
  224. if (ImageIndexDialog.imageIndexDialog != null)
  225. ImageIndexDialog.imageIndexDialog.comboBox_Name_Refresh(config.CaptureSaveMode);
  226. comboBox_Name_SelectedIndexChanged(null,null);
  227. dialog.Close();
  228. }
  229. private bool Inspect()
  230. {
  231. bool chek = false;
  232. //if (string.IsNullOrEmpty(textBox1.Text))
  233. //{
  234. // MessageBox.Show(PdnResources.GetString("Menu.pleasewriteNameprefix.text"));
  235. // chek = true;
  236. //}
  237. if (string.IsNullOrEmpty(textBox2.Text))
  238. {
  239. MessageBox.Show(PdnResources.GetString("Menu.pleaseNameformat.text"));
  240. chek = true;
  241. }
  242. else
  243. {
  244. string[] arrs = System.Text.RegularExpressions.Regex.Split(textBox2.Text.Trim(), "%"/*@"(?<=\G.{2})(?!$)"*/);
  245. foreach (string text in arrs)
  246. {
  247. if (text == "") continue;
  248. //if (!text.Equals("%P") && !text.Equals("%I") && !text.Equals("%h") && !text.Equals("%m")
  249. // && !text.Equals("%s") && !text.Equals("%Y") && !text.Equals("%M") && !text.Equals("%D")
  250. // && !text.Equals("%G") && !text.Equals("%U") && !text.Equals("%T1") && !text.Equals("%T2") && !text.Equals("%T3"))
  251. if (!text.Equals("P") && !text.Equals("I") && !text.Equals("h") && !text.Equals("m")
  252. && !text.Equals("s") && !text.Equals("Y") && !text.Equals("M") && !text.Equals("D")
  253. && !text.Equals("G") && !text.Equals("U") && !text.Equals("N") && !text.Equals("E")
  254. && !text.Equals("T1") && !text.Equals("T2") && !text.Equals("T3")
  255. && !text.Equals("Z1") && !text.Equals("Z2") && !text.Equals("R"))
  256. {
  257. MessageBox.Show("名称格式不合法, 请检查");
  258. chek = true;
  259. }
  260. }
  261. if (Islegal())
  262. {
  263. MessageBox.Show("文件名称中不能包含 \\ / : * ? \" < > | ");
  264. chek = true;
  265. }
  266. }
  267. if (radioButton1.Checked && !(Regex.IsMatch(textBox3.Text, pattern)))
  268. {
  269. MessageBox.Show(PdnResources.GetString("Menu.Numberscanbeentet.text") + "!");
  270. chek = true;
  271. }
  272. return chek;
  273. }
  274. /// <summary>
  275. /// 刷新名称
  276. /// </summary>
  277. private void comboBox_Name_Refresh()
  278. {
  279. this.comboBox_Name.SelectedIndexChanged -= new System.EventHandler(this.comboBox_Name_SelectedIndexChanged);
  280. string[] lstName = config.LstNaming.Select(a => a.name).ToArray();
  281. this.comboBox_Name.DataSource = lstName;
  282. this.comboBox_Name.Text = config.CurrentName;
  283. this.comboBox_Name.SelectedIndexChanged += new System.EventHandler(this.comboBox_Name_SelectedIndexChanged);
  284. }
  285. /// <summary>
  286. /// 条目选择后刷新
  287. /// </summary>
  288. private void comboBox_Name_SelectedIndex()
  289. {
  290. string CurrentName = config.CurrentName;
  291. if (config.LstNaming.Count > 0)
  292. {
  293. foreach (NamingMethod item in config.LstNaming)
  294. {
  295. if (CurrentName.Equals(item.name))
  296. {
  297. textBox1.Text = item.NamePrefix;
  298. textBox1.MaxLength = 20;
  299. textBox2.Text = item.NameFormat;
  300. //radioButton1.Checked = config.NameStatus == 1 ? true : false;
  301. //radioButton2.Checked = config.NameStatus == 2 ? true : false;
  302. radioButton1.Checked = true;
  303. radioButton2.Checked = false;
  304. textBox3.Text = item.ContinueNum.ToString();
  305. comboBox1.SelectedIndex = item.NumberNum - 1;
  306. textBox7.Text = item.CharZ1;
  307. textBox8.Text = item.CharZ2;
  308. config.NamePrefix = item.NamePrefix;
  309. config.NameFormat = item.NameFormat;
  310. config.NumberNum = item.NumberNum;
  311. config.NameStatus = item.NameStatus;
  312. config.ContinueNum = item.ContinueNum;
  313. config.CharZ1 = item.CharZ1;
  314. config.CharZ2 = item.CharZ2;
  315. }
  316. }
  317. }
  318. else
  319. {
  320. NamingMethod namingMethod = new NamingMethod();
  321. namingMethod.name = "default";
  322. namingMethod.NamePrefix = config.NamePrefix;
  323. namingMethod.NameFormat = config.NameFormat;
  324. namingMethod.NumberNum = config.NumberNum;
  325. namingMethod.NameStatus = config.NameStatus;
  326. namingMethod.ContinueNum = config.ContinueNum;
  327. namingMethod.CharZ1 = config.CharZ1;
  328. namingMethod.CharZ2 = config.CharZ2;
  329. config.LstNaming.Add(namingMethod);
  330. config.CurrentName = "default";
  331. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  332. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  333. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  334. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  335. comboBox_Name_Refresh();
  336. comboBox_Name_SelectedIndex();
  337. }
  338. }
  339. /// <summary>
  340. /// 条目选择
  341. /// </summary>
  342. /// <param name="sender"></param>
  343. /// <param name="e"></param>
  344. private void comboBox_Name_SelectedIndexChanged(object sender, EventArgs e)
  345. {
  346. config.CurrentName = this.comboBox_Name.Text.Trim();
  347. comboBox_Name_SelectedIndex();
  348. if (Inspect()) return;
  349. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  350. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  351. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  352. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  353. if (ImageIndexDialog.imageIndexDialog != null)
  354. ImageIndexDialog.imageIndexDialog.comboBox_Name_Refresh(config.CaptureSaveMode);
  355. }
  356. /// <summary>
  357. /// 删除
  358. /// </summary>
  359. /// <param name="sender"></param>
  360. /// <param name="e"></param>
  361. private void btn_Del_Click(object sender, EventArgs e)
  362. {
  363. DialogResult dr = MessageBox.Show(PdnResources.GetString("Menu.Areyousuretcteddata.text") + "?", PdnResources.GetString("Menu.ensure.text"), MessageBoxButtons.OKCancel, MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1);
  364. if (dr == DialogResult.Cancel) return;
  365. if (this.comboBox_Name.Text.Trim() != "")
  366. {
  367. if (config.LstNaming.Count > 1)
  368. {
  369. foreach (NamingMethod item in config.LstNaming)
  370. {
  371. if (this.comboBox_Name.Text.Trim().Equals(item.name))
  372. {
  373. config.LstNaming.Remove(item);
  374. break;
  375. }
  376. }
  377. }
  378. else
  379. {
  380. MessageBox.Show("只有一条数据,不可删除!");
  381. return;
  382. }
  383. if (config.LstNaming.Count > 0)
  384. {
  385. config.CurrentName = config.LstNaming[0].name;
  386. comboBox_Name_Refresh();
  387. comboBox_Name_SelectedIndexChanged(null, null);
  388. }
  389. else
  390. {
  391. comboBox_Name_Refresh();
  392. config.CurrentName = "";
  393. }
  394. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  395. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  396. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  397. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  398. if (ImageIndexDialog.imageIndexDialog != null)
  399. ImageIndexDialog.imageIndexDialog.comboBox_Name_Refresh(config.CaptureSaveMode);
  400. }
  401. }
  402. /// <summary>
  403. /// 保存
  404. /// </summary>
  405. /// <param name="sender"></param>
  406. /// <param name="e"></param>
  407. private void btn_Save_Click(object sender, EventArgs e)
  408. {
  409. if (Inspect()) return;
  410. string[] arrs = System.Text.RegularExpressions.Regex.Split(textBox2.Text.Trim(), "%");
  411. string CurrentName = this.comboBox_Name.Text.Trim();
  412. NamingMethod namingMethod = new NamingMethod();
  413. namingMethod.name = CurrentName;
  414. namingMethod.NamePrefix = textBox1.Text;
  415. namingMethod.NameFormat = textBox2.Text;
  416. namingMethod.NumberNum = Convert.ToInt32(comboBox1.SelectedItem);
  417. namingMethod.NameStatus = radioButton1.Checked == true ? 1 : 2;
  418. namingMethod.ContinueNum = radioButton1.Checked ? Convert.ToInt32(textBox3.Text) : 1;
  419. namingMethod.CharZ1 = textBox7.Text;
  420. namingMethod.CharZ2 = textBox8.Text;
  421. bool save = false;
  422. if (config.LstNaming.Count > 0)
  423. {
  424. for (int i = 0; i < config.LstNaming.Count; i++)
  425. {
  426. if (CurrentName.Equals(config.LstNaming[i].name))
  427. {
  428. config.LstNaming[i] = namingMethod;
  429. save = true;
  430. break;
  431. }
  432. }
  433. if (save)
  434. {
  435. if (((IList)arrs).Contains("T1")) config.customTxt = "T1";
  436. else if (((IList)arrs).Contains("T2")) config.customTxt = "T2";
  437. else if (((IList)arrs).Contains("T3")) config.customTxt = "T3";
  438. else config.customTxt = "";
  439. config.NamePrefix = textBox1.Text;
  440. config.NameFormat = textBox2.Text;
  441. config.NumberNum = Convert.ToInt32(comboBox1.SelectedItem);
  442. config.NameStatus = radioButton1.Checked == true ? 1 : 2;
  443. config.ContinueNum = radioButton1.Checked ? Convert.ToInt32(textBox3.Text) : 1;
  444. config.CharZ1 = textBox7.Text;
  445. config.CharZ2 = textBox8.Text;
  446. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  447. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  448. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  449. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  450. Startup.instance.configModel = config;
  451. }
  452. if (ImageIndexDialog.imageIndexDialog != null)
  453. ImageIndexDialog.imageIndexDialog.comboBox_Name_Refresh(config.CaptureSaveMode);
  454. }
  455. else
  456. {
  457. this.btn_SaveAs.PerformClick();
  458. }
  459. }
  460. //是否符合window命名规则不
  461. public bool Islegal()
  462. {
  463. //Regex regExp = new Regex("[\\/:*?\"<>|]");
  464. //bool isLegal = regExp.IsMatch(textBox7.Text.Trim()) || regExp.IsMatch(textBox8.Text.Trim());
  465. //return isLegal;
  466. char[] charstr = { '\\', '/', ':', '*', '?', '"', '<', '>', '|'};
  467. char[] textstr = (textBox7.Text.Trim()+ textBox8.Text.Trim()).ToString().Trim().ToCharArray();
  468. int count = 0;/*统计非法字符的个数*/
  469. for (int i = 0; i < charstr.Length; i++)
  470. {
  471. for (int j = 0; j < textstr.Length; j++)
  472. {
  473. if (charstr[i] == textstr[j])
  474. {
  475. count++;
  476. }
  477. }
  478. }
  479. if (count > 0)
  480. return true;
  481. else
  482. return false;
  483. }
  484. #endregion
  485. #region [点距列表]
  486. public void PointList()
  487. {
  488. listView2.View = View.Details;
  489. listView2.Columns.Add("0", 0, HorizontalAlignment.Center);
  490. listView2.Columns.Add(PdnResources.GetString("Menu.LabelAction.MarkAction.Text"), 60, HorizontalAlignment.Center);
  491. listView2.Columns.Add(PdnResources.GetString("Menu.sizeed.text"), 120, HorizontalAlignment.Center);
  492. listView2.Columns.Add(PdnResources.GetString("Menu.Set.Generalsettings.Maximum(pixels).text"), 120, HorizontalAlignment.Center);
  493. listView2.Columns.Add(PdnResources.GetString("Menu.Set.Generalsettings.dotspacing(mm).text"), 120, HorizontalAlignment.Center);
  494. listView2.Columns.Add(PdnResources.GetString("Menu.Set.Generalsettings.Screenwidth(mm).text"), 120, HorizontalAlignment.Center);
  495. var screenList = mic_screen_rules_BLL.FindAll();
  496. var screenRulesId = config.DotPitchId;
  497. listView2.BeginUpdate();
  498. foreach (var s in screenList)
  499. {
  500. var lv = new ListViewItem();
  501. lv.Text = "1";
  502. lv.SubItems.Add(screenRulesId == s.id ? "√" : "×");
  503. lv.SubItems.Add(s.size);
  504. lv.SubItems.Add(s.max_resolution);
  505. lv.SubItems.Add(s.point_pitch);
  506. lv.SubItems.Add(s.screen_width);
  507. lv.SubItems.Add(s.id.ToString());
  508. listView2.Items.Add(lv);
  509. }
  510. if (listView2.Items.Count > 0)
  511. {
  512. listView2.Items[0].Selected = true;
  513. listView2.Select();
  514. }
  515. listView2.EndUpdate();
  516. }
  517. #endregion
  518. #region [语言内容]
  519. public void ChooseLanguage()
  520. {
  521. radioButton3.Checked = config.Language == 1 ? true : false;
  522. radioButton4.Checked = config.Language == 3 ? true : false;
  523. radioButton5.Checked = config.Language == 2 ? true : false;
  524. }
  525. #endregion
  526. #region [控件相关]
  527. public GroupBox groupBox1;
  528. public GroupBox groupBox2;
  529. private Button button1;
  530. private Button button2;
  531. private ListBox listBox1;
  532. private GroupBox groupBox3;
  533. private GroupBox groupBox4;
  534. private TextBox textBox_Email;
  535. private TextBox textBox_Phone;
  536. private TextBox textBox_Contact;
  537. private TextBox textBox_Address;
  538. private TextBox textBox_City;
  539. private TextBox textBox_Province;
  540. private TextBox textBox_CompanyName;
  541. private Label label1;
  542. private TextBox textBox_Interface;
  543. private TextBox textBox_Camera;
  544. private TextBox textBox_SN;
  545. private TextBox textBox_Model;
  546. private Label label2;
  547. private Label label3;
  548. private Label label4;
  549. private Label label5;
  550. private Label label6;
  551. private Label label7;
  552. private Label label8;
  553. private Label label9;
  554. private Label label10;
  555. private Label label11;
  556. private Label label12;
  557. public GroupBox groupBox5;
  558. private GroupBox groupBox6;
  559. private GroupBox groupBox7;
  560. private GroupBox groupBox8;
  561. private GroupBox groupBox9;
  562. private GroupBox groupBox11;
  563. private Label label13;
  564. private TextBox textBox1;
  565. private TextBox textBox2;
  566. private Label label14;
  567. private Label label15;
  568. private ComboBox comboBox1;
  569. private RadioButton radioButton1;
  570. private RadioButton radioButton2;
  571. private TextBox textBox3;
  572. private ListView listView1;
  573. private RadioButton radioButton3;
  574. private Label label16;
  575. private RadioButton radioButton5;
  576. private RadioButton radioButton4;
  577. private CheckBox checkBox6;
  578. private CheckBox checkBox5;
  579. private CheckBox checkBox4;
  580. private CheckBox checkBox3;
  581. private CheckBox checkBox2;
  582. private CheckBox checkBox1;
  583. private Label label17;
  584. private ListView listView2;
  585. private GroupBox groupBox12;
  586. private Button button5;
  587. private Button button4;
  588. private Button button3;
  589. private CheckBox checkBox7;
  590. private CheckBox checkBox9;
  591. private CheckBox checkBox8;
  592. private PictureBox pictureBox1;
  593. private Button button10;
  594. private Button button9;
  595. private Button button11;
  596. private PictureBox pictureBox2;
  597. private Button button12;
  598. private Button button13;
  599. private void InitializeLanguageText()
  600. {
  601. this.groupBox1.Text = PdnResources.GetString("Menu.Type.text");
  602. this.groupBox8.Text = PdnResources.GetString("Menu.information.text");
  603. this.radioButton5.Text = PdnResources.GetString("Menu.Set.Generalsettings.English.text");
  604. this.radioButton4.Text = PdnResources.GetString("Menu.Set.Generalsettings.German.text");
  605. this.label16.Text = PdnResources.GetString("Menu.Set.Generalsettings.Switchlanguage.text") + ":";
  606. this.radioButton3.Text = PdnResources.GetString("Menu.Set.Generalsettings.Chinese.text");
  607. this.groupBox7.Text = PdnResources.GetString("Menu.information.text");
  608. this.label17.Text = PdnResources.GetString("Menu.Set.Generalsettings.Note:Maklizing.text");
  609. this.checkBox6.Text = PdnResources.GetString("Menu.Set.Geneings.Note:Maklizing.text");
  610. this.checkBox5.Text = PdnResources.GetString("Menu.Set.Generalsettings.toolbarinit.text");
  611. this.checkBox4.Text = PdnResources.GetString("Menu.shortcutbarfunctioninit.text");
  612. this.checkBox3.Text = PdnResources.GetString("Menu.Set.Generalsettings.loginformationinit.text");
  613. this.checkBox2.Text = PdnResources.GetString("Menu.Set.Generalsettings.Measurementinfotioninit.text");
  614. this.checkBox1.Text = PdnResources.GetString("Menu.Set.Generalsettings.Annotatitioninit.text");
  615. this.groupBox10.Text = PdnResources.GetString("Menu.Set.Generalsettings.Thearchivefilesavesthepath.text");
  616. this.button8.Text = PdnResources.GetString("Menu.Set.Generalsettings.Selectfolder.text");
  617. this.button7.Text = PdnResources.GetString("Menu.Set.Generalsettings.Selectfolder.text");
  618. this.button6.Text = PdnResources.GetString("Menu.Set.Generalsettings.Selectfolder.text");
  619. this.label20.Text = PdnResources.GetString("Menu.DedicatedAnalysis.Text") + ":";
  620. this.label19.Text = PdnResources.GetString("Menu.GeneralAnalysis.Text") + ":";
  621. this.label18.Text = PdnResources.GetString("Menu.Normaloperation.text") + ":";
  622. this.groupBox6.Text = PdnResources.GetString("Menu.Set.Generalsettings.dotspacinglist.text");
  623. this.groupBox9.Text = PdnResources.GetString("Menu.Set.Generalsettings.Startimage.text");
  624. this.button10.Text = PdnResources.GetString("Menu.Edit.Delete.Text");
  625. this.checkBox7.Text = PdnResources.GetString("Menu.Set.Generalsettings.Startimage.text") + ":";
  626. this.groupBox2.Text = PdnResources.GetString("Menu.operation.text");
  627. this.button2.Text = PdnResources.GetString("ConfirmLanguageDialog.CancelTB.ActionText");
  628. this.button1.Text = PdnResources.GetString("Menu.application.text");
  629. this.groupBox12.Text = PdnResources.GetString("Menu.operation.text");
  630. this.button13.Text = PdnResources.GetString("Menu.application.text");
  631. this.button5.Text = PdnResources.GetString("Menu.Edit.Text");
  632. this.button4.Text = PdnResources.GetString("Menu.New.text");
  633. this.button3.Text = PdnResources.GetString("Menu.Edit.Delete.Text");
  634. this.groupBox3.Text = PdnResources.GetString("Menu.UserInfo.text");
  635. this.button12.Text = PdnResources.GetString("Menu.Edit.Delete.Text");
  636. this.label7.Text = PdnResources.GetString("Menu.Set.Generalsettings.mail.text") + ":";
  637. this.label6.Text = PdnResources.GetString("Menu.Set.Generalsettings.phone.text") + ":";
  638. this.label5.Text = PdnResources.GetString("Menu.Contactperson.text") + ":";
  639. this.label4.Text = PdnResources.GetString("Menu.Set.Generalsettings.address.text") + ":";
  640. this.label3.Text = PdnResources.GetString("Menu.Set.Generalsettings.city.text") + ":";
  641. this.label2.Text = PdnResources.GetString("Menu.Set.Generalsettings.province.text") + ":";
  642. this.label1.Text = PdnResources.GetString("Menu.Set.Generalsettings.unitname.text") + ":";
  643. this.groupBox5.Text = PdnResources.GetString("Menu.information.text");
  644. this.radioButton2.Text = PdnResources.GetString("Menu.reinformation.text");
  645. this.radioButton1.Text = PdnResources.GetString("Menu.Set.Generalsettings.continue.text");
  646. this.label15.Text = PdnResources.GetString("Menu.Set.Generalsettings.Numericaldigits.text") + ":";
  647. this.label14.Text = PdnResources.GetString("Menu.Set.Generalsettings.Nameformat.text") + ":";
  648. this.label13.Text = PdnResources.GetString("Menu.LabelAction.DrawTextString.Text") + ":";
  649. this.groupBox4.Text = PdnResources.GetString("Menu.Set.Generalsettings.Microsmation.text");
  650. this.label12.Text = PdnResources.GetString("Menu.interface.text") + ":";
  651. this.label11.Text = PdnResources.GetString("Menu.thecamera.text") + ":";
  652. this.label10.Text = PdnResources.GetString("Menu.Set.Generalsettings.SNcode.text") + ":";
  653. this.label9.Text = PdnResources.GetString("Menu.model.text") + ":";
  654. this.groupBox11.Text = PdnResources.GetString("Menu.other.text");
  655. this.checkBox9.Text = PdnResources.GetString("Menu.Set.Generalsettings.autoaddAxioVisionruler.text");
  656. this.checkBox8.Text = PdnResources.GetString("Menu.Set.Generalsettings.autoaddZENruler.text");
  657. this.groupBox13.Text = PdnResources.GetString("Menu.operation.text");
  658. this.button14.Text = PdnResources.GetString("Menu.application.text");
  659. this.button15.Text = PdnResources.GetString("Menu.Edit.Text");
  660. this.button16.Text = PdnResources.GetString("Menu.New.text");
  661. this.button17.Text = PdnResources.GetString("Menu.Edit.Delete.Text");
  662. this.groupBox14.Text = PdnResources.GetString("Menu.operation.text");
  663. this.button18.Text = PdnResources.GetString("Menu.application.text");
  664. this.button19.Text = PdnResources.GetString("ConfirmLanguageDialog.CancelTB.ActionText");
  665. this.groupBox15.Text = PdnResources.GetString("Menu.Directionsetting.text");
  666. this.radioButton14.Text = PdnResources.GetString("Menu.positive.text");
  667. this.radioButton15.Text = PdnResources.GetString("Menu.negation.text");
  668. this.radioButton12.Text = PdnResources.GetString("Menu.positive.text");
  669. this.radioButton13.Text = PdnResources.GetString("Menu.negation.text");
  670. this.radioButton10.Text = PdnResources.GetString("Menu.positive.text");
  671. this.radioButton11.Text = PdnResources.GetString("Menu.negation.text");
  672. this.radioButton8.Text = PdnResources.GetString("Menu.positive.text");
  673. this.radioButton9.Text = PdnResources.GetString("Menu.negation.text");
  674. this.radioButton7.Text = PdnResources.GetString("Menu.Set.Generalsettings.under.text");
  675. this.radioButton6.Text = PdnResources.GetString("Menu.Set.Generalsettings.up.text");
  676. this.label25.Text = PdnResources.GetString("Menu.Set.Generalsettings.Xaxismovementdirection.text") + ":" + PdnResources.GetString("Menu.Set.Generalsettings.left.text");
  677. this.label24.Text = PdnResources.GetString("Menu.Set.Generalsettings.right.text");
  678. this.label23.Text = PdnResources.GetString("Menu.Set.Generalsettings.right.text");
  679. this.label22.Text = PdnResources.GetString("Menu.Set.Generalsettings.Yaxismovementdirection.text") + ":" + PdnResources.GetString("Menu.Set.Generalsettings.left.text");
  680. this.label21.Text = PdnResources.GetString("Menu.Set.Generalsettings.Zaxismovementdirection.text") + ":";
  681. this.Text = PdnResources.GetString("Menu.Setting.GeneralSetting.Text");
  682. this.label26.Text = PdnResources.GetString("Menu.Linestyle.Text") + ":";
  683. this.label27.Text = PdnResources.GetString("Menu.Set.Rulersettings.Linecolor.text") + ":";
  684. this.label28.Text = PdnResources.GetString("Menu.Set.Rulersettings.Linewidth.text") + ":";
  685. this.groupBox16.Text = PdnResources.GetString("Menu.Auxiliarylinesettings.text");
  686. this.button20.Text = PdnResources.GetString("Menu.application.text");
  687. this.button21.Text = PdnResources.GetString("ConfirmLanguageDialog.CancelTB.ActionText");
  688. this.groupBox17.Text = PdnResources.GetString("Menu.operation.text");
  689. label29.Text = PdnResources.GetString("Menu.name.text");
  690. groupBox19.Text = PdnResources.GetString("Menu.CurrentUse.Text");
  691. btn_Del.Text = PdnResources.GetString("Menu.Edit.Delete.Text");
  692. btn_SaveAs.Text = PdnResources.GetString("Menu.File.SaveAs.Text");
  693. btn_Save.Text = PdnResources.GetString("CloseWorkspaceAction.SaveButton.ActionText");
  694. button23.Text = PdnResources.GetString("Menu.SelectFolder.text");
  695. label32.Text = PdnResources.GetString("Menu.DefaultPath.text") + ":";
  696. ckbSaveAndOpen.Text = PdnResources.GetString("Menu.SaveAndOpen.text");
  697. ckNotSave.Text = PdnResources.GetString("Menu.SoftwareSave.text");
  698. ckAutoSave.Text = PdnResources.GetString("Menu.AutoSave.text");
  699. ckbSave.Text = PdnResources.GetString("Menu.SaveDisk.text");
  700. }
  701. private void InitializeComponent()
  702. {
  703. this.groupBox1 = new System.Windows.Forms.GroupBox();
  704. this.listBox1 = new System.Windows.Forms.ListBox();
  705. this.groupBox8 = new System.Windows.Forms.GroupBox();
  706. this.radioButton5 = new System.Windows.Forms.RadioButton();
  707. this.radioButton4 = new System.Windows.Forms.RadioButton();
  708. this.label16 = new System.Windows.Forms.Label();
  709. this.radioButton3 = new System.Windows.Forms.RadioButton();
  710. this.groupBox7 = new System.Windows.Forms.GroupBox();
  711. this.label17 = new System.Windows.Forms.Label();
  712. this.checkBox6 = new System.Windows.Forms.CheckBox();
  713. this.checkBox5 = new System.Windows.Forms.CheckBox();
  714. this.checkBox4 = new System.Windows.Forms.CheckBox();
  715. this.checkBox3 = new System.Windows.Forms.CheckBox();
  716. this.checkBox2 = new System.Windows.Forms.CheckBox();
  717. this.checkBox1 = new System.Windows.Forms.CheckBox();
  718. this.groupBoxCaptureSave = new System.Windows.Forms.GroupBox();
  719. this.button23 = new System.Windows.Forms.Button();
  720. this.ckNotSave = new System.Windows.Forms.RadioButton();
  721. this.textBox9 = new System.Windows.Forms.TextBox();
  722. this.ckAutoSave = new System.Windows.Forms.RadioButton();
  723. this.label32 = new System.Windows.Forms.Label();
  724. this.ckbSave = new System.Windows.Forms.RadioButton();
  725. this.ckbSaveAndOpen = new System.Windows.Forms.CheckBox();
  726. this.groupBox10 = new System.Windows.Forms.GroupBox();
  727. this.button8 = new System.Windows.Forms.Button();
  728. this.textBox6 = new System.Windows.Forms.TextBox();
  729. this.button7 = new System.Windows.Forms.Button();
  730. this.textBox5 = new System.Windows.Forms.TextBox();
  731. this.button6 = new System.Windows.Forms.Button();
  732. this.textBox4 = new System.Windows.Forms.TextBox();
  733. this.label20 = new System.Windows.Forms.Label();
  734. this.label19 = new System.Windows.Forms.Label();
  735. this.label18 = new System.Windows.Forms.Label();
  736. this.groupBox6 = new System.Windows.Forms.GroupBox();
  737. this.listView2 = new System.Windows.Forms.ListView();
  738. this.groupBox9 = new System.Windows.Forms.GroupBox();
  739. this.button10 = new System.Windows.Forms.Button();
  740. this.button9 = new System.Windows.Forms.Button();
  741. this.pictureBox1 = new System.Windows.Forms.PictureBox();
  742. this.checkBox7 = new System.Windows.Forms.CheckBox();
  743. this.groupBox2 = new System.Windows.Forms.GroupBox();
  744. this.btn_SaveAs = new System.Windows.Forms.Button();
  745. this.btn_Save = new System.Windows.Forms.Button();
  746. this.button2 = new System.Windows.Forms.Button();
  747. this.button1 = new System.Windows.Forms.Button();
  748. this.groupBox12 = new System.Windows.Forms.GroupBox();
  749. this.button13 = new System.Windows.Forms.Button();
  750. this.button5 = new System.Windows.Forms.Button();
  751. this.button4 = new System.Windows.Forms.Button();
  752. this.button3 = new System.Windows.Forms.Button();
  753. this.groupBox3 = new System.Windows.Forms.GroupBox();
  754. this.pictureBox2 = new System.Windows.Forms.PictureBox();
  755. this.button12 = new System.Windows.Forms.Button();
  756. this.button11 = new System.Windows.Forms.Button();
  757. this.label8 = new System.Windows.Forms.Label();
  758. this.label7 = new System.Windows.Forms.Label();
  759. this.label6 = new System.Windows.Forms.Label();
  760. this.label5 = new System.Windows.Forms.Label();
  761. this.label4 = new System.Windows.Forms.Label();
  762. this.label3 = new System.Windows.Forms.Label();
  763. this.label2 = new System.Windows.Forms.Label();
  764. this.textBox_Email = new System.Windows.Forms.TextBox();
  765. this.textBox_Phone = new System.Windows.Forms.TextBox();
  766. this.textBox_Contact = new System.Windows.Forms.TextBox();
  767. this.textBox_Address = new System.Windows.Forms.TextBox();
  768. this.textBox_City = new System.Windows.Forms.TextBox();
  769. this.textBox_Province = new System.Windows.Forms.TextBox();
  770. this.textBox_CompanyName = new System.Windows.Forms.TextBox();
  771. this.label1 = new System.Windows.Forms.Label();
  772. this.groupBox5 = new System.Windows.Forms.GroupBox();
  773. this.textBox8 = new System.Windows.Forms.TextBox();
  774. this.textBox7 = new System.Windows.Forms.TextBox();
  775. this.label31 = new System.Windows.Forms.Label();
  776. this.label30 = new System.Windows.Forms.Label();
  777. this.radioButton2 = new System.Windows.Forms.RadioButton();
  778. this.textBox3 = new System.Windows.Forms.TextBox();
  779. this.radioButton1 = new System.Windows.Forms.RadioButton();
  780. this.comboBox1 = new System.Windows.Forms.ComboBox();
  781. this.label15 = new System.Windows.Forms.Label();
  782. this.textBox2 = new System.Windows.Forms.TextBox();
  783. this.label14 = new System.Windows.Forms.Label();
  784. this.textBox1 = new System.Windows.Forms.TextBox();
  785. this.label13 = new System.Windows.Forms.Label();
  786. this.listView1 = new System.Windows.Forms.ListView();
  787. this.groupBox4 = new System.Windows.Forms.GroupBox();
  788. this.label12 = new System.Windows.Forms.Label();
  789. this.label11 = new System.Windows.Forms.Label();
  790. this.label10 = new System.Windows.Forms.Label();
  791. this.label9 = new System.Windows.Forms.Label();
  792. this.textBox_Interface = new System.Windows.Forms.TextBox();
  793. this.textBox_Camera = new System.Windows.Forms.TextBox();
  794. this.textBox_SN = new System.Windows.Forms.TextBox();
  795. this.textBox_Model = new System.Windows.Forms.TextBox();
  796. this.groupBox11 = new System.Windows.Forms.GroupBox();
  797. this.checkBox9 = new System.Windows.Forms.CheckBox();
  798. this.checkBox8 = new System.Windows.Forms.CheckBox();
  799. this.listView3 = new System.Windows.Forms.ListView();
  800. this.label21 = new System.Windows.Forms.Label();
  801. this.label22 = new System.Windows.Forms.Label();
  802. this.label23 = new System.Windows.Forms.Label();
  803. this.label24 = new System.Windows.Forms.Label();
  804. this.label25 = new System.Windows.Forms.Label();
  805. this.panel1 = new System.Windows.Forms.Panel();
  806. this.radioButton7 = new System.Windows.Forms.RadioButton();
  807. this.radioButton6 = new System.Windows.Forms.RadioButton();
  808. this.panel2 = new System.Windows.Forms.Panel();
  809. this.radioButton8 = new System.Windows.Forms.RadioButton();
  810. this.radioButton9 = new System.Windows.Forms.RadioButton();
  811. this.panel3 = new System.Windows.Forms.Panel();
  812. this.radioButton10 = new System.Windows.Forms.RadioButton();
  813. this.radioButton11 = new System.Windows.Forms.RadioButton();
  814. this.panel4 = new System.Windows.Forms.Panel();
  815. this.radioButton12 = new System.Windows.Forms.RadioButton();
  816. this.radioButton13 = new System.Windows.Forms.RadioButton();
  817. this.panel5 = new System.Windows.Forms.Panel();
  818. this.radioButton14 = new System.Windows.Forms.RadioButton();
  819. this.radioButton15 = new System.Windows.Forms.RadioButton();
  820. this.groupBox15 = new System.Windows.Forms.GroupBox();
  821. this.groupBox16 = new System.Windows.Forms.GroupBox();
  822. this.panel6 = new System.Windows.Forms.Button();
  823. this.label28 = new System.Windows.Forms.Label();
  824. this.label27 = new System.Windows.Forms.Label();
  825. this.label26 = new System.Windows.Forms.Label();
  826. this.numericUpDown1 = new System.Windows.Forms.NumericUpDown();
  827. this.comboBox2 = new System.Windows.Forms.ComboBox();
  828. this.button17 = new System.Windows.Forms.Button();
  829. this.button16 = new System.Windows.Forms.Button();
  830. this.button15 = new System.Windows.Forms.Button();
  831. this.button14 = new System.Windows.Forms.Button();
  832. this.groupBox13 = new System.Windows.Forms.GroupBox();
  833. this.button19 = new System.Windows.Forms.Button();
  834. this.button18 = new System.Windows.Forms.Button();
  835. this.groupBox14 = new System.Windows.Forms.GroupBox();
  836. this.groupBox17 = new System.Windows.Forms.GroupBox();
  837. this.button20 = new System.Windows.Forms.Button();
  838. this.button21 = new System.Windows.Forms.Button();
  839. this.groupBox18 = new System.Windows.Forms.GroupBox();
  840. this.button22 = new System.Windows.Forms.Button();
  841. this.groupBox19 = new System.Windows.Forms.GroupBox();
  842. this.btn_Del = new System.Windows.Forms.Button();
  843. this.comboBox_Name = new System.Windows.Forms.ComboBox();
  844. this.label29 = new System.Windows.Forms.Label();
  845. this.groupBox20 = new System.Windows.Forms.GroupBox();
  846. this.checkBox10 = new System.Windows.Forms.CheckBox();
  847. this.comboBox3 = new System.Windows.Forms.ComboBox();
  848. this.numericUpDown3 = new System.Windows.Forms.NumericUpDown();
  849. this.numericUpDown2 = new System.Windows.Forms.NumericUpDown();
  850. this.label35 = new System.Windows.Forms.Label();
  851. this.label34 = new System.Windows.Forms.Label();
  852. this.label33 = new System.Windows.Forms.Label();
  853. this.groupBox1.SuspendLayout();
  854. this.groupBox8.SuspendLayout();
  855. this.groupBox7.SuspendLayout();
  856. this.groupBoxCaptureSave.SuspendLayout();
  857. this.groupBox10.SuspendLayout();
  858. this.groupBox6.SuspendLayout();
  859. this.groupBox9.SuspendLayout();
  860. ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();
  861. this.groupBox2.SuspendLayout();
  862. this.groupBox12.SuspendLayout();
  863. this.groupBox3.SuspendLayout();
  864. ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).BeginInit();
  865. this.groupBox5.SuspendLayout();
  866. this.groupBox4.SuspendLayout();
  867. this.groupBox11.SuspendLayout();
  868. this.panel1.SuspendLayout();
  869. this.panel2.SuspendLayout();
  870. this.panel3.SuspendLayout();
  871. this.panel4.SuspendLayout();
  872. this.panel5.SuspendLayout();
  873. this.groupBox15.SuspendLayout();
  874. this.groupBox16.SuspendLayout();
  875. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).BeginInit();
  876. this.groupBox13.SuspendLayout();
  877. this.groupBox14.SuspendLayout();
  878. this.groupBox17.SuspendLayout();
  879. this.groupBox18.SuspendLayout();
  880. this.groupBox19.SuspendLayout();
  881. this.groupBox20.SuspendLayout();
  882. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown3)).BeginInit();
  883. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).BeginInit();
  884. this.SuspendLayout();
  885. //
  886. // groupBox1
  887. //
  888. this.groupBox1.Controls.Add(this.listBox1);
  889. this.groupBox1.Location = new System.Drawing.Point(6, 13);
  890. this.groupBox1.Name = "groupBox1";
  891. this.groupBox1.Size = new System.Drawing.Size(105, 531);
  892. this.groupBox1.TabIndex = 1;
  893. this.groupBox1.TabStop = false;
  894. this.groupBox1.Text = "类型";
  895. //
  896. // listBox1
  897. //
  898. this.listBox1.Dock = System.Windows.Forms.DockStyle.Fill;
  899. this.listBox1.DrawMode = System.Windows.Forms.DrawMode.OwnerDrawVariable;
  900. this.listBox1.FormattingEnabled = true;
  901. this.listBox1.ItemHeight = 30;
  902. this.listBox1.Location = new System.Drawing.Point(3, 17);
  903. this.listBox1.Name = "listBox1";
  904. this.listBox1.Size = new System.Drawing.Size(99, 511);
  905. this.listBox1.TabIndex = 0;
  906. this.listBox1.DrawItem += new System.Windows.Forms.DrawItemEventHandler(this.listBox1_DrawItem);
  907. this.listBox1.SelectedValueChanged += new System.EventHandler(this.listBox1_SelectedValueChanged);
  908. //
  909. // groupBox8
  910. //
  911. this.groupBox8.Controls.Add(this.radioButton5);
  912. this.groupBox8.Controls.Add(this.radioButton4);
  913. this.groupBox8.Controls.Add(this.label16);
  914. this.groupBox8.Controls.Add(this.radioButton3);
  915. this.groupBox8.Location = new System.Drawing.Point(117, 74);
  916. this.groupBox8.Name = "groupBox8";
  917. this.groupBox8.Size = new System.Drawing.Size(394, 470);
  918. this.groupBox8.TabIndex = 38;
  919. this.groupBox8.TabStop = false;
  920. this.groupBox8.Text = "信息";
  921. //
  922. // radioButton5
  923. //
  924. this.radioButton5.AutoSize = true;
  925. this.radioButton5.Location = new System.Drawing.Point(130, 66);
  926. this.radioButton5.Name = "radioButton5";
  927. this.radioButton5.Size = new System.Drawing.Size(47, 16);
  928. this.radioButton5.TabIndex = 8;
  929. this.radioButton5.TabStop = true;
  930. this.radioButton5.Text = "英文";
  931. this.radioButton5.UseVisualStyleBackColor = true;
  932. //
  933. // radioButton4
  934. //
  935. this.radioButton4.AutoSize = true;
  936. this.radioButton4.Location = new System.Drawing.Point(130, 98);
  937. this.radioButton4.Name = "radioButton4";
  938. this.radioButton4.Size = new System.Drawing.Size(47, 16);
  939. this.radioButton4.TabIndex = 7;
  940. this.radioButton4.TabStop = true;
  941. this.radioButton4.Text = "德文";
  942. this.radioButton4.UseVisualStyleBackColor = true;
  943. //
  944. // label16
  945. //
  946. this.label16.AutoSize = true;
  947. this.label16.Location = new System.Drawing.Point(17, 34);
  948. this.label16.Name = "label16";
  949. this.label16.Size = new System.Drawing.Size(65, 12);
  950. this.label16.TabIndex = 6;
  951. this.label16.Text = "切换语言:";
  952. //
  953. // radioButton3
  954. //
  955. this.radioButton3.AutoSize = true;
  956. this.radioButton3.Location = new System.Drawing.Point(130, 32);
  957. this.radioButton3.Name = "radioButton3";
  958. this.radioButton3.Size = new System.Drawing.Size(47, 16);
  959. this.radioButton3.TabIndex = 0;
  960. this.radioButton3.TabStop = true;
  961. this.radioButton3.Text = "中文";
  962. this.radioButton3.UseVisualStyleBackColor = true;
  963. //
  964. // groupBox7
  965. //
  966. this.groupBox7.Controls.Add(this.label17);
  967. this.groupBox7.Controls.Add(this.checkBox6);
  968. this.groupBox7.Controls.Add(this.checkBox5);
  969. this.groupBox7.Controls.Add(this.checkBox4);
  970. this.groupBox7.Controls.Add(this.checkBox3);
  971. this.groupBox7.Controls.Add(this.checkBox2);
  972. this.groupBox7.Controls.Add(this.checkBox1);
  973. this.groupBox7.Location = new System.Drawing.Point(117, 74);
  974. this.groupBox7.Name = "groupBox7";
  975. this.groupBox7.Size = new System.Drawing.Size(394, 470);
  976. this.groupBox7.TabIndex = 20;
  977. this.groupBox7.TabStop = false;
  978. this.groupBox7.Text = "信息";
  979. //
  980. // label17
  981. //
  982. this.label17.AutoSize = true;
  983. this.label17.ForeColor = System.Drawing.Color.Red;
  984. this.label17.Location = new System.Drawing.Point(15, 226);
  985. this.label17.Name = "label17";
  986. this.label17.Size = new System.Drawing.Size(269, 12);
  987. this.label17.TabIndex = 16;
  988. this.label17.Text = "注意:进行初始化前,请确保软件打开窗口均关闭";
  989. //
  990. // checkBox6
  991. //
  992. this.checkBox6.AutoSize = true;
  993. this.checkBox6.Location = new System.Drawing.Point(17, 194);
  994. this.checkBox6.Name = "checkBox6";
  995. this.checkBox6.Size = new System.Drawing.Size(120, 16);
  996. this.checkBox6.TabIndex = 16;
  997. this.checkBox6.Text = "快捷键功能初始化";
  998. this.checkBox6.UseVisualStyleBackColor = true;
  999. //
  1000. // checkBox5
  1001. //
  1002. this.checkBox5.AutoSize = true;
  1003. this.checkBox5.Location = new System.Drawing.Point(17, 162);
  1004. this.checkBox5.Name = "checkBox5";
  1005. this.checkBox5.Size = new System.Drawing.Size(96, 16);
  1006. this.checkBox5.TabIndex = 16;
  1007. this.checkBox5.Text = "工具栏初始化";
  1008. this.checkBox5.UseVisualStyleBackColor = true;
  1009. //
  1010. // checkBox4
  1011. //
  1012. this.checkBox4.AutoSize = true;
  1013. this.checkBox4.Location = new System.Drawing.Point(17, 130);
  1014. this.checkBox4.Name = "checkBox4";
  1015. this.checkBox4.Size = new System.Drawing.Size(120, 16);
  1016. this.checkBox4.TabIndex = 16;
  1017. this.checkBox4.Text = "快捷栏功能初始化";
  1018. this.checkBox4.UseVisualStyleBackColor = true;
  1019. //
  1020. // checkBox3
  1021. //
  1022. this.checkBox3.AutoSize = true;
  1023. this.checkBox3.Location = new System.Drawing.Point(17, 98);
  1024. this.checkBox3.Name = "checkBox3";
  1025. this.checkBox3.Size = new System.Drawing.Size(102, 16);
  1026. this.checkBox3.TabIndex = 16;
  1027. this.checkBox3.Text = "log信息初始化";
  1028. this.checkBox3.UseVisualStyleBackColor = true;
  1029. //
  1030. // checkBox2
  1031. //
  1032. this.checkBox2.AutoSize = true;
  1033. this.checkBox2.Location = new System.Drawing.Point(17, 66);
  1034. this.checkBox2.Name = "checkBox2";
  1035. this.checkBox2.Size = new System.Drawing.Size(132, 16);
  1036. this.checkBox2.TabIndex = 16;
  1037. this.checkBox2.Text = "测量信息配置初始化";
  1038. this.checkBox2.UseVisualStyleBackColor = true;
  1039. //
  1040. // checkBox1
  1041. //
  1042. this.checkBox1.AutoSize = true;
  1043. this.checkBox1.Location = new System.Drawing.Point(17, 34);
  1044. this.checkBox1.Name = "checkBox1";
  1045. this.checkBox1.Size = new System.Drawing.Size(132, 16);
  1046. this.checkBox1.TabIndex = 16;
  1047. this.checkBox1.Text = "标注信息配置初始化";
  1048. this.checkBox1.UseVisualStyleBackColor = true;
  1049. //
  1050. // groupBoxCaptureSave
  1051. //
  1052. this.groupBoxCaptureSave.Controls.Add(this.button23);
  1053. this.groupBoxCaptureSave.Controls.Add(this.ckNotSave);
  1054. this.groupBoxCaptureSave.Controls.Add(this.textBox9);
  1055. this.groupBoxCaptureSave.Controls.Add(this.ckAutoSave);
  1056. this.groupBoxCaptureSave.Controls.Add(this.label32);
  1057. this.groupBoxCaptureSave.Controls.Add(this.ckbSave);
  1058. this.groupBoxCaptureSave.Controls.Add(this.ckbSaveAndOpen);
  1059. this.groupBoxCaptureSave.Location = new System.Drawing.Point(117, 73);
  1060. this.groupBoxCaptureSave.Name = "groupBoxCaptureSave";
  1061. this.groupBoxCaptureSave.Size = new System.Drawing.Size(394, 470);
  1062. this.groupBoxCaptureSave.TabIndex = 21;
  1063. this.groupBoxCaptureSave.TabStop = false;
  1064. this.groupBoxCaptureSave.Text = "拍照保存";
  1065. //
  1066. // button23
  1067. //
  1068. this.button23.Location = new System.Drawing.Point(286, 106);
  1069. this.button23.Name = "button23";
  1070. this.button23.Size = new System.Drawing.Size(75, 21);
  1071. this.button23.TabIndex = 22;
  1072. this.button23.Text = "选择文件夹";
  1073. this.button23.UseVisualStyleBackColor = true;
  1074. this.button23.Click += new System.EventHandler(this.button23_Click);
  1075. //
  1076. // ckNotSave
  1077. //
  1078. this.ckNotSave.AutoSize = true;
  1079. this.ckNotSave.Location = new System.Drawing.Point(289, 37);
  1080. this.ckNotSave.Name = "ckNotSave";
  1081. this.ckNotSave.Size = new System.Drawing.Size(71, 16);
  1082. this.ckNotSave.TabIndex = 4;
  1083. this.ckNotSave.TabStop = true;
  1084. this.ckNotSave.Text = "软件保存";
  1085. this.ckNotSave.UseVisualStyleBackColor = true;
  1086. //
  1087. // textBox9
  1088. //
  1089. this.textBox9.Location = new System.Drawing.Point(94, 106);
  1090. this.textBox9.Name = "textBox9";
  1091. this.textBox9.ReadOnly = true;
  1092. this.textBox9.Size = new System.Drawing.Size(180, 21);
  1093. this.textBox9.TabIndex = 21;
  1094. //
  1095. // ckAutoSave
  1096. //
  1097. this.ckAutoSave.AutoSize = true;
  1098. this.ckAutoSave.Location = new System.Drawing.Point(156, 36);
  1099. this.ckAutoSave.Name = "ckAutoSave";
  1100. this.ckAutoSave.Size = new System.Drawing.Size(71, 16);
  1101. this.ckAutoSave.TabIndex = 3;
  1102. this.ckAutoSave.TabStop = true;
  1103. this.ckAutoSave.Text = "自动保存";
  1104. this.ckAutoSave.UseVisualStyleBackColor = true;
  1105. //
  1106. // label32
  1107. //
  1108. this.label32.AutoSize = true;
  1109. this.label32.Location = new System.Drawing.Point(13, 109);
  1110. this.label32.Name = "label32";
  1111. this.label32.Size = new System.Drawing.Size(65, 12);
  1112. this.label32.TabIndex = 20;
  1113. this.label32.Text = "默认路径:";
  1114. //
  1115. // ckbSave
  1116. //
  1117. this.ckbSave.AutoSize = true;
  1118. this.ckbSave.Location = new System.Drawing.Point(15, 37);
  1119. this.ckbSave.Name = "ckbSave";
  1120. this.ckbSave.Size = new System.Drawing.Size(83, 16);
  1121. this.ckbSave.TabIndex = 2;
  1122. this.ckbSave.TabStop = true;
  1123. this.ckbSave.Text = "保存到硬盘";
  1124. this.ckbSave.UseVisualStyleBackColor = true;
  1125. //
  1126. // ckbSaveAndOpen
  1127. //
  1128. this.ckbSaveAndOpen.AutoSize = true;
  1129. this.ckbSaveAndOpen.Location = new System.Drawing.Point(38, 65);
  1130. this.ckbSaveAndOpen.Name = "ckbSaveAndOpen";
  1131. this.ckbSaveAndOpen.Size = new System.Drawing.Size(144, 16);
  1132. this.ckbSaveAndOpen.TabIndex = 0;
  1133. this.ckbSaveAndOpen.Text = "保存后打开图片到软件";
  1134. this.ckbSaveAndOpen.UseVisualStyleBackColor = true;
  1135. //
  1136. // groupBox10
  1137. //
  1138. this.groupBox10.Controls.Add(this.button8);
  1139. this.groupBox10.Controls.Add(this.textBox6);
  1140. this.groupBox10.Controls.Add(this.button7);
  1141. this.groupBox10.Controls.Add(this.textBox5);
  1142. this.groupBox10.Controls.Add(this.button6);
  1143. this.groupBox10.Controls.Add(this.textBox4);
  1144. this.groupBox10.Controls.Add(this.label20);
  1145. this.groupBox10.Controls.Add(this.label19);
  1146. this.groupBox10.Controls.Add(this.label18);
  1147. this.groupBox10.Location = new System.Drawing.Point(117, 188);
  1148. this.groupBox10.Name = "groupBox10";
  1149. this.groupBox10.Size = new System.Drawing.Size(394, 171);
  1150. this.groupBox10.TabIndex = 30;
  1151. this.groupBox10.TabStop = false;
  1152. this.groupBox10.Text = "存档文件保存路径";
  1153. //
  1154. // button8
  1155. //
  1156. this.button8.Location = new System.Drawing.Point(313, 106);
  1157. this.button8.Name = "button8";
  1158. this.button8.Size = new System.Drawing.Size(75, 21);
  1159. this.button8.TabIndex = 16;
  1160. this.button8.Text = "选择文件夹";
  1161. this.button8.UseVisualStyleBackColor = true;
  1162. this.button8.Click += new System.EventHandler(this.button8_Click);
  1163. //
  1164. // textBox6
  1165. //
  1166. this.textBox6.Location = new System.Drawing.Point(87, 106);
  1167. this.textBox6.Name = "textBox6";
  1168. this.textBox6.ReadOnly = true;
  1169. this.textBox6.Size = new System.Drawing.Size(209, 21);
  1170. this.textBox6.TabIndex = 15;
  1171. //
  1172. // button7
  1173. //
  1174. this.button7.Location = new System.Drawing.Point(313, 74);
  1175. this.button7.Name = "button7";
  1176. this.button7.Size = new System.Drawing.Size(75, 21);
  1177. this.button7.TabIndex = 14;
  1178. this.button7.Text = "选择文件夹";
  1179. this.button7.UseVisualStyleBackColor = true;
  1180. this.button7.Click += new System.EventHandler(this.button7_Click);
  1181. //
  1182. // textBox5
  1183. //
  1184. this.textBox5.Location = new System.Drawing.Point(87, 74);
  1185. this.textBox5.Name = "textBox5";
  1186. this.textBox5.ReadOnly = true;
  1187. this.textBox5.Size = new System.Drawing.Size(209, 21);
  1188. this.textBox5.TabIndex = 13;
  1189. //
  1190. // button6
  1191. //
  1192. this.button6.Location = new System.Drawing.Point(313, 41);
  1193. this.button6.Name = "button6";
  1194. this.button6.Size = new System.Drawing.Size(75, 21);
  1195. this.button6.TabIndex = 12;
  1196. this.button6.Text = "选择文件夹";
  1197. this.button6.UseVisualStyleBackColor = true;
  1198. this.button6.Click += new System.EventHandler(this.button6_Click);
  1199. //
  1200. // textBox4
  1201. //
  1202. this.textBox4.Location = new System.Drawing.Point(87, 41);
  1203. this.textBox4.Name = "textBox4";
  1204. this.textBox4.ReadOnly = true;
  1205. this.textBox4.Size = new System.Drawing.Size(209, 21);
  1206. this.textBox4.TabIndex = 11;
  1207. //
  1208. // label20
  1209. //
  1210. this.label20.AutoSize = true;
  1211. this.label20.Location = new System.Drawing.Point(18, 109);
  1212. this.label20.Name = "label20";
  1213. this.label20.Size = new System.Drawing.Size(65, 12);
  1214. this.label20.TabIndex = 7;
  1215. this.label20.Text = "专用分析:";
  1216. //
  1217. // label19
  1218. //
  1219. this.label19.AutoSize = true;
  1220. this.label19.Location = new System.Drawing.Point(17, 77);
  1221. this.label19.Name = "label19";
  1222. this.label19.Size = new System.Drawing.Size(65, 12);
  1223. this.label19.TabIndex = 6;
  1224. this.label19.Text = "通用分析:";
  1225. //
  1226. // label18
  1227. //
  1228. this.label18.AutoSize = true;
  1229. this.label18.Location = new System.Drawing.Point(17, 45);
  1230. this.label18.Name = "label18";
  1231. this.label18.Size = new System.Drawing.Size(65, 12);
  1232. this.label18.TabIndex = 5;
  1233. this.label18.Text = "常规操作:";
  1234. //
  1235. // groupBox6
  1236. //
  1237. this.groupBox6.Controls.Add(this.listView2);
  1238. this.groupBox6.Location = new System.Drawing.Point(117, 74);
  1239. this.groupBox6.Name = "groupBox6";
  1240. this.groupBox6.Size = new System.Drawing.Size(394, 471);
  1241. this.groupBox6.TabIndex = 25;
  1242. this.groupBox6.TabStop = false;
  1243. this.groupBox6.Text = "点距列表";
  1244. //
  1245. // listView2
  1246. //
  1247. this.listView2.FullRowSelect = true;
  1248. this.listView2.HideSelection = false;
  1249. this.listView2.Location = new System.Drawing.Point(6, 20);
  1250. this.listView2.MultiSelect = false;
  1251. this.listView2.Name = "listView2";
  1252. this.listView2.Size = new System.Drawing.Size(382, 441);
  1253. this.listView2.TabIndex = 24;
  1254. this.listView2.UseCompatibleStateImageBehavior = false;
  1255. this.listView2.MouseDoubleClick += new System.Windows.Forms.MouseEventHandler(this.listView2_DoubleClick);
  1256. //
  1257. // groupBox9
  1258. //
  1259. this.groupBox9.Controls.Add(this.button10);
  1260. this.groupBox9.Controls.Add(this.button9);
  1261. this.groupBox9.Controls.Add(this.pictureBox1);
  1262. this.groupBox9.Controls.Add(this.checkBox7);
  1263. this.groupBox9.Location = new System.Drawing.Point(117, 74);
  1264. this.groupBox9.Name = "groupBox9";
  1265. this.groupBox9.Size = new System.Drawing.Size(394, 108);
  1266. this.groupBox9.TabIndex = 45;
  1267. this.groupBox9.TabStop = false;
  1268. this.groupBox9.Text = "启动图像";
  1269. //
  1270. // button10
  1271. //
  1272. this.button10.Location = new System.Drawing.Point(232, 43);
  1273. this.button10.Name = "button10";
  1274. this.button10.Size = new System.Drawing.Size(75, 23);
  1275. this.button10.TabIndex = 10;
  1276. this.button10.Text = "删除";
  1277. this.button10.UseVisualStyleBackColor = true;
  1278. this.button10.Click += new System.EventHandler(this.button10_Click);
  1279. //
  1280. // button9
  1281. //
  1282. this.button9.Font = new System.Drawing.Font("宋体", 25F);
  1283. this.button9.Location = new System.Drawing.Point(98, 14);
  1284. this.button9.Name = "button9";
  1285. this.button9.Size = new System.Drawing.Size(80, 80);
  1286. this.button9.TabIndex = 9;
  1287. this.button9.Text = "+";
  1288. this.button9.UseVisualStyleBackColor = true;
  1289. this.button9.Click += new System.EventHandler(this.button9_Click);
  1290. //
  1291. // pictureBox1
  1292. //
  1293. this.pictureBox1.Location = new System.Drawing.Point(98, 14);
  1294. this.pictureBox1.Name = "pictureBox1";
  1295. this.pictureBox1.Size = new System.Drawing.Size(80, 80);
  1296. this.pictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
  1297. this.pictureBox1.TabIndex = 8;
  1298. this.pictureBox1.TabStop = false;
  1299. //
  1300. // checkBox7
  1301. //
  1302. this.checkBox7.AutoSize = true;
  1303. this.checkBox7.Location = new System.Drawing.Point(8, 46);
  1304. this.checkBox7.Name = "checkBox7";
  1305. this.checkBox7.Size = new System.Drawing.Size(84, 16);
  1306. this.checkBox7.TabIndex = 6;
  1307. this.checkBox7.Text = "启动图像:";
  1308. this.checkBox7.UseVisualStyleBackColor = true;
  1309. //
  1310. // groupBox2
  1311. //
  1312. this.groupBox2.Controls.Add(this.btn_SaveAs);
  1313. this.groupBox2.Controls.Add(this.btn_Save);
  1314. this.groupBox2.Controls.Add(this.button2);
  1315. this.groupBox2.Controls.Add(this.button1);
  1316. this.groupBox2.Location = new System.Drawing.Point(117, 13);
  1317. this.groupBox2.Name = "groupBox2";
  1318. this.groupBox2.Size = new System.Drawing.Size(394, 58);
  1319. this.groupBox2.TabIndex = 2;
  1320. this.groupBox2.TabStop = false;
  1321. this.groupBox2.Text = "操作";
  1322. //
  1323. // btn_SaveAs
  1324. //
  1325. this.btn_SaveAs.Location = new System.Drawing.Point(232, 20);
  1326. this.btn_SaveAs.Name = "btn_SaveAs";
  1327. this.btn_SaveAs.Size = new System.Drawing.Size(75, 23);
  1328. this.btn_SaveAs.TabIndex = 3;
  1329. this.btn_SaveAs.Text = "另存为";
  1330. this.btn_SaveAs.UseVisualStyleBackColor = true;
  1331. this.btn_SaveAs.Click += new System.EventHandler(this.btn_SaveAs_Click);
  1332. //
  1333. // btn_Save
  1334. //
  1335. this.btn_Save.Location = new System.Drawing.Point(152, 20);
  1336. this.btn_Save.Name = "btn_Save";
  1337. this.btn_Save.Size = new System.Drawing.Size(75, 23);
  1338. this.btn_Save.TabIndex = 2;
  1339. this.btn_Save.Text = "保存";
  1340. this.btn_Save.UseVisualStyleBackColor = true;
  1341. this.btn_Save.Click += new System.EventHandler(this.btn_Save_Click);
  1342. //
  1343. // button2
  1344. //
  1345. this.button2.Location = new System.Drawing.Point(313, 20);
  1346. this.button2.Name = "button2";
  1347. this.button2.Size = new System.Drawing.Size(75, 23);
  1348. this.button2.TabIndex = 1;
  1349. this.button2.Text = "取消";
  1350. this.button2.UseVisualStyleBackColor = true;
  1351. this.button2.Click += new System.EventHandler(this.button2_Click);
  1352. //
  1353. // button1
  1354. //
  1355. this.button1.Location = new System.Drawing.Point(233, 20);
  1356. this.button1.Name = "button1";
  1357. this.button1.Size = new System.Drawing.Size(75, 23);
  1358. this.button1.TabIndex = 0;
  1359. this.button1.Text = "确定";
  1360. this.button1.UseVisualStyleBackColor = true;
  1361. this.button1.Click += new System.EventHandler(this.button1_Click);
  1362. //
  1363. // groupBox12
  1364. //
  1365. this.groupBox12.Controls.Add(this.button13);
  1366. this.groupBox12.Controls.Add(this.button5);
  1367. this.groupBox12.Controls.Add(this.button4);
  1368. this.groupBox12.Controls.Add(this.button3);
  1369. this.groupBox12.Location = new System.Drawing.Point(117, 12);
  1370. this.groupBox12.Name = "groupBox12";
  1371. this.groupBox12.Size = new System.Drawing.Size(394, 59);
  1372. this.groupBox12.TabIndex = 35;
  1373. this.groupBox12.TabStop = false;
  1374. this.groupBox12.Text = "操作";
  1375. //
  1376. // button13
  1377. //
  1378. this.button13.Location = new System.Drawing.Point(232, 21);
  1379. this.button13.Name = "button13";
  1380. this.button13.Size = new System.Drawing.Size(75, 23);
  1381. this.button13.TabIndex = 13;
  1382. this.button13.Text = "应用";
  1383. this.button13.UseVisualStyleBackColor = true;
  1384. this.button13.Click += new System.EventHandler(this.button13_Click);
  1385. //
  1386. // button5
  1387. //
  1388. this.button5.Location = new System.Drawing.Point(151, 21);
  1389. this.button5.Name = "button5";
  1390. this.button5.Size = new System.Drawing.Size(75, 23);
  1391. this.button5.TabIndex = 10;
  1392. this.button5.Text = "编辑";
  1393. this.button5.UseVisualStyleBackColor = true;
  1394. this.button5.Click += new System.EventHandler(this.button5_Click);
  1395. //
  1396. // button4
  1397. //
  1398. this.button4.Location = new System.Drawing.Point(70, 21);
  1399. this.button4.Name = "button4";
  1400. this.button4.Size = new System.Drawing.Size(75, 23);
  1401. this.button4.TabIndex = 9;
  1402. this.button4.Text = "新建";
  1403. this.button4.UseVisualStyleBackColor = true;
  1404. this.button4.Click += new System.EventHandler(this.button4_Click);
  1405. //
  1406. // button3
  1407. //
  1408. this.button3.Location = new System.Drawing.Point(311, 21);
  1409. this.button3.Name = "button3";
  1410. this.button3.Size = new System.Drawing.Size(75, 23);
  1411. this.button3.TabIndex = 8;
  1412. this.button3.Text = "删除";
  1413. this.button3.UseVisualStyleBackColor = true;
  1414. this.button3.Click += new System.EventHandler(this.button3_Click);
  1415. //
  1416. // groupBox3
  1417. //
  1418. this.groupBox3.Controls.Add(this.pictureBox2);
  1419. this.groupBox3.Controls.Add(this.button12);
  1420. this.groupBox3.Controls.Add(this.button11);
  1421. this.groupBox3.Controls.Add(this.label8);
  1422. this.groupBox3.Controls.Add(this.label7);
  1423. this.groupBox3.Controls.Add(this.label6);
  1424. this.groupBox3.Controls.Add(this.label5);
  1425. this.groupBox3.Controls.Add(this.label4);
  1426. this.groupBox3.Controls.Add(this.label3);
  1427. this.groupBox3.Controls.Add(this.label2);
  1428. this.groupBox3.Controls.Add(this.textBox_Email);
  1429. this.groupBox3.Controls.Add(this.textBox_Phone);
  1430. this.groupBox3.Controls.Add(this.textBox_Contact);
  1431. this.groupBox3.Controls.Add(this.textBox_Address);
  1432. this.groupBox3.Controls.Add(this.textBox_City);
  1433. this.groupBox3.Controls.Add(this.textBox_Province);
  1434. this.groupBox3.Controls.Add(this.textBox_CompanyName);
  1435. this.groupBox3.Controls.Add(this.label1);
  1436. this.groupBox3.Location = new System.Drawing.Point(117, 74);
  1437. this.groupBox3.Name = "groupBox3";
  1438. this.groupBox3.Size = new System.Drawing.Size(394, 276);
  1439. this.groupBox3.TabIndex = 35;
  1440. this.groupBox3.TabStop = false;
  1441. this.groupBox3.Text = "用户信息";
  1442. //
  1443. // pictureBox2
  1444. //
  1445. this.pictureBox2.Location = new System.Drawing.Point(280, 157);
  1446. this.pictureBox2.Name = "pictureBox2";
  1447. this.pictureBox2.Size = new System.Drawing.Size(36, 36);
  1448. this.pictureBox2.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage;
  1449. this.pictureBox2.TabIndex = 17;
  1450. this.pictureBox2.TabStop = false;
  1451. //
  1452. // button12
  1453. //
  1454. this.button12.Location = new System.Drawing.Point(322, 162);
  1455. this.button12.Name = "button12";
  1456. this.button12.Size = new System.Drawing.Size(45, 21);
  1457. this.button12.TabIndex = 16;
  1458. this.button12.Text = "删除";
  1459. this.button12.UseVisualStyleBackColor = true;
  1460. this.button12.Click += new System.EventHandler(this.button12_Click);
  1461. //
  1462. // button11
  1463. //
  1464. this.button11.Font = new System.Drawing.Font("宋体", 15F);
  1465. this.button11.Location = new System.Drawing.Point(280, 158);
  1466. this.button11.Name = "button11";
  1467. this.button11.Size = new System.Drawing.Size(36, 36);
  1468. this.button11.TabIndex = 15;
  1469. this.button11.Text = "+";
  1470. this.button11.UseVisualStyleBackColor = true;
  1471. this.button11.Click += new System.EventHandler(this.button11_Click);
  1472. //
  1473. // label8
  1474. //
  1475. this.label8.AutoSize = true;
  1476. this.label8.Location = new System.Drawing.Point(225, 162);
  1477. this.label8.Name = "label8";
  1478. this.label8.Size = new System.Drawing.Size(41, 12);
  1479. this.label8.TabIndex = 14;
  1480. this.label8.Text = "logo:";
  1481. //
  1482. // label7
  1483. //
  1484. this.label7.AutoSize = true;
  1485. this.label7.Location = new System.Drawing.Point(30, 162);
  1486. this.label7.Name = "label7";
  1487. this.label7.Size = new System.Drawing.Size(41, 12);
  1488. this.label7.TabIndex = 13;
  1489. this.label7.Text = "邮件:";
  1490. //
  1491. // label6
  1492. //
  1493. this.label6.AutoSize = true;
  1494. this.label6.Location = new System.Drawing.Point(225, 130);
  1495. this.label6.Name = "label6";
  1496. this.label6.Size = new System.Drawing.Size(41, 12);
  1497. this.label6.TabIndex = 12;
  1498. this.label6.Text = "电话:";
  1499. //
  1500. // label5
  1501. //
  1502. this.label5.AutoSize = true;
  1503. this.label5.Location = new System.Drawing.Point(18, 130);
  1504. this.label5.Name = "label5";
  1505. this.label5.Size = new System.Drawing.Size(53, 12);
  1506. this.label5.TabIndex = 11;
  1507. this.label5.Text = "联系人:";
  1508. //
  1509. // label4
  1510. //
  1511. this.label4.AutoSize = true;
  1512. this.label4.Location = new System.Drawing.Point(30, 98);
  1513. this.label4.Name = "label4";
  1514. this.label4.Size = new System.Drawing.Size(41, 12);
  1515. this.label4.TabIndex = 10;
  1516. this.label4.Text = "地址:";
  1517. //
  1518. // label3
  1519. //
  1520. this.label3.AutoSize = true;
  1521. this.label3.Location = new System.Drawing.Point(225, 66);
  1522. this.label3.Name = "label3";
  1523. this.label3.Size = new System.Drawing.Size(41, 12);
  1524. this.label3.TabIndex = 9;
  1525. this.label3.Text = "城市:";
  1526. //
  1527. // label2
  1528. //
  1529. this.label2.AutoSize = true;
  1530. this.label2.Cursor = System.Windows.Forms.Cursors.Default;
  1531. this.label2.Location = new System.Drawing.Point(30, 66);
  1532. this.label2.Name = "label2";
  1533. this.label2.Size = new System.Drawing.Size(41, 12);
  1534. this.label2.TabIndex = 8;
  1535. this.label2.Text = "省份:";
  1536. //
  1537. // textBox_Email
  1538. //
  1539. this.textBox_Email.Location = new System.Drawing.Point(77, 158);
  1540. this.textBox_Email.Name = "textBox_Email";
  1541. this.textBox_Email.Size = new System.Drawing.Size(140, 21);
  1542. this.textBox_Email.TabIndex = 7;
  1543. //
  1544. // textBox_Phone
  1545. //
  1546. this.textBox_Phone.Location = new System.Drawing.Point(277, 126);
  1547. this.textBox_Phone.Name = "textBox_Phone";
  1548. this.textBox_Phone.Size = new System.Drawing.Size(111, 21);
  1549. this.textBox_Phone.TabIndex = 6;
  1550. //
  1551. // textBox_Contact
  1552. //
  1553. this.textBox_Contact.Location = new System.Drawing.Point(77, 126);
  1554. this.textBox_Contact.Name = "textBox_Contact";
  1555. this.textBox_Contact.Size = new System.Drawing.Size(140, 21);
  1556. this.textBox_Contact.TabIndex = 5;
  1557. //
  1558. // textBox_Address
  1559. //
  1560. this.textBox_Address.Location = new System.Drawing.Point(77, 94);
  1561. this.textBox_Address.Name = "textBox_Address";
  1562. this.textBox_Address.Size = new System.Drawing.Size(311, 21);
  1563. this.textBox_Address.TabIndex = 4;
  1564. //
  1565. // textBox_City
  1566. //
  1567. this.textBox_City.Location = new System.Drawing.Point(277, 62);
  1568. this.textBox_City.Name = "textBox_City";
  1569. this.textBox_City.Size = new System.Drawing.Size(111, 21);
  1570. this.textBox_City.TabIndex = 3;
  1571. //
  1572. // textBox_Province
  1573. //
  1574. this.textBox_Province.Location = new System.Drawing.Point(77, 62);
  1575. this.textBox_Province.Name = "textBox_Province";
  1576. this.textBox_Province.Size = new System.Drawing.Size(140, 21);
  1577. this.textBox_Province.TabIndex = 2;
  1578. //
  1579. // textBox_CompanyName
  1580. //
  1581. this.textBox_CompanyName.Location = new System.Drawing.Point(77, 30);
  1582. this.textBox_CompanyName.Name = "textBox_CompanyName";
  1583. this.textBox_CompanyName.Size = new System.Drawing.Size(311, 21);
  1584. this.textBox_CompanyName.TabIndex = 1;
  1585. //
  1586. // label1
  1587. //
  1588. this.label1.AutoSize = true;
  1589. this.label1.Location = new System.Drawing.Point(6, 34);
  1590. this.label1.Name = "label1";
  1591. this.label1.Size = new System.Drawing.Size(65, 12);
  1592. this.label1.TabIndex = 0;
  1593. this.label1.Text = "单位名称:";
  1594. //
  1595. // groupBox5
  1596. //
  1597. this.groupBox5.Controls.Add(this.textBox8);
  1598. this.groupBox5.Controls.Add(this.textBox7);
  1599. this.groupBox5.Controls.Add(this.label31);
  1600. this.groupBox5.Controls.Add(this.label30);
  1601. this.groupBox5.Controls.Add(this.radioButton2);
  1602. this.groupBox5.Controls.Add(this.textBox3);
  1603. this.groupBox5.Controls.Add(this.radioButton1);
  1604. this.groupBox5.Controls.Add(this.comboBox1);
  1605. this.groupBox5.Controls.Add(this.label15);
  1606. this.groupBox5.Controls.Add(this.textBox2);
  1607. this.groupBox5.Controls.Add(this.label14);
  1608. this.groupBox5.Controls.Add(this.textBox1);
  1609. this.groupBox5.Controls.Add(this.label13);
  1610. this.groupBox5.Controls.Add(this.listView1);
  1611. this.groupBox5.Location = new System.Drawing.Point(117, 136);
  1612. this.groupBox5.Name = "groupBox5";
  1613. this.groupBox5.Size = new System.Drawing.Size(394, 408);
  1614. this.groupBox5.TabIndex = 1;
  1615. this.groupBox5.TabStop = false;
  1616. this.groupBox5.Text = "信息";
  1617. //
  1618. // textBox8
  1619. //
  1620. this.textBox8.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1621. | System.Windows.Forms.AnchorStyles.Left)));
  1622. this.textBox8.Location = new System.Drawing.Point(280, 65);
  1623. this.textBox8.Name = "textBox8";
  1624. this.textBox8.Size = new System.Drawing.Size(108, 21);
  1625. this.textBox8.TabIndex = 16;
  1626. //
  1627. // textBox7
  1628. //
  1629. this.textBox7.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1630. | System.Windows.Forms.AnchorStyles.Left)));
  1631. this.textBox7.Location = new System.Drawing.Point(280, 40);
  1632. this.textBox7.Name = "textBox7";
  1633. this.textBox7.Size = new System.Drawing.Size(108, 21);
  1634. this.textBox7.TabIndex = 15;
  1635. //
  1636. // label31
  1637. //
  1638. this.label31.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1639. | System.Windows.Forms.AnchorStyles.Left)));
  1640. this.label31.AutoSize = true;
  1641. this.label31.Location = new System.Drawing.Point(241, 68);
  1642. this.label31.Name = "label31";
  1643. this.label31.Size = new System.Drawing.Size(29, 12);
  1644. this.label31.TabIndex = 14;
  1645. this.label31.Text = "Z2:";
  1646. //
  1647. // label30
  1648. //
  1649. this.label30.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1650. | System.Windows.Forms.AnchorStyles.Left)));
  1651. this.label30.AutoSize = true;
  1652. this.label30.Location = new System.Drawing.Point(241, 45);
  1653. this.label30.Name = "label30";
  1654. this.label30.Size = new System.Drawing.Size(29, 12);
  1655. this.label30.TabIndex = 13;
  1656. this.label30.Text = "Z1:";
  1657. //
  1658. // radioButton2
  1659. //
  1660. this.radioButton2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1661. | System.Windows.Forms.AnchorStyles.Left)));
  1662. this.radioButton2.AutoSize = true;
  1663. this.radioButton2.Location = new System.Drawing.Point(9, 89);
  1664. this.radioButton2.Name = "radioButton2";
  1665. this.radioButton2.Size = new System.Drawing.Size(47, 16);
  1666. this.radioButton2.TabIndex = 11;
  1667. this.radioButton2.TabStop = true;
  1668. this.radioButton2.Text = "重置";
  1669. this.radioButton2.UseVisualStyleBackColor = true;
  1670. this.radioButton2.CheckedChanged += new System.EventHandler(this.radioButton2_CheckedChanged);
  1671. //
  1672. // textBox3
  1673. //
  1674. this.textBox3.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1675. | System.Windows.Forms.AnchorStyles.Left)));
  1676. this.textBox3.Location = new System.Drawing.Point(77, 65);
  1677. this.textBox3.Name = "textBox3";
  1678. this.textBox3.Size = new System.Drawing.Size(108, 21);
  1679. this.textBox3.TabIndex = 10;
  1680. //
  1681. // radioButton1
  1682. //
  1683. this.radioButton1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1684. | System.Windows.Forms.AnchorStyles.Left)));
  1685. this.radioButton1.AutoSize = true;
  1686. this.radioButton1.Location = new System.Drawing.Point(9, 67);
  1687. this.radioButton1.Name = "radioButton1";
  1688. this.radioButton1.Size = new System.Drawing.Size(47, 16);
  1689. this.radioButton1.TabIndex = 9;
  1690. this.radioButton1.TabStop = true;
  1691. this.radioButton1.Text = "延续";
  1692. this.radioButton1.UseVisualStyleBackColor = true;
  1693. this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
  1694. //
  1695. // comboBox1
  1696. //
  1697. this.comboBox1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1698. | System.Windows.Forms.AnchorStyles.Left)));
  1699. this.comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
  1700. this.comboBox1.FormattingEnabled = true;
  1701. this.comboBox1.Location = new System.Drawing.Point(77, 41);
  1702. this.comboBox1.Name = "comboBox1";
  1703. this.comboBox1.Size = new System.Drawing.Size(108, 20);
  1704. this.comboBox1.TabIndex = 8;
  1705. //
  1706. // label15
  1707. //
  1708. this.label15.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1709. | System.Windows.Forms.AnchorStyles.Left)));
  1710. this.label15.AutoSize = true;
  1711. this.label15.Location = new System.Drawing.Point(9, 45);
  1712. this.label15.Name = "label15";
  1713. this.label15.Size = new System.Drawing.Size(65, 12);
  1714. this.label15.TabIndex = 5;
  1715. this.label15.Text = "数值位数:";
  1716. //
  1717. // textBox2
  1718. //
  1719. this.textBox2.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1720. | System.Windows.Forms.AnchorStyles.Left)));
  1721. this.textBox2.Location = new System.Drawing.Point(280, 15);
  1722. this.textBox2.Name = "textBox2";
  1723. this.textBox2.Size = new System.Drawing.Size(108, 21);
  1724. this.textBox2.TabIndex = 4;
  1725. //
  1726. // label14
  1727. //
  1728. this.label14.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1729. | System.Windows.Forms.AnchorStyles.Left)));
  1730. this.label14.AutoSize = true;
  1731. this.label14.Location = new System.Drawing.Point(205, 20);
  1732. this.label14.Name = "label14";
  1733. this.label14.Size = new System.Drawing.Size(65, 12);
  1734. this.label14.TabIndex = 3;
  1735. this.label14.Text = "名称格式:";
  1736. //
  1737. // textBox1
  1738. //
  1739. this.textBox1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1740. | System.Windows.Forms.AnchorStyles.Left)));
  1741. this.textBox1.Location = new System.Drawing.Point(77, 16);
  1742. this.textBox1.Name = "textBox1";
  1743. this.textBox1.Size = new System.Drawing.Size(108, 21);
  1744. this.textBox1.TabIndex = 2;
  1745. //
  1746. // label13
  1747. //
  1748. this.label13.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1749. | System.Windows.Forms.AnchorStyles.Left)));
  1750. this.label13.AutoSize = true;
  1751. this.label13.Location = new System.Drawing.Point(33, 21);
  1752. this.label13.Name = "label13";
  1753. this.label13.Size = new System.Drawing.Size(41, 12);
  1754. this.label13.TabIndex = 1;
  1755. this.label13.Text = "文本:";
  1756. //
  1757. // listView1
  1758. //
  1759. this.listView1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  1760. | System.Windows.Forms.AnchorStyles.Left)));
  1761. this.listView1.GridLines = true;
  1762. this.listView1.HideSelection = false;
  1763. this.listView1.Location = new System.Drawing.Point(8, 124);
  1764. this.listView1.Name = "listView1";
  1765. this.listView1.Size = new System.Drawing.Size(380, 275);
  1766. this.listView1.TabIndex = 12;
  1767. this.listView1.UseCompatibleStateImageBehavior = false;
  1768. this.listView1.View = System.Windows.Forms.View.Details;
  1769. //
  1770. // groupBox4
  1771. //
  1772. this.groupBox4.Controls.Add(this.label12);
  1773. this.groupBox4.Controls.Add(this.label11);
  1774. this.groupBox4.Controls.Add(this.label10);
  1775. this.groupBox4.Controls.Add(this.label9);
  1776. this.groupBox4.Controls.Add(this.textBox_Interface);
  1777. this.groupBox4.Controls.Add(this.textBox_Camera);
  1778. this.groupBox4.Controls.Add(this.textBox_SN);
  1779. this.groupBox4.Controls.Add(this.textBox_Model);
  1780. this.groupBox4.Location = new System.Drawing.Point(117, 359);
  1781. this.groupBox4.Name = "groupBox4";
  1782. this.groupBox4.Size = new System.Drawing.Size(394, 185);
  1783. this.groupBox4.TabIndex = 30;
  1784. this.groupBox4.TabStop = false;
  1785. this.groupBox4.Text = "显微镜信息";
  1786. //
  1787. // label12
  1788. //
  1789. this.label12.AutoSize = true;
  1790. this.label12.Location = new System.Drawing.Point(30, 130);
  1791. this.label12.Name = "label12";
  1792. this.label12.Size = new System.Drawing.Size(41, 12);
  1793. this.label12.TabIndex = 7;
  1794. this.label12.Text = "接口:";
  1795. //
  1796. // label11
  1797. //
  1798. this.label11.AutoSize = true;
  1799. this.label11.Location = new System.Drawing.Point(18, 98);
  1800. this.label11.Name = "label11";
  1801. this.label11.Size = new System.Drawing.Size(53, 12);
  1802. this.label11.TabIndex = 6;
  1803. this.label11.Text = "摄像头:";
  1804. //
  1805. // label10
  1806. //
  1807. this.label10.AutoSize = true;
  1808. this.label10.Location = new System.Drawing.Point(30, 66);
  1809. this.label10.Name = "label10";
  1810. this.label10.Size = new System.Drawing.Size(41, 12);
  1811. this.label10.TabIndex = 5;
  1812. this.label10.Text = "SN码:";
  1813. //
  1814. // label9
  1815. //
  1816. this.label9.AutoSize = true;
  1817. this.label9.Location = new System.Drawing.Point(30, 34);
  1818. this.label9.Name = "label9";
  1819. this.label9.Size = new System.Drawing.Size(41, 12);
  1820. this.label9.TabIndex = 4;
  1821. this.label9.Text = "型号:";
  1822. //
  1823. // textBox_Interface
  1824. //
  1825. this.textBox_Interface.Location = new System.Drawing.Point(77, 126);
  1826. this.textBox_Interface.Name = "textBox_Interface";
  1827. this.textBox_Interface.Size = new System.Drawing.Size(311, 21);
  1828. this.textBox_Interface.TabIndex = 3;
  1829. //
  1830. // textBox_Camera
  1831. //
  1832. this.textBox_Camera.Location = new System.Drawing.Point(77, 94);
  1833. this.textBox_Camera.Name = "textBox_Camera";
  1834. this.textBox_Camera.Size = new System.Drawing.Size(311, 21);
  1835. this.textBox_Camera.TabIndex = 2;
  1836. //
  1837. // textBox_SN
  1838. //
  1839. this.textBox_SN.Location = new System.Drawing.Point(77, 62);
  1840. this.textBox_SN.Name = "textBox_SN";
  1841. this.textBox_SN.Size = new System.Drawing.Size(311, 21);
  1842. this.textBox_SN.TabIndex = 1;
  1843. //
  1844. // textBox_Model
  1845. //
  1846. this.textBox_Model.Location = new System.Drawing.Point(77, 30);
  1847. this.textBox_Model.Name = "textBox_Model";
  1848. this.textBox_Model.Size = new System.Drawing.Size(311, 21);
  1849. this.textBox_Model.TabIndex = 0;
  1850. //
  1851. // groupBox11
  1852. //
  1853. this.groupBox11.Controls.Add(this.checkBox9);
  1854. this.groupBox11.Controls.Add(this.checkBox8);
  1855. this.groupBox11.Location = new System.Drawing.Point(117, 367);
  1856. this.groupBox11.Name = "groupBox11";
  1857. this.groupBox11.Size = new System.Drawing.Size(394, 177);
  1858. this.groupBox11.TabIndex = 40;
  1859. this.groupBox11.TabStop = false;
  1860. this.groupBox11.Text = "其他";
  1861. //
  1862. // checkBox9
  1863. //
  1864. this.checkBox9.AutoSize = true;
  1865. this.checkBox9.Location = new System.Drawing.Point(8, 66);
  1866. this.checkBox9.Name = "checkBox9";
  1867. this.checkBox9.Size = new System.Drawing.Size(156, 16);
  1868. this.checkBox9.TabIndex = 8;
  1869. this.checkBox9.Text = "自动添加AxioVision标尺";
  1870. this.checkBox9.UseVisualStyleBackColor = true;
  1871. //
  1872. // checkBox8
  1873. //
  1874. this.checkBox8.AutoSize = true;
  1875. this.checkBox8.Location = new System.Drawing.Point(8, 34);
  1876. this.checkBox8.Name = "checkBox8";
  1877. this.checkBox8.Size = new System.Drawing.Size(114, 16);
  1878. this.checkBox8.TabIndex = 7;
  1879. this.checkBox8.Text = "自动添加ZEN标尺";
  1880. this.checkBox8.UseVisualStyleBackColor = true;
  1881. //
  1882. // listView3
  1883. //
  1884. this.listView3.FullRowSelect = true;
  1885. this.listView3.GridLines = true;
  1886. this.listView3.HideSelection = false;
  1887. this.listView3.Location = new System.Drawing.Point(117, 73);
  1888. this.listView3.MultiSelect = false;
  1889. this.listView3.Name = "listView3";
  1890. this.listView3.Size = new System.Drawing.Size(394, 471);
  1891. this.listView3.TabIndex = 46;
  1892. this.listView3.UseCompatibleStateImageBehavior = false;
  1893. this.listView3.Click += new System.EventHandler(this.listView1_SelectedIndexChanged);
  1894. //
  1895. // label21
  1896. //
  1897. this.label21.AutoSize = true;
  1898. this.label21.Location = new System.Drawing.Point(12, 44);
  1899. this.label21.Name = "label21";
  1900. this.label21.Size = new System.Drawing.Size(83, 12);
  1901. this.label21.TabIndex = 10;
  1902. this.label21.Text = "Z轴运动方向:";
  1903. //
  1904. // label22
  1905. //
  1906. this.label22.AutoSize = true;
  1907. this.label22.Location = new System.Drawing.Point(12, 117);
  1908. this.label22.Name = "label22";
  1909. this.label22.Size = new System.Drawing.Size(95, 12);
  1910. this.label22.TabIndex = 11;
  1911. this.label22.Text = "Y轴运动方向:左";
  1912. //
  1913. // label23
  1914. //
  1915. this.label23.AutoSize = true;
  1916. this.label23.Location = new System.Drawing.Point(239, 117);
  1917. this.label23.Name = "label23";
  1918. this.label23.Size = new System.Drawing.Size(17, 12);
  1919. this.label23.TabIndex = 12;
  1920. this.label23.Text = "右";
  1921. //
  1922. // label24
  1923. //
  1924. this.label24.AutoSize = true;
  1925. this.label24.Location = new System.Drawing.Point(239, 82);
  1926. this.label24.Name = "label24";
  1927. this.label24.Size = new System.Drawing.Size(17, 12);
  1928. this.label24.TabIndex = 13;
  1929. this.label24.Text = "右";
  1930. //
  1931. // label25
  1932. //
  1933. this.label25.AutoSize = true;
  1934. this.label25.Location = new System.Drawing.Point(12, 82);
  1935. this.label25.Name = "label25";
  1936. this.label25.Size = new System.Drawing.Size(95, 12);
  1937. this.label25.TabIndex = 14;
  1938. this.label25.Text = "X轴运动方向:左";
  1939. //
  1940. // panel1
  1941. //
  1942. this.panel1.Controls.Add(this.radioButton7);
  1943. this.panel1.Controls.Add(this.radioButton6);
  1944. this.panel1.Location = new System.Drawing.Point(101, 39);
  1945. this.panel1.Name = "panel1";
  1946. this.panel1.Size = new System.Drawing.Size(84, 24);
  1947. this.panel1.TabIndex = 16;
  1948. //
  1949. // radioButton7
  1950. //
  1951. this.radioButton7.AutoSize = true;
  1952. this.radioButton7.Location = new System.Drawing.Point(43, 3);
  1953. this.radioButton7.Name = "radioButton7";
  1954. this.radioButton7.Size = new System.Drawing.Size(35, 16);
  1955. this.radioButton7.TabIndex = 1;
  1956. this.radioButton7.TabStop = true;
  1957. this.radioButton7.Text = "下";
  1958. this.radioButton7.UseVisualStyleBackColor = true;
  1959. //
  1960. // radioButton6
  1961. //
  1962. this.radioButton6.AutoSize = true;
  1963. this.radioButton6.Location = new System.Drawing.Point(3, 3);
  1964. this.radioButton6.Name = "radioButton6";
  1965. this.radioButton6.Size = new System.Drawing.Size(35, 16);
  1966. this.radioButton6.TabIndex = 0;
  1967. this.radioButton6.TabStop = true;
  1968. this.radioButton6.Text = "上";
  1969. this.radioButton6.UseVisualStyleBackColor = true;
  1970. //
  1971. // panel2
  1972. //
  1973. this.panel2.Controls.Add(this.radioButton8);
  1974. this.panel2.Controls.Add(this.radioButton9);
  1975. this.panel2.Location = new System.Drawing.Point(144, 75);
  1976. this.panel2.Name = "panel2";
  1977. this.panel2.Size = new System.Drawing.Size(84, 24);
  1978. this.panel2.TabIndex = 17;
  1979. //
  1980. // radioButton8
  1981. //
  1982. this.radioButton8.AutoSize = true;
  1983. this.radioButton8.Location = new System.Drawing.Point(5, 5);
  1984. this.radioButton8.Name = "radioButton8";
  1985. this.radioButton8.Size = new System.Drawing.Size(35, 16);
  1986. this.radioButton8.TabIndex = 3;
  1987. this.radioButton8.TabStop = true;
  1988. this.radioButton8.Text = "正";
  1989. this.radioButton8.UseVisualStyleBackColor = true;
  1990. //
  1991. // radioButton9
  1992. //
  1993. this.radioButton9.AutoSize = true;
  1994. this.radioButton9.Location = new System.Drawing.Point(44, 5);
  1995. this.radioButton9.Name = "radioButton9";
  1996. this.radioButton9.Size = new System.Drawing.Size(35, 16);
  1997. this.radioButton9.TabIndex = 2;
  1998. this.radioButton9.TabStop = true;
  1999. this.radioButton9.Text = "负";
  2000. this.radioButton9.UseVisualStyleBackColor = true;
  2001. //
  2002. // panel3
  2003. //
  2004. this.panel3.Controls.Add(this.radioButton10);
  2005. this.panel3.Controls.Add(this.radioButton11);
  2006. this.panel3.Location = new System.Drawing.Point(273, 76);
  2007. this.panel3.Name = "panel3";
  2008. this.panel3.Size = new System.Drawing.Size(82, 23);
  2009. this.panel3.TabIndex = 18;
  2010. //
  2011. // radioButton10
  2012. //
  2013. this.radioButton10.AutoSize = true;
  2014. this.radioButton10.Location = new System.Drawing.Point(5, 4);
  2015. this.radioButton10.Name = "radioButton10";
  2016. this.radioButton10.Size = new System.Drawing.Size(35, 16);
  2017. this.radioButton10.TabIndex = 5;
  2018. this.radioButton10.TabStop = true;
  2019. this.radioButton10.Text = "正";
  2020. this.radioButton10.UseVisualStyleBackColor = true;
  2021. //
  2022. // radioButton11
  2023. //
  2024. this.radioButton11.AutoSize = true;
  2025. this.radioButton11.Location = new System.Drawing.Point(44, 4);
  2026. this.radioButton11.Name = "radioButton11";
  2027. this.radioButton11.Size = new System.Drawing.Size(35, 16);
  2028. this.radioButton11.TabIndex = 4;
  2029. this.radioButton11.TabStop = true;
  2030. this.radioButton11.Text = "负";
  2031. this.radioButton11.UseVisualStyleBackColor = true;
  2032. //
  2033. // panel4
  2034. //
  2035. this.panel4.Controls.Add(this.radioButton12);
  2036. this.panel4.Controls.Add(this.radioButton13);
  2037. this.panel4.Location = new System.Drawing.Point(144, 110);
  2038. this.panel4.Name = "panel4";
  2039. this.panel4.Size = new System.Drawing.Size(84, 24);
  2040. this.panel4.TabIndex = 19;
  2041. //
  2042. // radioButton12
  2043. //
  2044. this.radioButton12.AutoSize = true;
  2045. this.radioButton12.Location = new System.Drawing.Point(5, 5);
  2046. this.radioButton12.Name = "radioButton12";
  2047. this.radioButton12.Size = new System.Drawing.Size(35, 16);
  2048. this.radioButton12.TabIndex = 7;
  2049. this.radioButton12.TabStop = true;
  2050. this.radioButton12.Text = "正";
  2051. this.radioButton12.UseVisualStyleBackColor = true;
  2052. //
  2053. // radioButton13
  2054. //
  2055. this.radioButton13.AutoSize = true;
  2056. this.radioButton13.Location = new System.Drawing.Point(47, 5);
  2057. this.radioButton13.Name = "radioButton13";
  2058. this.radioButton13.Size = new System.Drawing.Size(35, 16);
  2059. this.radioButton13.TabIndex = 6;
  2060. this.radioButton13.TabStop = true;
  2061. this.radioButton13.Text = "负";
  2062. this.radioButton13.UseVisualStyleBackColor = true;
  2063. //
  2064. // panel5
  2065. //
  2066. this.panel5.Controls.Add(this.radioButton14);
  2067. this.panel5.Controls.Add(this.radioButton15);
  2068. this.panel5.Location = new System.Drawing.Point(273, 112);
  2069. this.panel5.Name = "panel5";
  2070. this.panel5.Size = new System.Drawing.Size(82, 22);
  2071. this.panel5.TabIndex = 20;
  2072. //
  2073. // radioButton14
  2074. //
  2075. this.radioButton14.AutoSize = true;
  2076. this.radioButton14.Location = new System.Drawing.Point(5, 3);
  2077. this.radioButton14.Name = "radioButton14";
  2078. this.radioButton14.Size = new System.Drawing.Size(35, 16);
  2079. this.radioButton14.TabIndex = 9;
  2080. this.radioButton14.TabStop = true;
  2081. this.radioButton14.Text = "正";
  2082. this.radioButton14.UseVisualStyleBackColor = true;
  2083. //
  2084. // radioButton15
  2085. //
  2086. this.radioButton15.AutoSize = true;
  2087. this.radioButton15.Location = new System.Drawing.Point(44, 3);
  2088. this.radioButton15.Name = "radioButton15";
  2089. this.radioButton15.Size = new System.Drawing.Size(35, 16);
  2090. this.radioButton15.TabIndex = 8;
  2091. this.radioButton15.TabStop = true;
  2092. this.radioButton15.Text = "负";
  2093. this.radioButton15.UseVisualStyleBackColor = true;
  2094. //
  2095. // groupBox15
  2096. //
  2097. this.groupBox15.Controls.Add(this.panel5);
  2098. this.groupBox15.Controls.Add(this.panel4);
  2099. this.groupBox15.Controls.Add(this.panel3);
  2100. this.groupBox15.Controls.Add(this.panel2);
  2101. this.groupBox15.Controls.Add(this.panel1);
  2102. this.groupBox15.Controls.Add(this.label25);
  2103. this.groupBox15.Controls.Add(this.label24);
  2104. this.groupBox15.Controls.Add(this.label23);
  2105. this.groupBox15.Controls.Add(this.label22);
  2106. this.groupBox15.Controls.Add(this.label21);
  2107. this.groupBox15.Location = new System.Drawing.Point(117, 73);
  2108. this.groupBox15.Name = "groupBox15";
  2109. this.groupBox15.Size = new System.Drawing.Size(394, 471);
  2110. this.groupBox15.TabIndex = 47;
  2111. this.groupBox15.TabStop = false;
  2112. this.groupBox15.Text = "方向设置";
  2113. //
  2114. // groupBox16
  2115. //
  2116. this.groupBox16.Controls.Add(this.panel6);
  2117. this.groupBox16.Controls.Add(this.label28);
  2118. this.groupBox16.Controls.Add(this.label27);
  2119. this.groupBox16.Controls.Add(this.label26);
  2120. this.groupBox16.Controls.Add(this.numericUpDown1);
  2121. this.groupBox16.Controls.Add(this.comboBox2);
  2122. this.groupBox16.Location = new System.Drawing.Point(117, 73);
  2123. this.groupBox16.Name = "groupBox16";
  2124. this.groupBox16.Size = new System.Drawing.Size(394, 471);
  2125. this.groupBox16.TabIndex = 48;
  2126. this.groupBox16.TabStop = false;
  2127. this.groupBox16.Text = "辅助线设置";
  2128. //
  2129. // panel6
  2130. //
  2131. this.panel6.BackColor = System.Drawing.Color.Red;
  2132. this.panel6.Cursor = System.Windows.Forms.Cursors.AppStarting;
  2133. this.panel6.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
  2134. this.panel6.Location = new System.Drawing.Point(135, 105);
  2135. this.panel6.Name = "panel6";
  2136. this.panel6.Size = new System.Drawing.Size(152, 20);
  2137. this.panel6.TabIndex = 18;
  2138. this.panel6.UseVisualStyleBackColor = false;
  2139. this.panel6.Click += new System.EventHandler(this.panel6_Click);
  2140. //
  2141. // label28
  2142. //
  2143. this.label28.AutoSize = true;
  2144. this.label28.Location = new System.Drawing.Point(45, 162);
  2145. this.label28.Name = "label28";
  2146. this.label28.Size = new System.Drawing.Size(59, 12);
  2147. this.label28.TabIndex = 17;
  2148. this.label28.Text = "线条宽度:";
  2149. //
  2150. // label27
  2151. //
  2152. this.label27.AutoSize = true;
  2153. this.label27.Location = new System.Drawing.Point(45, 108);
  2154. this.label27.Name = "label27";
  2155. this.label27.Size = new System.Drawing.Size(59, 12);
  2156. this.label27.TabIndex = 16;
  2157. this.label27.Text = "线条颜色:";
  2158. //
  2159. // label26
  2160. //
  2161. this.label26.AutoSize = true;
  2162. this.label26.Location = new System.Drawing.Point(45, 54);
  2163. this.label26.Name = "label26";
  2164. this.label26.Size = new System.Drawing.Size(59, 12);
  2165. this.label26.TabIndex = 15;
  2166. this.label26.Text = "线条样式:";
  2167. //
  2168. // numericUpDown1
  2169. //
  2170. this.numericUpDown1.Location = new System.Drawing.Point(135, 158);
  2171. this.numericUpDown1.Name = "numericUpDown1";
  2172. this.numericUpDown1.Size = new System.Drawing.Size(152, 21);
  2173. this.numericUpDown1.TabIndex = 14;
  2174. this.numericUpDown1.Value = new decimal(new int[] {
  2175. 1,
  2176. 0,
  2177. 0,
  2178. 0});
  2179. //
  2180. // comboBox2
  2181. //
  2182. this.comboBox2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
  2183. this.comboBox2.FormattingEnabled = true;
  2184. this.comboBox2.Location = new System.Drawing.Point(135, 51);
  2185. this.comboBox2.Name = "comboBox2";
  2186. this.comboBox2.Size = new System.Drawing.Size(152, 20);
  2187. this.comboBox2.TabIndex = 12;
  2188. //
  2189. // button17
  2190. //
  2191. this.button17.Location = new System.Drawing.Point(311, 21);
  2192. this.button17.Name = "button17";
  2193. this.button17.Size = new System.Drawing.Size(75, 23);
  2194. this.button17.TabIndex = 8;
  2195. this.button17.Text = "删除";
  2196. this.button17.UseVisualStyleBackColor = true;
  2197. this.button17.Click += new System.EventHandler(this.button17_Click);
  2198. //
  2199. // button16
  2200. //
  2201. this.button16.Location = new System.Drawing.Point(70, 21);
  2202. this.button16.Name = "button16";
  2203. this.button16.Size = new System.Drawing.Size(75, 23);
  2204. this.button16.TabIndex = 9;
  2205. this.button16.Text = "新建";
  2206. this.button16.UseVisualStyleBackColor = true;
  2207. this.button16.Click += new System.EventHandler(this.button16_Click);
  2208. //
  2209. // button15
  2210. //
  2211. this.button15.Location = new System.Drawing.Point(151, 21);
  2212. this.button15.Name = "button15";
  2213. this.button15.Size = new System.Drawing.Size(75, 23);
  2214. this.button15.TabIndex = 10;
  2215. this.button15.Text = "编辑";
  2216. this.button15.UseVisualStyleBackColor = true;
  2217. this.button15.Click += new System.EventHandler(this.button15_Click);
  2218. //
  2219. // button14
  2220. //
  2221. this.button14.Location = new System.Drawing.Point(232, 21);
  2222. this.button14.Name = "button14";
  2223. this.button14.Size = new System.Drawing.Size(75, 23);
  2224. this.button14.TabIndex = 13;
  2225. this.button14.Text = "应用";
  2226. this.button14.UseVisualStyleBackColor = true;
  2227. this.button14.Click += new System.EventHandler(this.button14_Click);
  2228. //
  2229. // groupBox13
  2230. //
  2231. this.groupBox13.Controls.Add(this.button14);
  2232. this.groupBox13.Controls.Add(this.button15);
  2233. this.groupBox13.Controls.Add(this.button16);
  2234. this.groupBox13.Controls.Add(this.button17);
  2235. this.groupBox13.Location = new System.Drawing.Point(117, 13);
  2236. this.groupBox13.Name = "groupBox13";
  2237. this.groupBox13.Size = new System.Drawing.Size(394, 59);
  2238. this.groupBox13.TabIndex = 36;
  2239. this.groupBox13.TabStop = false;
  2240. this.groupBox13.Text = "操作";
  2241. //
  2242. // button19
  2243. //
  2244. this.button19.Location = new System.Drawing.Point(311, 21);
  2245. this.button19.Name = "button19";
  2246. this.button19.Size = new System.Drawing.Size(75, 23);
  2247. this.button19.TabIndex = 10;
  2248. this.button19.Text = "取消";
  2249. this.button19.UseVisualStyleBackColor = true;
  2250. this.button19.Click += new System.EventHandler(this.button19_Click);
  2251. //
  2252. // button18
  2253. //
  2254. this.button18.Location = new System.Drawing.Point(232, 21);
  2255. this.button18.Name = "button18";
  2256. this.button18.Size = new System.Drawing.Size(75, 23);
  2257. this.button18.TabIndex = 13;
  2258. this.button18.Text = "确定";
  2259. this.button18.UseVisualStyleBackColor = true;
  2260. this.button18.Click += new System.EventHandler(this.button18_Click);
  2261. //
  2262. // groupBox14
  2263. //
  2264. this.groupBox14.Controls.Add(this.button18);
  2265. this.groupBox14.Controls.Add(this.button19);
  2266. this.groupBox14.Location = new System.Drawing.Point(117, 13);
  2267. this.groupBox14.Name = "groupBox14";
  2268. this.groupBox14.Size = new System.Drawing.Size(394, 59);
  2269. this.groupBox14.TabIndex = 37;
  2270. this.groupBox14.TabStop = false;
  2271. this.groupBox14.Text = "操作";
  2272. //
  2273. // groupBox17
  2274. //
  2275. this.groupBox17.Controls.Add(this.button20);
  2276. this.groupBox17.Controls.Add(this.button21);
  2277. this.groupBox17.Location = new System.Drawing.Point(117, 13);
  2278. this.groupBox17.Name = "groupBox17";
  2279. this.groupBox17.Size = new System.Drawing.Size(394, 59);
  2280. this.groupBox17.TabIndex = 38;
  2281. this.groupBox17.TabStop = false;
  2282. this.groupBox17.Text = "操作";
  2283. //
  2284. // button20
  2285. //
  2286. this.button20.Location = new System.Drawing.Point(232, 21);
  2287. this.button20.Name = "button20";
  2288. this.button20.Size = new System.Drawing.Size(75, 23);
  2289. this.button20.TabIndex = 13;
  2290. this.button20.Text = "应用";
  2291. this.button20.UseVisualStyleBackColor = true;
  2292. this.button20.Click += new System.EventHandler(this.button20_Click);
  2293. //
  2294. // button21
  2295. //
  2296. this.button21.Location = new System.Drawing.Point(311, 21);
  2297. this.button21.Name = "button21";
  2298. this.button21.Size = new System.Drawing.Size(75, 23);
  2299. this.button21.TabIndex = 10;
  2300. this.button21.Text = "取消";
  2301. this.button21.UseVisualStyleBackColor = true;
  2302. this.button21.Click += new System.EventHandler(this.button21_Click);
  2303. //
  2304. // groupBox18
  2305. //
  2306. this.groupBox18.Controls.Add(this.button22);
  2307. this.groupBox18.Location = new System.Drawing.Point(117, 12);
  2308. this.groupBox18.Name = "groupBox18";
  2309. this.groupBox18.Size = new System.Drawing.Size(394, 59);
  2310. this.groupBox18.TabIndex = 39;
  2311. this.groupBox18.TabStop = false;
  2312. this.groupBox18.Text = "操作";
  2313. //
  2314. // button22
  2315. //
  2316. this.button22.Location = new System.Drawing.Point(307, 22);
  2317. this.button22.Name = "button22";
  2318. this.button22.Size = new System.Drawing.Size(75, 23);
  2319. this.button22.TabIndex = 13;
  2320. this.button22.Text = "应用";
  2321. this.button22.UseVisualStyleBackColor = true;
  2322. //
  2323. // groupBox19
  2324. //
  2325. this.groupBox19.Controls.Add(this.btn_Del);
  2326. this.groupBox19.Controls.Add(this.comboBox_Name);
  2327. this.groupBox19.Controls.Add(this.label29);
  2328. this.groupBox19.Location = new System.Drawing.Point(117, 74);
  2329. this.groupBox19.Name = "groupBox19";
  2330. this.groupBox19.Size = new System.Drawing.Size(394, 58);
  2331. this.groupBox19.TabIndex = 49;
  2332. this.groupBox19.TabStop = false;
  2333. this.groupBox19.Text = "当前使用";
  2334. //
  2335. // btn_Del
  2336. //
  2337. this.btn_Del.Location = new System.Drawing.Point(313, 23);
  2338. this.btn_Del.Name = "btn_Del";
  2339. this.btn_Del.Size = new System.Drawing.Size(75, 23);
  2340. this.btn_Del.TabIndex = 10;
  2341. this.btn_Del.Text = "删除";
  2342. this.btn_Del.UseVisualStyleBackColor = true;
  2343. this.btn_Del.Click += new System.EventHandler(this.btn_Del_Click);
  2344. //
  2345. // comboBox_Name
  2346. //
  2347. this.comboBox_Name.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
  2348. | System.Windows.Forms.AnchorStyles.Left)));
  2349. this.comboBox_Name.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
  2350. this.comboBox_Name.FormattingEnabled = true;
  2351. this.comboBox_Name.Location = new System.Drawing.Point(77, 25);
  2352. this.comboBox_Name.Name = "comboBox_Name";
  2353. this.comboBox_Name.Size = new System.Drawing.Size(230, 20);
  2354. this.comboBox_Name.TabIndex = 9;
  2355. //
  2356. // label29
  2357. //
  2358. this.label29.AutoSize = true;
  2359. this.label29.Location = new System.Drawing.Point(30, 28);
  2360. this.label29.Name = "label29";
  2361. this.label29.Size = new System.Drawing.Size(41, 12);
  2362. this.label29.TabIndex = 0;
  2363. this.label29.Text = "名称:";
  2364. //
  2365. // groupBox20
  2366. //
  2367. this.groupBox20.Controls.Add(this.checkBox10);
  2368. this.groupBox20.Controls.Add(this.comboBox3);
  2369. this.groupBox20.Controls.Add(this.numericUpDown3);
  2370. this.groupBox20.Controls.Add(this.numericUpDown2);
  2371. this.groupBox20.Controls.Add(this.label35);
  2372. this.groupBox20.Controls.Add(this.label34);
  2373. this.groupBox20.Controls.Add(this.label33);
  2374. this.groupBox20.Location = new System.Drawing.Point(117, 74);
  2375. this.groupBox20.Name = "groupBox20";
  2376. this.groupBox20.Size = new System.Drawing.Size(394, 470);
  2377. this.groupBox20.TabIndex = 17;
  2378. this.groupBox20.TabStop = false;
  2379. this.groupBox20.Text = "设置";
  2380. //
  2381. // checkBox10
  2382. //
  2383. this.checkBox10.AutoSize = true;
  2384. this.checkBox10.Location = new System.Drawing.Point(286, 168);
  2385. this.checkBox10.Name = "checkBox10";
  2386. this.checkBox10.Size = new System.Drawing.Size(84, 16);
  2387. this.checkBox10.TabIndex = 6;
  2388. this.checkBox10.Text = "锁定横纵比";
  2389. this.checkBox10.UseVisualStyleBackColor = true;
  2390. //
  2391. // comboBox3
  2392. //
  2393. this.comboBox3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
  2394. this.comboBox3.FormattingEnabled = true;
  2395. this.comboBox3.Location = new System.Drawing.Point(146, 166);
  2396. this.comboBox3.Name = "comboBox3";
  2397. this.comboBox3.Size = new System.Drawing.Size(121, 20);
  2398. this.comboBox3.TabIndex = 5;
  2399. //
  2400. // numericUpDown3
  2401. //
  2402. this.numericUpDown3.Location = new System.Drawing.Point(146, 108);
  2403. this.numericUpDown3.Maximum = new decimal(new int[] {
  2404. 100000,
  2405. 0,
  2406. 0,
  2407. 0});
  2408. this.numericUpDown3.Name = "numericUpDown3";
  2409. this.numericUpDown3.Size = new System.Drawing.Size(120, 21);
  2410. this.numericUpDown3.TabIndex = 4;
  2411. //
  2412. // numericUpDown2
  2413. //
  2414. this.numericUpDown2.Location = new System.Drawing.Point(146, 44);
  2415. this.numericUpDown2.Maximum = new decimal(new int[] {
  2416. 100000,
  2417. 0,
  2418. 0,
  2419. 0});
  2420. this.numericUpDown2.Name = "numericUpDown2";
  2421. this.numericUpDown2.Size = new System.Drawing.Size(120, 21);
  2422. this.numericUpDown2.TabIndex = 3;
  2423. //
  2424. // label35
  2425. //
  2426. this.label35.AutoSize = true;
  2427. this.label35.Location = new System.Drawing.Point(72, 49);
  2428. this.label35.Name = "label35";
  2429. this.label35.Size = new System.Drawing.Size(65, 12);
  2430. this.label35.TabIndex = 2;
  2431. this.label35.Text = "最大宽度:";
  2432. //
  2433. // label34
  2434. //
  2435. this.label34.AutoSize = true;
  2436. this.label34.Location = new System.Drawing.Point(96, 169);
  2437. this.label34.Name = "label34";
  2438. this.label34.Size = new System.Drawing.Size(41, 12);
  2439. this.label34.TabIndex = 1;
  2440. this.label34.Text = "单位:";
  2441. //
  2442. // label33
  2443. //
  2444. this.label33.AutoSize = true;
  2445. this.label33.Location = new System.Drawing.Point(72, 111);
  2446. this.label33.Name = "label33";
  2447. this.label33.Size = new System.Drawing.Size(65, 12);
  2448. this.label33.TabIndex = 0;
  2449. this.label33.Text = "最大高度:";
  2450. //
  2451. // GeneralSettingDialog
  2452. //
  2453. this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 12F);
  2454. this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
  2455. this.AutoScroll = true;
  2456. this.ClientSize = new System.Drawing.Size(533, 561);
  2457. this.Controls.Add(this.groupBox20);
  2458. this.Controls.Add(this.groupBox1);
  2459. this.Controls.Add(this.groupBox5);
  2460. this.Controls.Add(this.groupBox2);
  2461. this.Controls.Add(this.groupBox18);
  2462. this.Controls.Add(this.groupBox10);
  2463. this.Controls.Add(this.groupBox19);
  2464. this.Controls.Add(this.groupBox6);
  2465. this.Controls.Add(this.groupBox3);
  2466. this.Controls.Add(this.groupBox16);
  2467. this.Controls.Add(this.groupBox15);
  2468. this.Controls.Add(this.listView3);
  2469. this.Controls.Add(this.groupBox11);
  2470. this.Controls.Add(this.groupBox4);
  2471. this.Controls.Add(this.groupBoxCaptureSave);
  2472. this.Controls.Add(this.groupBox17);
  2473. this.Controls.Add(this.groupBox14);
  2474. this.Controls.Add(this.groupBox13);
  2475. this.Controls.Add(this.groupBox12);
  2476. this.Controls.Add(this.groupBox7);
  2477. this.Controls.Add(this.groupBox8);
  2478. this.Controls.Add(this.groupBox9);
  2479. this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
  2480. this.MaximizeBox = false;
  2481. this.MinimizeBox = false;
  2482. this.Name = "GeneralSettingDialog";
  2483. this.Text = "常规设置";
  2484. this.Controls.SetChildIndex(this.groupBox9, 0);
  2485. this.Controls.SetChildIndex(this.groupBox8, 0);
  2486. this.Controls.SetChildIndex(this.groupBox7, 0);
  2487. this.Controls.SetChildIndex(this.groupBox12, 0);
  2488. this.Controls.SetChildIndex(this.groupBox13, 0);
  2489. this.Controls.SetChildIndex(this.groupBox14, 0);
  2490. this.Controls.SetChildIndex(this.groupBox17, 0);
  2491. this.Controls.SetChildIndex(this.groupBoxCaptureSave, 0);
  2492. this.Controls.SetChildIndex(this.groupBox4, 0);
  2493. this.Controls.SetChildIndex(this.groupBox11, 0);
  2494. this.Controls.SetChildIndex(this.listView3, 0);
  2495. this.Controls.SetChildIndex(this.groupBox15, 0);
  2496. this.Controls.SetChildIndex(this.groupBox16, 0);
  2497. this.Controls.SetChildIndex(this.groupBox3, 0);
  2498. this.Controls.SetChildIndex(this.groupBox6, 0);
  2499. this.Controls.SetChildIndex(this.groupBox19, 0);
  2500. this.Controls.SetChildIndex(this.groupBox10, 0);
  2501. this.Controls.SetChildIndex(this.groupBox18, 0);
  2502. this.Controls.SetChildIndex(this.groupBox2, 0);
  2503. this.Controls.SetChildIndex(this.groupBox5, 0);
  2504. this.Controls.SetChildIndex(this.groupBox1, 0);
  2505. this.Controls.SetChildIndex(this.groupBox20, 0);
  2506. this.groupBox1.ResumeLayout(false);
  2507. this.groupBox8.ResumeLayout(false);
  2508. this.groupBox8.PerformLayout();
  2509. this.groupBox7.ResumeLayout(false);
  2510. this.groupBox7.PerformLayout();
  2511. this.groupBoxCaptureSave.ResumeLayout(false);
  2512. this.groupBoxCaptureSave.PerformLayout();
  2513. this.groupBox10.ResumeLayout(false);
  2514. this.groupBox10.PerformLayout();
  2515. this.groupBox6.ResumeLayout(false);
  2516. this.groupBox9.ResumeLayout(false);
  2517. this.groupBox9.PerformLayout();
  2518. ((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
  2519. this.groupBox2.ResumeLayout(false);
  2520. this.groupBox12.ResumeLayout(false);
  2521. this.groupBox3.ResumeLayout(false);
  2522. this.groupBox3.PerformLayout();
  2523. ((System.ComponentModel.ISupportInitialize)(this.pictureBox2)).EndInit();
  2524. this.groupBox5.ResumeLayout(false);
  2525. this.groupBox5.PerformLayout();
  2526. this.groupBox4.ResumeLayout(false);
  2527. this.groupBox4.PerformLayout();
  2528. this.groupBox11.ResumeLayout(false);
  2529. this.groupBox11.PerformLayout();
  2530. this.panel1.ResumeLayout(false);
  2531. this.panel1.PerformLayout();
  2532. this.panel2.ResumeLayout(false);
  2533. this.panel2.PerformLayout();
  2534. this.panel3.ResumeLayout(false);
  2535. this.panel3.PerformLayout();
  2536. this.panel4.ResumeLayout(false);
  2537. this.panel4.PerformLayout();
  2538. this.panel5.ResumeLayout(false);
  2539. this.panel5.PerformLayout();
  2540. this.groupBox15.ResumeLayout(false);
  2541. this.groupBox15.PerformLayout();
  2542. this.groupBox16.ResumeLayout(false);
  2543. this.groupBox16.PerformLayout();
  2544. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown1)).EndInit();
  2545. this.groupBox13.ResumeLayout(false);
  2546. this.groupBox14.ResumeLayout(false);
  2547. this.groupBox17.ResumeLayout(false);
  2548. this.groupBox18.ResumeLayout(false);
  2549. this.groupBox19.ResumeLayout(false);
  2550. this.groupBox19.PerformLayout();
  2551. this.groupBox20.ResumeLayout(false);
  2552. this.groupBox20.PerformLayout();
  2553. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown3)).EndInit();
  2554. ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).EndInit();
  2555. this.ResumeLayout(false);
  2556. }
  2557. #endregion
  2558. #region [画板颜色]
  2559. /// <summary>
  2560. /// 画板点击
  2561. /// </summary>
  2562. /// <param name="sender"></param>
  2563. /// <param name="e"></param>
  2564. private void panel6_Click(object sender, EventArgs e)
  2565. {
  2566. this.colorsForm.UserPrimaryColor = ColorBgra.FromColor(this.panel6.BackColor);
  2567. this.colorsForm.setSaveBtn_Click(new System.EventHandler(this.panel6Changed));
  2568. this.colorsForm.ShowDialog();
  2569. }
  2570. private void panel6Changed(object sender, EventArgs e)
  2571. {
  2572. this.panel6.BackColor = this.colorsForm.UserPrimaryColor.ToColor();
  2573. this.colorsForm.Close();
  2574. }
  2575. private void colorsFormUserPrimaryColorChanged(object sender, ColorEventArgs ce)
  2576. {
  2577. }
  2578. #endregion
  2579. #region [用户信息]
  2580. public void UserInformation()
  2581. {
  2582. textBox_CompanyName.MaxLength = 100;
  2583. textBox_CompanyName.Text = userInfo.CompanyName;
  2584. textBox_Province.MaxLength = 10;
  2585. textBox_Province.Text = userInfo.Province;
  2586. textBox_City.MaxLength = 10;
  2587. textBox_City.Text = userInfo.City;
  2588. textBox_Address.MaxLength = 100;
  2589. textBox_Address.Text = userInfo.Address;
  2590. textBox_Contact.MaxLength = 10;
  2591. textBox_Contact.Text = userInfo.Contact;
  2592. textBox_Phone.MaxLength = 20;
  2593. textBox_Phone.Text = userInfo.Phone;
  2594. textBox_Email.MaxLength = 30;
  2595. textBox_Email.Text = userInfo.Email;
  2596. textBox_Model.Text = userInfo.Model;
  2597. textBox_SN.Text = userInfo.SN;
  2598. textBox_Camera.Text = userInfo.Camera;
  2599. textBox_Interface.Text = userInfo.Interface;
  2600. if (string.IsNullOrEmpty(userInfo.Logo))
  2601. {
  2602. button11.Show();
  2603. button12.Hide();
  2604. pictureBox2.Hide();
  2605. }
  2606. else
  2607. {
  2608. button11.Hide();
  2609. button12.Show();
  2610. if (System.IO.File.Exists(userInfo.Logo))
  2611. {
  2612. pictureBox2.ImageLocation = userInfo.Logo;
  2613. FileStream userPicStream = new FileStream(userInfo.Logo, FileMode.Open, FileAccess.Read);
  2614. pictureBox2.Image = Image.FromStream(userPicStream);
  2615. userPicStream.Close();
  2616. userPicStream.Dispose();
  2617. }
  2618. pictureBox2.Show();
  2619. }
  2620. }
  2621. #endregion
  2622. #region [基础设置]
  2623. public void BasicSettings()
  2624. {
  2625. checkBox7.Checked = config.StartImgStatus == 1 ? false : true;
  2626. checkBox8.Checked = config.AddZEN == 1 ? true : false;
  2627. checkBox9.Checked = config.AddAxioVision == 1 ? true : false;
  2628. textBox4.Text = config.NormalOperation;
  2629. textBox5.Text = config.GeneralAnalysis;
  2630. textBox6.Text = config.DedicatedAnalysis;
  2631. if (string.IsNullOrEmpty(config.StartImg))
  2632. {
  2633. button9.Show();
  2634. button10.Hide();
  2635. pictureBox1.Hide();
  2636. }
  2637. else
  2638. {
  2639. button9.Hide();
  2640. button10.Show();
  2641. if (System.IO.File.Exists(config.StartImg))
  2642. {
  2643. pictureBox1.ImageLocation = config.StartImg;
  2644. FileStream imgFileStream = new FileStream(config.StartImg, FileMode.Open, FileAccess.Read);
  2645. pictureBox1.Image = Image.FromStream(imgFileStream);
  2646. imgFileStream.Close();
  2647. imgFileStream.Dispose();
  2648. }
  2649. pictureBox1.Show();
  2650. }
  2651. }
  2652. #endregion
  2653. #region [相机设置]
  2654. private void listView1_SelectedIndexChanged(object sender, EventArgs e)
  2655. {
  2656. if (listView3.FocusedItem != null)
  2657. {
  2658. int idx = listView3.FocusedItem.Index;
  2659. for (int i = 0; i < listView3.Items.Count; i++)
  2660. {
  2661. if (i == idx)
  2662. listView3.Items[i].BackColor = Color.Aqua;
  2663. else
  2664. listView3.Items[i].BackColor = Color.White;
  2665. }
  2666. listView3.Items[idx].Selected = false;
  2667. }
  2668. }
  2669. public void CameraSettings()
  2670. {
  2671. listView3.View = View.Details;
  2672. listView3.Columns.Add("0", 0, HorizontalAlignment.Center);
  2673. listView3.Columns.Add(PdnResources.GetString("Menu.LabelAction.MarkAction.Text"), 50, HorizontalAlignment.Center);
  2674. listView3.Columns.Add(PdnResources.GetString("Menu.Cameramodel.text"), 131, HorizontalAlignment.Center);
  2675. listView3.Columns.Add(PdnResources.GetString("Menu.PixelSize.text"), 300, HorizontalAlignment.Center);
  2676. //listView3.Columns.Add(PdnResources.GetString("Menu.Cameramodelweimi.text"), 300, HorizontalAlignment.Center);
  2677. //listView3.Columns.Add(PdnResources.GetString("Menu.Set.Generalsettings.Sidelengthresolution.text"), 200, HorizontalAlignment.Center);
  2678. var screenList = mic_camerasettings_BLL.FindAll();
  2679. var screenRulesId = config.Camera;
  2680. listView3.BeginUpdate();
  2681. foreach (var s in screenList)
  2682. {
  2683. var lv = new ListViewItem();
  2684. lv.SubItems.Add(screenRulesId == s.id ? "√" : "×");
  2685. lv.SubItems.Add(s.camera_model);
  2686. lv.SubItems.Add(s.pixel_size);
  2687. //lv.SubItems.Add(s.resolution);
  2688. lv.Tag = s.id;
  2689. listView3.Items.Add(lv);
  2690. }
  2691. if (listView3.Items.Count > 0)
  2692. {
  2693. listView3.Items[0].Selected = true;
  2694. listView3.Select();
  2695. }
  2696. else
  2697. {
  2698. var lv = new ListViewItem();
  2699. lv.SubItems.Add("2");
  2700. lv.SubItems.Add("3");
  2701. //lv.SubItems.Add("4");
  2702. lv.Name = "virtualItem";
  2703. listView3.Items.Add(lv);
  2704. }
  2705. listView3.EndUpdate();
  2706. }
  2707. #endregion
  2708. #region [方向设置]
  2709. public void OrientationSetting()
  2710. {
  2711. radioButton6.Checked = config.ZMovementDirection == 0 ? true : false;
  2712. radioButton7.Checked = config.ZMovementDirection == 1 ? true : false;
  2713. radioButton8.Checked = config.XLeftMovementDirection == 0 ? true : false;
  2714. radioButton9.Checked = config.XLeftMovementDirection == 1 ? true : false;
  2715. radioButton10.Checked = config.XRighttMovementDirection == 0 ? true : false;
  2716. radioButton11.Checked = config.XRighttMovementDirection == 1 ? true : false;
  2717. radioButton12.Checked = config.YLeftMovementDirection == 0 ? true : false;
  2718. radioButton13.Checked = config.YLeftMovementDirection == 1 ? true : false;
  2719. radioButton14.Checked = config.YRighttMovementDirection == 0 ? true : false;
  2720. radioButton15.Checked = config.YRighttMovementDirection == 1 ? true : false;
  2721. }
  2722. #endregion
  2723. #region [辅助线设置]
  2724. public void GuideSetting()
  2725. {
  2726. //绑定线样式数据
  2727. this.comboBox2.Items.AddRange(InvariantData.dashStyles);
  2728. //获取xml样式信息
  2729. this.comboBox2.SelectedIndex = Startup.instance.guideStyleModel.lineStyle;
  2730. this.panel6.BackColor = Color.FromArgb(Startup.instance.guideStyleModel.lineColour);
  2731. this.numericUpDown1.Value = Startup.instance.guideStyleModel.lineWidth;
  2732. }
  2733. #endregion
  2734. #region 拍照保存
  2735. bool _isInitCaptureSave = false;
  2736. void InitCaptureSave()
  2737. {
  2738. _isInitCaptureSave = true;
  2739. //初始化字串
  2740. this.groupBox18.Text = PdnResources.GetString("Menu.operation.text");
  2741. groupBoxCaptureSave.Text = PdnResources.GetString("Menu.CaptureSave.text");
  2742. //ckbSave.Text = PdnResources.GetString("SaveToDisk");
  2743. //ckbSaveAndOpen.Text = PdnResources.GetString("SaveAndOpenImage");
  2744. this.button22.Text = PdnResources.GetString("Menu.application.text");
  2745. ckbSave.Checked = config.CaptureSaveMode == 1 || config.CaptureSaveMode == 3 ? true : false/*(config.CaptureSaveMode & 1) > 0*/;
  2746. ckbSaveAndOpen.Enabled = config.CaptureSaveMode != 0 ? true : false/*(config.CaptureSaveMode & 1) > 0*/;
  2747. ckbSaveAndOpen.Checked = config.CaptureSaveMode == 3 || config.CaptureSaveMode == -3 ? true : false/*(config.CaptureSaveMode & 2) > 0*/;
  2748. ckAutoSave.Checked = config.CaptureSaveMode == -1 || config.CaptureSaveMode == -3 ? true : false;
  2749. ckNotSave.Checked = config.CaptureSaveMode == 0 ? true : false;
  2750. textBox9.Text = config.FilePath;
  2751. ckbSave.Click += CkbSave_Click;
  2752. ckAutoSave.Click += ckAutoSave_Click;
  2753. ckNotSave.Click += ckNotSave_Click;
  2754. ckbSaveAndOpen.Click += ckbSaveAndOpen_Click;
  2755. button22.Click += Apply_Click;
  2756. Disable();
  2757. }
  2758. private void CkbSave_Click(object sender, EventArgs e)
  2759. {
  2760. ckbSaveAndOpen.Enabled = true;
  2761. config.CaptureSaveMode = (ckbSave.Checked ? 1 : 0) + (ckbSaveAndOpen.Checked ? 2 : 0);
  2762. Disable();
  2763. }
  2764. private void ckAutoSave_Click(object sender, EventArgs e)
  2765. {
  2766. ckbSaveAndOpen.Enabled = true;
  2767. config.CaptureSaveMode = (ckbSaveAndOpen.Checked ? -2 : 0) + (ckAutoSave.Checked ? -1 : 0);
  2768. Disable();
  2769. }
  2770. private void ckbSaveAndOpen_Click(object sender, EventArgs e)
  2771. {
  2772. int isOpen = 0;
  2773. if (ckbSave.Checked && ckbSaveAndOpen.Checked)
  2774. isOpen = 2;
  2775. else if (ckAutoSave.Checked && ckbSaveAndOpen.Checked)
  2776. isOpen = -2;
  2777. ckbSaveAndOpen.Enabled = ckbSave.Checked || ckAutoSave.Checked ? true : false;
  2778. config.CaptureSaveMode = (ckbSave.Checked ? 1 : 0) + (ckbSaveAndOpen.Checked ? isOpen : 0) + (ckAutoSave.Checked ? -1 : 0);
  2779. }
  2780. private void ckNotSave_Click(object sender, EventArgs e)
  2781. {
  2782. ckbSaveAndOpen.Enabled = false;
  2783. ckbSaveAndOpen.Checked = false;
  2784. config.CaptureSaveMode = 0;
  2785. Disable();
  2786. }
  2787. private void Apply_Click(object sender, EventArgs e)
  2788. {
  2789. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  2790. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  2791. FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create);
  2792. appWorkspace.Widgets.ImageIndexDialog.PreviewRefresh(config.CaptureSaveMode);
  2793. }
  2794. private void button23_Click(object sender, EventArgs e)
  2795. {
  2796. FolderBrowserDialog path = new FolderBrowserDialog();
  2797. path.ShowDialog();
  2798. textBox9.Text = path.SelectedPath;
  2799. config.FilePath = textBox9.Text;
  2800. }
  2801. private void Disable()
  2802. {
  2803. if (this.ckAutoSave.Checked)
  2804. {
  2805. this.label32.Enabled = true;
  2806. this.textBox9.Enabled = true;
  2807. this.button23.Enabled = true;
  2808. }
  2809. else
  2810. {
  2811. this.label32.Enabled = false;
  2812. this.textBox9.Enabled = false;
  2813. this.button23.Enabled = false;
  2814. }
  2815. }
  2816. #endregion
  2817. private void listBox1_SelectedValueChanged(object sender, EventArgs e)
  2818. {
  2819. groupBox3.Hide();
  2820. groupBox4.Hide();
  2821. groupBox5.Hide();
  2822. groupBox6.Hide();
  2823. groupBox7.Hide();
  2824. groupBox8.Hide();
  2825. groupBox9.Hide();
  2826. groupBox10.Hide();
  2827. groupBox11.Hide();
  2828. groupBox2.Hide();
  2829. groupBox12.Hide();
  2830. groupBox13.Hide();
  2831. listView3.Hide();
  2832. groupBox14.Hide();
  2833. groupBox15.Hide();
  2834. groupBox16.Hide();
  2835. groupBox17.Hide();
  2836. groupBox18.Hide();
  2837. groupBox19.Hide();
  2838. groupBoxCaptureSave.Hide();
  2839. groupBox20.Hide();
  2840. button1.Visible = true;
  2841. btn_Save.Visible = false;
  2842. btn_SaveAs.Visible = false;
  2843. if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Namingrules.text")))
  2844. {
  2845. groupBox5.Show();
  2846. groupBox2.Show();
  2847. groupBox19.Show();
  2848. button1.Visible = false;
  2849. btn_Save.Visible = true;
  2850. btn_SaveAs.Visible = true;
  2851. }
  2852. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.UserInfo.text")))
  2853. {
  2854. groupBox3.Show();
  2855. groupBox4.Show();
  2856. groupBox2.Show();
  2857. }
  2858. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.dotspacingsetting.text")))
  2859. {
  2860. groupBox6.Show();
  2861. groupBox12.Show();
  2862. }
  2863. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Softwarelanguage.text")))
  2864. {
  2865. groupBox8.Show();
  2866. groupBox2.Show();
  2867. }
  2868. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Systemreset.text")))
  2869. {
  2870. groupBox7.Show();
  2871. groupBox2.Show();
  2872. }
  2873. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.BasicSettings.text")))
  2874. {
  2875. groupBox9.Show();
  2876. groupBox10.Show();
  2877. groupBox11.Show();
  2878. groupBox2.Show();
  2879. }
  2880. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.ImageCollection.CameraSetting.Text")))
  2881. {
  2882. groupBox13.Show();
  2883. listView3.Show();
  2884. if (listView3.Items.Count > 0)
  2885. {
  2886. listView3.Items.RemoveByKey("virtualItem");
  2887. }
  2888. }
  2889. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Directionsetting.text")))
  2890. {
  2891. groupBox14.Show();
  2892. groupBox15.Show();
  2893. }
  2894. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Auxiliarylinesettings.text")))
  2895. {
  2896. groupBox16.Show();
  2897. groupBox17.Show();
  2898. }
  2899. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.CaptureSave.text")))
  2900. {
  2901. if (!_isInitCaptureSave) InitCaptureSave();
  2902. groupBoxCaptureSave.Show();
  2903. groupBox18.Show();
  2904. }
  2905. else if (listBox1.SelectedItems[0].ToString().Equals("拼图设置"))
  2906. {
  2907. groupBox2.Show();
  2908. groupBox20.Show();
  2909. }
  2910. }
  2911. private void button2_Click(object sender, EventArgs e)
  2912. {
  2913. Close();
  2914. }
  2915. private void button1_Click(object sender, EventArgs e)
  2916. {
  2917. if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Namingrules.text")))
  2918. {
  2919. //if (string.IsNullOrEmpty(textBox1.Text))
  2920. //{
  2921. // MessageBox.Show(PdnResources.GetString("Menu.pleasewriteNameprefix.text"));
  2922. // return;
  2923. //}
  2924. //if (string.IsNullOrEmpty(textBox2.Text))
  2925. //{
  2926. // MessageBox.Show(PdnResources.GetString("Menu.pleaseNameformat.text"));
  2927. // return;
  2928. //}
  2929. //else
  2930. //{
  2931. // string[] arrs = System.Text.RegularExpressions.Regex.Split(textBox2.Text, @"(?<=\G.{2})(?!$)");
  2932. // foreach (string text in arrs)
  2933. // {
  2934. // if (!text.Equals("%P") && !text.Equals("%I") && !text.Equals("%h") && !text.Equals("%m")
  2935. // && !text.Equals("%s") && !text.Equals("%Y") && !text.Equals("%M") && !text.Equals("%D")
  2936. // && !text.Equals("%G") && !text.Equals("%U"))
  2937. // {
  2938. // MessageBox.Show("名称格式不合法, 请检查");
  2939. // return;
  2940. // }
  2941. // }
  2942. //}
  2943. //if (radioButton1.Checked && !(Regex.IsMatch(textBox3.Text, pattern)))
  2944. //{
  2945. // MessageBox.Show(PdnResources.GetString("Menu.Numberscanbeentet.text") + "!");
  2946. // return;
  2947. //}
  2948. //config.CurrentName = comboBox_Name.Text;
  2949. //config.NamePrefix = textBox1.Text;
  2950. //config.NameFormat = textBox2.Text;
  2951. //config.NumberNum = Convert.ToInt32(comboBox1.SelectedItem);
  2952. //config.NameStatus = radioButton1.Checked == true ? 1 : 2;
  2953. //config.ContinueNum = radioButton1.Checked ? Convert.ToInt32(textBox3.Text) : 1;
  2954. //string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  2955. //string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  2956. //if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  2957. //{
  2958. //}
  2959. //else
  2960. //{
  2961. // MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  2962. //}
  2963. }
  2964. else if (listBox1.SelectedItems[0].ToString().Equals("拼图设置"))
  2965. {
  2966. config.MaxHeight = (int)numericUpDown3.Value;
  2967. config.MaxWidth = (int)numericUpDown2.Value;
  2968. config.MaxUnit = comboBox3.SelectedIndex;
  2969. config.MaxLocked = checkBox10.Checked;
  2970. Startup.instance.configModel = config;
  2971. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  2972. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  2973. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  2974. {
  2975. }
  2976. else
  2977. {
  2978. MessageBox.Show(PdnResources.GetString("Menu.mingconventionsavefailed.text"));
  2979. }
  2980. }
  2981. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.UserInfo.text")))
  2982. {
  2983. userInfo.CompanyName = textBox_CompanyName.Text;
  2984. userInfo.Province = textBox_Province.Text;
  2985. userInfo.City = textBox_City.Text;
  2986. userInfo.Address = textBox_Address.Text;
  2987. userInfo.Contact = textBox_Contact.Text;
  2988. userInfo.Phone = textBox_Phone.Text;
  2989. userInfo.Email = textBox_Email.Text;
  2990. if (pictureBox2.ImageLocation == null)
  2991. {
  2992. if (!string.IsNullOrEmpty(userInfo.Logo))
  2993. {
  2994. if (System.IO.File.Exists(userInfo.Logo))
  2995. {
  2996. System.IO.File.Delete(userInfo.Logo);
  2997. }
  2998. }
  2999. }
  3000. userInfo.Logo = pictureBox2.ImageLocation == null ? "" : pictureBox2.ImageLocation;
  3001. userInfo.Model = textBox_Model.Text;
  3002. userInfo.SN = textBox_SN.Text;
  3003. userInfo.Camera = textBox_Camera.Text;
  3004. userInfo.Interface = textBox_Interface.Text;
  3005. string userInfoXml = XmlSerializeHelper.XmlSerialize<UserInfoModel>(userInfo);
  3006. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\UserInfo.xml";
  3007. if (FileOperationHelper.WriteStringToFile(userInfoXml, filePath, FileMode.Create))
  3008. {
  3009. }
  3010. else
  3011. {
  3012. MessageBox.Show(PdnResources.GetString("Menu.UserInfosavefiled.text"));
  3013. }
  3014. }
  3015. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.dotspacingsetting.text")))
  3016. {
  3017. }
  3018. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Softwarelanguage.text")))
  3019. {
  3020. if (radioButton3.Checked)
  3021. {
  3022. config.Language = 1;
  3023. }
  3024. else if (radioButton5.Checked)
  3025. {
  3026. config.Language = 2;
  3027. }
  3028. else if (radioButton4.Checked)
  3029. {
  3030. config.Language = 3;
  3031. }
  3032. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3033. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3034. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3035. {
  3036. MessageBox.Show(PdnResources.GetString("Menu.nguageswitchissuccessfulthesoftware.text"));
  3037. }
  3038. else
  3039. {
  3040. MessageBox.Show(PdnResources.GetString("Menu.twarelanguageswitchfailed.text"));
  3041. }
  3042. }
  3043. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.Set.Generalsettings.Systemreset.text")))
  3044. {
  3045. if (!checkBox1.Checked && !checkBox2.Checked && !checkBox3.Checked && !checkBox4.Checked && !checkBox5.Checked && !checkBox6.Checked)
  3046. {
  3047. MessageBox.Show(PdnResources.GetString("Menu.asefirstchecatleastoneite.text"));
  3048. return;
  3049. }
  3050. config.LabelInformationReset = checkBox1.Checked ? 1 : 0;
  3051. config.MeasurementInformationReset = checkBox2.Checked ? 1 : 0;
  3052. config.LogReset = checkBox3.Checked ? 1 : 0;
  3053. config.ShortcutBarReset = checkBox4.Checked ? 1 : 0;
  3054. config.ToolbarReset = checkBox5.Checked ? 1 : 0;
  3055. config.HotKeyReset = checkBox6.Checked ? 1 : 0;
  3056. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3057. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3058. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3059. {
  3060. MessageBox.Show(PdnResources.GetString("Menu.emresetsuccessfulthesoftw.text") + "!");
  3061. }
  3062. else
  3063. {
  3064. MessageBox.Show(PdnResources.GetString("Menu.Systemresetfailure.text"));
  3065. }
  3066. }
  3067. else if (listBox1.SelectedItems[0].ToString().Equals(PdnResources.GetString("Menu.BasicSettings.text")))
  3068. {
  3069. config.StartImgStatus = checkBox7.Checked ? 2 : 1;
  3070. if (pictureBox1.ImageLocation == null)
  3071. {
  3072. if (!string.IsNullOrEmpty(config.StartImg))
  3073. {
  3074. if (System.IO.File.Exists(config.StartImg))
  3075. {
  3076. System.IO.File.Delete(config.StartImg);
  3077. }
  3078. }
  3079. }
  3080. config.StartImg = pictureBox1.ImageLocation == null ? "" : pictureBox1.ImageLocation;
  3081. config.NormalOperation = textBox4.Text;
  3082. config.GeneralAnalysis = textBox5.Text;
  3083. config.DedicatedAnalysis = textBox6.Text;
  3084. appWorkspace.Widgets.ImageIndexDialog.PreviewRefresh(config.CaptureSaveMode); ;
  3085. config.AddZEN = checkBox8.Checked ? 1 : 2;
  3086. config.AddAxioVision = checkBox9.Checked ? 1 : 2;
  3087. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3088. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3089. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3090. {
  3091. Startup.instance.configModel.NormalOperation = config.NormalOperation;
  3092. Startup.instance.configModel.GeneralAnalysis = config.GeneralAnalysis;
  3093. Startup.instance.configModel.DedicatedAnalysis = config.DedicatedAnalysis;
  3094. if (this.appWorkspace != null && this.appWorkspace.Widgets != null && this.appWorkspace.Widgets.ProjectEngineering != null && !this.appWorkspace.Widgets.ProjectEngineering.IsDisposed)
  3095. {
  3096. this.appWorkspace.Widgets.ProjectEngineering.InitializeTreeViewDetailData();
  3097. }
  3098. }
  3099. else
  3100. {
  3101. MessageBox.Show(PdnResources.GetString("Menu.Theoperationfailure.text"));
  3102. }
  3103. }
  3104. }
  3105. private void listView2_DoubleClick(object sender, EventArgs e)
  3106. {
  3107. if (listView2.Items.Count == 0)
  3108. {
  3109. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3110. return;
  3111. }
  3112. string id = listView2.FocusedItem.SubItems[6].Text;
  3113. if (config.DotPitchId == Convert.ToInt32(id))
  3114. {
  3115. MessageBox.Show(PdnResources.GetString("Menu.Thepointditanceisenabled.text"));
  3116. return;
  3117. }
  3118. config.DotPitchId = Convert.ToInt32(id);
  3119. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3120. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3121. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3122. {
  3123. //MessageBox.Show(PdnResources.GetString("Menu.nablesuccessfui.text"));
  3124. listView2.BeginUpdate();
  3125. int nRowOrder = 0;
  3126. int nRowOrders = listView2.Items.Count;//行数
  3127. for (nRowOrder = 0; nRowOrder < nRowOrders; nRowOrder++)//遍历listView1的每一行
  3128. {
  3129. ListViewItem lvi = listView2.Items[nRowOrder];
  3130. if (lvi.SubItems[1].Text == "√")
  3131. {
  3132. lvi.SubItems[1].Text = "×";
  3133. }
  3134. }
  3135. var Index = listView2.SelectedItems[0].Index;
  3136. var lv = listView2.Items[Index];
  3137. lv.SubItems[1].Text = "√";
  3138. listView2.EndUpdate();
  3139. }
  3140. else
  3141. {
  3142. MessageBox.Show(PdnResources.GetString("Menu.Enablethefailure.text"));
  3143. }
  3144. }
  3145. private void button3_Click(object sender, EventArgs e)
  3146. {
  3147. if (listView2.Items.Count == 0)
  3148. {
  3149. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3150. return;
  3151. }
  3152. DialogResult dr;
  3153. dr = MessageBox.Show(PdnResources.GetString("Menu.eyousureyouwanttodeletethisdi.text") + "?", PdnResources.GetString("Menu.Edit.Delete.Text"), MessageBoxButtons.OKCancel,
  3154. MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1);
  3155. if (dr == DialogResult.OK)
  3156. {
  3157. string id = string.Empty;
  3158. if (listView2.FocusedItem != null)
  3159. {
  3160. id = listView2.FocusedItem.SubItems[6].Text;
  3161. }
  3162. else
  3163. {
  3164. id = listView2.Items[0].SubItems[6].Text;
  3165. }
  3166. var point = mic_screen_rules_BLL.FindDefault(Convert.ToInt32(id));
  3167. if (point == null || point.delete_flag == 1)
  3168. {
  3169. MessageBox.Show(PdnResources.GetString("Menu.Abnormalinformation.text"));
  3170. }
  3171. point.delete_flag = 1;
  3172. mic_screen_rules_BLL.Update(point);
  3173. if (listView2.SelectedItems.Count > 0)
  3174. {
  3175. var Index = listView2.SelectedItems[0].Index;
  3176. listView2.Items[Index].Remove();
  3177. }
  3178. else
  3179. {
  3180. listView2.Items[0].Remove();
  3181. }
  3182. }
  3183. else if (dr == DialogResult.Cancel)
  3184. {
  3185. }
  3186. if (listView2.Items.Count > 0)
  3187. {
  3188. listView2.Items[0].Selected = true;
  3189. listView2.Select();
  3190. }
  3191. }
  3192. private void button4_Click(object sender, EventArgs e)
  3193. {
  3194. string id = string.Empty;
  3195. using (PointDataDialog pd = new PointDataDialog(id, listView2))
  3196. {
  3197. pd.Text = PdnResources.GetString("Menu.Set.Generalsettings.Adddotpitch.text");
  3198. pd.ShowDialog();
  3199. }
  3200. }
  3201. private void button5_Click(object sender, EventArgs e)
  3202. {
  3203. string id = string.Empty;
  3204. int thisIndex = 0;
  3205. if (listView2.Items.Count == 0)
  3206. {
  3207. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3208. return;
  3209. }
  3210. if (listView2.FocusedItem != null)
  3211. {
  3212. id = listView2.FocusedItem.SubItems[6].Text;
  3213. thisIndex = listView2.Items.IndexOf(listView2.FocusedItem);
  3214. }
  3215. else
  3216. {
  3217. id = "1";
  3218. }
  3219. using (PointDataDialog pd = new PointDataDialog(id, listView2, thisIndex))
  3220. {
  3221. pd.Text = PdnResources.GetString("Menu.Editdistance.text");
  3222. pd.ShowDialog();
  3223. }
  3224. }
  3225. private void button6_Click(object sender, EventArgs e)
  3226. {
  3227. FolderBrowserDialog path = new FolderBrowserDialog();
  3228. path.ShowDialog();
  3229. textBox4.Text = path.SelectedPath;
  3230. }
  3231. private void button7_Click(object sender, EventArgs e)
  3232. {
  3233. FolderBrowserDialog path = new FolderBrowserDialog();
  3234. path.ShowDialog();
  3235. textBox5.Text = path.SelectedPath;
  3236. }
  3237. private void button8_Click(object sender, EventArgs e)
  3238. {
  3239. FolderBrowserDialog path = new FolderBrowserDialog();
  3240. path.ShowDialog();
  3241. textBox6.Text = path.SelectedPath;
  3242. }
  3243. private void button9_Click(object sender, EventArgs e)
  3244. {
  3245. OpenFileDialog file = new OpenFileDialog();
  3246. file.Filter = "All Image Files|*.bmp;*.jpeg;*.jpg;*.png";
  3247. DialogResult dr;
  3248. dr = file.ShowDialog();
  3249. if (dr == DialogResult.OK)
  3250. {
  3251. var lastName = Path.GetExtension(file.FileName);
  3252. if (lastName != ".png" && lastName != ".jpg" && lastName != ".jpeg" && lastName != ".bmp")
  3253. {
  3254. MessageBox.Show(PdnResources.GetString("Menu.Pleaseuploadpicturese.text"));
  3255. return;
  3256. }
  3257. var fileName = Path.GetFullPath(file.FileName);
  3258. byte[] bytes = ReadFileToByte(fileName);
  3259. var saveFilePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + $"\\{DateTime.Now.ToString("yyyyMMddHHmmss") + file.SafeFileName}";
  3260. WriteByteToFile(bytes, saveFilePath);
  3261. button9.Hide();
  3262. button10.Show();
  3263. pictureBox1.Show();
  3264. pictureBox1.ImageLocation = saveFilePath;
  3265. FileStream pFileStream = new FileStream(saveFilePath, FileMode.Open, FileAccess.Read);
  3266. pictureBox1.Image = Image.FromStream(pFileStream);
  3267. pFileStream.Close();
  3268. pFileStream.Dispose();
  3269. }
  3270. }
  3271. private void button10_Click(object sender, EventArgs e)
  3272. {
  3273. button9.Show();
  3274. button10.Hide();
  3275. pictureBox1.ImageLocation = null;
  3276. pictureBox1.Hide();
  3277. }
  3278. #region [读文件到byte数组]
  3279. /// <summary>
  3280. /// 读文件到byte[]
  3281. /// </summary>
  3282. /// <param name="fileName">硬盘文件路径</param>
  3283. /// <returns></returns>
  3284. public static byte[] ReadFileToByte(string fileName)
  3285. {
  3286. FileStream pFileStream = null;
  3287. byte[] pReadByte = new byte[0];
  3288. try
  3289. {
  3290. pFileStream = new FileStream(fileName, FileMode.Open, FileAccess.Read);
  3291. BinaryReader r = new BinaryReader(pFileStream);
  3292. r.BaseStream.Seek(0, SeekOrigin.Begin); //将文件指针设置到文件开
  3293. pReadByte = r.ReadBytes((int)r.BaseStream.Length);
  3294. return pReadByte;
  3295. }
  3296. catch
  3297. {
  3298. return pReadByte;
  3299. }
  3300. finally
  3301. {
  3302. if (pFileStream != null)
  3303. pFileStream.Close();
  3304. }
  3305. }
  3306. #endregion [读文件到byte数组]
  3307. #region [写byte数组到fileName]
  3308. /// <summary>
  3309. /// 写byte[]到fileName
  3310. /// </summary>
  3311. /// <param name="pReadByte">byte[]</param>
  3312. /// <param name="fileName">保存至硬盘路径</param>
  3313. /// <returns></returns>
  3314. public static void WriteByteToFile(byte[] pReadByte, string fileName)
  3315. {
  3316. FileStream pFileStream = null;
  3317. try
  3318. {
  3319. pFileStream = new FileStream(fileName, FileMode.OpenOrCreate);
  3320. pFileStream.Write(pReadByte, 0, pReadByte.Length);
  3321. }
  3322. catch (Exception ex)
  3323. {
  3324. throw ex;
  3325. }
  3326. finally
  3327. {
  3328. if (pFileStream != null)
  3329. {
  3330. pFileStream.Flush();
  3331. pFileStream.Close();
  3332. pFileStream.Dispose();
  3333. }
  3334. }
  3335. }
  3336. #endregion [写byte数组到fileName]
  3337. private void button11_Click(object sender, EventArgs e)
  3338. {
  3339. OpenFileDialog file = new OpenFileDialog();
  3340. file.Filter = "All Image Files|*.bmp;*.jpeg;*.jpg;*.png";
  3341. DialogResult dr;
  3342. dr = file.ShowDialog();
  3343. if (dr == DialogResult.OK)
  3344. {
  3345. var lastName = Path.GetExtension(file.FileName);
  3346. if (String.Compare(lastName, ".png", true) != 0 && String.Compare(lastName, ".jpg", true) != 0 && String.Compare(lastName, ".jpeg", true) != 0 && String.Compare(lastName, ".bmp", true) != 0)
  3347. {
  3348. MessageBox.Show(PdnResources.GetString("Menu.Pleaseuploadpicturese.text"));
  3349. return;
  3350. }
  3351. var fileName = Path.GetFullPath(file.FileName);
  3352. byte[] bytes = ReadFileToByte(fileName);
  3353. var saveFilePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + $"\\{DateTime.Now.ToString("yyyyMMddHHmmss") + file.SafeFileName}";
  3354. WriteByteToFile(bytes, saveFilePath);
  3355. button11.Hide();
  3356. button12.Show();
  3357. pictureBox2.Show();
  3358. pictureBox2.ImageLocation = saveFilePath;
  3359. FileStream pFileStream = new FileStream(saveFilePath, FileMode.Open, FileAccess.Read);
  3360. pictureBox2.Image = Image.FromStream(pFileStream);
  3361. pFileStream.Close();
  3362. pFileStream.Dispose();
  3363. }
  3364. }
  3365. private void button12_Click(object sender, EventArgs e)
  3366. {
  3367. button11.Show();
  3368. button12.Hide();
  3369. pictureBox2.ImageLocation = null;
  3370. pictureBox2.Hide();
  3371. }
  3372. private void button13_Click(object sender, EventArgs e)
  3373. {
  3374. if (listView2.Items.Count == 0)
  3375. {
  3376. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3377. return;
  3378. }
  3379. if (listView2.FocusedItem == null)
  3380. {
  3381. MessageBox.Show(PdnResources.GetString("Menu.seselecthedotditancedatafi.text"));
  3382. return;
  3383. }
  3384. string id = listView2.FocusedItem.SubItems[6].Text;
  3385. if (config.DotPitchId == Convert.ToInt32(id))
  3386. {
  3387. //MessageBox.Show(PdnResources.GetString("Menu.Thepointditanceisenabled.text"));
  3388. return;
  3389. }
  3390. config.DotPitchId = Convert.ToInt32(id);
  3391. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3392. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3393. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3394. {
  3395. //MessageBox.Show(PdnResources.GetString("Menu.nablesuccessfui.text"));
  3396. listView2.BeginUpdate();
  3397. int nRowOrder = 0;
  3398. int nRowOrders = listView2.Items.Count;//行数
  3399. for (nRowOrder = 0; nRowOrder < nRowOrders; nRowOrder++)//遍历listView1的每一行
  3400. {
  3401. ListViewItem lvi = listView2.Items[nRowOrder];
  3402. if (lvi.SubItems[1].Text == "√")
  3403. {
  3404. lvi.SubItems[1].Text = "×";
  3405. }
  3406. }
  3407. var Index = listView2.SelectedItems[0].Index;
  3408. var lv = listView2.Items[Index];
  3409. lv.SubItems[1].Text = "√";
  3410. listView2.EndUpdate();
  3411. }
  3412. else
  3413. {
  3414. MessageBox.Show(PdnResources.GetString("Menu.Enablethefailure.text"));
  3415. }
  3416. }
  3417. private void radioButton2_CheckedChanged(object sender, EventArgs e)
  3418. {
  3419. textBox3.ReadOnly = true;
  3420. //textBox3.Text = "";
  3421. }
  3422. private void radioButton1_CheckedChanged(object sender, EventArgs e)
  3423. {
  3424. textBox3.ReadOnly = false;
  3425. }
  3426. private void listBox1_DrawItem(object sender, DrawItemEventArgs e)
  3427. {
  3428. e.DrawBackground();
  3429. e.DrawFocusRectangle();
  3430. StringFormat strFmt = new System.Drawing.StringFormat();
  3431. strFmt.Alignment = StringAlignment.Center; //文本垂直居中
  3432. strFmt.LineAlignment = StringAlignment.Center; //文本水平居中
  3433. e.Graphics.DrawString(listBox1.Items[e.Index].ToString(), e.Font, new SolidBrush(Color.Black), e.Bounds, strFmt);
  3434. }
  3435. /// <summary>
  3436. /// 相机设置添加按钮
  3437. /// </summary>
  3438. /// <param name="sender"></param>
  3439. /// <param name="e"></param>
  3440. private void button16_Click(object sender, EventArgs e)
  3441. {
  3442. string id = string.Empty;
  3443. using (CameraSettingsAddDialog pd = new CameraSettingsAddDialog(id, listView3))
  3444. {
  3445. pd.ShowDialog();
  3446. }
  3447. }
  3448. /// <summary>
  3449. /// 相机设置编辑按钮
  3450. /// </summary>
  3451. /// <param name="sender"></param>
  3452. /// <param name="e"></param>
  3453. private void button15_Click(object sender, EventArgs e)
  3454. {
  3455. string id = string.Empty;
  3456. int thisIndex = 0;
  3457. if (listView3.Items.Count == 0)
  3458. {
  3459. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3460. return;
  3461. }
  3462. if (listView3.FocusedItem != null)
  3463. {
  3464. id = listView3.FocusedItem.Tag.ToString();
  3465. thisIndex = listView3.Items.IndexOf(listView3.FocusedItem);
  3466. }
  3467. else
  3468. {
  3469. MessageBox.Show(PdnResources.GetString("Menu.Pleaseselecadirectoryfirst.Text"));
  3470. return;
  3471. //id = "1";
  3472. }
  3473. using (CameraSettingsAddDialog pd = new CameraSettingsAddDialog(id, listView3, thisIndex))
  3474. {
  3475. pd.ShowDialog();
  3476. }
  3477. }
  3478. /// <summary>
  3479. /// 相机设置删除按钮
  3480. /// </summary>
  3481. /// <param name="sender"></param>
  3482. /// <param name="e"></param>
  3483. private void button17_Click(object sender, EventArgs e)
  3484. {
  3485. if (listView3.Items.Count == 0)
  3486. {
  3487. MessageBox.Show(PdnResources.GetString("Menu.Dataisemptyi.text") + "!");
  3488. return;
  3489. }
  3490. if (listView3.FocusedItem == null)
  3491. {
  3492. MessageBox.Show(PdnResources.GetString("Menu.Pleaseselecadirectoryfirst.Text"));
  3493. //id = listView3.Items[0].Tag.ToString();
  3494. return;
  3495. }
  3496. DialogResult dr;
  3497. dr = MessageBox.Show(PdnResources.GetString("Menu.eyousureyouwantodeletet.text"), PdnResources.GetString("Menu.Edit.Delete.Text"), MessageBoxButtons.OKCancel,
  3498. MessageBoxIcon.Warning, MessageBoxDefaultButton.Button1);
  3499. if (dr == DialogResult.OK)
  3500. {
  3501. string id = string.Empty;
  3502. if (listView3.FocusedItem != null)
  3503. {
  3504. id = listView3.FocusedItem.Tag.ToString();
  3505. }
  3506. //else
  3507. //{
  3508. // MessageBox.Show(PdnResources.GetString("Menu.Pleaseselecadirectoryfirst.Text"));
  3509. // //id = listView3.Items[0].Tag.ToString();
  3510. // return;
  3511. //}
  3512. var point = mic_camerasettings_BLL.FindDefault(Convert.ToInt32(id));
  3513. if (point == null || point.delete_flag == 1)
  3514. {
  3515. MessageBox.Show(PdnResources.GetString("Menu.Abnormalinformation.text"));
  3516. }
  3517. point.delete_flag = 1;
  3518. mic_camerasettings_BLL.Update(point);
  3519. if (listView3.SelectedItems.Count > 0)
  3520. {
  3521. var Index = listView3.SelectedItems[0].Index;
  3522. listView3.Items[Index].Remove();
  3523. }
  3524. else
  3525. {
  3526. listView3.Items[0].Remove();
  3527. }
  3528. }
  3529. else if (dr == DialogResult.Cancel)
  3530. {
  3531. }
  3532. if (listView3.Items.Count > 0)
  3533. {
  3534. listView3.Items[0].Selected = true;
  3535. listView3.Select();
  3536. }
  3537. }
  3538. /// <summary>
  3539. /// 应用按钮
  3540. /// </summary>
  3541. /// <param name="sender"></param>
  3542. /// <param name="e"></param>
  3543. private void button14_Click(object sender, EventArgs e)
  3544. {
  3545. if (listView3.Items.Count == 0)
  3546. {
  3547. MessageBox.Show(PdnResources.GetString("Menu.Thereisnolistofdata.text"));
  3548. return;
  3549. }
  3550. if (listView3.FocusedItem == null)
  3551. {
  3552. MessageBox.Show("请选择要应用的数据");
  3553. return;
  3554. }
  3555. string id = listView3.FocusedItem.Tag.ToString();
  3556. if (config.Camera == Convert.ToInt32(id))
  3557. {
  3558. //MessageBox.Show(PdnResources.GetString("Menu.Thepointditanceisenabled.text"));
  3559. return;
  3560. }
  3561. config.Camera = Convert.ToInt32(id);
  3562. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3563. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3564. if (FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3565. {
  3566. //MessageBox.Show(PdnResources.GetString("Menu.nablesuccessfui.text"));
  3567. listView3.BeginUpdate();
  3568. int nRowOrder = 0;
  3569. int nRowOrders = listView3.Items.Count;//行数
  3570. for (nRowOrder = 0; nRowOrder < nRowOrders; nRowOrder++)//遍历listView1的每一行
  3571. {
  3572. ListViewItem lvi = listView3.Items[nRowOrder];
  3573. if (lvi.SubItems[1].Text == "√")
  3574. {
  3575. lvi.SubItems[1].Text = "×";
  3576. }
  3577. }
  3578. var Index = listView3.SelectedItems.Count < 1 ? listView3.FocusedItem.Index : listView3.SelectedItems[0].Index;
  3579. var lv = listView3.Items[Index];
  3580. lv.SubItems[1].Text = "√";
  3581. listView3.EndUpdate();
  3582. }
  3583. else
  3584. {
  3585. MessageBox.Show(PdnResources.GetString("Menu.Enablethefailure.text"));
  3586. }
  3587. //this.Close();
  3588. //MessageBox.Show(PdnResources.GetString("Menu.Applicationsuccessfully.Text")+ "!");
  3589. }
  3590. /// <summary>
  3591. /// 方向设置确定按钮
  3592. /// </summary>
  3593. /// <param name="sender"></param>
  3594. /// <param name="e"></param>
  3595. private void button18_Click(object sender, EventArgs e)
  3596. {
  3597. if (radioButton6.Checked)
  3598. {
  3599. config.ZMovementDirection = 0;
  3600. }
  3601. else if (radioButton7.Checked)
  3602. {
  3603. config.ZMovementDirection = 1;
  3604. }
  3605. if (radioButton8.Checked)
  3606. {
  3607. config.XLeftMovementDirection = 0;
  3608. }
  3609. else if (radioButton9.Checked)
  3610. {
  3611. config.XLeftMovementDirection = 1;
  3612. }
  3613. if (radioButton10.Checked)
  3614. {
  3615. config.XRighttMovementDirection = 0;
  3616. }
  3617. else if (radioButton11.Checked)
  3618. {
  3619. config.XRighttMovementDirection = 1;
  3620. }
  3621. if (radioButton12.Checked)
  3622. {
  3623. config.YLeftMovementDirection = 0;
  3624. }
  3625. else if (radioButton13.Checked)
  3626. {
  3627. config.YLeftMovementDirection = 1;
  3628. }
  3629. if (radioButton14.Checked)
  3630. {
  3631. config.YRighttMovementDirection = 0;
  3632. }
  3633. else if (radioButton15.Checked)
  3634. {
  3635. config.YRighttMovementDirection = 1;
  3636. }
  3637. string configXml = XmlSerializeHelper.XmlSerialize<ConfigModel>(config);
  3638. string filePath = Application.StartupPath + "\\Config\\" + Startup.instance.SettingPrefix + "\\Config.xml";
  3639. if (!FileOperationHelper.WriteStringToFile(configXml, filePath, FileMode.Create))
  3640. {
  3641. MessageBox.Show(PdnResources.GetString("Menu.Directionsettingfailed.text") + "!");
  3642. //MessageBox.Show(PdnResources.GetString("Menu.Directionsetsuccessfully.text")+"!");
  3643. //this.Close();
  3644. }
  3645. //else
  3646. //{
  3647. // MessageBox.Show(PdnResources.GetString("Menu.Directionsettingfailed.text")+ "!");
  3648. //}
  3649. }
  3650. /// <summary>
  3651. /// 方向设置取消按钮
  3652. /// </summary>
  3653. /// <param name="sender"></param>
  3654. /// <param name="e"></param>
  3655. private void button19_Click(object sender, EventArgs e)
  3656. {
  3657. this.Close();
  3658. }
  3659. /// <summary>
  3660. /// 辅助线样式应用按钮
  3661. /// </summary>
  3662. /// <param name="sender"></param>
  3663. /// <param name="e"></param>
  3664. private void button20_Click(object sender, EventArgs e)
  3665. {
  3666. Startup.instance.guideStyleModel.lineStyle = this.comboBox2.SelectedIndex;
  3667. Startup.instance.guideStyleModel.lineColour = this.panel6.BackColor.ToArgb();
  3668. Startup.instance.guideStyleModel.lineWidth = this.numericUpDown1.Value;
  3669. //另存为XML
  3670. string stageModelXml = XmlSerializeHelper.XmlSerialize<GuideStyleModel>(Startup.instance.guideStyleModel);
  3671. string filePath = Application.StartupPath + @"\Config\Default\SetUp\GuideStyle.xml";
  3672. FileOperationHelper.WriteStringToFile(stageModelXml, filePath, FileMode.Create);
  3673. }
  3674. /// <summary>
  3675. /// 辅助线样式取消按钮
  3676. /// </summary>
  3677. /// <param name="sender"></param>
  3678. /// <param name="e"></param>
  3679. private void button21_Click(object sender, EventArgs e)
  3680. {
  3681. this.Close();
  3682. }
  3683. }
  3684. }