⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 singzm.~pas

📁 LED字幕显示屏
💻 ~PAS
📖 第 1 页 / 共 3 页
字号:
                 end;
               CmdEffect: begin
                   SendData[n] := $08;
                   ChkSum := ChkSum + SendData[n]; inc(n,1);
                   SendData[n] := Parameters[i].Display_CmdDate.Effect_Mode;
                   ChkSum := ChkSum + SendData[n]; inc(n,1);
                   SendData[n] := Parameters[i].Display_CmdDate.Speed;
                   ChkSum := ChkSum + SendData[n]; inc(n,1);
                 end;
               CmdEnd : begin
                   SendData[n] := $1F;
                   ChkSum := ChkSum + SendData[n]; inc(n,1);
                 end;
               end;
             end;
          end;
       ChangeDataTimeMode  :   SendData[n] := $01;

       TestSignMode        :   SendData[n] := $02;
     end;
     SendData[n]:= Lo(ChkSum);

for i:= 0 to Count - 1 do
    SignComPort.PutChar(char(senddata[i]));
end;



procedure TForm1.FormCreate(Sender: TObject);
var i,j,x:Integer;
begin
case SystemOs of
//   874 泰语
//   932 日语
     936 : {中文(简体)}
	  begin
            BlOpenPort := false;
	    RzGroupBox.Caption    := S00001;
	    RadioGroup1.Caption   := copy(S00002,1,11);
	    RadioGroup1.Items.Add(format(S00002,[1]));
	    RadioGroup1.Items.Add(format(S00002,[2]));
	    RadioGroup1.ItemIndex := 0;
	    RzLabel1.Caption  := S00003;
	    RzLabel2.Caption  := S00004;
	    RzMenuToolbarButton1.Caption := S00005;
	    RzMarqueeStatus1.Caption := S00006;
	    Form1.Caption := S00007;
	    RzMenuToolbarButton2.Caption  := S00008;
	    VrHotImage1.Caption := S00010;
	    RzMenuToolbarButton3.Caption  := S00011;
	    RzGroupBox1.Caption := S00012;
	    RzLabel3.Caption := S00013;
	    RzLabel4.Caption := S00014;
	    RzCheckBox1.Caption := S00015;
	    RadioGroup2.Caption := S00021;
	    RadioGroup2.Items.Add(S00016);
	    RadioGroup2.Items.Add(S00017);
	    RadioGroup2.Items.Add(S00018);
	    RadioGroup2.Items.Add(S00019);
	    RadioGroup2.Items.Add(S00020);
	    RadioGroup2.ItemIndex := 0;
	    RadioGroup3.Caption := S00022;
	    RadioGroup3.Items.Add(S00023);
	    RadioGroup3.Items.Add(S00024);
	    RadioGroup3.ItemIndex := 0;
	    RzButton1.Caption := S00026;
	    RzButton2.Caption := S00025;
	    RzLabel6.Caption := S00035;
	    RzLabel5.Caption := S00027;
	    BlGbOrBig5 := false;
	    RzMenuToolbarButton4.Caption := S00029;
	    RzMenuToolbarButton5.Caption := S00030;
	    RzMenuToolbarButton6.Caption := S00031;
	    RzMenuToolbarButton7.Caption := S00032;
            RzLabel7.Caption := S00037;
            RzBitBtn1.Caption := S00038;

	    i := 0 ; x := strtoint(RxSpinEdit3.Text);
	    SendStringGrid1.RowCount := x * 200;
	    repeat
	    for j:=0 to x - 1 do
	       SendStringGrid1.Cells[0,i+j] := format( S00009,[1+j]);
	       inc(i,x);
	    until i >= X*200 ;

	    for j:=0 to X - 1 do
	       RzCheckList1.Items.Add(format(S00009,[j+1]));

	  end;
//   949 朝鲜语
//   950 :  中文(台湾和香港繁体)
//   1200 Unicode
//   1250 东欧语言
//   1251 西里尔语
//   1252 美国和西欧语言
//   1253 希腊语
//   1254 土耳其语
//   1255 希伯来语
//   1256 阿拉伯语
//   1257 波罗的语
end;
BlOpenPort := true;
try
  SignComPort.ComNumber :=1;
  SignComPort.Open := true;
