Changeset 227


Ignore:
Timestamp:
Jun 24, 2023, 1:20:22 AM (18 months ago)
Author:
chronos
Message:
  • Added: Test form.
  • Added: Interface translation.
  • Added: Common package.
Location:
branches/xpascal
Files:
78 added
10 edited

Legend:

Unmodified
Added
Removed
  • branches/xpascal/Forms/FormMain.lfm

    r224 r227  
    4949  end
    5050  object MainMenu1: TMainMenu
    51     Left = 760
     51    Left = 744
    5252    Top = 760
    5353    object MenuItemFile: TMenuItem
     
    7979      object MenuItem5: TMenuItem
    8080        Action = ACompile
     81      end
     82    end
     83    object MenuItem8: TMenuItem
     84      Caption = 'Tools'
     85      object MenuItem9: TMenuItem
     86        Action = ATest
    8187      end
    8288    end
     
    115121      OnExecute = AGenerateXmlExecute
    116122    end
     123    object ATest: TAction
     124      Caption = 'Test'
     125      OnExecute = ATestExecute
     126    end
    117127  end
    118128end
  • branches/xpascal/Forms/FormMain.pas

    r225 r227  
    1414  TFormMain = class(TForm)
    1515    ACompile: TAction;
     16    ATest: TAction;
    1617    AGenerateXml: TAction;
    1718    AExit: TAction;
     
    2930    MenuItem6: TMenuItem;
    3031    MenuItem7: TMenuItem;
     32    MenuItem8: TMenuItem;
     33    MenuItem9: TMenuItem;
    3134    MenuItemRun: TMenuItem;
    3235    MenuItemGenerate: TMenuItem;
     
    4245    procedure AGeneratePhpExecute(Sender: TObject);
    4346    procedure AGenerateXmlExecute(Sender: TObject);
     47    procedure ATestExecute(Sender: TObject);
    4448    procedure FormCreate(Sender: TObject);
    4549    procedure Optimize(Features: TOptimizeFeatures);
     
    7175
    7276uses
    73   Parser, Executor, GeneratorPascal, GeneratorPhp,
     77  Parser, Executor, GeneratorPascal, GeneratorPhp, FormTests,
    7478  GeneratorCSharp, GeneratorXml, ParserPascal;
    7579
     
    9498  FreeAndNil(FormSource);
    9599  FreeAndNil(FormMessages);
     100  FreeAndNil(FormOutput);
    96101end;
    97102
     
    194199end;
    195200
     201procedure TFormMain.ATestExecute(Sender: TObject);
     202begin
     203  with TFormTests.Create(nil) do
     204  try
     205    ShowModal;
     206  finally
     207    Free;
     208  end;
     209end;
     210
    196211procedure TFormMain.FormCreate(Sender: TObject);
    197212begin
  • branches/xpascal/Forms/FormMessages.lfm

    r224 r227  
    88  ClientWidth = 521
    99  DesignTimePPI = 144
    10   LCLVersion = '2.0.2.0'
     10  LCLVersion = '2.2.6.0'
    1111  object Label1: TLabel
    1212    Left = 8
  • branches/xpascal/Forms/FormMessages.pas

    r224 r227  
    44
    55uses
    6   Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls;
     6  Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls, FormEx;
    77
    88type
     
    1010  { TFormMessages }
    1111
    12   TFormMessages = class(TForm)
     12  TFormMessages = class(TFormEx)
    1313    Label1: TLabel;
    1414    MemoLog: TMemo;
  • branches/xpascal/Forms/FormOutput.lfm

    r224 r227  
    88  ClientWidth = 932
    99  DesignTimePPI = 144
    10   LCLVersion = '2.0.2.0'
     10  LCLVersion = '2.2.6.0'
    1111  inline SynEditOutput: TSynEdit
    1212    Left = 11
     
    512512    Height = 26
    513513    Top = 8
    514     Width = 66
     514    Width = 64
    515515    Caption = 'Output:'
    516516    ParentColor = False
     
    520520    CompilerMode = pcmDelphi
    521521    NestedComments = False
    522     left = 304
    523     top = 219
     522    TypeHelpers = True
     523    Left = 304
     524    Top = 219
    524525  end
    525526  object SynCppSyn1: TSynCppSyn
    526527    DefaultFilter = 'Soubory C++ (*.c,*.cpp,*.h,*.hpp,*.hh)|*.c;*.cpp;*.h;*.hpp;*.hh'
    527528    Enabled = False
    528     left = 325
    529     top = 136
     529    Left = 325
     530    Top = 136
    530531  end
    531532  object SynXMLSyn1: TSynXMLSyn
     
    533534    Enabled = False
    534535    WantBracesParsed = False
    535     left = 213
    536     top = 100
     536    Left = 213
     537    Top = 100
    537538  end
    538539  object SynPHPSyn1: TSynPHPSyn
    539540    DefaultFilter = 'Soubory PHP (*.php,*.php3,*.phtml,*.inc)|*.php;*.php3;*.phtml;*.inc'
    540541    Enabled = False
    541     left = 359
    542     top = 75
     542    Left = 359
     543    Top = 75
    543544  end
    544545end
  • branches/xpascal/Forms/FormOutput.pas

    r224 r227  
    66  Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls, SynEdit,
    77  SynHighlighterAny, SynHighlighterPas, SynHighlighterCpp, SynHighlighterXML,
    8   SynHighlighterPHP;
     8  SynHighlighterPHP, FormEx;
    99
    1010type
     
    1212  { TFormOutput }
    1313
    14   TFormOutput = class(TForm)
     14  TFormOutput = class(TFormEx)
    1515    Label1: TLabel;
    1616    SynCppSyn1: TSynCppSyn;
  • branches/xpascal/Forms/FormSource.lfm

    r224 r227  
    88  ClientWidth = 1176
    99  DesignTimePPI = 144
    10   LCLVersion = '2.0.2.0'
     10  LCLVersion = '2.2.6.0'
    1111  inline SynEditSource: TSynEdit
    1212    Left = 12
     
    521521    CompilerMode = pcmObjFPC
    522522    NestedComments = True
    523     left = 616
    524     top = 184
     523    TypeHelpers = False
     524    Left = 616
     525    Top = 184
    525526  end
    526527end
  • branches/xpascal/Forms/FormSource.pas

    r224 r227  
    55uses
    66  Classes, SysUtils, Forms, Controls, Graphics, Dialogs, StdCtrls,
    7   SynHighlighterPas, SynEdit;
     7  SynHighlighterPas, SynEdit, FormEx;
    88
    99type
     
    1111  { TFormSource }
    1212
    13   TFormSource = class(TForm)
     13  TFormSource = class(TFormEx)
    1414    Label1: TLabel;
    1515    SynEditSource: TSynEdit;
  • branches/xpascal/xpascal.lpi

    r225 r227  
    1717      <Icon Value="0"/>
    1818    </General>
     19    <i18n>
     20      <EnableI18N Value="True"/>
     21      <OutDir Value="Languages"/>
     22    </i18n>
    1923    <BuildModes Count="2">
    2024      <Item1 Name="Debug" Default="True"/>
     
    6569      <FormatVersion Value="2"/>
    6670    </RunParams>
    67     <RequiredPackages Count="2">
     71    <RequiredPackages Count="3">
    6872      <Item1>
    69         <PackageName Value="SynEdit"/>
     73        <PackageName Value="Common"/>
     74        <DefaultFilename Value="Packages/Common/Common.lpk" Prefer="True"/>
    7075      </Item1>
    7176      <Item2>
     77        <PackageName Value="SynEdit"/>
     78      </Item2>
     79      <Item3>
    7280        <PackageName Value="LCL"/>
    73       </Item2>
     81      </Item3>
    7482    </RequiredPackages>
    75     <Units Count="17">
     83    <Units Count="19">
    7684      <Unit0>
    7785        <Filename Value="xpascal.lpr"/>
     
    154162        <IsPartOfProject Value="True"/>
    155163      </Unit16>
     164      <Unit17>
     165        <Filename Value="Forms/FormTests.pas"/>
     166        <IsPartOfProject Value="True"/>
     167        <ComponentName Value="FormTests"/>
     168        <HasResources Value="True"/>
     169        <ResourceBaseClass Value="Form"/>
     170      </Unit17>
     171      <Unit18>
     172        <Filename Value="Forms/FormTest.pas"/>
     173        <IsPartOfProject Value="True"/>
     174        <ComponentName Value="FormTestCase"/>
     175        <HasResources Value="True"/>
     176        <ResourceBaseClass Value="Form"/>
     177      </Unit18>
    156178    </Units>
    157179  </ProjectOptions>
  • branches/xpascal/xpascal.lpr

    r225 r227  
    88  {$ENDIF}{$ENDIF}
    99  Interfaces, SysUtils, // this includes the LCL widgetset
    10   Forms, Parser, Tokenizer, Source, Executor, Interpreter,
    11   Generator, FormMessages,
    12   FormSource, Optimizer, FormOutput, FormMain, ParserPascal
    13   { you can add units after this };
     10  Forms, Parser, Tokenizer, Source, Executor, Interpreter, Generator,
     11  FormMessages, FormSource, Optimizer, FormOutput, FormMain,
     12  FormTests, FormTest, ParserPascal;
    1413
    1514{$R *.res}
Note: See TracChangeset for help on using the changeset viewer.