.GUI AlphaCS
#Axiom(RUNPRGM)
#Axiom(ZSTAXE)
Lbl DLIST
ClrDraw
ClrDraw^^r
sub(D1,0,0)
RectI(0,11,96,1)
!If sub(POLAR,1)
	RectI(0,63,96,1)
	Text(1,13,"No programs found.")
	DispGraph
	Goto KLIST2
	Else
	Fill(L5,50,0)
	Copy(L1,L5,20)
	13->B->G
	0->I
	1->H
	Text(1,13,L2)
	If D
		Pt-On(77,13,Pic21)
	End
	If E
		Pt-On(83,13,Pic22)
	End
	If F
		Pt-On(89,13,Pic23)
	End
	For(S,1,6)
		If sub(ADJ,1)
			S*7+13->G
			Text(1,S*7+13,L2)
			If D
				Pt-On(77,S*7+13,Pic21)
			End
			If E
				Pt-On(83,S*7+13,Pic22)
			End
			If F
				Pt-On(89,S*7+13,Pic23)
			End
		End
	End
End
Fill(L4,50,0)
Copy(L1,L4,20)
Lbl KLIST1
Rect(90,0,6,10)
RectI(90,0,6,10)
0->S->T
sub(POLAR,1)
If Equ>String(L1,L5)
	S++
End
sub(POLAR,0)
If Equ>String(L1,L4)
	T++
End
If (S) and (T)
	Pt-On(90,6,[F870200000000000])
	Pt-On(90,2,[2070F80000000000])
	Else
	If S
		Pt-On(90,4,[2070F80000000000])
	End
	If T
		Pt-On(90,4,[F870200000000000])
	End
End
RectI(0,63,96,1)
RectI(0,B,96,7)
DispGraph
RectI(0,B,96,7)
RectI(0,63,96,1)
If getKey(15)
	Goto DLIST
End
Repeat getKey
	If getKey(41)
		Repeat getKey(41)=0
		End
		Asm(3E01D303FB76)
		Repeat getKey(41)=0
		End
	End
End
If getKey(48)
	Goto DSET1
End
If (getKey(9)) or (getKey(54))
	Fill(L1,50,0)
	Copy(L5,L1,20)
	If (B-13/7)=0
		Fill(L1,50,0)
		Copy(L5+1,L1,20)
		sub(DATA)
		Else
		For(B-13/7)
			sub(ADJ,1)
		End
	End
	Goto DPRGM1
End
If getKey(4)
	If (B!=13)
		For(S,0,7)
			RectI(0,63,96,1)
			RectI(0,B-S,96,7)
			DispGraph
			RectI(0,B-S,96,7)
			RectI(0,63,96,1)
		End
		B-7->B
		Else
		sub(POLAR,1)
		If Equ>String(L1,L5)
			Fill(L1,50,0)
			Copy(L4,L1,20)
			sub(ADJ,0)
			Fill(L4,50,0)
			Copy(L1,L4,20)
			Fill(L1,50,0)
			Copy(L5,L1,20)
			sub(ADJ,0)
			Fill(L5,50,0)
			Copy(L1,L5,20)
			Fill(L1,50,0)
			Copy(L4,L1,20)
			Rect(0,0,96,13)
			RectI(0,0,96,13)
			For(7)
				Vertical+
			End
			Rect(0,62,96,2)
			RectI(0,62,96,2)
			Text(1,13,L2)
			If D
				Pt-On(77,13,Pic21)
			End
			If E
				Pt-On(83,13,Pic22)
			End
			If F
				Pt-On(89,13,Pic23)
			End
			Rect(0,0,96,13)
			RectI(0,0,96,13)
			sub(D1,0,0)
			RectI(0,11,96,1)
		End
	End
