
! script name: draft.d/makeuserchar
! topic: make font characters

!A
!A NAME:
!A
!A 	Make User Character
!A
!A DESCRIPTION:
!A
!A 	This script allows the user to make their own font characters.
!A 	The characters should be made within a one inch square.
!A
!B INSTRUCTIONS:
!B
!B 	FONT NUMBER ( 1 ) ( 2 ) ( 3 ): Enter the font number to be used for
!B 		calling out the characters created.
!B
!B 	CHARACTER NUMBER: Enter the number (0-255) to be associated with the
!B 		new character.
!B
!B 	SELECT VIEW FOR SELECTION BOX: Pick view that the new character is in.
!B
!B 	PICK FIRST CORNER OF PICK ZONE: Pick a corner of the box.
!B
!B 	PICK SECOND CORNER OF PICK ZONE: Pick the other corner of the view box.
!B

stat=ChangeLabelStr("ScriptNameStatus","Function: make user character ")

DIM Destination$[256]
DIM Answer$[256]

DEG

fontnum=1

Stat=SetInputFormat("n0=","")
Stat= SetEqualsValue(fontnum)
fontnum=GetValue("FONT NUMBER ( 1 ) ( 2 ) ( 3 )",Answer$)
IF (ExitScript(Destination$)) THEN Leave

Group_loop:!
stat= SetInputFormat("n0","")
Char_num= GetValue("CHARACTER NUMBER",Answer$)
IF (ExitScript(Destination$)) THEN Leave

Group=CreateGroup("TEMPGROUP")
Vnum=PickView("SELECT VIEW FOR SELECTION BOX")
IF (ExitScript(Destination$)) THEN Leave

Stat=PickBox(Group,Vnum,WsPickPen)
IF (ExitScript(Destination$)) THEN Leave

stat= MakeUserChar(Group,Char_num,fontnum)

GOTO Group_loop

Leave:!
stat= SetInputFormat("n4","")
Stat=DeleteEntity(Group)
IF (NOT LEN(Destination$)) THEN
	 LOAD "typecontrol"
ELSE
	 LOAD Destination$
END IF
END
