V8.38
This commit is contained in:
BIN
Binary file not shown.
@@ -14,8 +14,8 @@
|
||||
-$N+
|
||||
-$O-
|
||||
-$P+
|
||||
-$Q+
|
||||
-$R+
|
||||
-$Q-
|
||||
-$R-
|
||||
-$S-
|
||||
-$T-
|
||||
-$U-
|
||||
|
||||
@@ -17,8 +17,8 @@ M=0
|
||||
N=1
|
||||
O=0
|
||||
P=1
|
||||
Q=1
|
||||
R=1
|
||||
Q=0
|
||||
R=0
|
||||
S=0
|
||||
T=0
|
||||
U=0
|
||||
|
||||
+47
-47
@@ -1,8 +1,8 @@
|
||||
|
||||
Start Length Name Class
|
||||
0001:00000000 001A254CH .text CODE
|
||||
0002:00000000 00002C7CH .data DATA
|
||||
0002:00002C7C 045DE035H .bss BSS
|
||||
0001:00000000 001A397CH .text CODE
|
||||
0002:00000000 00002C54H .data DATA
|
||||
0002:00002C54 045E204DH .bss BSS
|
||||
|
||||
|
||||
Detailed map of segments
|
||||
@@ -76,29 +76,29 @@ Detailed map of segments
|
||||
0001:00095228 00000128 C=CODE S=.text G=(none) M=WinSock ACBP=A9
|
||||
0001:00095350 00003A78 C=CODE S=.text G=(none) M=ScktComp ACBP=A9
|
||||
0001:00098DC8 000008EA C=CODE S=.text G=(none) M=OleServer ACBP=A9
|
||||
0001:000996B4 000005A0 C=CODE S=.text G=(none) M=MSCommLib_TLB ACBP=A9
|
||||
0001:00099C54 00000040 C=CODE S=.text G=(none) M=MMSystem ACBP=A9
|
||||
0001:00099C94 00000038 C=CODE S=.text G=(none) M=Nb30 ACBP=A9
|
||||
0001:00099CCC 00000A18 C=CODE S=.text G=(none) M=MaskUtils ACBP=A9
|
||||
0001:0009A6E4 00002108 C=CODE S=.text G=(none) M=Mask ACBP=A9
|
||||
0001:0009C7EC 0000924C C=CODE S=.text G=(none) M=Grids ACBP=A9
|
||||
0001:000A5A38 00001980 C=CODE S=.text G=(none) M=UnitPilote ACBP=A9
|
||||
0001:000A73B8 00000574 C=CODE S=.text G=(none) M=Importation ACBP=A9
|
||||
0001:000A792C 00013B38 C=CODE S=.text G=(none) M=UnitAnalyseSegCDM ACBP=A9
|
||||
0001:000BB464 00002D20 C=CODE S=.text G=(none) M=UnitConfigTCO ACBP=A9
|
||||
0001:000BE184 00000D10 C=CODE S=.text G=(none) M=Unit_Pilote_aig ACBP=A9
|
||||
0001:000BEE94 00004DD8 C=CODE S=.text G=(none) M=UnitConfigCellTCO ACBP=A9
|
||||
0001:000C3C6C 00045748 C=CODE S=.text G=(none) M=UnitTCO ACBP=A9
|
||||
0001:001093B4 00003160 C=CODE S=.text G=(none) M=UnitSR ACBP=A9
|
||||
0001:0010C514 000028D4 C=CODE S=.text G=(none) M=UnitCDF ACBP=A9
|
||||
0001:0010EDE8 00001833 C=CODE S=.text G=(none) M=verif_version ACBP=A9
|
||||
0001:0011061C 000011D0 C=CODE S=.text G=(none) M=UnitPareFeu ACBP=A9
|
||||
0001:001117EC 00043384 C=CODE S=.text G=(none) M=UnitConfig ACBP=A9
|
||||
0001:00154B70 00002BC8 C=CODE S=.text G=(none) M=UnitDebug ACBP=A9
|
||||
0001:00157738 00000D2C C=CODE S=.text G=(none) M=UnitSimule ACBP=A9
|
||||
0001:00158464 00002678 C=CODE S=.text G=(none) M=Unitplace ACBP=A9
|
||||
0001:0015AADC 000475E0 C=CODE S=.text G=(none) M=UnitPrinc ACBP=A9
|
||||
0001:001A20BC 0000048D C=CODE S=.text G=(none) M=Signaux_complexes_GL ACBP=A9
|
||||
0001:000996B4 00000598 C=CODE S=.text G=(none) M=MSCommLib_TLB ACBP=A9
|
||||
0001:00099C4C 00000040 C=CODE S=.text G=(none) M=MMSystem ACBP=A9
|
||||
0001:00099C8C 00000038 C=CODE S=.text G=(none) M=Nb30 ACBP=A9
|
||||
0001:00099CC4 00000A18 C=CODE S=.text G=(none) M=MaskUtils ACBP=A9
|
||||
0001:0009A6DC 00002108 C=CODE S=.text G=(none) M=Mask ACBP=A9
|
||||
0001:0009C7E4 0000924C C=CODE S=.text G=(none) M=Grids ACBP=A9
|
||||
0001:000A5A30 00001980 C=CODE S=.text G=(none) M=UnitPilote ACBP=A9
|
||||
0001:000A73B0 00000574 C=CODE S=.text G=(none) M=Importation ACBP=A9
|
||||
0001:000A7924 00014800 C=CODE S=.text G=(none) M=UnitAnalyseSegCDM ACBP=A9
|
||||
0001:000BC124 00002D20 C=CODE S=.text G=(none) M=UnitConfigTCO ACBP=A9
|
||||
0001:000BEE44 00000D10 C=CODE S=.text G=(none) M=Unit_Pilote_aig ACBP=A9
|
||||
0001:000BFB54 00004DD8 C=CODE S=.text G=(none) M=UnitConfigCellTCO ACBP=A9
|
||||
0001:000C492C 00045854 C=CODE S=.text G=(none) M=UnitTCO ACBP=A9
|
||||
0001:0010A180 00003160 C=CODE S=.text G=(none) M=UnitSR ACBP=A9
|
||||
0001:0010D2E0 000028D4 C=CODE S=.text G=(none) M=UnitCDF ACBP=A9
|
||||
0001:0010FBB4 00001833 C=CODE S=.text G=(none) M=verif_version ACBP=A9
|
||||
0001:001113E8 000011D0 C=CODE S=.text G=(none) M=UnitPareFeu ACBP=A9
|
||||
0001:001125B8 00043720 C=CODE S=.text G=(none) M=UnitConfig ACBP=A9
|
||||
0001:00155CD8 00002BC8 C=CODE S=.text G=(none) M=UnitDebug ACBP=A9
|
||||
0001:001588A0 00000D2C C=CODE S=.text G=(none) M=UnitSimule ACBP=A9
|
||||
0001:001595CC 00002678 C=CODE S=.text G=(none) M=Unitplace ACBP=A9
|
||||
0001:0015BC44 000478A8 C=CODE S=.text G=(none) M=UnitPrinc ACBP=A9
|
||||
0001:001A34EC 0000048D C=CODE S=.text G=(none) M=Signaux_complexes_GL ACBP=A9
|
||||
0002:00000000 000000CC C=DATA S=.data G=DGROUP M=System ACBP=A9
|
||||
0002:000000CC 00000020 C=DATA S=.data G=DGROUP M=SysInit ACBP=A9
|
||||
0002:000000EC 00000254 C=DATA S=.data G=DGROUP M=SysUtils ACBP=A9
|
||||
@@ -125,12 +125,12 @@ Detailed map of segments
|
||||
0002:00001250 00000030 C=DATA S=.data G=DGROUP M=ComObj ACBP=A9
|
||||
0002:00001280 0000002C C=DATA S=.data G=DGROUP M=OleCtrls ACBP=A9
|
||||
0002:000012AC 00000908 C=DATA S=.data G=DGROUP M=jpeg ACBP=A9
|
||||
0002:00001BB4 00000080 C=DATA S=.data G=DGROUP M=MSCommLib_TLB ACBP=A9
|
||||
0002:00001C34 00000009 C=DATA S=.data G=DGROUP M=MaskUtils ACBP=A9
|
||||
0002:00001C40 00000004 C=DATA S=.data G=DGROUP M=Mask ACBP=A9
|
||||
0002:00001C44 00000006 C=DATA S=.data G=DGROUP M=Grids ACBP=A9
|
||||
0002:00001C4C 000000D4 C=DATA S=.data G=DGROUP M=UnitTCO ACBP=A9
|
||||
0002:00001D20 0000060D C=DATA S=.data G=DGROUP M=UnitPrinc ACBP=A9
|
||||
0002:00001BB4 00000058 C=DATA S=.data G=DGROUP M=MSCommLib_TLB ACBP=A9
|
||||
0002:00001C0C 00000009 C=DATA S=.data G=DGROUP M=MaskUtils ACBP=A9
|
||||
0002:00001C18 00000004 C=DATA S=.data G=DGROUP M=Mask ACBP=A9
|
||||
0002:00001C1C 00000006 C=DATA S=.data G=DGROUP M=Grids ACBP=A9
|
||||
0002:00001C24 000000D4 C=DATA S=.data G=DGROUP M=UnitTCO ACBP=A9
|
||||
0002:00001CF8 0000060D C=DATA S=.data G=DGROUP M=UnitPrinc ACBP=A9
|
||||
0002:00003000 00000664 C=BSS S=.bss G=DGROUP M=System ACBP=A9
|
||||
0002:00003664 00000010 C=BSS S=.bss G=DGROUP M=SysInit ACBP=A9
|
||||
0002:00003674 00000004 C=BSS S=.bss G=DGROUP M=Types ACBP=A9
|
||||
@@ -208,20 +208,20 @@ Detailed map of segments
|
||||
0002:00003E60 00000004 C=BSS S=.bss G=DGROUP M=Grids ACBP=A9
|
||||
0002:00003E64 00000010 C=BSS S=.bss G=DGROUP M=UnitPilote ACBP=A9
|
||||
0002:00003E74 00000010 C=BSS S=.bss G=DGROUP M=Importation ACBP=A9
|
||||
0002:00003E84 000118A0 C=BSS S=.bss G=DGROUP M=UnitAnalyseSegCDM ACBP=A9
|
||||
0002:00015724 00000014 C=BSS S=.bss G=DGROUP M=UnitConfigTCO ACBP=A9
|
||||
0002:00015738 00000014 C=BSS S=.bss G=DGROUP M=Unit_Pilote_aig ACBP=A9
|
||||
0002:0001574C 00000014 C=BSS S=.bss G=DGROUP M=UnitConfigCellTCO ACBP=A9
|
||||
0002:00015760 00418704 C=BSS S=.bss G=DGROUP M=UnitTCO ACBP=A9
|
||||
0002:0042DE64 00000010 C=BSS S=.bss G=DGROUP M=UnitSR ACBP=A9
|
||||
0002:0042DE74 00000014 C=BSS S=.bss G=DGROUP M=UnitCDF ACBP=A9
|
||||
0002:0042DE88 00000018 C=BSS S=.bss G=DGROUP M=verif_version ACBP=A9
|
||||
0002:0042DEA0 00000004 C=BSS S=.bss G=DGROUP M=UnitPareFeu ACBP=A9
|
||||
0002:0042DEA4 000004FC C=BSS S=.bss G=DGROUP M=UnitConfig ACBP=A9
|
||||
0002:0042E3A0 0000002C C=BSS S=.bss G=DGROUP M=UnitDebug ACBP=A9
|
||||
0002:0042E3CC 0000000C C=BSS S=.bss G=DGROUP M=UnitSimule ACBP=A9
|
||||
0002:0042E3D8 00000008 C=BSS S=.bss G=DGROUP M=Unitplace ACBP=A9
|
||||
0002:0042E3E0 041B2C54 C=BSS S=.bss G=DGROUP M=UnitPrinc ACBP=A9
|
||||
0002:00003E84 000148B0 C=BSS S=.bss G=DGROUP M=UnitAnalyseSegCDM ACBP=A9
|
||||
0002:00018734 00000014 C=BSS S=.bss G=DGROUP M=UnitConfigTCO ACBP=A9
|
||||
0002:00018748 00000014 C=BSS S=.bss G=DGROUP M=Unit_Pilote_aig ACBP=A9
|
||||
0002:0001875C 00000014 C=BSS S=.bss G=DGROUP M=UnitConfigCellTCO ACBP=A9
|
||||
0002:00018770 00418700 C=BSS S=.bss G=DGROUP M=UnitTCO ACBP=A9
|
||||
0002:00430E70 00000010 C=BSS S=.bss G=DGROUP M=UnitSR ACBP=A9
|
||||
0002:00430E80 00000014 C=BSS S=.bss G=DGROUP M=UnitCDF ACBP=A9
|
||||
0002:00430E94 00000018 C=BSS S=.bss G=DGROUP M=verif_version ACBP=A9
|
||||
0002:00430EAC 00000004 C=BSS S=.bss G=DGROUP M=UnitPareFeu ACBP=A9
|
||||
0002:00430EB0 000004FC C=BSS S=.bss G=DGROUP M=UnitConfig ACBP=A9
|
||||
0002:004313AC 0000002C C=BSS S=.bss G=DGROUP M=UnitDebug ACBP=A9
|
||||
0002:004313D8 0000000C C=BSS S=.bss G=DGROUP M=UnitSimule ACBP=A9
|
||||
0002:004313E4 00000008 C=BSS S=.bss G=DGROUP M=Unitplace ACBP=A9
|
||||
0002:004313EC 041B3C60 C=BSS S=.bss G=DGROUP M=UnitPrinc ACBP=A9
|
||||
|
||||
Bound resource files
|
||||
|
||||
@@ -247,4 +247,4 @@ Signaux_complexes_GL.res
|
||||
Signaux_complexes_GL.drf
|
||||
|
||||
|
||||
Program entry point at 0001:001A23CC
|
||||
Program entry point at 0001:001A37FC
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
object FormAnalyseCDM: TFormAnalyseCDM
|
||||
Left = 206
|
||||
Top = 0
|
||||
Left = 212
|
||||
Top = 69
|
||||
AutoScroll = False
|
||||
Caption = 'Fen'#234'tre r'#233'seau CDM'
|
||||
ClientHeight = 648
|
||||
|
||||
+963
-222
File diff suppressed because it is too large
Load Diff
+3
-3
@@ -668,7 +668,7 @@ object FormConfig: TFormConfig
|
||||
Top = 8
|
||||
Width = 633
|
||||
Height = 505
|
||||
ActivePage = TabSheetCDM
|
||||
ActivePage = TabSheetAig
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clBlack
|
||||
Font.Height = -11
|
||||
@@ -2405,7 +2405,7 @@ object FormConfig: TFormConfig
|
||||
Width = 137
|
||||
Height = 21
|
||||
Style = csDropDownList
|
||||
ItemHeight = 13
|
||||
ItemHeight = 0
|
||||
TabOrder = 1
|
||||
OnChange = ComboBoxDecChange
|
||||
end
|
||||
@@ -2512,7 +2512,7 @@ object FormConfig: TFormConfig
|
||||
Width = 137
|
||||
Height = 21
|
||||
Style = csDropDownList
|
||||
ItemHeight = 13
|
||||
ItemHeight = 0
|
||||
TabOrder = 2
|
||||
OnChange = ComboBoxAspChange
|
||||
end
|
||||
|
||||
+152
-111
@@ -1041,6 +1041,8 @@ begin
|
||||
if aiguillage[index].EtatTJD=2 then s:=s+',E2' else s:=s+',E4';
|
||||
end;
|
||||
|
||||
s:=s+',C'+intToSTR(aiguillage[index].AdrCDM);
|
||||
|
||||
encode_aig:=s;
|
||||
end;
|
||||
|
||||
@@ -2669,7 +2671,7 @@ var s,sa,SOrigine: string;
|
||||
aiguillage[maxaiguillage].tjsInt:=adr;
|
||||
c:=#0;
|
||||
if erreur<>0 then c:=enregistrement[erreur];
|
||||
if ((c<>'S') and (c<>'D')) then
|
||||
if ((c<>'S') and (c<>'D')) then
|
||||
begin
|
||||
c:=' ';Affiche('Erreur paramètre L '+sOrigine,clred);
|
||||
end;
|
||||
@@ -2688,7 +2690,7 @@ var s,sa,SOrigine: string;
|
||||
i:=pos(',',enregistrement);
|
||||
if i<>0 then delete(enregistrement,1,i);
|
||||
Val(enregistrement,j,erreur);
|
||||
aiguillage[maxaiguillage].temps:=j;
|
||||
aiguillage[maxaiguillage].temps:=j;
|
||||
aiguillage[maxaiguillage].posinit:=position;
|
||||
i:=pos(')',enregistrement);
|
||||
delete(enregistrement,1,i);
|
||||
@@ -2708,6 +2710,17 @@ var s,sa,SOrigine: string;
|
||||
delete(enregistrement,1,virgule);
|
||||
end;
|
||||
|
||||
if (length(enregistrement)<>0) then
|
||||
if enregistrement[1]='C' then
|
||||
begin
|
||||
delete(enregistrement,1,1);
|
||||
Val(enregistrement,adr,erreur);
|
||||
aiguillage[maxaiguillage].AdrCDM:=adr;
|
||||
virgule:=pos(',',enregistrement);if virgule=0 then virgule:=length(s)+1;
|
||||
delete(enregistrement,1,virgule);
|
||||
end;
|
||||
|
||||
|
||||
inc(itl);
|
||||
until (enregistrement='') or (itl>3);
|
||||
if itl>4 then begin Affiche('Erreur 400 ligne '+sOrigine,clred);exit;end;
|
||||
@@ -5753,6 +5766,7 @@ begin
|
||||
//Affiche(s,clLime);
|
||||
if s='' then exit;
|
||||
|
||||
formconfig.labelInfo.caption:='';
|
||||
Val(s,Adresse,erreur); // Récupérer l'adresse de l'aiguillage
|
||||
if adresse=0 then exit;
|
||||
|
||||
@@ -5760,7 +5774,7 @@ begin
|
||||
clicliste:=true;
|
||||
|
||||
ss:=InttoSTr(Adresse);
|
||||
formconfig.EditAdrAig.text:= ss;
|
||||
formconfig.EditAdrAig.text:=ss;
|
||||
if sombre then formConfig.editAdrAig.Color:=couleurfond else FormConfig.EditAdrAig.Color:=clWindow;
|
||||
|
||||
tjd:=pos('TJD',s)<>0 ;
|
||||
@@ -5877,14 +5891,14 @@ begin
|
||||
end;
|
||||
|
||||
CheckInverse.checked:=aiguillage[Index_Aig(adresse)].inversionCDM=1;
|
||||
|
||||
|
||||
if aiguillage[Index_Aig(adresse)].vitesse=0 then begin RadioButtonSans.checked:=true; RadioButton30kmh.checked:=false;RadioButtonSpecifique.checked:=false;RadioButton60kmh.checked:=false;end;
|
||||
if aiguillage[Index_Aig(adresse)].vitesse=30 then begin RadioButtonSans.checked:=false;RadioButton30kmh.checked:=true; RadioButtonSpecifique.checked:=false;RadioButton60kmh.checked:=false;end;
|
||||
if aiguillage[Index_Aig(adresse)].vitesse=40 then begin RadioButtonSans.checked:=false;RadioButton30kmh.checked:=false;RadioButtonSpecifique.checked:=true ;RadioButton60kmh.checked:=false;end;
|
||||
if aiguillage[Index_Aig(adresse)].vitesse=60 then begin RadioButtonSans.checked:=false;RadioButton30kmh.checked:=false;RadioButtonSpecifique.checked:=false;RadioButton60kmh.checked:=true;end;
|
||||
end;
|
||||
|
||||
if croi then
|
||||
if croi then
|
||||
begin
|
||||
GroupBox21.Visible:=false;
|
||||
GroupBox10.Visible:=false;
|
||||
@@ -5971,6 +5985,11 @@ begin
|
||||
formconfig.EditTempo10.text:=InttoSTr(aiguillage[index].temps);
|
||||
formconfig.EditTempo10.text:=InttoSTr(aiguillage[index].temps);
|
||||
|
||||
if aiguillage[index].AdrCDM<>0 then
|
||||
begin
|
||||
if croi then s:='Croisement ' else s:='Aiguillage ';
|
||||
formconfig.labelInfo.caption:=s+'décrivant la BJS '+intToSTR(aiguillage[index].AdrCDM);
|
||||
end;
|
||||
clicListe:=false;
|
||||
end;
|
||||
|
||||
@@ -9280,8 +9299,9 @@ begin
|
||||
// et les tjd pour voir si pb de cohérence
|
||||
for Indexaig:=1 to maxaiguillage do
|
||||
begin
|
||||
modAig:=aiguillage[Indexaig].modele;
|
||||
// tjd ou tjs
|
||||
if ((aiguillage[Indexaig].modele=tjd) and (aiguillage[Indexaig].EtatTJD=4)) or (aiguillage[Indexaig].modele=tjs) then
|
||||
if ((modAig=tjd) and (aiguillage[Indexaig].EtatTJD=4)) or (modAig=tjs) then
|
||||
begin
|
||||
if aiguillage[Indexaig].Ddroit<>aiguillage[Indexaig].Ddevie then
|
||||
begin
|
||||
@@ -9296,6 +9316,7 @@ begin
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
|
||||
// vérifier si l'aiguillage est dans les branches inutile
|
||||
{if aiguillage[Indexaig].modele<>rien then
|
||||
begin
|
||||
@@ -9307,100 +9328,119 @@ begin
|
||||
end;
|
||||
end;}
|
||||
|
||||
// vérifier si le détecteur sur la position droite est dans les branches
|
||||
adr:=aiguillage[Indexaig].Adroit;
|
||||
if (aiguillage[Indexaig].AdroitB='Z') or (aiguillage[Indexaig].AdroitB=#0) then
|
||||
// exclure les TJD/S
|
||||
if (modAig<>tjd) and (modAig<>tjs) then
|
||||
begin
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
// vérifier si le détecteur sur la position droite est dans les branches
|
||||
adr:=aiguillage[Indexaig].Adroit;
|
||||
if (aiguillage[Indexaig].AdroitB='Z') or (aiguillage[Indexaig].AdroitB=#0) then
|
||||
begin
|
||||
Affiche('Erreur 21.1: détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clred);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse; // adresse avant détecteur
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
if (det1br<>AdrAig) and (det2br<>AdrAig) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 21.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
// vérifier si le détecteur sur la position déviée est dans les branches
|
||||
adr:=aiguillage[Indexaig].Adevie;
|
||||
if (aiguillage[Indexaig].AdevieB='Z') or (aiguillage[Indexaig].AdevieB=#0) then
|
||||
begin
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 22.1: détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse; // adresse avant détecteur
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
if (det1br<>AdrAig) and (det2br<>AdrAig) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 22.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
// vérifier si le détecteur sur la pointe est dans les branches
|
||||
adr:=aiguillage[Indexaig].Apointe;
|
||||
if ( ((aiguillage[Indexaig].ApointeB='Z') or (aiguillage[Indexaig].ApointeB=#0)) and (aiguillage[Indexaig].modele=aig) ) then
|
||||
begin
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 23.1 : détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse; // adresse avant détecteur
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
if (det1br<>AdrAig) and (det2br<>AdrAig) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 23.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
if (aiguillage[Indexaig].modele=triple) then // aiguillage triple
|
||||
begin
|
||||
if (aiguillage[Indexaig].Adevie2B='Z') or (aiguillage[Indexaig].Adevie2B=#0) then
|
||||
begin
|
||||
adr:=aiguillage[Indexaig].Adevie2;
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 5 : détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
Affiche('Erreur 21.1: détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clred);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
if indexBranche_Trouve>1 then det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse // adresse avant détecteur
|
||||
else det1br:=0;
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
if (det1br<>AdrAig) and (det2br<>AdrAig) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 21.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if indexBranche_trouve>1 then
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
// vérifier si le détecteur sur la position déviée est dans les branches
|
||||
|
||||
adr:=aiguillage[Indexaig].Adevie;
|
||||
if (aiguillage[Indexaig].AdevieB='Z') or (aiguillage[Indexaig].AdevieB=#0) then
|
||||
begin
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 22.1: détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
if indexBranche_trouve>1 then det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse // adresse avant détecteur
|
||||
else det1br:=0;
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
if (det1br<>AdrAig) and (det2br<>AdrAig) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 22.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if indexBranche_trouve>1 then
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
// vérifier si le détecteur sur la pointe est dans les branches
|
||||
adr:=aiguillage[Indexaig].Apointe;
|
||||
if ( ((aiguillage[Indexaig].ApointeB='Z') or (aiguillage[Indexaig].ApointeB=#0)) and (aiguillage[Indexaig].modele=aig) ) then
|
||||
begin
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 23.1 : détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
ok:=false;
|
||||
end
|
||||
else
|
||||
begin
|
||||
AdrAig:=aiguillage[IndexAig].Adresse;
|
||||
if indexBranche_trouve>1 then
|
||||
begin
|
||||
det1br:=brancheN[branche_trouve,indexBranche_trouve-1].Adresse; // adresse avant détecteur
|
||||
model:=brancheN[branche_trouve,indexBranche_trouve-1].Btype;
|
||||
end
|
||||
else begin det1br:=0;model:=det;end;
|
||||
|
||||
det2br:=brancheN[branche_trouve,indexBranche_trouve+1].Adresse; // adresse après détecteur
|
||||
model2:=brancheN[branche_trouve,indexBranche_trouve+1].Btype;
|
||||
if (det1br<>AdrAig) and (model=det) and (det2br<>AdrAig) and (model2=det) and (adr<>0) then
|
||||
begin
|
||||
Affiche('Erreur 23.2: Le détecteur '+intToSTR(adr)+' est décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais déclaré dans la ',clred);
|
||||
s:='branche '+intToSTR(Branche_trouve)+' entre';
|
||||
if indexBranche_trouve>1 then
|
||||
if brancheN[branche_trouve,indexBranche_trouve-1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det1br)+' et ';
|
||||
if brancheN[branche_trouve,indexBranche_trouve+1].BType=aig then s:=s+' l''aiguillage ' else s:=s+' le détecteur ';
|
||||
s:=s+intToSTR(det2br);
|
||||
Affiche(s,clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
if (aiguillage[Indexaig].modele=triple) then // aiguillage triple
|
||||
begin
|
||||
if (aiguillage[Indexaig].Adevie2B='Z') or (aiguillage[Indexaig].Adevie2B=#0) then
|
||||
begin
|
||||
adr:=aiguillage[Indexaig].Adevie2;
|
||||
trouve_detecteur(adr);
|
||||
if IndexBranche_trouve=0 then
|
||||
begin
|
||||
Affiche('Erreur 5 : détecteur '+intToSTR(adr)+' décrit dans l''aiguillage '+intToSTR(aiguillage[Indexaig].adresse)+' mais absent dans la description des branches',clRed);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@@ -9735,20 +9775,20 @@ begin
|
||||
if c='D' then
|
||||
begin
|
||||
extr:=aiguillage[index2].ADroit;
|
||||
if adr<>extr then Affiche('Erreur 10.23: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'D différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.23: Discordance de déclaration aiguillages '+intToSTR(adr)+'D: '+intToSTR(adr2)+'D différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
if c='S' then
|
||||
begin
|
||||
extr:=aiguillage[index2].ADevie;
|
||||
if adr<>extr then Affiche('Erreur 10.24: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.24: Discordance de déclaration aiguillages '+intToSTR(adr)+'D: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
if c='P' then
|
||||
begin
|
||||
extr:=aiguillage[index2].APointe;
|
||||
if adr<>extr then Affiche('Erreur 10.25: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.25: Discordance de déclaration aiguillages '+intToSTR(adr)+'D: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
adr2:=aiguillage[indexaig].Adevie; // adresse de ce qui est connecté sur la position déviée
|
||||
@@ -9773,7 +9813,7 @@ begin
|
||||
begin
|
||||
Affiche('Erreur 10.31: Discordance de déclaration aiguillage '+intToSTR(adr)+': '+intToSTR(adr2),clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
// tjs ou tjs à 4 états
|
||||
@@ -9784,7 +9824,7 @@ begin
|
||||
if (adr<>aiguillage[index2].Adevie) and (adr<>aiguillage[index2].ADroit) and
|
||||
(adr<>aiguillage[index3].ADevie) and (adr<>aiguillage[index3].Adroit) then
|
||||
begin
|
||||
Affiche('Erreur 10.32: Discordance de déclaration aiguillage '+intToSTR(adr)+': '+intToSTR(adr2),clred);
|
||||
Affiche('Erreur 10.32: Discordance de déclaration aiguillage '+intToSTR(adr)+': '+intToSTR(adr2),clred);
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
@@ -9799,17 +9839,17 @@ begin
|
||||
if c='S' then
|
||||
begin
|
||||
extr:=aiguillage[index2].ADevie;
|
||||
if adr<>extr then Affiche('Erreur 10.34: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.34: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
if c='P' then
|
||||
begin
|
||||
extr:=aiguillage[index2].APointe;
|
||||
if adr<>extr then Affiche('Erreur 10.35: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.35: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
adr2:=aiguillage[indexaig].APointe; // adresse de ce qui est connecté sur la pointe
|
||||
c:=aiguillage[indexaig].ApointeB;
|
||||
if (c='D') or (c='S') or (c='P') then
|
||||
@@ -9827,7 +9867,7 @@ begin
|
||||
Affiche('Erreur 10.41: Discordance de déclaration aiguillage '+intToSTR(adr)+': '+intToSTR(adr2),clred);
|
||||
ok:=false;
|
||||
end;
|
||||
|
||||
|
||||
// tjs ou tjs à 4 états
|
||||
if (((model2=tjs) or (model2=tjd)) and (aiguillage[index2].EtatTJD=4)) then
|
||||
begin
|
||||
@@ -9840,23 +9880,23 @@ begin
|
||||
ok:=false;
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
if (model2=aig) or (model2=triple) then
|
||||
begin
|
||||
if c='D' then
|
||||
begin
|
||||
extr:=aiguillage[index2].ADroit;
|
||||
if adr<>extr then Affiche('Erreur 10.43: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'D différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.43: Discordance de déclaration aiguillages '+intToSTR(adr)+'P: '+intToSTR(adr2)+'D différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
if c='S' then
|
||||
begin
|
||||
extr:=aiguillage[index2].ADevie;
|
||||
if adr<>extr then Affiche('Erreur 10.44: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.44: Discordance de déclaration aiguillages '+intToSTR(adr)+'P: '+intToSTR(adr2)+'S différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
if c='P' then
|
||||
begin
|
||||
begin
|
||||
extr:=aiguillage[index2].APointe;
|
||||
if adr<>extr then Affiche('Erreur 10.45: Discordance de déclaration aiguillages '+intToSTR(adr)+'S: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
if adr<>extr then Affiche('Erreur 10.45: Discordance de déclaration aiguillages '+intToSTR(adr)+'P: '+intToSTR(adr2)+'P différent de '+intToSTR(extr),clred);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@@ -12356,6 +12396,7 @@ begin
|
||||
adr:=Signaux[ligneClicSig+1].adresse;
|
||||
if Signaux[ligneClicSig+1].contrevoie then Maj_Etat_Signal(adr,clignote_f or bita1_F) else Maj_Etat_Signal(adr,clignote_F);
|
||||
dessine_signal_mx(Signaux[ligneClicSig+1].Img.Canvas,0,0,1,1,Signaux[ligneClicSig+1].adresse,1); // dessine les feux du signal
|
||||
for adr:=1 to NbreTCO do affiche_tco(adr);
|
||||
end;
|
||||
end;
|
||||
|
||||
|
||||
+13
-13
@@ -1,6 +1,6 @@
|
||||
object FormPrinc: TFormPrinc
|
||||
Left = 107
|
||||
Top = 224
|
||||
Left = 112
|
||||
Top = 157
|
||||
Width = 1149
|
||||
Height = 689
|
||||
Anchors = [akLeft, akTop, akRight]
|
||||
@@ -19,8 +19,8 @@ object FormPrinc: TFormPrinc
|
||||
OnCreate = FormCreate
|
||||
OnResize = FormResize
|
||||
DesignSize = (
|
||||
1133
|
||||
630)
|
||||
1141
|
||||
638)
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 13
|
||||
object LabelTitre: TLabel
|
||||
@@ -1429,8 +1429,8 @@ object FormPrinc: TFormPrinc
|
||||
end
|
||||
object StatusBar1: TStatusBar
|
||||
Left = 0
|
||||
Top = 608
|
||||
Width = 1133
|
||||
Top = 616
|
||||
Width = 1141
|
||||
Height = 22
|
||||
Panels = <
|
||||
item
|
||||
@@ -1480,11 +1480,11 @@ object FormPrinc: TFormPrinc
|
||||
object GrandPanel: TPanel
|
||||
Left = 8
|
||||
Top = 48
|
||||
Width = 1025
|
||||
Width = 1057
|
||||
Height = 476
|
||||
TabOrder = 3
|
||||
DesignSize = (
|
||||
1025
|
||||
1057
|
||||
476)
|
||||
object SplitterV: TSplitter
|
||||
Left = 1
|
||||
@@ -1520,7 +1520,7 @@ object FormPrinc: TFormPrinc
|
||||
OnMouseDown = FenRichMouseDown
|
||||
end
|
||||
object ScrollBox1: TScrollBox
|
||||
Left = 504
|
||||
Left = 536
|
||||
Top = 176
|
||||
Width = 465
|
||||
Height = 249
|
||||
@@ -1534,7 +1534,7 @@ object FormPrinc: TFormPrinc
|
||||
TabOrder = 1
|
||||
end
|
||||
object GroupBox1: TGroupBox
|
||||
Left = 465
|
||||
Left = 497
|
||||
Top = 21
|
||||
Width = 265
|
||||
Height = 52
|
||||
@@ -1591,7 +1591,7 @@ object FormPrinc: TFormPrinc
|
||||
end
|
||||
end
|
||||
object GroupBox3: TGroupBox
|
||||
Left = 457
|
||||
Left = 489
|
||||
Top = 104
|
||||
Width = 265
|
||||
Height = 129
|
||||
@@ -1833,7 +1833,7 @@ object FormPrinc: TFormPrinc
|
||||
end
|
||||
end
|
||||
object Panel1: TPanel
|
||||
Left = 689
|
||||
Left = 761
|
||||
Top = -3
|
||||
Width = 288
|
||||
Height = 180
|
||||
@@ -1980,7 +1980,7 @@ object FormPrinc: TFormPrinc
|
||||
end
|
||||
end
|
||||
object GroupBox2: TGroupBox
|
||||
Left = 577
|
||||
Left = 609
|
||||
Top = 104
|
||||
Width = 265
|
||||
Height = 129
|
||||
|
||||
+108
-78
@@ -492,6 +492,7 @@ Taiguillage = record
|
||||
// si modifié en mode config
|
||||
modifie : boolean ;
|
||||
NumBranche,IndexBranche : integer; // index dans les branches
|
||||
AdrCDM : integer; // adresse de l'aiguillage dans CDM, si c'est une BDJ (bretelle double jonction)
|
||||
end;
|
||||
TtabloDet = array[1..Mtd] of integer;
|
||||
TSignal = record
|
||||
@@ -864,7 +865,9 @@ function InfoSignal(adresse : integer) : string;
|
||||
procedure det_prec_signal(adresse : integer;var tabloDet : TTabloDet);
|
||||
procedure composant(c : tComponent;fond,texte : tColor);
|
||||
procedure maj_couleurs;
|
||||
|
||||
procedure AffTexteIncliBordeTexture(c : TCanvas; x,y : integer; Fonte : tFont;
|
||||
clBord : TColor; EpBord : integer; PenMode : TPenMode;
|
||||
Texture : tBitMap; texte : string; AngleDD : longint);
|
||||
|
||||
implementation
|
||||
|
||||
@@ -1081,13 +1084,12 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
// dessine les feux sur une cible à 2 feux dans le canvas spécifié
|
||||
// dessine les 2 feux sur la cible dans le canvas spécifié
|
||||
// x,y : offset en pixels du coin supérieur gauche du feu
|
||||
// Acanvas : canvas de destination
|
||||
// x,y : point d'origine de destination
|
||||
// frX, frY : facteurs de réduction (pour agrandissement)
|
||||
// EtatSignal : état du signal
|
||||
// orientation à donner au signal : 1= vertical 2=90° à gauche 3=90° à droite
|
||||
// orientation à donner au signal : 1= vertical 2=90° à gauche 3=90° à droite 4=180°
|
||||
procedure dessine_signal2(Acanvas : Tcanvas;x,y : integer;frX,frY : real;EtatSignal : word;orientation : integer);
|
||||
var Temp,rayon,xViolet,YViolet,xBlanc,yBlanc,
|
||||
LgImage,HtImage,code,combine : integer;
|
||||
@@ -1116,8 +1118,8 @@ begin
|
||||
|
||||
if (orientation=3) then
|
||||
begin
|
||||
//rotation 90° vers la droite des feux
|
||||
// calcul des facteurs de réduction pour la rotation
|
||||
// rotation 90° vers la droite des feux
|
||||
// inversion des facteurs de réduction pour la rotation
|
||||
ech:=frY;frY:=frX;FrX:=ech;
|
||||
Temp:=LgImage-XBlanc;Xblanc:=Yblanc;Yblanc:=Temp;
|
||||
Temp:=LgImage-Xviolet;Xviolet:=Yviolet;Yviolet:=Temp;
|
||||
@@ -1130,8 +1132,8 @@ begin
|
||||
Xviolet:=LgIMage-Xviolet;Yviolet:=HtImage-Yviolet;
|
||||
end;
|
||||
|
||||
XBlanc:=round(xBlanc*Frx)+x; YBlanc:=round(Yblanc*Fry)+Y;
|
||||
XViolet:=round(XViolet*FrX)+x; YViolet:=round(YViolet*FrY)+Y;
|
||||
XBlanc:=round(xBlanc*Frx)+x; YBlanc:=round(Yblanc*Fry)+y;
|
||||
XViolet:=round(XViolet*FrX)+x; YViolet:=round(YViolet*FrY)+y;
|
||||
|
||||
// extinctions
|
||||
if not((code=blanc_cli) and clignotant) then cercle(ACanvas,xBlanc,yBlanc,rayon,GrisF);
|
||||
@@ -1265,7 +1267,6 @@ begin
|
||||
Xcarre:=LgImage-Xcarre;Ycarre:=HtImage-Ycarre;
|
||||
end;
|
||||
|
||||
|
||||
XJaune:=round(Xjaune*Frx)+x; YJaune:=round(Yjaune*Fry)+Y;
|
||||
Xvert:=round(Xvert*FrX)+x; Yvert:=round(Yvert*FrY)+Y;
|
||||
XSem:=round(XSem*FrX)+x; YSem:=round(YSem*FrY)+Y;
|
||||
@@ -1342,7 +1343,6 @@ begin
|
||||
Xblanc:=LgImage-Xblanc;Yblanc:=HtImage-YBlanc;
|
||||
end;
|
||||
|
||||
|
||||
XJaune:=round(Xjaune*Frx)+x; YJaune:=round(Yjaune*Fry)+Y;
|
||||
Xblanc:=round(XBlanc*FrX)+x; YBlanc:=round(YBlanc*FrY)+Y;
|
||||
Xvert:=round(Xvert*FrX)+x; Yvert:=round(Yvert*FrY)+Y;
|
||||
@@ -1473,7 +1473,6 @@ var rayon,
|
||||
XBlanc,Yblanc,xJaune,yJaune,Xsem,YSem,Xvert,YVert,Xcarre,Ycarre,Xral1,Yral1,Xral2,YRal2,
|
||||
Xrap1,Yrap1,Xrap2,Yrap2,Temp,LgImage,HtImage,xt,yt,code,combine : integer;
|
||||
ech : real;
|
||||
|
||||
begin
|
||||
rayon:=round(6*frX);
|
||||
code_to_aspect(Etatsignal,code,combine); // et aspect
|
||||
@@ -1538,7 +1537,6 @@ begin
|
||||
Xrap2:=LgImage-Xrap2; Yrap2:=HtImage-Yrap2;
|
||||
end;
|
||||
|
||||
|
||||
XJaune:=round(Xjaune*Frx)+x; YJaune:=round(Yjaune*Fry)+Y;
|
||||
Xblanc:=round(XBlanc*FrX)+x; YBlanc:=round(YBlanc*FrY)+Y;
|
||||
XRal1:=round(XRal1*FrX)+x; YRal1:=round(YRal1*FrY)+Y;
|
||||
@@ -1590,10 +1588,7 @@ begin
|
||||
end;
|
||||
|
||||
// Ecrire sur un canvas un texte avec un angle, avec ou sans bordure, monochrome ou à face texturée
|
||||
procedure AffTexteIncliBordeTexture(C : TCanvas; X,Y : integer; Fonte : tFont;
|
||||
clBord : TColor; EpBord : integer; PenMode : TPenMode;
|
||||
Texture : tBitMap; Texte : string; AngleDD : longint);
|
||||
// params : C = Canvas-cible
|
||||
// params : C = Canvas-cible
|
||||
// X,Y = Coordonnées angle supérieur gauche du début du texte.
|
||||
// Fonte = Police de caractères à utiliser : uniquement des fontes scalables.
|
||||
// clBord = Couleur de la bordure.
|
||||
@@ -1601,28 +1596,31 @@ procedure AffTexteIncliBordeTexture(C : TCanvas; X,Y : integer; Fonte : tFont;
|
||||
// PenMode = TPenMode : utiliser en général pmCopy.
|
||||
// Texture = BitMap de texture : Si Texture = Nil alors la face sera de la couleur de Fonte avec un contour de clBord si EpBord > 0.
|
||||
// Texte = Texte à écrire.
|
||||
// AngleDD = Angle d'inclinaison en Dixièmes de degré.
|
||||
var dc : Hdc;
|
||||
lgFont : Logfont;
|
||||
// AngleDD = Angle d'inclinaison en Dixièmes de degré.
|
||||
procedure AffTexteIncliBordeTexture(c : TCanvas; x,y : integer; Fonte : tFont;
|
||||
clBord : TColor; EpBord : integer; PenMode : TPenMode;
|
||||
Texture : tBitMap; texte : string; AngleDD : longint);
|
||||
var dc : Hdc;
|
||||
lgFont : Logfont; // structure d'attributs de police
|
||||
AncFonte,NouvFonte : Hfont;
|
||||
AncPen,NouvPen : Hpen;
|
||||
AncPen,NouvPen : Hpen;
|
||||
AncBrush,NouvBrush : Hbrush;
|
||||
begin
|
||||
C.Pen.Mode:=PenMode;
|
||||
dc:=C.Handle;
|
||||
|
||||
// Initialisation de la fonte
|
||||
zeroMemory(@lgFont,sizeOf(lgFont));
|
||||
strPCopy(lgFont.lfFaceName,Fonte.Name);
|
||||
lgFont.lfHeight := Fonte.Height;
|
||||
if Fonte.style=[] then lgFont.lfWeight:=FW_REGULAR; // Normal
|
||||
zeroMemory(@lgFont,sizeOf(lgFont)); // remplit la structure de 0
|
||||
strPCopy(lgFont.lfFaceName,Fonte.Name); // copie la chaîne dans le nom de la fonte depuis le paramètre
|
||||
lgFont.lfHeight:=Fonte.Height; // la taille
|
||||
if Fonte.style=[] then lgFont.lfWeight:=FW_REGULAR; // Normal
|
||||
if Fonte.style=[fsBold] then lgFont.lfWeight:=FW_BOLD; // Gras
|
||||
|
||||
if fsItalic in Fonte.style then lgFont.lfItalic:=1;
|
||||
if fsUnderline in Fonte.style then lgFont.lfUnderline:=1;
|
||||
if fsStrikeout in Fonte.style then lgFont.lfStrikeout:=1;
|
||||
|
||||
lgFont.lfEscapement:=AngleDD; // Modification de l'inclinaison
|
||||
lgFont.lfEscapement:=AngleDD; // Angle d'inclinaison en dixièmes de degrés
|
||||
|
||||
NouvFonte:=CreateFontInDirect(lgFont);
|
||||
AncFonte:=SelectObject(dc,NouvFonte);
|
||||
@@ -1672,7 +1670,7 @@ end;
|
||||
procedure dessine_signal20(Acanvas : Tcanvas;x,y : integer;frX,frY : real;EtatSignal : word;orientation,adresse : integer);
|
||||
var xblanc,xvert,xrouge,Yblanc,xjauneBas,xJauneHaut,yJauneBas,yJauneHaut,YVert,Yrouge,largeur,
|
||||
index,Temp,rayon,LgImage,HtImage,code,combine,x1,y1,x2,y2,x3,y3,xChiffre,yChiffre,xfin,yfin,angle,
|
||||
AdrAig,IndexAig,vitesse,indexTCO,tailleFonte : integer;
|
||||
AdrAig,IndexAig,vitesse,indexTCO,tailleFonte,xTexte,yTexte : integer;
|
||||
ech : real;
|
||||
inverse,etatChevron,EtatChiffre,codeClignote : boolean;
|
||||
r : Trect;
|
||||
@@ -1697,9 +1695,12 @@ begin
|
||||
x1:=9;y1:=3;
|
||||
x2:=16;y2:=10;
|
||||
x3:=x2+(x2-x1);y3:=y1;
|
||||
// texte
|
||||
XChiffre:=14;Ychiffre:=76;
|
||||
Xfin:=26;yFin:=99;
|
||||
// effacement du chiffre
|
||||
XChiffre:=11;Ychiffre:=77;
|
||||
Xfin:=27;yFin:=102;
|
||||
// texte du chiffre
|
||||
xTexte:=xChiffre+2;
|
||||
yTexte:=yChiffre+1;
|
||||
|
||||
index:=index_signal(adresse);
|
||||
if Signaux[index].contrevoie then
|
||||
@@ -1714,6 +1715,7 @@ begin
|
||||
x3:=largeur-x3;
|
||||
Xchiffre:=32;
|
||||
Xfin:=44;
|
||||
Xtexte:=Xchiffre+1;
|
||||
codeclignote:=true;
|
||||
end;
|
||||
|
||||
@@ -1739,6 +1741,7 @@ begin
|
||||
Temp:=HtImage-y2;Y2:=X2;X2:=Temp;
|
||||
Temp:=HtImage-y3;Y3:=X3;X3:=Temp;
|
||||
Temp:=HtImage-yChiffre;YChiffre:=XChiffre;XChiffre:=Temp;
|
||||
Temp:=HtImage-yTexte;YTexte:=XTexte;XTexte:=Temp;
|
||||
Temp:=HtImage-yfin;Yfin:=Xfin;Xfin:=Temp;
|
||||
end;
|
||||
|
||||
@@ -1758,6 +1761,7 @@ begin
|
||||
Temp:=LgImage-X3;X3:=Y3;Y3:=Temp;
|
||||
Temp:=LgImage-XChiffre;XChiffre:=YChiffre;YChiffre:=Temp;
|
||||
Temp:=LgImage-Xfin;Xfin:=Yfin;Yfin:=Temp;
|
||||
Temp:=LgImage-XTexte;XTexte:=YTexte;YTexte:=Temp;
|
||||
end;
|
||||
|
||||
if orientation=4 then
|
||||
@@ -1773,6 +1777,7 @@ begin
|
||||
X3:=LgImage-X3;Y3:=HtImage-Y3;
|
||||
XChiffre:=LgImage-XChiffre;YChiffre:=HtImage-YChiffre;
|
||||
XFin:=LgImage-Xfin;Yfin:=HtImage-yFin;
|
||||
xTexte:=LgImage-XTexte;YTexte:=HtImage-YTexte;
|
||||
end;
|
||||
|
||||
XJauneBas:=round(XjauneBas*Frx)+x; YJauneBas:=round(YjauneBas*Fry)+Y;
|
||||
@@ -1781,6 +1786,7 @@ begin
|
||||
Xvert:=round(Xvert*FrX)+x; Yvert:=round(Yvert*FrY)+Y;
|
||||
Xrouge:=round(Xrouge*FrX)+x; Yrouge:=round(Yrouge*FrY)+Y;
|
||||
xchiffre:=round(Xchiffre*frx)+x; ychiffre:=round(ychiffre*fry)+y;
|
||||
xTexte:=round(XTexte*frx)+x; yTexte:=round(yTexte*fry)+y;
|
||||
xfin:=round(Xfin*frx)+x; yfin:=round(yfin*fry)+y;
|
||||
x1:=round(X1*frx)+x; y1:=round(y1*fry)+y;
|
||||
x2:=round(X2*frx)+x; y2:=round(y2*fry)+y;
|
||||
@@ -1864,7 +1870,7 @@ begin
|
||||
IndexAig:=index_aig(adrAig);
|
||||
vitesse:=aiguillage[IndexAig].vitesse div 10;
|
||||
|
||||
if orientation=1 then Textout(XChiffre,Ychiffre,intToSTR(vitesse))
|
||||
if orientation=1 then Textout(XTexte,YTexte,intToSTR(vitesse))
|
||||
else
|
||||
begin
|
||||
case orientation of
|
||||
@@ -1872,7 +1878,7 @@ begin
|
||||
3 : angle:=900;
|
||||
4 : angle:=1800;
|
||||
end;
|
||||
AffTexteIncliBordeTexture(Acanvas,Xchiffre,Ychiffre,Acanvas.Font,clYellow,0,pmcopy,nil,intToSTR(vitesse),angle);
|
||||
AffTexteIncliBordeTexture(Acanvas,XTexte,YTexte,Acanvas.Font,clYellow,0,pmcopy,nil,intToSTR(vitesse),angle);
|
||||
end;
|
||||
end;
|
||||
end
|
||||
@@ -1881,8 +1887,8 @@ begin
|
||||
// éteint le chiffre
|
||||
Brush.Color:=clblack;
|
||||
Pen.Color:=clblack;
|
||||
r.Left:=xchiffre+1;r.Top:=Ychiffre+1;
|
||||
r.Right:=Xfin-2;r.Bottom:=Yfin-1;
|
||||
r.Left:=xchiffre;r.Top:=Ychiffre;
|
||||
r.Right:=Xfin;r.Bottom:=Yfin;
|
||||
Fillrect(r);
|
||||
end;
|
||||
end;
|
||||
@@ -2120,7 +2126,7 @@ begin
|
||||
if adresse>MaxAcc then result:=0 else
|
||||
//result:=Index_Accessoire[adresse];
|
||||
result:=Tablo_Index_Signal[adresse];
|
||||
// vérifier si l'index correspond à un signal
|
||||
// vérifier si l'adresse correspond
|
||||
if Signaux[result].adresse<>adresse then result:=0;
|
||||
end;
|
||||
|
||||
@@ -2142,7 +2148,7 @@ function Index_Aig(adresse : integer) : integer;
|
||||
begin
|
||||
if adresse>MaxAcc then result:=0 else
|
||||
result:=tablo_index_aiguillage[adresse];
|
||||
// vérifier si l'index correspond à un aiguillage
|
||||
// vérifier si l'adresse correspond
|
||||
if Aiguillage[result].adresse<>adresse then result:=0;
|
||||
end;
|
||||
|
||||
@@ -2197,8 +2203,11 @@ begin
|
||||
i:=pos('@',s); if i<>0 then delete(s,1,i);
|
||||
i:=pos('=',s); if i<>0 then delete(s,i,1);
|
||||
i:=pos(' ',s);
|
||||
if i<>0 then s:=copy(s,1,i-1);
|
||||
val(s,AdrPilote,erreur);
|
||||
if i<>0 then
|
||||
begin
|
||||
s:=copy(s,1,i-1);
|
||||
val(s,AdrPilote,erreur);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
@@ -10790,10 +10799,10 @@ end;
|
||||
// pos = const_droit=2 ou const_devie=1
|
||||
procedure Event_Aig(adresse,pos : integer);
|
||||
var s: string;
|
||||
faire_event,inv : boolean;
|
||||
prov,index,i,etatact,typ,adr : integer;
|
||||
faire_event,inv,bjd : boolean;
|
||||
AdrCDM,prov,index,i,id,etatact,typ,adr : integer;
|
||||
begin
|
||||
if nivDebug=1 then AfficheDebug('Event Aig '+intToSTR(adresse),clorange);
|
||||
if AffAigDet then AfficheDebug('Tick='+IntToSTR(tick)+' Event Aig '+intToSTR(adresse)+'='+intToSTR(pos),clorange);
|
||||
index:=index_aig(adresse);
|
||||
if index<>0 then
|
||||
begin
|
||||
@@ -10843,10 +10852,6 @@ begin
|
||||
begin
|
||||
evalue;evalue;evalue;
|
||||
end;
|
||||
|
||||
// Mettre à jour les TCOs
|
||||
if TCOActive then
|
||||
for i:=1 to NbreTCO do Maj_TCO(i,Adresse);
|
||||
end;
|
||||
|
||||
// evt actionneur d'aiguillage
|
||||
@@ -10872,9 +10877,9 @@ begin
|
||||
s:='T'+intToSTR(adresse)+','+intToSTR(pos);
|
||||
if Tablo_periph[i].ScvVis then Affiche(s,clWhite);
|
||||
if Tablo_periph[i].cr then s:=s+#13;
|
||||
index:=Tablo_periph[i].NumComposant;
|
||||
if index=1 then Formprinc.MSCommCde1.Output:=s;
|
||||
if index=2 then Formprinc.MSCommCde2.Output:=s;
|
||||
id:=Tablo_periph[i].NumComposant;
|
||||
if id=1 then Formprinc.MSCommCde1.Output:=s;
|
||||
if id=2 then Formprinc.MSCommCde2.Output:=s;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@@ -10885,9 +10890,9 @@ begin
|
||||
s:='T'+intToSTR(adresse)+','+intToSTR(pos);
|
||||
if Tablo_periph[i].ScvVis then Affiche(s,clWhite);
|
||||
if Tablo_periph[i].cr then s:=s+#13;
|
||||
index:=Tablo_periph[i].NumComposant;
|
||||
if index=1 then Formprinc.ClientSocketCde1.Socket.SendText(s);
|
||||
if index=2 then Formprinc.ClientSocketCde2.Socket.SendText(s);
|
||||
id:=Tablo_periph[i].NumComposant;
|
||||
if id=1 then Formprinc.ClientSocketCde1.Socket.SendText(s);
|
||||
if id=2 then Formprinc.ClientSocketCde2.Socket.SendText(s);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@@ -10895,6 +10900,23 @@ begin
|
||||
// Serveur envoi au clients
|
||||
Envoi_serveur('T'+intToSTR(adresse)+','+intToSTR(pos));
|
||||
|
||||
// Si aiguillage de bjd
|
||||
bjd:=false;
|
||||
begin
|
||||
for i:=1 to MaxAiguillage do
|
||||
begin
|
||||
if (aiguillage[i].AdrCDM=adresse) then
|
||||
begin
|
||||
bjd:=true;
|
||||
aiguillage[i].position:=pos; // stockage de la nouvelle position de l'aiguillage
|
||||
end;
|
||||
end;
|
||||
if bjd then evalue;
|
||||
end;
|
||||
|
||||
// Mettre à jour les TCOs
|
||||
if TCOActive then
|
||||
for i:=1 to NbreTCO do Maj_TCO(i,Adresse);
|
||||
end;
|
||||
|
||||
// pilote une sortie à 0 à l'interface dont l'adresse est à 1 ou 2 (octet)
|
||||
@@ -11584,7 +11606,7 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
if chaineINT[1]=#$42 then
|
||||
if chaineINT[1]=#$42 then // accessory decodeur information response 4 octets
|
||||
begin
|
||||
check(chaineINT,4);
|
||||
delete(chaineInt,1,1);
|
||||
@@ -11594,7 +11616,7 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
if chaineINT[1]=#$81 then
|
||||
if chaineINT[1]=#$81 then // arrêt urgence 3 octets
|
||||
begin
|
||||
check(chaineINT,3);
|
||||
delete(chaineInt,1,3);
|
||||
@@ -11604,43 +11626,43 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
if chaineINT[1]=#$46 then
|
||||
if chaineINT[1]=#$46 then // non doc
|
||||
begin
|
||||
//FF FD 46 43 40 41 40 40 49 4D non documentée
|
||||
//FF FD 46 43 50 41 50 40 50 54 non documentée
|
||||
// 46 43 40 41 40 40 48 4C
|
||||
// 46 43 50 41 54 40 50 50
|
||||
|
||||
// supprimer jusque FF ou fin de chaine
|
||||
check(chaineINT,8);
|
||||
i:=0;
|
||||
repeat
|
||||
inc(i);
|
||||
until (i>length(chaineINT)) or (chaineINT[i]=#$FF);
|
||||
delete(chaineINT,1,i-1);
|
||||
|
||||
Affiche('reprise puissance ',clLime);
|
||||
delete(chaineInt,1,8);
|
||||
Hors_tension:=false;
|
||||
decode_chaine_retro_Xpress:=chaineINT;
|
||||
exit;
|
||||
end;
|
||||
|
||||
i:=pos(#$46+#$43+#$50,chaineInt);
|
||||
if (i<>0) and (length(chaineInt)>=3) then
|
||||
begin
|
||||
check(chaineINT,3);
|
||||
delete(chaineInt,1,3);
|
||||
Affiche('Reprise msg 2',clOrange);
|
||||
Hors_tension:=false;
|
||||
decode_chaine_retro_Xpress:=chaineINT;
|
||||
exit;
|
||||
end;
|
||||
|
||||
if chaineInt[1]=#$81 then
|
||||
if chaineInt[1]=#$81 then // non documentée
|
||||
begin
|
||||
check(chaineINT,2);
|
||||
delete(chaineInt,1,2);
|
||||
i:=0;
|
||||
repeat
|
||||
inc(i);
|
||||
until (i>length(chaineINT)) or (chaineINT[i]=#$FF);
|
||||
delete(chaineINT,1,i-1);
|
||||
|
||||
Affiche('Court circuit msg 1',clRed);
|
||||
Hors_tension:=true;
|
||||
decode_chaine_retro_Xpress:=chaineINT;
|
||||
exit;
|
||||
end;
|
||||
|
||||
// E3 40 ah al A0
|
||||
// E3 40 ah al xor
|
||||
if chaineInt[1]=#$E3 then
|
||||
begin
|
||||
// la loco ah al est pilotée par le PC
|
||||
@@ -11650,6 +11672,7 @@ begin
|
||||
exit;
|
||||
end;
|
||||
|
||||
// E4 id speed FcA FcB xor loco information
|
||||
if chaineInt[1]=#$E4 then
|
||||
begin
|
||||
check(chaineINT,6);
|
||||
@@ -11665,7 +11688,13 @@ begin
|
||||
ack:=false;
|
||||
nack:=true;
|
||||
affiche('Erreur 7, chaîne rétrosig. inconnue recue:'+chaine_HEX(chaineINT),clred);
|
||||
decode_chaine_retro_Xpress:='';
|
||||
i:=0;
|
||||
repeat
|
||||
inc(i);
|
||||
until (i>length(chaineINT)) or (chaineINT[i]=#$FF);
|
||||
delete(chaineINT,1,i-1);
|
||||
|
||||
decode_chaine_retro_Xpress:=chaineINT;
|
||||
end;
|
||||
|
||||
// procédure appellée après réception sur le port USB ou socket
|
||||
@@ -15501,12 +15530,14 @@ procedure TFormPrinc.Apropos1Click(Sender: TObject);
|
||||
var i,t,t1 : integer;
|
||||
begin
|
||||
Affiche(' ',clyellow);
|
||||
Affiche('Signaux complexes GL version '+version+sousVersion+' (C) 2022-23 F1IWQ Gily TDR',clWhite);
|
||||
Affiche('Signaux complexes GL version '+version+sousVersion+' (C) 2022-24 F1IWQ Gily TDR',clWhite);
|
||||
Affiche('Double cliquez sur un des liens ci-dessous',clWhite);
|
||||
|
||||
FenRich.SelStart:=length(FenRich.Text);
|
||||
FenRich.SelAttributes.Style:=[fsUnderline];
|
||||
FenRich.lines.add('https://github.com/f1iwq2/Signaux_complexes_GL');
|
||||
RE_ColorLine(FenRich,FenRich.lines.count-1,clAqua);
|
||||
|
||||
FenRich.SelStart:=length(FenRich.Text);
|
||||
FenRich.SelAttributes.Style:=[fsUnderline];
|
||||
FenRich.Lines.add('https://github.com/f1iwq2/Signaux_complexes_GL/releases');
|
||||
@@ -15518,7 +15549,7 @@ begin
|
||||
RE_ColorLine(FenRich,FenRich.lines.count-1,clAqua);
|
||||
|
||||
Affiche('Ce programme pilote des signaux complexes et les trains de façon autonome ou avec CDM rail ',ClYellow);
|
||||
Affiche('En fonction des détecteurs mis à 1 ou 0 par des locomotives',ClYellow);
|
||||
Affiche('en fonction des détecteurs mis à 1 ou 0 par des locomotives',ClYellow);
|
||||
Affiche('en circulation sur le réseau',ClYellow);
|
||||
Affiche('En vert : Trames envoyées à l''interface',ClWhite);
|
||||
Affiche('En blanc : Trames brutes reçues de l''interface',ClWhite);
|
||||
@@ -15705,8 +15736,7 @@ begin
|
||||
end;
|
||||
|
||||
// cliqué gauche dans la fenetre Fenrich
|
||||
procedure TFormPrinc.FenRichMouseDown(Sender: TObject;
|
||||
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
procedure TFormPrinc.FenRichMouseDown(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
|
||||
var lc,i : integer;
|
||||
s : string;
|
||||
begin
|
||||
@@ -15728,7 +15758,7 @@ begin
|
||||
lc:=Perform(EM_LINEFROMCHAR,i,0);
|
||||
s:=lines[lc];
|
||||
end;
|
||||
if pos('http',s)<>0 then ShellExecute(0,'open',Pchar(s),nil,nil,sw_shownormal);
|
||||
if pos('http',s)=1 then ShellExecute(0,'open',Pchar(s),nil,nil,sw_shownormal);
|
||||
end;
|
||||
end;
|
||||
|
||||
@@ -15958,11 +15988,11 @@ begin
|
||||
end;
|
||||
|
||||
procedure TFormPrinc.Button1Click(Sender: TObject);
|
||||
var s : string;
|
||||
begin
|
||||
// placement_trains;
|
||||
//ouvre_simulation('C:\Program Files (x86)\Borland\Delphi7\Projects\Signaux_complexes_GL\2trains_autonome.txt');
|
||||
//ouvre_simulation('C:\Program Files\Borland\Delphi7\Projects\Signaux_complexes_GL\2trains_autonome.txt');
|
||||
// ouvre_simulation('C:\temp\Signaux_complexes_GL\2trains_autonome.txt');
|
||||
s:=#$46+#$43+#$40+#$41+#$40+#$40+#$49+#$4D+#$FF;
|
||||
decode_chaine_retro_Xpress(s);
|
||||
|
||||
end;
|
||||
|
||||
procedure affiche_com(s : string;var n : integer);
|
||||
|
||||
+139
-160
@@ -1,6 +1,6 @@
|
||||
object FormTCO: TFormTCO
|
||||
Left = 104
|
||||
Top = 226
|
||||
Left = 83
|
||||
Top = 123
|
||||
Width = 1212
|
||||
Height = 661
|
||||
VertScrollBar.Visible = False
|
||||
@@ -16,6 +16,7 @@ object FormTCO: TFormTCO
|
||||
Menu = MainMenuTCO
|
||||
OldCreateOrder = False
|
||||
Position = poScreenCenter
|
||||
SnapBuffer = 0
|
||||
OnActivate = FormActivate
|
||||
OnCreate = FormCreate
|
||||
OnDragOver = FormDragOver
|
||||
@@ -23,8 +24,8 @@ object FormTCO: TFormTCO
|
||||
OnKeyPress = FormKeyPress
|
||||
OnMouseWheel = FormMouseWheel
|
||||
DesignSize = (
|
||||
1204
|
||||
610)
|
||||
1196
|
||||
602)
|
||||
PixelsPerInch = 96
|
||||
TextHeight = 13
|
||||
object LabelZoom: TLabel
|
||||
@@ -59,7 +60,7 @@ object FormTCO: TFormTCO
|
||||
Left = 10
|
||||
Top = 15
|
||||
Width = 687
|
||||
Height = 347
|
||||
Height = 410
|
||||
HorzScrollBar.Smooth = True
|
||||
HorzScrollBar.Tracking = True
|
||||
VertScrollBar.Smooth = True
|
||||
@@ -71,12 +72,12 @@ object FormTCO: TFormTCO
|
||||
TabOrder = 1
|
||||
DesignSize = (
|
||||
683
|
||||
343)
|
||||
406)
|
||||
object ImageTCO: TImage
|
||||
Left = 120
|
||||
Top = 41
|
||||
Width = 486
|
||||
Height = 257
|
||||
Height = 320
|
||||
Anchors = [akLeft, akTop, akRight, akBottom]
|
||||
AutoSize = True
|
||||
ParentShowHint = False
|
||||
@@ -106,11 +107,11 @@ object FormTCO: TFormTCO
|
||||
TickMarks = tmTopLeft
|
||||
OnChange = TrackBarZoomChange
|
||||
end
|
||||
object Panel1: TPanel
|
||||
object PanelBas: TPanel
|
||||
Left = 2
|
||||
Top = 413
|
||||
Top = 461
|
||||
Width = 1143
|
||||
Height = 185
|
||||
Height = 140
|
||||
Anchors = [akLeft, akRight, akBottom]
|
||||
Color = clActiveBorder
|
||||
Font.Charset = ANSI_CHARSET
|
||||
@@ -120,12 +121,12 @@ object FormTCO: TFormTCO
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
TabOrder = 2
|
||||
OnDragOver = Panel1DragOver
|
||||
OnDragOver = PanelBasDragOver
|
||||
DesignSize = (
|
||||
1143
|
||||
185)
|
||||
140)
|
||||
object Label1: TLabel
|
||||
Left = 216
|
||||
Left = 240
|
||||
Top = 22
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -138,7 +139,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label2: TLabel
|
||||
Left = 272
|
||||
Left = 296
|
||||
Top = 22
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -151,7 +152,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label5: TLabel
|
||||
Left = 440
|
||||
Left = 456
|
||||
Top = 22
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -164,7 +165,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label6: TLabel
|
||||
Left = 216
|
||||
Left = 240
|
||||
Top = 70
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -177,7 +178,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label7: TLabel
|
||||
Left = 272
|
||||
Left = 296
|
||||
Top = 70
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -190,7 +191,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label8: TLabel
|
||||
Left = 328
|
||||
Left = 352
|
||||
Top = 70
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -203,7 +204,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label9: TLabel
|
||||
Left = 384
|
||||
Left = 408
|
||||
Top = 62
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -216,7 +217,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label3: TLabel
|
||||
Left = 328
|
||||
Left = 344
|
||||
Top = 22
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -229,7 +230,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label4: TLabel
|
||||
Left = 384
|
||||
Left = 400
|
||||
Top = 22
|
||||
Width = 9
|
||||
Height = 19
|
||||
@@ -242,7 +243,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label10: TLabel
|
||||
Left = 208
|
||||
Left = 232
|
||||
Top = 118
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -255,7 +256,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label11: TLabel
|
||||
Left = 272
|
||||
Left = 296
|
||||
Top = 118
|
||||
Width = 17
|
||||
Height = 19
|
||||
@@ -268,7 +269,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label50: TLabel
|
||||
Left = 680
|
||||
Left = 704
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -281,7 +282,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label12: TLabel
|
||||
Left = 488
|
||||
Left = 504
|
||||
Top = 22
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -294,7 +295,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label13: TLabel
|
||||
Left = 552
|
||||
Left = 568
|
||||
Top = 22
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -307,7 +308,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label14: TLabel
|
||||
Left = 608
|
||||
Left = 624
|
||||
Top = 14
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -320,7 +321,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label15: TLabel
|
||||
Left = 664
|
||||
Left = 680
|
||||
Top = 14
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -333,7 +334,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label16: TLabel
|
||||
Left = 432
|
||||
Left = 456
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -346,7 +347,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label17: TLabel
|
||||
Left = 488
|
||||
Left = 512
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -359,7 +360,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label18: TLabel
|
||||
Left = 544
|
||||
Left = 568
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -372,7 +373,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label19: TLabel
|
||||
Left = 608
|
||||
Left = 632
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -385,7 +386,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label20: TLabel
|
||||
Left = 664
|
||||
Left = 688
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -398,7 +399,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label21: TLabel
|
||||
Left = 728
|
||||
Left = 744
|
||||
Top = 14
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -411,7 +412,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label22: TLabel
|
||||
Left = 784
|
||||
Left = 800
|
||||
Top = 14
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -424,7 +425,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label51: TLabel
|
||||
Left = 720
|
||||
Left = 744
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -437,7 +438,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label24: TLabel
|
||||
Left = 728
|
||||
Left = 752
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -450,7 +451,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label25: TLabel
|
||||
Left = 792
|
||||
Left = 816
|
||||
Top = 62
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -463,7 +464,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette1: TImage
|
||||
Left = 232
|
||||
Left = 256
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -472,7 +473,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette1MouseDown
|
||||
end
|
||||
object ImagePalette2: TImage
|
||||
Left = 288
|
||||
Left = 312
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -481,7 +482,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette2MouseDown
|
||||
end
|
||||
object ImagePalette3: TImage
|
||||
Left = 344
|
||||
Left = 360
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -490,7 +491,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette3MouseDown
|
||||
end
|
||||
object ImagePalette4: TImage
|
||||
Left = 400
|
||||
Left = 416
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -499,7 +500,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette4MouseDown
|
||||
end
|
||||
object ImagePalette5: TImage
|
||||
Left = 448
|
||||
Left = 464
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -508,7 +509,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette5MouseDown
|
||||
end
|
||||
object ImagePalette12: TImage
|
||||
Left = 512
|
||||
Left = 528
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -517,7 +518,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette12MouseDown
|
||||
end
|
||||
object ImagePalette13: TImage
|
||||
Left = 576
|
||||
Left = 592
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -526,7 +527,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette13MouseDown
|
||||
end
|
||||
object ImagePalette14: TImage
|
||||
Left = 624
|
||||
Left = 640
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -535,7 +536,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette14MouseDown
|
||||
end
|
||||
object ImagePalette15: TImage
|
||||
Left = 688
|
||||
Left = 704
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -544,7 +545,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette15MouseDown
|
||||
end
|
||||
object ImagePalette21: TImage
|
||||
Left = 752
|
||||
Left = 768
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -553,7 +554,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette21MouseDown
|
||||
end
|
||||
object ImagePalette22: TImage
|
||||
Left = 808
|
||||
Left = 824
|
||||
Top = 8
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -562,7 +563,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette22MouseDown
|
||||
end
|
||||
object ImagePalette6: TImage
|
||||
Left = 232
|
||||
Left = 256
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -571,7 +572,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette6MouseDown
|
||||
end
|
||||
object ImagePalette7: TImage
|
||||
Left = 288
|
||||
Left = 312
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -580,7 +581,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette7MouseDown
|
||||
end
|
||||
object ImagePalette9: TImage
|
||||
Left = 400
|
||||
Left = 424
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -589,7 +590,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette9MouseDown
|
||||
end
|
||||
object ImagePalette16: TImage
|
||||
Left = 448
|
||||
Left = 472
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -598,7 +599,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette16MouseDown
|
||||
end
|
||||
object ImagePalette17: TImage
|
||||
Left = 504
|
||||
Left = 528
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -607,7 +608,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette17MouseDown
|
||||
end
|
||||
object ImagePalette18: TImage
|
||||
Left = 576
|
||||
Left = 600
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -616,7 +617,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette18MouseDown
|
||||
end
|
||||
object ImagePalette19: TImage
|
||||
Left = 624
|
||||
Left = 648
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -625,7 +626,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette19MouseDown
|
||||
end
|
||||
object ImagePalette20: TImage
|
||||
Left = 688
|
||||
Left = 712
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -634,7 +635,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette20MouseDown
|
||||
end
|
||||
object ImagePalette24: TImage
|
||||
Left = 752
|
||||
Left = 776
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -643,7 +644,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette24MouseDown
|
||||
end
|
||||
object ImagePalette25: TImage
|
||||
Left = 808
|
||||
Left = 832
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -652,7 +653,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette25MouseDown
|
||||
end
|
||||
object ImagePalette10: TImage
|
||||
Left = 232
|
||||
Left = 256
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -661,7 +662,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette10MouseDown
|
||||
end
|
||||
object ImagePalette11: TImage
|
||||
Left = 288
|
||||
Left = 312
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -670,7 +671,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette11MouseDown
|
||||
end
|
||||
object ImagePalette51: TImage
|
||||
Left = 736
|
||||
Left = 760
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -682,7 +683,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette51MouseDown
|
||||
end
|
||||
object ImagePalette50: TImage
|
||||
Left = 696
|
||||
Left = 720
|
||||
Top = 104
|
||||
Width = 25
|
||||
Height = 41
|
||||
@@ -695,7 +696,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette50MouseDown
|
||||
end
|
||||
object ImagePalette8: TImage
|
||||
Left = 344
|
||||
Left = 368
|
||||
Top = 56
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -704,7 +705,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette8MouseDown
|
||||
end
|
||||
object ImagePalette26: TImage
|
||||
Left = 344
|
||||
Left = 368
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -713,7 +714,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette26MouseDown
|
||||
end
|
||||
object Label26: TLabel
|
||||
Left = 320
|
||||
Left = 344
|
||||
Top = 118
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -726,7 +727,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette23: TImage
|
||||
Left = 496
|
||||
Left = 520
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -735,7 +736,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette23MouseDown
|
||||
end
|
||||
object Label23: TLabel
|
||||
Left = 480
|
||||
Left = 504
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -748,7 +749,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label27: TLabel
|
||||
Left = 376
|
||||
Left = 400
|
||||
Top = 118
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -761,7 +762,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette27: TImage
|
||||
Left = 400
|
||||
Left = 424
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -770,7 +771,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette27MouseDown
|
||||
end
|
||||
object ImagePalette28: TImage
|
||||
Left = 448
|
||||
Left = 472
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -779,7 +780,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette28MouseDown
|
||||
end
|
||||
object Label28: TLabel
|
||||
Left = 432
|
||||
Left = 456
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -792,7 +793,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label29: TLabel
|
||||
Left = 536
|
||||
Left = 560
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -805,7 +806,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette29: TImage
|
||||
Left = 552
|
||||
Left = 576
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -814,7 +815,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette29MouseDown
|
||||
end
|
||||
object Label32: TLabel
|
||||
Left = 584
|
||||
Left = 608
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -827,7 +828,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette32: TImage
|
||||
Left = 600
|
||||
Left = 624
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -836,7 +837,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette32MouseDown
|
||||
end
|
||||
object Label33: TLabel
|
||||
Left = 632
|
||||
Left = 656
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -849,7 +850,7 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette33: TImage
|
||||
Left = 648
|
||||
Left = 672
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -858,8 +859,8 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette33MouseDown
|
||||
end
|
||||
object Label34: TLabel
|
||||
Left = 208
|
||||
Top = 150
|
||||
Left = 872
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
Caption = '34'
|
||||
@@ -871,8 +872,8 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ImagePalette34: TImage
|
||||
Left = 232
|
||||
Top = 144
|
||||
Left = 896
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
OnDragOver = ImagePalette34DragOver
|
||||
@@ -880,7 +881,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette34MouseDown
|
||||
end
|
||||
object ImagePalette52: TImage
|
||||
Left = 808
|
||||
Left = 832
|
||||
Top = 104
|
||||
Width = 33
|
||||
Height = 33
|
||||
@@ -892,7 +893,7 @@ object FormTCO: TFormTCO
|
||||
OnMouseDown = ImagePalette52MouseDown
|
||||
end
|
||||
object Label52: TLabel
|
||||
Left = 776
|
||||
Left = 800
|
||||
Top = 110
|
||||
Width = 18
|
||||
Height = 19
|
||||
@@ -906,88 +907,66 @@ object FormTCO: TFormTCO
|
||||
end
|
||||
object ButtonSauveTCO: TButton
|
||||
Left = 1037
|
||||
Top = 64
|
||||
Top = 8
|
||||
Width = 96
|
||||
Height = 33
|
||||
Anchors = [akTop, akRight]
|
||||
Anchors = [akTop]
|
||||
Caption = 'Sauvegarder TCO'
|
||||
TabOrder = 0
|
||||
TabStop = False
|
||||
WordWrap = True
|
||||
OnClick = ButtonSauveTCOClick
|
||||
end
|
||||
object Button1: TButton
|
||||
Left = 478
|
||||
Top = 152
|
||||
Width = 57
|
||||
Height = 25
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Simu det 1'
|
||||
TabOrder = 1
|
||||
TabStop = False
|
||||
OnClick = Button1Click
|
||||
end
|
||||
object Button2: TButton
|
||||
Left = 414
|
||||
Top = 152
|
||||
Width = 57
|
||||
Height = 25
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Simu Det 0'
|
||||
TabOrder = 2
|
||||
TabStop = False
|
||||
OnClick = Button2Click
|
||||
end
|
||||
object ButtonConfigTCO: TButton
|
||||
Left = 1037
|
||||
Top = 104
|
||||
Top = 48
|
||||
Width = 96
|
||||
Height = 33
|
||||
Anchors = [akTop, akRight]
|
||||
Anchors = [akTop]
|
||||
Caption = 'Configuration TCO'
|
||||
TabOrder = 3
|
||||
TabOrder = 1
|
||||
TabStop = False
|
||||
OnClick = ButtonConfigTCOClick
|
||||
end
|
||||
object ButtonSimu: TButton
|
||||
Left = 566
|
||||
Top = 152
|
||||
Left = 822
|
||||
Top = 80
|
||||
Width = 113
|
||||
Height = 25
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Simu canton occup'#233
|
||||
TabOrder = 4
|
||||
TabOrder = 2
|
||||
TabStop = False
|
||||
OnClick = ButtonSimuClick
|
||||
end
|
||||
object ButtonMasquer: TButton
|
||||
Left = 1037
|
||||
Top = 144
|
||||
Top = 88
|
||||
Width = 96
|
||||
Height = 33
|
||||
Anchors = [akTop, akRight]
|
||||
Anchors = [akTop]
|
||||
Caption = 'Masquer bandeau'
|
||||
TabOrder = 5
|
||||
TabOrder = 3
|
||||
TabStop = False
|
||||
WordWrap = True
|
||||
OnClick = ButtonMasquerClick
|
||||
end
|
||||
object GroupBox1: TGroupBox
|
||||
Left = 16
|
||||
Top = 8
|
||||
Width = 185
|
||||
Height = 169
|
||||
Left = 8
|
||||
Top = 3
|
||||
Width = 225
|
||||
Height = 125
|
||||
Caption = 'Configuration cellule'
|
||||
Font.Charset = ANSI_CHARSET
|
||||
Font.Color = clBackground
|
||||
Font.Height = -15
|
||||
Font.Height = -13
|
||||
Font.Name = 'Arial Narrow'
|
||||
Font.Style = []
|
||||
ParentFont = False
|
||||
TabOrder = 6
|
||||
TabOrder = 4
|
||||
object Label41: TLabel
|
||||
Left = 8
|
||||
Top = 24
|
||||
Left = 64
|
||||
Top = 20
|
||||
Width = 103
|
||||
Height = 16
|
||||
Caption = 'Adresse de l'#39#233'l'#233'ment: '
|
||||
@@ -999,8 +978,8 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label71: TLabel
|
||||
Left = 8
|
||||
Top = 46
|
||||
Left = 72
|
||||
Top = 36
|
||||
Width = 93
|
||||
Height = 16
|
||||
Caption = 'Image de l'#39#233'l'#233'ment: '
|
||||
@@ -1012,8 +991,8 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label230: TLabel
|
||||
Left = 56
|
||||
Top = 72
|
||||
Left = 88
|
||||
Top = 56
|
||||
Width = 27
|
||||
Height = 16
|
||||
Caption = 'Texte'
|
||||
@@ -1025,8 +1004,8 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object Label65: TLabel
|
||||
Left = 8
|
||||
Top = 96
|
||||
Left = 40
|
||||
Top = 74
|
||||
Width = 75
|
||||
Height = 16
|
||||
Caption = 'position du texte'
|
||||
@@ -1038,13 +1017,13 @@ object FormTCO: TFormTCO
|
||||
ParentFont = False
|
||||
end
|
||||
object ShapeCoulFond: TShape
|
||||
Left = 160
|
||||
Top = 146
|
||||
Left = 200
|
||||
Top = 98
|
||||
Width = 18
|
||||
Height = 18
|
||||
end
|
||||
object EditAdrElement: TEdit
|
||||
Left = 144
|
||||
Left = 176
|
||||
Top = 20
|
||||
Width = 33
|
||||
Height = 21
|
||||
@@ -1059,8 +1038,8 @@ object FormTCO: TFormTCO
|
||||
OnClick = EditAdrElementClick
|
||||
end
|
||||
object EditTypeImage: TEdit
|
||||
Left = 144
|
||||
Top = 44
|
||||
Left = 176
|
||||
Top = 36
|
||||
Width = 33
|
||||
Height = 21
|
||||
Font.Charset = ANSI_CHARSET
|
||||
@@ -1074,8 +1053,8 @@ object FormTCO: TFormTCO
|
||||
OnChange = EditTypeImageChange
|
||||
end
|
||||
object ButtonFonte: TButton
|
||||
Left = 8
|
||||
Top = 72
|
||||
Left = 32
|
||||
Top = 58
|
||||
Width = 41
|
||||
Height = 17
|
||||
Caption = 'Fonte'
|
||||
@@ -1083,8 +1062,8 @@ object FormTCO: TFormTCO
|
||||
OnClick = ButtonFonteClick
|
||||
end
|
||||
object EditTexte: TEdit
|
||||
Left = 88
|
||||
Top = 70
|
||||
Left = 120
|
||||
Top = 54
|
||||
Width = 89
|
||||
Height = 21
|
||||
Font.Charset = ANSI_CHARSET
|
||||
@@ -1097,8 +1076,8 @@ object FormTCO: TFormTCO
|
||||
OnChange = EditTexteChange
|
||||
end
|
||||
object ComboRepr: TComboBox
|
||||
Left = 88
|
||||
Top = 96
|
||||
Left = 120
|
||||
Top = 72
|
||||
Width = 89
|
||||
Height = 21
|
||||
Style = csDropDownList
|
||||
@@ -1122,7 +1101,7 @@ object FormTCO: TFormTCO
|
||||
end
|
||||
object CheckPinv: TCheckBox
|
||||
Left = 8
|
||||
Top = 126
|
||||
Top = 98
|
||||
Width = 113
|
||||
Height = 17
|
||||
Hint = 'Cocher si l'#39'aiguillage est repr'#233'sent'#233' invers'#233
|
||||
@@ -1139,8 +1118,8 @@ object FormTCO: TFormTCO
|
||||
OnClick = CheckPinvClick
|
||||
end
|
||||
object ButtonCoulFond: TButton
|
||||
Left = 80
|
||||
Top = 146
|
||||
Left = 120
|
||||
Top = 98
|
||||
Width = 81
|
||||
Height = 18
|
||||
Caption = 'Couleur de fond'
|
||||
@@ -1156,30 +1135,30 @@ object FormTCO: TFormTCO
|
||||
end
|
||||
object buttonRaz: TButton
|
||||
Left = 931
|
||||
Top = 144
|
||||
Top = 88
|
||||
Width = 97
|
||||
Height = 33
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Raz des occupations'
|
||||
TabOrder = 7
|
||||
TabOrder = 5
|
||||
TabStop = False
|
||||
WordWrap = True
|
||||
OnClick = buttonRazClick
|
||||
end
|
||||
object ButtonCalibrage: TButton
|
||||
Left = 686
|
||||
Top = 152
|
||||
Left = 862
|
||||
Top = 56
|
||||
Width = 75
|
||||
Height = 25
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Calibrage'
|
||||
TabOrder = 8
|
||||
TabOrder = 6
|
||||
TabStop = False
|
||||
OnClick = ButtonCalibrageClick
|
||||
end
|
||||
object ButtonDessiner: TButton
|
||||
Left = 931
|
||||
Top = 104
|
||||
Top = 48
|
||||
Width = 97
|
||||
Height = 33
|
||||
Hint =
|
||||
@@ -1189,26 +1168,26 @@ object FormTCO: TFormTCO
|
||||
Caption = 'Dessiner le TCO'
|
||||
ParentShowHint = False
|
||||
ShowHint = True
|
||||
TabOrder = 9
|
||||
TabOrder = 7
|
||||
TabStop = False
|
||||
OnClick = ButtonDessinerClick
|
||||
end
|
||||
object ButtonAffSC: TButton
|
||||
Left = 931
|
||||
Top = 64
|
||||
Top = 8
|
||||
Width = 97
|
||||
Height = 33
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Afficher Signaux Complexes'
|
||||
TabOrder = 10
|
||||
TabOrder = 8
|
||||
TabStop = False
|
||||
WordWrap = True
|
||||
OnClick = ButtonAffSCClick
|
||||
end
|
||||
object RadioGroupSel: TRadioGroup
|
||||
Left = 959
|
||||
Left = 783
|
||||
Top = 8
|
||||
Width = 169
|
||||
Width = 138
|
||||
Height = 49
|
||||
Anchors = [akTop, akRight]
|
||||
Caption = 'Outil de s'#233'lection'
|
||||
@@ -1221,7 +1200,7 @@ object FormTCO: TFormTCO
|
||||
'Cellules s'#233'lectionn'#233'es'
|
||||
'fen'#234'tre d'#233'pla'#231'able')
|
||||
ParentFont = False
|
||||
TabOrder = 11
|
||||
TabOrder = 9
|
||||
OnClick = RadioGroupSelClick
|
||||
end
|
||||
end
|
||||
@@ -1376,9 +1355,9 @@ object FormTCO: TFormTCO
|
||||
Caption = 'Rafra'#238'chir le TCO'
|
||||
OnClick = Redessine1Click
|
||||
end
|
||||
object Affichebandeau1: TMenuItem
|
||||
Caption = 'Affiche bandeau'
|
||||
OnClick = Affichebandeau1Click
|
||||
object Bandeau: TMenuItem
|
||||
Caption = 'Masquer bandeau'
|
||||
OnClick = BandeauClick
|
||||
end
|
||||
object Affichage1: TMenuItem
|
||||
Caption = 'Affichage'
|
||||
|
||||
+127
-91
@@ -20,7 +20,7 @@ type
|
||||
Tourner90D: TMenuItem;
|
||||
Pos_vert: TMenuItem;
|
||||
TrackBarZoom: TTrackBar;
|
||||
Panel1: TPanel;
|
||||
PanelBas: TPanel;
|
||||
Label1: TLabel;
|
||||
Label2: TLabel;
|
||||
Label5: TLabel;
|
||||
@@ -34,8 +34,6 @@ type
|
||||
Label11: TLabel;
|
||||
Label50: TLabel;
|
||||
ButtonSauveTCO: TButton;
|
||||
Button1: TButton;
|
||||
Button2: TButton;
|
||||
LabelZoom: TLabel;
|
||||
ButtonConfigTCO: TButton;
|
||||
Annulercouper: TMenuItem;
|
||||
@@ -145,7 +143,7 @@ type
|
||||
N8: TMenuItem;
|
||||
DessinerleTCO1: TMenuItem;
|
||||
ConfigurationduTCO1: TMenuItem;
|
||||
Affichebandeau1: TMenuItem;
|
||||
Bandeau: TMenuItem;
|
||||
Affichage1: TMenuItem;
|
||||
Mosaquehorizontale1: TMenuItem;
|
||||
Mosaqueverticale1: TMenuItem;
|
||||
@@ -308,7 +306,7 @@ type
|
||||
Y: Integer; State: TDragState; var Accept: Boolean);
|
||||
procedure ImagePalette50DragOver(Sender, Source: TObject; X,
|
||||
Y: Integer; State: TDragState; var Accept: Boolean);
|
||||
procedure Panel1DragOver(Sender, Source: TObject; X, Y: Integer;
|
||||
procedure PanelBasDragOver(Sender, Source: TObject; X, Y: Integer;
|
||||
State: TDragState; var Accept: Boolean);
|
||||
procedure ImagePalette51DragOver(Sender, Source: TObject; X,
|
||||
Y: Integer; State: TDragState; var Accept: Boolean);
|
||||
@@ -417,7 +415,7 @@ type
|
||||
procedure DessinerleTCO1Click(Sender: TObject);
|
||||
procedure ConfigurationduTCO1Click(Sender: TObject);
|
||||
procedure Redessine1Click(Sender: TObject);
|
||||
procedure Affichebandeau1Click(Sender: TObject);
|
||||
procedure BandeauClick(Sender: TObject);
|
||||
procedure Mosaquehorizontale1Click(Sender: TObject);
|
||||
procedure Mosaqueverticale1Click(Sender: TObject);
|
||||
procedure AfficherSignauxComplexes1Click(Sender: TObject);
|
||||
@@ -432,8 +430,9 @@ type
|
||||
|
||||
const
|
||||
MaxCellX=150;MaxCellY=70;
|
||||
licone=35;
|
||||
hicone=35;
|
||||
licone=26; // largeur icone du bas 35
|
||||
hicone=licone;
|
||||
Xicones=40; //début de la zone icones
|
||||
maxUndo=30;
|
||||
ZoomMax=(8191 div MaxCellX)-1; // pour ne pas dépasser un canvas de 8191 pixel maxi
|
||||
ZoomMin=15;
|
||||
@@ -554,7 +553,7 @@ var
|
||||
end;
|
||||
|
||||
rAncien : TRect;
|
||||
VBm,OldBmp : TBitMap;
|
||||
OldBmp : TBitMap;
|
||||
PScrollBoxTCO : TScrollBox;
|
||||
|
||||
// liste des variables par tco
|
||||
@@ -1599,7 +1598,7 @@ begin
|
||||
hauteurCell[indexTCO]:=(LargeurCell[indexTCO] * RatioC) div 10;
|
||||
largeurCelld2[indexTCO]:=largeurCell[indexTCO] div 2;
|
||||
HauteurCelld2[indexTCO]:=HauteurCell[indexTCO] div 2;
|
||||
Epaisseur:=LargeurCell[indexTCO]*epaisseur_voies div 30; // épaisseur du trait pour PEN
|
||||
|
||||
//Affiche(intToSTR(LargeurCell[indexTCO])+' '+intToSTR(epaisseur),clyellow);
|
||||
end;
|
||||
|
||||
@@ -1750,6 +1749,7 @@ begin
|
||||
Adr:=tco[indextco,x,y].adresse;
|
||||
if adr<>0 then
|
||||
begin
|
||||
pen.Width:=1;
|
||||
if detecteur[Adr].etat then
|
||||
begin
|
||||
brush.Color:=clAllume[indexTCO];
|
||||
@@ -1760,8 +1760,8 @@ begin
|
||||
pen.color:=tco[indextco,x,y].CouleurFond;
|
||||
brush.color:=tco[indextco,x,y].CouleurFond;
|
||||
end;
|
||||
jy1:=y0+(HauteurCell[indexTCO] div 2)-round(6*fryGlob[indexTCO]); // pos Y de la bande sup
|
||||
jy2:=y0+(HauteurCell[indexTCO] div 2)+round(6*fryGlob[indexTCO]); // pos Y de la bande inf
|
||||
jy1:=y0+(HauteurCell[indexTCO] div 2)-round(7*fryGlob[indexTCO]); // pos Y de la bande sup
|
||||
jy2:=y0+(HauteurCell[indexTCO] div 2)+round(7*fryGlob[indexTCO]); // pos Y de la bande inf
|
||||
if avecGrille[indexTCO] then r:=Rect(x0+1,jy1,xf-1,jy2) else
|
||||
r:=Rect(x0,jy1,x0+LargeurCell[indexTCO],jy2) ;
|
||||
FillRect(r);
|
||||
@@ -1773,8 +1773,7 @@ begin
|
||||
2 : couleur:=couleurTrain[TCO[IndexTCO,x,y].train];
|
||||
end;
|
||||
pen.color:=couleur;
|
||||
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 2 else
|
||||
pen.Width:=epaisseur;
|
||||
if testbit(ep,7) or testbit(ep,3) then pen.Width:=epaisseur div 2 else pen.Width:=epaisseur;
|
||||
moveTo(x0,yc);LineTo(xf,yc);
|
||||
end;
|
||||
end;
|
||||
@@ -3341,7 +3340,6 @@ begin
|
||||
pen.color:=tco[indextco,x,y].CouleurFond;
|
||||
brush.color:=tco[indextco,x,y].CouleurFond;
|
||||
end;
|
||||
// if avecGrille then r:=Rect(x0+1,jy1,x0+LargeurCell[indexTCO]-1,jy2) else
|
||||
pen.Width:=epaisseur+3;
|
||||
MoveTo(x0,y0);LineTo(x0+LargeurCell[indexTCO],y0+hauteurCell[indexTCO]);
|
||||
end;
|
||||
@@ -4667,8 +4665,8 @@ begin
|
||||
Brush.Color:=couleur;
|
||||
pen.color:=couleur;
|
||||
end;
|
||||
jx1:=x0+(LargeurCell[indexTCO] div 2)-round(6*frxGlob[indexTCO]); // pos Y de la bande sup
|
||||
jx2:=x0+(LargeurCell[indexTCO] div 2)+round(6*frxGlob[indexTCO]); // pos Y de la bande inf
|
||||
jx1:=x0+(LargeurCell[indexTCO] div 2)-round(7*frxGlob[indexTCO]); // pos Y de la bande sup
|
||||
jx2:=x0+(LargeurCell[indexTCO] div 2)+round(7*frxGlob[indexTCO]); // pos Y de la bande inf
|
||||
if avecGrille[indexTCO] then r:=Rect(jx1,y0+1,jx2,y0+hauteurCell[indexTCO]-1) else
|
||||
r:=Rect(jx1,y0,jx2,y0+hauteurCell[indexTCO]) ;
|
||||
FillRect(r);
|
||||
@@ -8394,6 +8392,7 @@ begin
|
||||
BImage:=tco[indextco,x,y].BImage;
|
||||
mode:=tco[indextco,x,y].mode; // mode pour la couleur
|
||||
repr:=tco[indextco,x,y].repr;
|
||||
Epaisseur:=LargeurCell[indexTCO]*epaisseur_voies div 30;
|
||||
|
||||
Xorg:=(x-1)*LargeurCell[indexTCO];
|
||||
Yorg:=(y-1)*hauteurCell[indexTCO];
|
||||
@@ -8498,7 +8497,7 @@ begin
|
||||
end;
|
||||
|
||||
// autres détecteurs
|
||||
if ((Bimage=7) or (Bimage=8) or (Bimage=9) or (Bimage=10) or (Bimage=17) or (Bimage=20)) and (adresse<>0) then
|
||||
if ((Bimage=7) or (Bimage=8) or (Bimage=9) or (Bimage=10) or (Bimage=17) ) and (adresse<>0) then
|
||||
begin // Adresse de l'élément
|
||||
with PCanvasTCO[indexTCO] do
|
||||
begin
|
||||
@@ -8510,6 +8509,22 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
// écriture adresse à 90°
|
||||
if (Bimage=20) and (adresse<>0) then
|
||||
begin
|
||||
with PCanvasTCO[indexTCO] do
|
||||
begin
|
||||
Brush.Color:=tco[indextco,x,y].CouleurFond;
|
||||
Font.Name:='Arial';
|
||||
Font.Style:=style(tco[indextco,x,y].FontStyle);
|
||||
Font.Color:=tco[indextco,x,y].coulFonte;
|
||||
PCanvasTCO[indexTCO].font.Size:=PCanvasTCO[indexTCO].font.Size+1;
|
||||
//TextOut(xOrg+round(2*frxGlob[indexTCO]),yOrg+round(2*fryGlob[indexTCO]),s);
|
||||
AffTexteIncliBordeTexture(PCanvasTCO[indexTCO],Xorg,yOrg+round(30*fryGlob[indexTCO]),
|
||||
PCanvasTCO[indexTCO].Font,clYellow,0,pmcopy,nil,s,910);
|
||||
end;
|
||||
end;
|
||||
|
||||
// autres détecteurs
|
||||
if (Bimage=18) and (adresse<>0) then
|
||||
begin // Adresse de l'élément
|
||||
@@ -8563,13 +8578,13 @@ begin
|
||||
end;
|
||||
if (Oriente=3) then
|
||||
begin
|
||||
if inverse then begin xt:=LargeurCell[indexTCO]+round(10*frxGlob[indexTCO]);yt:=hauteurCell[indexTCO]-round(16*fryGlob[indexTCO]);end
|
||||
else begin xt:=LargeurCell[indexTCO]+round(10*frxGlob[indexTCO]);yt:=round(1*fryGlob[indexTCO]);end;
|
||||
if inverse then begin xt:=round(10*frxGlob[indexTCO]);yt:=round(50*frxGlob[indexTCO]);end
|
||||
else begin xt:=round(60*frxGlob[indexTCO]);yt:=round(1*frxGlob[indexTCO])end;
|
||||
end;
|
||||
if (oriente=4) then
|
||||
begin
|
||||
if inverse then begin xt:=LargeurCell[indexTCO]+round(10*frxGlob[indexTCO]);yt:=hauteurCell[indexTCO]-round(16*fryGlob[indexTCO]);end
|
||||
else begin xt:=round(2*frxGlob[indexTCO]);yt:=round(1*fryGlob[indexTCO]);end;
|
||||
if inverse then begin xt:=round(40*frxGlob[indexTCO]);yt:=round(40*fryGlob[indexTCO]);end
|
||||
else begin xt:=round(2*frxGlob[indexTCO]);yt:=round(10*fryGlob[indexTCO]);end;
|
||||
end;
|
||||
end;
|
||||
if (aspect=9) and (Oriente=1) then begin xt:=LargeurCell[indexTCO]-round(25*frxGlob[indexTCO]);yt:=round(60*fryGlob[indexTCO]);end;
|
||||
@@ -8590,7 +8605,6 @@ begin
|
||||
if (aspect=5) and (Oriente=4) and (pied=1) then begin xt:=round(35*frxGlob[indexTCO]);yt:=round(1*frYGlob[indexTCO]);end;
|
||||
if (aspect=5) and (Oriente=4) and (pied=2) then begin xt:=round(3*frxGlob[indexTCO]);yt:=round(1*frYGlob[indexTCO]);end;
|
||||
|
||||
|
||||
if (aspect=4) and (Oriente=1) then begin xt:=1;yt:=hauteurCell[indexTCO]+round(20*fryGlob[indexTCO]);end;
|
||||
if (aspect=4) and (Oriente=2) then begin xt:=round(10*frxGlob[indexTCO]);yt:=hauteurCell[indexTCO];end;
|
||||
if (aspect=4) and (Oriente=3) then begin xt:=round(10*frxGlob[indexTCO]);yt:=-round(14*fryGlob[indexTCO]);end;
|
||||
@@ -8605,12 +8619,11 @@ begin
|
||||
if (aspect=3) and (Oriente=4) and (pied=1) then begin xt:=round(35*frxGlob[indexTCO]);yt:=round(1*frYGlob[indexTCO]);end;
|
||||
if (aspect=3) and (Oriente=4) and (pied=2) then begin xt:=round(3*frxGlob[indexTCO]);yt:=round(1*frYGlob[indexTCO]);end;
|
||||
|
||||
|
||||
if (aspect=2) and (Oriente=1) and (pied=2) then begin xt:=round(-15*frxGlob[indexTCO]);yt:=1;end; // signal à droite
|
||||
if (aspect=2) and (Oriente=1) and (pied=1) then begin xt:=round(45*frxGlob[indexTCO]);yt:=1;end; // signal à gauche
|
||||
if (aspect=2) and (Oriente=2) then begin xt:=round(10*frxGlob[indexTCO]);yt:=hauteurCell[indexTCO];end; // orientation G
|
||||
if (aspect=2) and (Oriente=3) then begin xt:=round(20*frxGlob[indexTCO]);yt:=round(40*fryGlob[indexTCO]);end; // orientation D
|
||||
if (aspect=2) and (Oriente=4) then begin xt:=round(35*frxGlob[indexTCO]);yt:=round(2*fryglob[indexTCO]);end; // orientation 180
|
||||
if (aspect=2) and (Oriente=4) then begin xt:=round(40*frxGlob[indexTCO]);yt:=round(10*fryglob[indexTCO]);end; // orientation 180
|
||||
|
||||
// signaux directionnels
|
||||
if (aspect>10) and (aspect<20) and(oriente=1) then begin xt:=1;yt:=hauteurCell[indexTCO]-round(14*fryGlob[indexTCO]);end;
|
||||
@@ -8691,6 +8704,7 @@ begin
|
||||
if pImageTCO[indexTCO]=nil then exit;
|
||||
DimX:=LargeurCell[indexTCO]*NbreCellX[indexTCO];
|
||||
DimY:=hauteurCell[indexTCO]*NbreCellY[indexTCO];
|
||||
Epaisseur:=LargeurCell[indexTCO]*epaisseur_voies div 30;
|
||||
// DimX DimY maxi 8191 pixels pour les bitmap
|
||||
if (dimX>8192) then begin Affiche('Espace TCO X trop grand',clred); exit; end;
|
||||
if (dimY>8192) then begin Affiche('Espace TCO Y trop grand',clred); exit; end;
|
||||
@@ -8833,9 +8847,6 @@ begin
|
||||
Top:=0;
|
||||
Left:=0;
|
||||
end;
|
||||
VBm:=TbitMap.Create; // masque
|
||||
Vbm.Width:=100;
|
||||
Vbm.Height:=100;
|
||||
oldbmp:=Tbitmap.Create;
|
||||
oldbmp.width:=100;
|
||||
oldbmp.Height:=100;
|
||||
@@ -10488,6 +10499,7 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
// positionne l'icone du groupe G2 (signal, quai, action)
|
||||
procedure positionne_icone_G2(IndexTCO : integer;ip : timage;lbl : tlabel;i : integer);
|
||||
const NbElLi=12;
|
||||
var s : string;
|
||||
@@ -10502,7 +10514,7 @@ begin
|
||||
begin
|
||||
width:=licone;
|
||||
height:=hicone;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+50;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+xicones;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+8;
|
||||
with canvas do
|
||||
begin
|
||||
@@ -10519,53 +10531,53 @@ begin
|
||||
s:=intToSTR(i+17);
|
||||
if i<10 then s:=' '+s;
|
||||
caption:=s;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+32;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+xicones-18;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+16;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
// dessine l'icone d'image ip et la place en x y d'après son index
|
||||
// positionne l'icone d'image ip et la place en x y d'après son index i
|
||||
procedure positionne_iconeLbIm(IndexTCO : integer;ip : timage;lbl : tlabel;i : integer);
|
||||
const NbElLi=12;
|
||||
var s : string;
|
||||
l : integer;
|
||||
l : integer;
|
||||
begin
|
||||
l:=formTCO[1].groupBox1.Width;
|
||||
|
||||
if (i>=32) and (i<=34) then dec(i,2);
|
||||
|
||||
if ip<>nil then
|
||||
begin
|
||||
with ip do
|
||||
begin
|
||||
width:=licone;
|
||||
height:=hicone;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+Xicones;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+8;
|
||||
with canvas do
|
||||
begin
|
||||
with ip do
|
||||
begin
|
||||
width:=licone;
|
||||
height:=hicone;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+50;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+8;
|
||||
with canvas do
|
||||
begin
|
||||
Pen.Color:=clFond[IndexTCO];
|
||||
Brush.color:=clFond[IndexTCO];
|
||||
Rectangle(0,0,licone,hicone);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
if lbl<>nil then
|
||||
begin
|
||||
with lbl do
|
||||
begin
|
||||
if (i=35) or (i=36) or (i=37) then s:=intToSTR(i+15) else
|
||||
if (i>=30) and (i<=32) then
|
||||
s:=intToSTR(i+2)
|
||||
else
|
||||
s:=intToSTR(i);
|
||||
if i<10 then s:=' '+s;
|
||||
caption:=s;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+32;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+16;
|
||||
end;
|
||||
Pen.Color:=clFond[IndexTCO];
|
||||
Brush.color:=clFond[IndexTCO];
|
||||
Rectangle(0,0,licone,hicone);
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
if lbl<>nil then
|
||||
begin
|
||||
with lbl do
|
||||
begin
|
||||
if (i=35) or (i=36) or (i=37) then s:=intToSTR(i+15) else
|
||||
if (i>=30) and (i<=32) then
|
||||
s:=intToSTR(i+2)
|
||||
else
|
||||
s:=intToSTR(i);
|
||||
if i<10 then s:=' '+s;
|
||||
caption:=s;
|
||||
left:=((i-1) mod NbElLi)*(licone+20)+l+Xicones-18;
|
||||
top:= ((i-1) div NbElLi)*(hicone+10)+16;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
// dessine les icones du tco et les aligne
|
||||
@@ -10577,6 +10589,8 @@ begin
|
||||
// d'abord on positionne les icones
|
||||
with formTCO[indexTCO] do
|
||||
begin
|
||||
|
||||
// groupe 1 les voies, les aiguillages, les TJD
|
||||
for i:=1 to 29 do
|
||||
begin
|
||||
ip:=findComponent('ImagePalette'+intToSTR(i)) as Timage;
|
||||
@@ -10623,7 +10637,7 @@ begin
|
||||
|
||||
// et puis on les dessine
|
||||
sauv_ep:=epaisseur;
|
||||
epaisseur:=4;
|
||||
epaisseur:=3;
|
||||
ancw:=LargeurCell[indexTCO];
|
||||
AncH:=hauteurCell[indexTCO];
|
||||
hauteurCell[indexTCO]:=ImagePalette1.Height;
|
||||
@@ -10695,8 +10709,8 @@ begin
|
||||
clLarge:=Width;
|
||||
clHaut:=Height;
|
||||
|
||||
panel1.width:=clLarge-20;
|
||||
Panel1.Top:=clHaut-Panel1.Height-64; // 64=entete de la fenetre
|
||||
panelBas.width:=clLarge-5;
|
||||
PanelBas.Top:=clHaut-PanelBas.Height-50; // 50=entete de la fenetre
|
||||
|
||||
with ScrollBox do
|
||||
begin
|
||||
@@ -10709,16 +10723,16 @@ begin
|
||||
if MasqueBandeauTCO then
|
||||
begin
|
||||
BandeauMasque:=true;
|
||||
Panel1.Hide;
|
||||
ScrollBox.Height:=clHaut-32;
|
||||
PanelBas.Hide;
|
||||
ScrollBox.Height:=clientHeight;
|
||||
end
|
||||
else
|
||||
begin
|
||||
BandeauMasque:=false;
|
||||
Panel1.show;
|
||||
ScrollBox.Height:=ClHaut-Panel1.Height-ScrollBox.Top-64;
|
||||
PanelBas.show;
|
||||
ScrollBox.Height:=ClHaut-PanelBas.Height-ScrollBox.Top-54;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFormTCO.FormActivate(Sender: TObject);
|
||||
@@ -10733,8 +10747,6 @@ begin
|
||||
{initalisation des dimensions du tco - à ne faire qu'une fois}
|
||||
if not(Forminit[indexTCO]) then
|
||||
begin
|
||||
Button1.Visible:=not(Diffusion);
|
||||
Button2.Visible:=not(Diffusion);
|
||||
ButtonCalibrage.Visible:=not(diffusion);
|
||||
ButtonSimu.Visible:=not(Diffusion);
|
||||
ImageTemp.Visible:=not(Diffusion);
|
||||
@@ -11427,12 +11439,16 @@ begin
|
||||
|
||||
l:=image.Width;
|
||||
h:=image.height;
|
||||
|
||||
// ImageTemp <- imageicone
|
||||
StretchBlt(formTCO[indexTCO].ImageTemp.canvas.Handle,0,0,LargeurCell[indexTCO],hauteurCell[indexTCO], // destination avec mise à l'échelle
|
||||
image.Canvas.Handle,0,0,l,h,srccopy);
|
||||
|
||||
//dessin_1(indexTCO,formTCO[indexTCO].ImageTemp.Canvas ,1,1,0);
|
||||
|
||||
// OldBMP<-ImageTCO ; sauve le bitmap sous le pointeur de la souris
|
||||
BitBlt(OldBmp.Canvas.Handle,0,0,LargeurCell[indexTCO],hauteurCell[indexTCO],FormTCO[IndexTCO].ImageTCO.Canvas.Handle,offsetSourisX,offsetSourisY,SRCCOPY);
|
||||
StretchBlt(Vbm.Handle,0,0,LargeurCell[indexTCO],hauteurCell[indexTCO], // destination masque avec mise à l'échelle
|
||||
image.Canvas.Handle,0,0,l,h,srccopy);
|
||||
|
||||
drag:=true;
|
||||
TCODrag:=indexTCO;
|
||||
oldx:=offsetSourisX;
|
||||
@@ -11455,11 +11471,13 @@ begin
|
||||
Accept:=source is TImage;
|
||||
if drag then
|
||||
begin
|
||||
// canvasTCO<-oldBMP restitue l'ancien en oldx,oldy fond avant le nouveau
|
||||
BitBlt(PImageTCO[indexTCO].canvas.handle,oldx,oldy,LargeurCell[indexTCO],hauteurCell[indexTCO],oldbmp.canvas.handle,0,0,SRCCOPY); // remettre la sauvegarde du bitmap à l'ancienne position souris
|
||||
// oldbmp(0,0)<-canvasTCO(x1,y1) sauve le nouveau bitmap en x1,y1
|
||||
BitBlt(oldbmp.canvas.handle,0,0,LargeurCell[indexTCO],hauteurCell[indexTCO],PImageTCO[IndexTCO].canvas.handle,xl,yl,SRCCOPY); // sauvegarder le bitmap actuel sous la souris
|
||||
oldx:=xl; oldy:=yl;
|
||||
BitBlt(PImageTCO[indexTCO].canvas.handle,xl,yl,LargeurCell[indexTCO],hauteurCell[indexTCO],Vbm.canvas.handle,0,0,SRCAND); // prendre le masque de l'icone vers la souris, ne change rien...
|
||||
BitBlt(PImageTCO[indexTCO].canvas.handle,xl,yl,LargeurCell[indexTCO],hauteurCell[indexTCO],formTCO[indexTCO].ImageTemp.canvas.handle,0,0,SRCPAINT); // copier l'icone vers la souris
|
||||
// canvasTCO(x1,y1)<-ImageTemp(0,0)
|
||||
BitBlt(PImageTCO[indexTCO].canvas.handle,xl,yl,LargeurCell[indexTCO],hauteurCell[indexTCO],formTCO[indexTCO].ImageTemp.canvas.handle,0,0,SRCCOPY); // copier l'icone vers la souris
|
||||
PImageTCO[IndexTCO].Repaint;
|
||||
end;
|
||||
end;
|
||||
@@ -11793,12 +11811,13 @@ begin
|
||||
c:=c.GetParentComponent; // formTCO
|
||||
indexTCO:=index_tco(c);
|
||||
for y:=TamponTCO_Org.y1 to TamponTCO_Org.y2 do // rectangle de la sélection
|
||||
for x:=TamponTCO_Org.x1 to TamponTCO_Org.x2 do
|
||||
begin
|
||||
xPlace:=XclicCell[indexTCO]+x-TamponTCO_Org.x1; // destination
|
||||
yPlace:=YclicCell[indexTCO]+y-TamponTCO_Org.y1;
|
||||
if (xPlace<=NbreCellX[indexTCO]) and (yPlace<=NbreCellY[indexTCO]) then tco[indextco,xPlace,yPlace]:=tampontco[x,y];
|
||||
end;
|
||||
for x:=TamponTCO_Org.x1 to TamponTCO_Org.x2 do
|
||||
begin
|
||||
xPlace:=XclicCell[indexTCO]+x-TamponTCO_Org.x1; // destination
|
||||
yPlace:=YclicCell[indexTCO]+y-TamponTCO_Org.y1;
|
||||
if (xPlace<=NbreCellX[indexTCO]) and (yPlace<=NbreCellY[indexTCO]) then tco[indextco,xPlace,yPlace]:=tampontco[x,y];
|
||||
end;
|
||||
selectionaffichee[indexTCO]:=false;
|
||||
Affiche_TCO(indexTCO);
|
||||
TCO_modifie:=true;
|
||||
ligne_supprime:=0;
|
||||
@@ -12877,21 +12896,23 @@ begin
|
||||
defocusControl(ButtonConfigTCO,true);
|
||||
end;
|
||||
|
||||
// dépose un signal
|
||||
procedure TFormTCO.ImagePalette50EndDrag(Sender, Target: TObject; X, Y: Integer);
|
||||
var indexTCO,Xclic,Yclic : integer;
|
||||
begin
|
||||
if not(Target is TImage) then exit;
|
||||
if (x=0) and (y=0) then exit;
|
||||
indexTCO:=index_TCO(sender);
|
||||
|
||||
xclicCell[indexTCO]:=(x div LargeurCell[indexTCO]) +1;
|
||||
yclicCell[indexTCO]:=(y div LargeurCell[indexTCO]) +1;
|
||||
|
||||
xclic:=xclicCell[indexTCO];
|
||||
yclic:=yclicCell[indexTCO];
|
||||
|
||||
BitBlt(formTCO[indexTCO].imageTCO.canvas.handle,oldx,oldy,LargeurCell[indexTCO],hauteurCell[indexTCO],oldbmp.canvas.handle,0,0,SRCCOPY);
|
||||
efface_entoure(indexTCO);
|
||||
TCO_modifie:=true;
|
||||
Xclic:=X;YClic:=Y;
|
||||
Xclic:=Xclic div LargeurCell[indexTCO] +1;
|
||||
Yclic:=Yclic div hauteurCell[indexTCO] +1;
|
||||
stocke_undo(indexTCO,1,XClic,YClic);
|
||||
maj_undo(1);
|
||||
efface_cellule(indexTCO,formTCO[indexTCO].ImageTCO.Canvas,XClic,YClic,PmCopy);
|
||||
@@ -12900,7 +12921,9 @@ begin
|
||||
tco[indextco,XClic,YClic].FeuOriente:=1;
|
||||
tco[indextco,XClic,YClic].PiedFeu:=1;
|
||||
tco[indextco,XClic,YClic].coulFonte:=clWhite;
|
||||
// ne pas convertir l'adresse sinon evt changement du composant et on écrase l'aspect EditAdrElement.Text:=IntToSTR( tco[indextco,XClicCell,YClicCell].Adresse);
|
||||
clicTCO:=true;
|
||||
editAdrElement.Text:='';
|
||||
clicTCO:=false;
|
||||
EdittypeImage.Text:=IntToSTR(tco[indextco,XClic,YClic].BImage);
|
||||
Dessin_Signal(indexTCO,formTCO[indexTCO].ImageTCO.Canvas,XClic,YClic);
|
||||
end;
|
||||
@@ -13229,7 +13252,7 @@ end;
|
||||
|
||||
procedure TFormTCO.ButtonMasquerClick(Sender: TObject);
|
||||
begin
|
||||
Panel1.Hide;
|
||||
PanelBas.Hide;
|
||||
ScrollBox.Height:=ClientHeight-32;
|
||||
BandeauMasque:=true;
|
||||
defocusControl(ButtonMasquer,true);
|
||||
@@ -13435,7 +13458,7 @@ end;
|
||||
procedure TFormTCO.ImagePalette51EndDrag(Sender, Target: TObject; X,
|
||||
Y: Integer);
|
||||
begin
|
||||
end_drag(51,x,y,sender,target);
|
||||
end_drag(id_Quai,x,y,sender,target);
|
||||
end;
|
||||
|
||||
|
||||
@@ -13547,7 +13570,7 @@ begin
|
||||
accept:=true;
|
||||
end;
|
||||
|
||||
procedure TFormTCO.Panel1DragOver(Sender, Source: TObject; X, Y: Integer;
|
||||
procedure TFormTCO.PanelBasDragOver(Sender, Source: TObject; X, Y: Integer;
|
||||
State: TDragState; var Accept: Boolean);
|
||||
begin
|
||||
accept:=true;
|
||||
@@ -14385,13 +14408,26 @@ begin
|
||||
Affiche_TCO(indexTCO);
|
||||
end;
|
||||
|
||||
procedure TFormTCO.Affichebandeau1Click(Sender: TObject);
|
||||
procedure TFormTCO.BandeauClick(Sender: TObject);
|
||||
var indexTCO : integer;
|
||||
begin
|
||||
indexTCO:=index_TCOMainMenu;
|
||||
Panel1.Show;
|
||||
positionne(indexTCO);
|
||||
BandeauMasque:=false;
|
||||
if bandeauMasque then
|
||||
begin
|
||||
PanelBas.Show;
|
||||
BandeauMasque:=false;
|
||||
positionne(indexTCO);
|
||||
Bandeau.Caption:='Masquer le bandeau';
|
||||
exit;
|
||||
end
|
||||
else
|
||||
begin
|
||||
PanelBas.Hide;
|
||||
ScrollBox.Height:=ClientHeight;
|
||||
BandeauMasque:=true;
|
||||
defocusControl(ButtonMasquer,true);
|
||||
Bandeau.Caption:='Afficher le bandeau';
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TFormTCO.Mosaquehorizontale1Click(Sender: TObject);
|
||||
|
||||
+1
-1
@@ -25,7 +25,7 @@ var
|
||||
verifVersion,notificationVersion : boolean;
|
||||
date_creation,nombre_tel : string;
|
||||
|
||||
Const Version='8.37'; // sert à la comparaison de la version publiée
|
||||
Const Version='8.38'; // sert à la comparaison de la version publiée
|
||||
SousVersion=' '; // A B C ... en cas d'absence de sous version mettre un espace
|
||||
|
||||
function GetCurrentProcessEnvVar(const VariableName: string): string;
|
||||
|
||||
+4
-1
@@ -222,4 +222,7 @@ version 8.35 : Correction ajout de signaux et d'aiguillages.
|
||||
version 8.36 : Création d'un mode de fond sombre modifiable pour l'affichage.
|
||||
Amélioration édition des lignes et colonnes du TCO.
|
||||
version 8.37 : Correction des calculs des index des aiguillages et des signaux lors de leur suppression.
|
||||
Correction présence trains avant signal.
|
||||
Correction présence trains avant signal.
|
||||
version 8.38 : Ajout de l'importation depuis le réseau CDM rail des bretelles double jonction, ce qui crée 4 aiguillages et un croisement.
|
||||
Amélioration du traitement des trames inconnues en XpressNet.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user