Имя пользователя:
Пароль:  
Помощь | Регистрация | Забыли пароль?  

Показать сообщение отдельно

Ветеран


Сообщения: 1133
Благодарности: 581

Профиль | Отправить PM | Цитировать


Цитата Krekerpro:
Опять ему чтот не нравится »
Ух, какой он у вас привередливый...
Попробуйте закомментировать эту строку, должно помочь.

Цитата Konstantin_555:
А есть где-то ссылка на подробное описание создания форм? »
Подробное описание вы не найдёте. Есть коротко написаное описание, в Справке к Inno. Есть пример, в папке Examples, название скрипта не помню. Вот, как-то делал форму авторан:
Пример
Код: Выделить весь код
[Setup]
AppName=My Program
AppVerName=My Program v 1.5
DefaultDirName={pf}\My Program
OutputDir=.
Compression=lzma/ultra
InternalCompressLevel=ultra
SolidCompression=yes

[Files]
Source: AutoRun.bmp; Flags: dontcopy

[code]
var
  AutoRun: TSetupForm;
  img1: TBitmapImage;
  btn, btn1: TButton;
  btn2: TButton;
  btn3: TButton;
  btn4: TButton;
  btn5: TButton;
  btn6: TButton;
  btn7: TButton;
  btn8: TButton;
  i, t: integer;

procedure btn7Click(Sender: TObject);
begin
  btn7.Height:= 21;
  btn7.Width:= 21;
  btn7.Top:= 325;
  btn7.Font.Style := [fsBold];
  btn8.Height:= 23;
  btn8.Width:= 23;
  btn8.Top:= 324;
  btn8.Font.Style := [];
end;

procedure btn8Click(Sender: TObject);
begin
  btn7.Height:= 23;
  btn7.Width:= 23;
  btn7.Top:= 324;
  btn7.Font.Style := [];
  btn8.Height:= 21;
  btn8.Width:= 21;
  btn8.Top:= 325;
  btn8.Font.Style := [fsBold];
end;


procedure CreateAutoRun;
begin
  //AutoRun
  AutoRun := CreateCustomForm;
  with AutoRun do begin
    Left := 498;
    Top := 75;
    Width := 586;
    Height := 386;
    BorderIcons := [];
    Color := clBtnFace;
    Font.Color := clWindowText;
    Font.Height := -11;
    Font.Name := 'MS Sans Serif';
    Font.Style := [];
    Position := poScreenCenter;
  end;
  //img1
  img1 := TBitmapImage.Create(AutoRun);
  ExtractTemporaryFile('AutoRun.bmp');
  with img1 do begin
    Parent := AutoRun;
    Left := 10;
    Top := 10;
    Width := 220;
    Height := 335;
    Bitmap.LoadFromFile(ExpandConstant('{tmp}\AutoRun.bmp'));
  end;
  //btn1
  btn1:= TButton.Create(AutoRun);
  with btn1 do begin
    Parent := AutoRun;
    Left := 248;
    Top := 15;
    Width := 313;
    Height := 22;
    Caption:= 'Начать игру';
    Cursor:= crHand;
  end;
  //btn2
  btn2:= TButton.Create(AutoRun);
  with btn2 do begin
    Parent:= AutoRun;
    Left := 248;
    Top := 75;
    Width := 313;
    Height := 22;
    Caption:= 'Установка';
    Cursor:= crHand;
  end;
  //btn3
  btn3:= TButton.Create(AutoRun);
  with btn3 do begin
    Parent:= AutoRun;
    Left := 248;
    Top := 135;
    Width := 313;
    Height := 22;
    Caption:= 'Техническая поддержка';
    Cursor:= crHand;
  end;
  //btn4
  btn4:= TButton.Create(AutoRun);
  with btn4 do begin
    Parent:= AutoRun;
    Left := 248;
    Top := 195;
    Width := 313;
    Height := 22;
    Caption:= 'Readme';
    Cursor:= crHand;
  end;
  //btn5
  btn5:= TButton.Create(AutoRun);
  with btn5 do begin
    Parent:= AutoRun;
    Left := 248;
    Top := 255;
    Width := 313;
    Height := 22;
    Caption:= 'Веб-сайт';
    Cursor:= crHand;
  end;
  //btn6
  btn6:= TButton.Create(AutoRun);
  with btn6 do begin
    Parent:= AutoRun;
    Left := 248;
    Top := 315;
    Width := 313;
    Height := 22;
    Caption:= 'Выход';
    Cursor:= crHand;
    ModalResult:= mrCancel;
  end;
  //btn7
  btn7:= TButton.Create(AutoRun);
  with btn7 do begin
    Parent := AutoRun;
    Left := 8;
    Top := 324;
    Width := 23;
    Height := 23;
    Cursor := crHand;
    Caption := 'EN';
    Font.Color := clWindowText;
    Font.Height := -5;
    Font.Name := 'MS Sans Serif';
    Font.Style := [];
    ParentFont := False;
    TabOrder := 6;
    OnClick := @btn7Click;
  end;
  //btn8
  btn8:= TButton.Create(AutoRun);
  with btn8 do begin
    Parent := AutoRun;
    Left := 31;
    Top := 325;
    Width := 21;
    Height := 21;
    Cursor := crHand;
    Caption := 'RU';
    Font.Color := clWindowText;
    Font.Height := -5;
    Font.Name := 'MS Sans Serif';
    Font.Style := [fsBold];
    ParentFont := False;
    TabOrder := 6;
    OnClick := @btn8Click;
  end;
  AutoRun.ShowModal;
end;

procedure InitializeWizard;
begin
  CreateAutoRun;
end;

-------
Книги нужны, чтобы напоминать человеку, что его оригинальные мысли не так уж новы... Авраам Линкольн.


Отправлено: 23:55, 09-06-2009 | #907