End
If getKey(1)
	If (B!=G)
		For(S,0,7)
			RectI(0,63,96,1)
			RectI(0,B+S,96,7)
			DispGraph
			RectI(0,B+S,96,7)
			RectI(0,63,96,1)
		End
		B+7->B
		Else
		sub(POLAR,0)
		If Equ>String(L1,L4)
			Fill(L1,50,0)
			Copy(L5,L1,20)
			sub(ADJ,1)
			Fill(L5,50,0)
			Copy(L1,L5,20)
			Fill(L1,50,0)
			Copy(L4,L1,20)
			sub(ADJ,1)
			Fill(L4,50,0)
			Copy(L1,L4,20)
			For(7)
				Vertical-
			End
			Text(1,55,L2)
			If D
				Pt-On(77,55,Pic21)
			End
			If E
				Pt-On(83,55,Pic22)
			End
			If F
				Pt-On(89,55,Pic23)
			End
			Rect(0,0,96,13)
			RectI(0,0,96,13)
			sub(D1,0,0)
			RectI(0,11,96,1)
		End
	End
End
If getKey(15)
	Goto END
End
Goto KLIST1
Lbl KLIST2
If getKey(15)
	Goto DLIST
End
Repeat getKey
	If getKey(41)
		Repeat getKey(41)=0
		End
		Asm(3E01D303FB76)
		Repeat getKey(41)=0
		End
	End
End
If getKey(48)
	Goto DSET1
End
If getKey(15)
	Goto END
End
Goto KLIST2
Lbl DPRGM1
GetCalc("appv alpha ",[Y1])
13->B
D->X
E->Y
F->Z
Lbl DPRGM2
GetCalc(L1,[Y3])
0->H
If ({[Y3]+0}=187) and ({[Y3]+1}=109)
	1->H
	If {[Y3]+2}=201
		2->H
	End
	If {[Y3]+3}=201
		3->H
	End
End
If {[Y3]+0}=58
	4->H
End
ClrDraw
ClrDraw^^r
sub(D1,0,0)
RectI(0,11,96,1)
Text(1,49,L2)
RectI(0,48,96,16)
69->S
If Z
	Pt-Change(S,56,Pic23)
	S-6->S
End
If Y
	Pt-Change(S,56,Pic22)
	S-6->S
End
If X
	Pt-Change(S,56,Pic21)
End
RectI(1,56,94,7)
Text(2,56,"size: ",{[Y3]-2}^^r>Dec)
Text(1,13,"Run (with zStart)")
If X
	Text(1,20,"Unarchive PRGM")
	Else
	Text(1,20,"Archive PRGM")
End
If Y
	Text(1,27,"Unhide PRGM")
	Else
	Text(1,27,"Hide PRGM")
End
If Z
	Text(1,34,"Unlock PRGM")
	Else
	Text(1,34,"Lock PRGM")
End
Rect(76,44,20,20)
RectI(77,45,18,18)
If H=0
	Bitmap(78,46,GDB11)
End
If H=1
	Bitmap(78,46,GDB13)
End
If H=2
	Bitmap(78,46,GDB14)
End
If H=3
	Bitmap(78,46,GDB14)
End
If H=4
	Bitmap(78,46,GDB12)
End
Lbl KPRGM
RectI(0,B,96,7)
DispGraph
RectI(0,B,96,7)
Repeat getKey
End
If (getKey(9)) or (getKey(54))
	If B=13
		sub(SETPRGM)
		Goto RUN
		Else
		Fill(L2,20,0)
		Copy(L1+1,L2,20)
		Fill(L1,20,0)
		Copy(L2,L1,20)
		sub(DATA)
		If B=20
			If X
				0->X
				Else
				1->X
			End
			Goto DPRGM2
		End
		If B=27
			If Y
				0->Y
				Else
				1->Y
			End
			Goto DPRGM2
		End
		If B=34
			If Z
				0->Z
				Else
				1->Z
			End
			Goto DPRGM2
		End
	End
End
If (getKey(4)) and (B!=13)
	For(S,0,7)
		RectI(0,B-S,96,7)
		DispGraph
		RectI(0,B-S,96,7)
		Normal
		Pause 3
		Full
	End
	B-7->B
