main.h

来自「To create a VCL for RS232.」· C头文件 代码 · 共 56 行

H
56
字号
//---------------------------------------------------------------------------

#ifndef MainH
#define MainH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <ExtCtrls.hpp>
#include "..\lib\rs232\RS232.h"
//---------------------------------------------------------------------------
class TForm1 : public TForm
{
__published:	// IDE-managed Components
        TRadioGroup *PortRadioGroup;
        TButton *OpenPortButton;
        TButton *StopSystemButton;
        TMemo *TxMemo;
        TMemo *RxMemo;
        TLabel *Label1;
        TLabel *Label2;
        TButton *TxDataButton;
        TButton *RxDataButton;
        TShape *DTRShape;
        TShape *CTSShape;
        TShape *DSRShape;
        TShape *RIShape;
        TLabel *CD;
        TLabel *CTS;
        TLabel *DSR;
        TLabel *RI;
        TShape *RTSShape;
        TButton *DTRBtn;
        TButton *RTSBtn;
        TShape *CDShape;
        TTimer *Timer1;
        TRS232 *RS2321;
        void __fastcall TxDataButtonClick(TObject *Sender);
        void __fastcall OpenPortButtonClick(TObject *Sender);
        void __fastcall RxDataButtonClick(TObject *Sender);
        void __fastcall StopSystemButtonClick(TObject *Sender);
        void __fastcall Timer1Timer(TObject *Sender);
        void __fastcall DTRBtnClick(TObject *Sender);
        void __fastcall RTSBtnClick(TObject *Sender);
        void __fastcall RS2321ReceiveData(TObject *Sender);
        void __fastcall TxMemoKeyPress(TObject *Sender, char &Key);
private:	// User declarations
public:		// User declarations
        __fastcall TForm1(TComponent* Owner);
};
//---------------------------------------------------------------------------
extern PACKAGE TForm1 *Form1;
//---------------------------------------------------------------------------
#endif

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?