home *** CD-ROM | disk | FTP | other *** search
/ Chip 2001 September / Chip_2001-09_cd1.bin / zkuste / delphi / kolekce / d12345 / CHEMPLOT.ZIP / TPlot / Parser.hpp < prev    next >
C/C++ Source or Header  |  2001-06-01  |  4KB  |  131 lines

  1. // Borland C++ Builder
  2. // Copyright (c) 1995, 1998 by Borland International
  3. // All rights reserved
  4.  
  5. // (DO NOT EDIT: machine generated header) 'Parser.pas' rev: 3.00
  6.  
  7. #ifndef ParserHPP
  8. #define ParserHPP
  9. #include <Misc.hpp>
  10. #include <StdCtrls.hpp>
  11. #include <Grids.hpp>
  12. #include <Graphics.hpp>
  13. #include <Forms.hpp>
  14. #include <ExtCtrls.hpp>
  15. #include <Controls.hpp>
  16. #include <ComCtrls.hpp>
  17. #include <Buttons.hpp>
  18. #include <Windows.hpp>
  19. #include <SysUtils.hpp>
  20. #include <Classes.hpp>
  21. #include <SysInit.hpp>
  22. #include <System.hpp>
  23.  
  24. //-- user supplied -----------------------------------------------------------
  25.  
  26. namespace Parser
  27. {
  28. //-- type declarations -------------------------------------------------------
  29. enum TDelimiter { dlNone, dlTab, dlComma, dlSpace, dlColon, dlSemiColon, dlLineFeed, dlOwn };
  30.  
  31. enum TColumnType { ctIgnore, ctX, ctY };
  32.  
  33. struct TSeriesInfo
  34. {
  35.     int Index;
  36.     int XCol;
  37.     int XTextCol;
  38.     int YCol;
  39.     int XSeriesIndex;
  40.     float XValue;
  41.     float YValue;
  42. } ;
  43.  
  44. typedef TSeriesInfo TSeriesInfoArray[1024];
  45.  
  46. typedef TSeriesInfoArray *pSeriesInfoArray;
  47.  
  48. typedef System::AnsiString Parser__2[8];
  49.  
  50. class DELPHICLASS TParserForm;
  51. class PASCALIMPLEMENTATION TParserForm : public Forms::TForm 
  52. {
  53.     typedef Forms::TForm inherited;
  54.     
  55. __published:
  56.     Stdctrls::TListBox* DataListBox;
  57.     Stdctrls::TLabel* Label1;
  58.     Stdctrls::TComboBox* DelimiterComboBox;
  59.     Stdctrls::TEdit* LineEdit;
  60.     Stdctrls::TGroupBox* GroupBox1;
  61.     Stdctrls::TButton* SeriesNamesButton;
  62.     Stdctrls::TButton* FirstLineOfDataButton;
  63.     Buttons::TBitBtn* HelpBitBtn;
  64.     Buttons::TBitBtn* BitBtn2;
  65.     Buttons::TBitBtn* OKBitBtn;
  66.     Grids::TStringGrid* InfoGrid;
  67.     Stdctrls::TComboBox* PickXDataComboBox;
  68.     Stdctrls::TButton* ZDataLineButton;
  69.     Stdctrls::TLabel* NoSeriesLabel;
  70.     Buttons::TBitBtn* ExpandBitBtn;
  71.     Extctrls::TTimer* Timer1;
  72.     Stdctrls::TLabel* InstructionsLabel;
  73.     void __fastcall FormCreate(System::TObject* Sender);
  74.     void __fastcall DataListBoxClick(System::TObject* Sender);
  75.     void __fastcall FirstLineOfDataButtonClick(System::TObject* Sender);
  76.     void __fastcall SeriesNamesButtonClick(System::TObject* Sender);
  77.     void __fastcall InfoGridClick(System::TObject* Sender);
  78.     void __fastcall PickXDataComboBoxClick(System::TObject* Sender);
  79.     void __fastcall HelpBitBtnClick(System::TObject* Sender);
  80.     void __fastcall ZDataLineButtonClick(System::TObject* Sender);
  81.     void __fastcall FormResize(System::TObject* Sender);
  82.     void __fastcall ExpandBitBtnClick(System::TObject* Sender);
  83.     void __fastcall Timer1Timer(System::TObject* Sender);
  84.     
  85. private:
  86.     int OriginalHeight;
  87.     int InstructionIndex;
  88.     void __fastcall CheckDelimiter(void);
  89.     void __fastcall CalculateNoSeries(void);
  90.     
  91. public:
  92.     System::AnsiString Delimiters[8];
  93.     TDelimiter TheDelimiter;
  94.     int TheFirstDataLine;
  95.     int TheSeriesNamesLine;
  96.     int TheSeriesUnitsLine;
  97.     int TheZDataLine;
  98.     int NumberOfSeries;
  99.     int TheCol;
  100.     int TheRow;
  101.     bool XDataPresent;
  102. public:
  103.     /* TCustomForm.Create */ __fastcall virtual TParserForm(Classes::TComponent* AOwner) : Forms::TForm(
  104.         AOwner) { }
  105.     /* TCustomForm.CreateNew */ __fastcall TParserForm(Classes::TComponent* AOwner, int Dummy) : Forms::
  106.         TForm(AOwner, Dummy) { }
  107.     /* TCustomForm.Destroy */ __fastcall virtual ~TParserForm(void) { }
  108.     
  109. public:
  110.     /* TWinControl.CreateParented */ __fastcall TParserForm(HWND ParentWindow) : Forms::TForm(ParentWindow
  111.         ) { }
  112.     
  113. };
  114.  
  115. //-- var, const, procedure ---------------------------------------------------
  116. #define COLUMN_NOS (Byte)(0)
  117. #define SERIES_NAMES (Byte)(1)
  118. #define FIRST_LINE_OF_DATA (Byte)(2)
  119. #define X_OR_Y_OR_Z (Byte)(3)
  120. #define DEPENDS_ON_X (Byte)(4)
  121. #define Z_DATA_LINE (Byte)(5)
  122. extern PACKAGE System::AnsiString DelimiterNames[8];
  123. extern PACKAGE TParserForm* ParserForm;
  124.  
  125. }    /* namespace Parser */
  126. #if !defined(NO_IMPLICIT_NAMESPACE_USE)
  127. using namespace Parser;
  128. #endif
  129. //-- end unit ----------------------------------------------------------------
  130. #endif    // Parser
  131.