Develop and Download Open Source Software

Browse Subversion Repository

Contents of /optina.pas

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1 - (show annotations) (download) (as text)
Mon Nov 7 12:03:00 2011 UTC (12 years, 4 months ago) by shiraishikazuo
File MIME type: text/x-pascal
File size: 1650 byte(s)


1 unit optina;
2
3 {$IFDEF FPC}
4 {$MODE DELPHI}{$H+}
5 {$ENDIF}
6
7 (***************************************)
8 (* Copyright (C) 2003, SHIRAISHI Kazuo *)
9 (***************************************)
10
11
12 interface
13
14 uses
15 SysUtils, Classes, Graphics, Controls,
16 StdCtrls, Forms, CheckLst , LResources, Buttons;
17
18 type
19 TOptionAC = class(TForm)
20 Button1: TButton;
21 Button2: TButton;
22 Help1: TButton;
23 CheckListBox1: TCheckListBox;
24 Label1: TLabel;
25 CheckListBox2: TCheckListBox;
26 Label2: TLabel;
27 Label3: TLabel;
28 CheckListBox3: TCheckListBox;
29 Label4: TLabel;
30 CheckListBox4: TCheckListBox;
31 procedure FormCreate(Sender: TObject);
32 procedure Help1Click(Sender: TObject);
33 procedure FormDestroy(Sender: TObject);
34 end;
35
36 var
37 OptionAC: TOptionAC;
38
39
40
41 implementation
42 uses inifiles,base,base0;
43 {$R *.lfm}
44
45
46 procedure TOptionAC.FormCreate(Sender: TObject);
47 var
48 i:integer;
49 IniFile:TMyIniFile;
50 begin
51 with CheckListBox1 do
52 for i:=ac_let to ac_remark do
53 checked[i]:=true;
54
55 IniFile:=TMyIniFile.create('OptionAC');
56 for i:=0 to ac_end do
57 AutoCorrect[i]:=IniFile.ReadBool(IntToStr(i),AutoCorrect[i]);
58 IniFile.free;
59 end;
60
61 procedure TOptionAC.Help1Click(Sender: TObject);
62 begin
63 Application.HelpContext(HelpContext);
64 end;
65
66 procedure TOptionAC.FormDestroy(Sender: TObject);
67 var
68 i:integer;
69 IniFile:TMyIniFile;
70 begin
71 IniFile:=TMyIniFile.create('OptionAC');
72 for i:=0 to ac_end do
73 IniFile.WriteBool(IntToStr(i),AutoCorrect[i]);
74 IniFile.free;
75 end;
76
77 initialization
78
79
80
81 end.

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26