home *** CD-ROM | disk | FTP | other *** search
- on setCal
- clearAll()
- set theFont to "Times New Roman"
- set fontSize to 18
- set lineheight to 43
- set the textSize of field "sun" to fontSize
- set the textHeight of field "sun" to lineheight
- set the textFont of field "sun" to theFont
- set the textSize of field "mon" to fontSize
- set the textHeight of field "mon" to lineheight
- set the textFont of field "mon" to theFont
- set the textSize of field "tue" to fontSize
- set the textHeight of field "tue" to lineheight
- set the textFont of field "tue" to theFont
- set the textSize of field "wed" to fontSize
- set the textHeight of field "wed" to lineheight
- set the textFont of field "wed" to theFont
- set the textSize of field "thu" to fontSize
- set the textHeight of field "thu" to lineheight
- set the textFont of field "thu" to theFont
- set the textSize of field "fri" to fontSize
- set the textHeight of field "fri" to lineheight
- set the textFont of field "fri" to theFont
- set the textSize of field "sat" to fontSize
- set the textHeight of field "sat" to lineheight
- set the textFont of field "sat" to theFont
- end
-
- on minderFinder
- global thisMonth, firstDayOfMonthList, spriteOffset, thisYear, firstDay, offsetX, offsetY, width, height, minderSprite, HDPath
- cursor(4)
- set year to string(thisYear)
- set fileType to char 1 to 3 of thisMonth
- set minderList to []
- repeat with i = 1 to the maxinteger
- set x to getNthFileNameInFolder(HDPath & "calndr1\", i)
- if x = EMPTY then
- exit repeat
- end if
- if (x contains fileType) and (x starts year) then
- append(minderList, x)
- end if
- end repeat
- if count(minderList) <> 0 then
- clearMinder()
- repeat with i = 1 to count(minderList)
- set n to getAt(minderList, i)
- if char 6 of n = "." then
- set dayNumber to value(char 5 of n)
- else
- set dayNumber to value(char 5 to 6 of n)
- end if
- set location to dayNumber + firstDay - 2
- set the locV of sprite minderSprite to offsetY + (location / 7 * height)
- set the locH of sprite minderSprite to offsetX + (location mod 7 * width)
- updateStage()
- end repeat
- set the locV of sprite minderSprite to -20
- set the locH of sprite minderSprite to -20
- updateStage()
- end if
- cursor(-1)
- end
-
- on clearMinder
- end
-