Syntax Highlighing:
comments, key words, predefined symbols, class members & methods, functions & classes
#assign variables for each pit.
to$ = sprintf("%d",Import.To_Depth)
i = recordNumber
LineStyleDropAnchor(1)
#Find number of records attached to each pit.
n = SetNum (Import[*])
n$ = NumToStr(n)
#Set text color and font
LineStyleSetTextColor(0,0,255)
LineStyleSetFont("ARIALBD.TTF")
#Find depth of each soil horizon
longAxis = 10; shortAxis = 5
dp = 0
# Set Rectangle colors
r = 70
g = 70
b = 20
a$ = ""
for i = 1 to n
begin
d1 = Import[i].To_Depth - Import[i].From_Depth
d1$ = NumToStr(d1)
if (i > 1) a$ = a$ + ", "
a$ = a$ + d1$
c$ = Import[i].Carbonate_Class
t$ = Import[i].Texture
# Increment the rectangle colour down the hole.
r = r + 30
LineStyleSetColor(r,g,b)
# Reduce the size of the profile by 10
d1 = d1/5
# Draw a rectangle at the bottom of the last rectangle
LineStyleMoveTo(-90,dp + d1/2)
LineStyleDrawRectangle(longAxis,d1,0,1)
LineStyleMoveTo(0,5)
LineStyleDrawText(d1$,5,0,0)
LineStyleMoveTo(0,10)
LineStyleSetTextColor(0,0,0)
LineStyleDrawText(c$,5,0,0)
LineStyleMoveTo(0,10)
LineStyleSetTextColor(255,0,0)
LineStyleDrawText(t$,5,0,0)
LineStyleMoveToAnchor(1)
dp = dp + d1
LineStyleSetTextColor(0,0,255)
end
#Set edge line color and cylinder dimensions
#Draw label = first record info.
#LineStyleDrawText(to$,20,0,0)
#LineStyleMoveTo(-90,10)
# LineStyleDrawText(t$,20,0,0)
#LineStyleMoveTo(-90,10)
# LineStyleDrawText(c$,20,0,0)
#LineStyleMoveTo(-90,10)
# LineStyleDrawText(n$,20,0,0)
# LineStyleSetColor(255,255,0)
#LineStyleMoveToAnchor(1)
#LineStyleMoveTo(-90,longAxis)
#longAxis = d2; shortAxis = 15
#LineStyleDrawRectangle(longAxis,shortAxis,-90,1)