# Define SciTE settings for MapServer's MAP files.
# This settings is based on lua.properties file
# Modification by Ruslan Nuryadin (nuryadin@gmail.com)
# Last modified on June 9th, 2008

file.patterns.lua=*.map

filter.lua=MapServer (map)|$(file.patterns.lua)|

lexer.$(file.patterns.lua)=lua

word.chars.lua=$(chars.alpha)$(chars.numeric)$(chars.accented)_%
word.characters.$(file.patterns.lua)=$(word.chars.lua)

keywordclass.lua=\
END METADATA MAP OUTPUTFORMAT LABEL LAYER CLASS STYLE FEATURE LEGEND QUERYMAP JOIN \
REFERENCE SCALEBAR WEB PROJECTION GRID \
end metadata map outputformat label layer class style feature legend querymap join \
reference scalebar web projection grid 

keywords.$(file.patterns.lua)=$(keywordclass.lua)

# Basic Functions (in both versions of Lua)
keywordclass2.lua=
#### Lua 4.0
# Basic Functions
keywordclass2.lua4=\
ON OFF EMBED DEFAULT TRUE TRUETYPE FALSE HILITE BITMAP \
GD GIF PNG JPEG WBMP GTIFF SWF X-SHOCKWAVE-FLASH APPLICATION \
FEET INCHES KILOMETERS METERS MILES DD \
PC256 RGB RGBA INT16 FLOAT32 \
UL UC UR CL CC CR LL LC LR AUTO \
TINY SMALL MEDIUM LARGE GIANT \
LOCAL SDE OGR POSTGIS ORACLESPATIAL VMS \
PIXELS \
POINT LINE POLYGON CIRCLE ANNOTATION RASTER QUERY \
MULTIPLE SINGLE \
DDMM DDMMSS \
ONE-TO-ONE ONE-TO-MANY \
AGG AGGA \
on off embed default true truetype false hilite bitmap \
gd gif png jpeg wbmp gtiff swf x-shockwave-flash application \
feet inches kilometers meters miles dd \
pc256 rgb rgba int16 float32 \
ul uc ur cl cc cr ll lc lr auto \
tiny small medium large giant \
local sde ogr postgis oraclespatial vms \
pixels \
point line polygon circle annotation raster query \
multiple single \
ddmm ddmmss \
one-to-one one-to-many \
agg agga

# String Manipulation & Mathematical Functions
keywordclass3.lua4=
# Input and Output Facilities & System Facilities
keywordclass4.lua4=\
CONFIG DATAPATTERN DEBUG EXTENT FONTSET IMAGECOLOR IMAGEQUALITY IMAGETYPE INTERLACE MAXSIZE NAME \
RESOLUTION SCALE SHAPEPATH SIZE STATUS SYMBOLSET TEMPLATEPATTERN TRANSPARENT UNITS DRIVER IMAGEMODE MIMETYPE EXTENSION \
TRANSPARENT FORMATOPTION ANGLE ANTIALIAS BACKGROUNDCOLOR BACKGROUNDSHADOWCOLOR BACKGROUNDSHADOWSIZE BUFFER COLOR \
FONT FORCE MAXSIZE MINDISTANCE MINFEATURESIZE MINSIZE OFFSET OUTLINECOLOR PARTIALS POSITION SHADOWCOLOR SHADOWSIZE \
SIZE TYPE WRAP CLASSITEM CONNECTION CONNECTIONTYPE DATA DEBUG DUMP FILTER FILTERITEM FOOTER GROUP LABELANGLEITEM \
LABELCACHE LABELITEM LABELMAXSCALE LABELMINSCALE LABELREQUIRES LABELSIZEITEM MAXFEATURES MAXSCALE MINSCALE \
OFFSITE POSTLABELCACHE PROCESSING REQUIRES SIZEUNITS STATUS STYLEITEM SYMBOLSCALE TEMPLATE TILEINDEX TILEITEM \
TOLERANCE TOLERANCEUNITS TRANSPARENCY TRANSFORM BACKGROUNDCOLOR DEBUG EXPRESSION KEYIMAGE OUTLINECOLOR SIZE SYMBOL \
TEXT ANTIALIAS POINTS INTERLACE POSITION KEYSIZE KEYSPACING TRANSPARENT FROM TO IMAGE MARKER MARKERSIZE \
MINBOXSIZE MAXBOXSIZE INTERLACE INTERVALS EMPTY ERROR FOOTER HEADER IMAGEPATH IMAGEURL LOG MAXTEMPLATE MINTEMPLATE \
LABELFORMAT MINARCS MAXARCS MININTERVAL MAXINTERVAL MINSUBDIVIDE MAXSUBDIVIDE \
INCLUDE OVERLAYBACKGROUNDCOLOR OVERLAYCOLOR OVERLAYOUTLINECOLOR OVERLAYSIZE OVERLAYMINSIZE OVERLAYMAXSIZE OVERLAYSYMBOL \
MAXSCALEDENOM MINSCALEDENOM SYMBOLSCALEDENOM TABLE ENCODING PRIORITY \
config datapattern debug extent fontset imagecolor imagequality imagetype interlace maxsize name \
resolution scale shapepath size status symbolset templatepattern transparent units driver imagemode mimetype extension \
transparent formatoption angle antialias backgroundcolor backgroundshadowcolor backgroundshadowsize buffer color \
font force maxsize mindistance minfeaturesize minsize offset outlinecolor partials position shadowcolor shadowsize \
size type wrap classitem connection connectiontype data debug dump filter filteritem footer group labelangleitem \
labelcache labelitem labelmaxscale labelminscale labelrequires labelsizeitem maxfeatures maxscale minscale \
offsite postlabelcache processing requires sizeunits status styleitem symbolscale template tileindex tileitem \
tolerance toleranceunits transparency transform backgroundcolor debug expression keyimage outlinecolor size symbol \
text antialias points interlace position keysize keyspacing transparent from to image marker markersize \
minboxsize maxboxsize interlace intervals empty error footer header imagepath imageurl log maxtemplate mintemplate \
labelformat minarcs maxarcs mininterval maxinterval minsubdivide maxsubdivide \
include overlaybackgroundcolor overlaycolor overlayoutlinecolor overlaysize overlayminsize overlaymaxsize overlaysymbol \
maxscaledenom minscaledenom symbolscaledenom table encoding priority \