except
  SignComPort.ComNumber :=2;
  SignComPort.Open := true;
end;
end;

procedure TForm1.SendStringGrid1SelectCell(Sender: TObject; ACol,
  ARow: Integer; var CanSelect: Boolean);
var
  i:integer;

begin
CanSelect := true;
OutLine :=( ARow div RzCheckList1.Count) * RzCheckList1.Count;
SendStringGrid1.ClearRowSelect ;
For i:=0 to RzCheckList1.Count -1 do
    SendStringGrid1.RowSelect[OutLine+i]:= true;
end;

procedure TForm1.VrHotImage1Click(Sender: TObject);
begin
Close;
end;

procedure TForm1.RadioGroup3Click(Sender: TObject);
begin
if RadioGroup3.ItemIndex = 1 then 
   begin
     RzPanel2.Visible := true ;
     SendStringGrid1.ShowSelection:= true ;
     SendStringGrid1.Options := SendStringGrid1.Options  - [ goEditing{, goAlwaysShowEditor}] + [goRowSelect];
   end else begin
     RzPanel2.Visible :=false;
     SendStringGrid1.ShowSelection:= false ;
     SendStringGrid1.Options := SendStringGrid1.Options - [goRowSelect] + [ goEditing{ ,goAlwaysShowEditor}] ;
   end;
end;

procedure TForm1.RzButton1Click(Sender: TObject);
var i:Integer;
begin         
  for i := 0 to rzchecklist1.Items.Count - 1 do
     RzCheckList1.ItemState[i]:=  cbChecked;
end;

procedure TForm1.RzMenuToolbarButton6Click(Sender: TObject);
begin
RzMenuToolbarButton4.Visible := false;
RzMenuToolbarButton5.Visible := false;
RzMenuToolbarButton6.Visible := false;
RzMenuToolbarButton7.Visible := true;
Timer1.Interval := 1;
Timer1.Enabled := true;


end;

procedure TForm1.RzMenuToolbarButton7Click(Sender: TObject);
begin
RzMenuToolbarButton4.Visible := true;
RzMenuToolbarButton5.Visible := true;
RzMenuToolbarButton6.Visible := true;
RzMenuToolbarButton7.Visible := false;
Timer1.Enabled := false;
end;

procedure TForm1.RzMenuToolbarButton1Click(Sender: TObject);
var
  i,j,x:integer;
begin
OpenDialog1.Filter := S00036;
if OpenDialog1.Execute  then
   begin
      SendStringGrid1.LoadFromFile(OpenDialog1.FileName);
      i := 0 ; x := strtoint(RxSpinEdit3.Text);
      SendStringGrid1.RowCount := x * 200;
      repeat
	    for j:=0 to x - 1 do
	       SendStringGrid1.Cells[0,i+j] := format( S00009,[1+j]);
	       inc(i,x);
      until i >= X*200 ;
   end;
end;

procedure TForm1.RzMenuToolbarButton2Click(Sender: TObject);
begin
SaveDialog1.Filter := S00036;
SaveDialog1.DefaultExt:='zmj';
if SaveDialog1.Execute  then
   begin
      SendStringGrid1.SaveToFile(SaveDialog1.FileName);
   end;
end;

procedure TForm1.RzMenuToolbarButton3Click(Sender: TObject);
var i,j,x:integer;
begin
   RzMenuToolbarButton3.Enabled := false;
   SendStringGrid1.Clear;
   i := 0 ; x := strtoint(RxSpinEdit3.Text);
   SendStringGrid1.RowCount := x * 200;
   repeat
     for j:=0 to x - 1 do
     SendStringGrid1.Cells[0,i+j] := format( S00009,[1+j]);
     inc(i,x);
   until i >= X*200 ; 
   RzMenuToolbarButton3.Enabled := true;  
end;

