source: trunk/NewView/InformationFormUnit.pas@ 33

Last change on this file since 33 was 33, checked in by RBRi, 19 years ago

more uses cleanup

  • Property svn:eol-style set to native
File size: 1.6 KB
Line 
1Unit InformationFormUnit;
2
3// NewView - a new OS/2 Help Viewer
4// Copyright 2003 Aaron Lawrence (aaronl at consultant dot com)
5// This software is released under the Gnu Public License - see readme.txt
6
7Interface
8
9Uses
10 Classes,
11 Forms,
12 StdCtrls,
13 Buttons,
14 ACLLanguageUnit;
15
16Type
17 TInformationForm = Class (TForm)
18 InformationMemo: TMemo;
19 OKButton: TButton;
20 Procedure InformationFormOnSetupShow (Sender: TObject);
21 Procedure InformationFormOnShow (Sender: TObject);
22 Procedure InformationFormOnCreate (Sender: TObject);
23 Private
24 {Insert private declarations here}
25 Public
26 FText: pchar; // for messages with long lines
27 Procedure OnLanguageEvent( Language: TLanguageFile;
28 const Apply: boolean );
29 End;
30
31Var
32 InformationForm: TInformationForm;
33
34Implementation
35
36Uses
37 ControlsUtility;
38
39Procedure TInformationForm.InformationFormOnSetupShow (Sender: TObject);
40Begin
41 ScaleForm( self, 11, 16 );
42
43 InformationMemo.XStretch := xsFrame;
44 InformationMemo.YStretch := ysFrame;
45End;
46
47Procedure TInformationForm.InformationFormOnShow (Sender: TObject);
48Begin
49 if FText <> nil then
50 InformationMemo.Lines.SetText( FText );
51 FText := nil;
52End;
53
54Procedure TInformationForm.InformationFormOnCreate (Sender: TObject);
55Begin
56 RegisterForLanguages( OnLanguageEvent );
57End;
58
59Procedure TInformationForm.OnLanguageEvent( Language: TLanguageFile;
60 const Apply: boolean );
61begin
62 Language.LoadComponentLanguage( self, Apply );
63end;
64
65Initialization
66 RegisterClasses ([TInformationForm, TMemo, TButton]);
67End.
Note: See TracBrowser for help on using the repository browser.