#### Lua 5.0
# Basic Functions
keywordclass2.lua5=
# I put the library names here, so when highlighted standalone, they are probably variable name from Lua 4.0 times.

# String Manipulation, Table Manipulation, Mathematical Functions (string & table & math)
keywordclass3.lua5=
# Coroutine Manipulation, Input and Output Facilities, System Facilities (coroutine & io & os)
keywordclass4.lua5=

# I keep keywords5, 6, 7 & 8 for other libraries
# To make the change from Lua 4 to Lua 5 as smooth as possible, I made these properties
# modular and flexible.
# If you use only Lua 4, you can remove the lua5 keywords.
# If you use only Lua 5, you can either remove the lua4 keywords, or put them
# in another property to highlight them in a warning/error style.
# If you still use both, you can keep them like below, or use separate styles.

keywords2.$(file.patterns.lua)=$(keywordclass2.lua) $(keywordclass2.lua4) $(keywordclass2.lua5)
keywords3.$(file.patterns.lua)=$(keywordclass3.lua4) $(keywordclass3.lua5)
keywords4.$(file.patterns.lua)=$(keywordclass4.lua4) $(keywordclass4.lua5)

#~ statement.indent.$(file.patterns.lua)=5 do else function then
#~ statement.end.$(file.patterns.lua)=5 end until
#~ statement.lookback.$(file.patterns.lua)=20
indent.maintain.$(file.patterns.lua)=1

comment.block.lua=#--
comment.block.at.line.start.lua=10

# Lua styles

#Default
style.lua.32=$(font.code.base),fore:#000000
# White space: Visible only in View Whitespace mode (or if it has a back colour)
style.lua.0=fore:#7F7F0F,italics
# Block comment (Lua 5.0)
#style.lua.1=$(colour.code.comment.box),$(font.code.comment.box),back:#D0F0F0,eolfilled
style.lua.1=fore:#7F7F0F,italics
# Line comment
#style.lua.2=$(colour.code.comment.line),$(font.code.comment.line),italics
style.lua.2=fore:#7F7F0F,italics
# Doc comment -- Not used in Lua (yet?)
#style.lua.3=$(colour.notused),$(font.notused)
style.lua.3=fore:#7F7F0F,italics
# Number
style.lua.4=fore:#CF00CF
# Keyword
#style.lua.5=$(colour.keyword),bold
style.lua.5=fore:#00007F,bold
# (Double quoted) String
style.lua.6=fore:#CF0000
# Character (Single quoted string)
style.lua.7=$(colour.char)
# Literal string
style.lua.8=$(colour.string),$(font.code.comment.box),back:#E0FFFF
# Preprocessor (obsolete in Lua 4.0 and up)
style.lua.9=fore:#5A020A
# Operators
style.lua.10=$(colour.operator)
# Identifier (everything else...)
style.lua.11=fire:#000000
# End of line where string is not closed
style.lua.12=back:#E0C0E0,eolfilled
# Other keywords (bozo test colors :-)
style.lua.13=$(style.lua.9),back:#D0FFD0  
style.lua.14=$(style.lua.5),back:#D0D0FF
style.lua.15=$(style.lua.9)
style.lua.16=$(style.lua.5),back:#FFD0FF
style.lua.17=$(style.lua.5),back:#FFFFD0
style.lua.18=$(style.lua.5),back:#FFA0A0
style.lua.19=$(style.lua.5),back:#FFD0D0
# Braces are only matched in operator style
braces.lua.style=10

#command.compile.*.lua=LuaC-5.0.exe -o "$(FileName).luc" "$(FileNameExt)"
# Lua 5.0
#command.go.*.lua=Lua-5.0.exe "$(FileNameExt)"
# Lua 4.0
#command.go.*.lua=Lua-4.0.exe -c -f "$(FileNameExt)"
