이노셋업 (Inno Setup) // About , 홈페이지 버튼
만드는법을 알려드릴까 합니다.
(저도 예제 샘플보고 알려드리는 겁니다 ..)
모두 [Code]섹션에 넣어주시면 됩니다.
붉은 글씨를 수정하시면 됩니다.
버튼에 링크 및 설명을 연결합니다
procedure AboutButtonOnClick(Sender: TObject);
begin
MsgBox(' 대하여 설명 ', mbInformation, mb_Ok);
end;
procedure URLLabelOnClick(Sender: TObject);
var
ErrorCode: Integer;
begin
ShellExec('open', ' 링크 ', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end;
begin
MsgBox(' 대하여 설명 ', mbInformation, mb_Ok);
end;
procedure URLLabelOnClick(Sender: TObject);
var
ErrorCode: Integer;
begin
ShellExec('open', ' 링크 ', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end;
대하여 설명 과 링크를 수정하시면 됩니다.
그다음 버튼 제작
procedure CreateAboutButtonAndURLLabel(ParentForm: TSetupForm; CancelButton: TNewButton);
var
AboutButton: TNewButton;
URLLabel: TNewStaticText;
begin
AboutButton := TNewButton.Create(ParentForm);
AboutButton.Left := ParentForm.ClientWidth - CancelButton.Left - CancelButton.Width;
AboutButton.Top := CancelButton.Top;
AboutButton.Width := CancelButton.Width;
AboutButton.Height := CancelButton.Height;
AboutButton.Caption := '&대하여';
AboutButton.OnClick := @AboutButtonOnClick;
AboutButton.Parent := ParentForm;
URLLabel := TNewStaticText.Create(ParentForm);
URLLabel.Caption := 'NoBLess 블로그';
URLLabel.Cursor := crHand;
URLLabel.OnClick := @URLLabelOnClick;
URLLabel.Parent := ParentForm;
URLLabel.Font.Style := URLLabel.Font.Style + [fsUnderline];
URLLabel.Font.Color := clBlue;
URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
URLLabel.Left := AboutButton.Left + AboutButton.Width + ScaleX(20);
end;
var
AboutButton: TNewButton;
URLLabel: TNewStaticText;
begin
AboutButton := TNewButton.Create(ParentForm);
AboutButton.Left := ParentForm.ClientWidth - CancelButton.Left - CancelButton.Width;
AboutButton.Top := CancelButton.Top;
AboutButton.Width := CancelButton.Width;
AboutButton.Height := CancelButton.Height;
AboutButton.Caption := '&대하여';
AboutButton.OnClick := @AboutButtonOnClick;
AboutButton.Parent := ParentForm;
URLLabel := TNewStaticText.Create(ParentForm);
URLLabel.Caption := 'NoBLess 블로그';
URLLabel.Cursor := crHand;
URLLabel.OnClick := @URLLabelOnClick;
URLLabel.Parent := ParentForm;
URLLabel.Font.Style := URLLabel.Font.Style + [fsUnderline];
URLLabel.Font.Color := clBlue;
URLLabel.Top := AboutButton.Top + AboutButton.Height - URLLabel.Height - 2;
URLLabel.Left := AboutButton.Left + AboutButton.Width + ScaleX(20);
end;
그다음 버튼을 표시해야합니다
procedure InitializeWizard();
begin
CreateAboutButtonAndURLLabel(WizardForm, WizardForm.CancelButton);
begin
CreateAboutButtonAndURLLabel(WizardForm, WizardForm.CancelButton);
저런식으로 하면 간단하게 대하여 버튼과 홈페이지 버튼을 추가할수 있습니다.
샘플 스크립트(아래는 샘플 스크립트입니다 참고해서 사용하세요 ㅎㅎ)
'자료 > Inno-Setup' 카테고리의 다른 글
이노셋업 (Inno Setup) // IST Tray (트레이) (0) | 2010.09.16 |
---|---|
이노셋업 (Inno Setup) // 편리한 InnoIDE (GUI) (0) | 2010.09.16 |
이노 셋업 (Inno Setup) // 다운로더 한글화 하는법 (1) | 2010.09.14 |
Inno Setup :: 이노 셋업 업데이트 기능 (0) | 2010.08.04 |
이노 셋업(Inno Setup) :: 사용자 지정 설치 (1) | 2010.07.14 |
이노 셋업(Inno Setup) :: 포함 스크립트 (#Includes Script) (0) | 2010.07.14 |
이노셋업 (Inno Setup) :: 인스톨러에 스킨을 적용하자! (0) | 2010.07.13 |