procedure TForm1.FormCloseQuery(Sender: TObject; var CanClose: Boolean);
var DoClose:integer;
begin
  DoClose := MessageBox(Handle,S00033,S00034,MB_ICONQUESTION or MB_OKCANCEL	);
  if DoClose = IDOk then  begin CanClose := true; SignComPort.Open := false end else
  CanClose := false;
end;

procedure TForm1.RxSpinEdit3Exit(Sender: TObject);
var i,j,x:integer;
begin
   RxSpinEdit3.Enabled := false;
//   SendStringGrid1.Clear;
   i := 0 ; x := strtoint(RxSpinEdit3.Text);
   SendStringGrid1.RowCount := x * 200;
   OutLine := 0;
   repeat
     for j:=0 to x - 1 do
     SendStringGrid1.Cells[0,i+j] := format( S00009,[1+j]);
     inc(i,x);
   until i >= X*200 ;
   RzCheckList1.Items.Clear;   
   for j:=0 to X - 1 do
      RzCheckList1.Items.Add(format(S00009,[j+1]));
   RxSpinEdit3.Enabled := true;
end;

procedure TForm1.RxSpinEdit3KeyPress(Sender: TObject; var Key: Char);
begin
key := char($00);
end;

procedure TForm1.RzComboBox2KeyPress(Sender: TObject; var Key: Char);
begin
 key:= char($00);
end;

procedure TForm1.RzButton2Click(Sender: TObject);
var i:Integer;
begin         
  for i := 0 to rzchecklist1.Items.Count - 1 do
     RzCheckList1.ItemState[i]:=  cbUnChecked;

end;

procedure TForm1.RzMenuToolbarButton4Click(Sender: TObject);
var
    Idn:TIDn;
    param:TParameters;
begin

Idn[0]:=$00;
Idn[1]:=$3f;

setlength(param,1);

param[0].Display_command := CmdCls ;
param[0].Display_CmdDate.Wait_Time := $FFFF;
param[0].Display_CmdDate.TextString :='欢迎光临上海鹦鹉小鸟公司';
param[0].Display_CmdDate.Style := $02;
param[0].Display_CmdDate.Gap := $01;
param[0].Display_CmdDate.Color:=$01;
param[0].Display_CmdDate.Mode := $08;
param[0].Display_CmdDate.Speed := $06;
param[0].Display_CmdDate.Position:= $05;
param[0].Display_CmdDate.Effect_Mode := $02;

PostCommand($9A,$00,Idn,CommandMode,param);
end;

procedure TForm1.RzMenuToolbarButton5Click(Sender: TObject);
var
   I   :integer;
   Id   :TIDn;
   Param :TParameters;
begin
if OutLine > SendStringGrid1.RowCount -2 then
begin
  RzMenuToolbarButton7.Click;
  exit;
end;

ListBox1.Clear;

for i := RzCheckList1.Items.Count - 1 downto 0 do
   begin
      Id[0]:= i;
   if SendStringGrid1.Cells[1,i+outline] <> '' then
     begin
       if RzCheckList1.ItemChecked[i]then
         begin
           GetSignParameters(SendStringGrid1.Cells[1,i+outline],Param,true) ;
           ListBox1.Items.Add(format(S00009,[i+1])+' : '+ SendStringGrid1.Cells[1,i+outline]);
         end
       else
         begin
           GetSignParameters(SendStringGrid1.Cells[1,i+outline],Param,false);
           ListBox1.Items.Add(format(S00009,[i+1])+' : '+ SendStringGrid1.Cells[1,i+outline]);
         end;
         PostCommand($9A,01,Id,CommandMode,Param) ;
     end;
   end;
OutLine := OutLine + RzCheckList1.Items.Count;

SendStringGrid1.ClearRowSelect ;
For i:=0 to RzCheckList1.Count -1 do
    begin
      if OutLine > SendStringGrid1.RowCount - 1 then Exit;
      SendStringGrid1.RowSelect[OutLine+i]:= true;
      SendMessage(SendStringGrid1.Handle,WM_VSCROLL,SB_LINEDOWN,0);
    end;
end;



procedure TForm1.GetSignParameters(S: string; var Param: TParameters;

⌨️ 快捷键说明

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