End
If ((getKey(1)) and (B!=34)
	For(S,0,7)
		RectI(0,B+S,96,7)
		DispGraph
		RectI(0,B+S,96,7)
		Normal
		Pause 3
		Full
	End
	B+7->B
End
If getKey(15)
	sub(SETPRGM)
	Goto DLIST
End
Goto KPRGM
Lbl SETPRGM
If (X!=D) or (Y!=E) or (Z!=F)
	If X
		sub(D3)
		DispGraph
	End
	UnArchive L1
	X->D
	If (E!=Y)
		If Y
			{C-7}-64->{C-7}
			{L1+1}-64->{L1+1}
			Else
			{C-7}+64->{C-7}
			{L1+1}+64->{L1+1}
		End
		Y->E
	End
	If (F!=Z)
		If Z
			6->{C}
			|E06->{L1}
			Else
			5->{C}
			|E05->{L1}
		End
		Z->F
	End
	If X
		Archive L1
	End
End
GetCalc(L1,[Y3])
Return
Lbl RUN
GetCalc("appv hold ",20)->S
Fill(S,20,0)
Copy(L1+1,S,10)
A->{S+15}
DiagnosticOn
Fix 4
Normal
If D
	GetCalc("appvzRun",{[Y3]-2}^^r)->S
	Copy([Y3],S,{[Y3]-2}^^r)
End
2-SampZInt(|LRUNERR)
If D
	Fpdf("appvzRun")
	Else
	Fpdf(L1)
End
2-SampTInt 
DelVar "appvzRun"
GetCalc("appv hold ")->S
Fill(L1,20,0)
Copy(S,L1,10)
{S+15}->A
sub(DATA)
DelVar "appv hold "
DiagnosticOff
Fix 5
Full
Repeat getKey=0
End
Goto DPRGM1
Lbl RUNERR
2-SampFTest ->S
DelVar "appvzRun"
DiagnosticOff
Fix 5
Full
sub(D2,10,22,76,20,"Error")
If S=8
	Text(12,31,"Syntax")
	Else
	Text(12,31,"Error "[23]"",S>Dec)
End
DispGraph
Repeat (getKey) and (getKey(9))
End
GetCalc("appv hold ")->S
Fill(L1,20,0)
Copy(S,L1,10)
{S+15}->A
sub(DATA)
DelVar "appv hold "
DiagnosticOff
Fix 5
Full
Repeat getKey=0
End
Goto DPRGM1
Lbl DSET1
21->B
{[Y1]+5}->X
{[Y1]}->Y
{[Y1]+6}->Z
Lbl DSET2
ClrDraw
sub(D1,0,0)
RectI(0,11,96,1)
Text(1,12,"by ClrDraw, Nov 2013, v 1")
RectI(0,19,96,1)
RectI(0,63,96,1)
If X
	Text(1,21,"Show Hidden On")
	Else
	Text(1,21,"Show Hidden Off")
End
If Y
	Text(1,28,"Password On")
	Else
	Text(1,28,"Password Off")
End
If Z
	Text(1,35,"Lowercase On")
	Else
	Text(1,35,"Lowercase Off")
End
Text(1,42,"Uninstall AlphaCS")
Lbl KSET
RectI(0,B,96,7)
DispGraph
RectI(0,B,96,7)
Repeat getKey
End
If (getKey(54)) or (getKey(9))
	If B=21
		If X
			0->X
			Else
			1->X
		End
		Goto DSET2
	End
	If B=28
		If Y
			0->Y
			Else
			1->Y
		End
		Goto DSET2
	End
	If B=35
		If Z
			0->Z
			Else
			1->Z
		End
		Goto DSET2
	End
	If B=42
		If sub(CODE)
			DelVar Str1
			Goto END
			Else
			Goto DSET2
		End
	End
End
If (getKey(4)) and (B!=21)
	For(7)
		RectI(0,B,96,7)
		DispGraph
		RectI(0,B,96,7)
		B--
		Normal
		Pause 3
		Full
	End
End
If (getKey(1)) and (B!=42)
	For(7)
		RectI(0,B,96,7)
		DispGraph
		RectI(0,B,96,7)
		B++
		Normal
		Pause 3
		Full
	End
End
If getKey(15)
	If ({[Y1]+5}!=X) or ({[Y1]}!=Y) or ({[Y1]+6}!=Z)
		UnArchive Str1
		GetCalc(Str1)->S
		X->{S+5}
		Y->{S}
		Z->{S+6}
		sub(D3)
		DispGraph
		Archive Str1
		GetCalc(Str1,[Y1])
	End
	Repeat getKey=0
	End
	Goto DLIST
End
Goto KSET