#-------------------------------------------------------------------------------
#
#	Name    : AspicScript
#	Purpose : Display Aspic script files
#	Author  :  JMB & FJG
#	Licence : Freeware
#	Version : 1.01, 29.08.24
#
#-------------------------------------------------------------------------------
# 27.07.24 JMB Initial version (named AspicGraph) by Jean-Michel Brck
# 29.08.24 FJG Changed mode name to more accurate AspicScript (IMHO)
#          FJG Changed SyntaxWords groups for more logical grouping
#          FJG Added a SyntaxWords group to colour label references
#          FJG Made SyntaxWords groups case-sensitive (as Aspic is)
#          FJG Use ID definitions to colour variables
#===============================================================================

HelpPath	DrWimpC,C-Version5,C++,C,OS,Wimp,MiscSWIs,InetSWIs,InetSocket,VDU,Toolbox,Desk,OSLib,UnixLib,Temporaries,

ID_FirstChar	$A-Za-z
ID_Middle	A-Za-z0-9

#-------------------------------------------------------------------------------

Search
	Label		{'A-Z0-9'} ":"
	LabelRef	{'A-Z0-9'} @9 " " | (";" >)
End

#-------------------------------------------------------------------------------

SyntaxOptions
	SingleQuote	No
	DoubleQuote	Yes
	QuoteQuote	No
	SplitString	No
	Numbers		Int
	HexPrefix	&
	Binprefix	%
	Numbers		flt
End

SyntaxComment 1
	CommentType	OneLine
	StartWhere	AnyWhere
	StartWith	#
End

Search
#	index		< "Index ">
	diffcontent	< (' !'|("+" ~"+")|("-" ~"-")) * >
	diff		 diffcontent NL
End



# Environment cmds
SyntaxWords Group1 Case EndAlways
	bLength bDescriptorType  bcdUSB
	Interface Endpoint
End

# Global commands
SyntaxWords Group2 Case EndAlways
	 bConfigurationValue  iConfiguration
End

# Drawing commands
SyntaxWords Group3 Case EndAlways
	bInterfaceClass bInterfaceSubClass  bInterfaceProtocol
	iInterface  bInterfaceNumber
End

# Command options
SyntaxWords Group4 Case EndAlways
	bAlternateSetting  bNumEndpoints  bNumInterfaces
	bEndpointAddress  Standard
End

# Directions/Level
SyntaxWords Group5 Case EndAlways
	bmAttributes wMaxPacketSize bMaxPacketSize
End

# Object positions
SyntaxWords Group6 Case EndAlways
	 Descriptor
End

# Object relations
SyntaxWords Group7 Case EndAlways
	bDeviceClass bDeviceSubClass bDeviceProtocol
	
End

# Label definition
SyntaxWords Group8 Case EndOfExpr LabelRef
	"Audio" "Video"
End



# Filenames (light blue)
SyntaxWords Group9 Case StartOfLine EndOfLine
##	: Index:
End


# segment and sub-segment separators (yellow)
SyntaxWords Group10 Case 
##	segment separators
#	diff -c
	***
#	diff -u
	@@
##	sub-segment separators
#	diff & diff -c
	"---"
	"+----+"
End
# file separators (purple)
SyntaxWords Group11 Case StartOfLine EndOfLine
#	diff, diff -c & diff -u
	=============================================
End

# Label reference
SyntaxWords Group12 Case EndOfExpr LabelRef
	"Isochronous" "Streaming" "streaming"
End
#-------------------------------------------------------------------------------



#-------------------------------------------------------------------------------
