#########################################################################
# WARNING:  DO NOT EDIT THIS FILE UNLESS YOU KNOW WHAT YOU'RE DOING     #
# (i.e., you're comfortable with Tcl).                                  #
#########################################################################

# There are several maps you can use.  In this section, you define which
# map you will use by default.
#
# Select from one of these maps (you can change maps from within JStrack
# and from the command line):
#
# NEW MAPS:
# set defmap large_js          ;# Overall picture (recommended/default)
# set defmap east_coast_js     ;# East coast (north of FL)
# set defmap gulf_cab2_js      ;# Gulf coast + FL East coast

set defmap large_js

# units:  set to either MPH for miles/MPH or KT for NM/KT
set units MPH

# home_latt and home_long are your home coordinates (for the
# big 'X' on the display).  Default:  my home coords.
set home_long 86.60548183
set home_latt 30.39789452

# storms is the directory where storm data is located.  It is now
# set from $install_dir/paths.tcl

# set auto_fc to 1 (non-zero) if you want forecast positions
# to be plotted automatically for the latest storm position.
# auto_radii works the same for wind radii (now plots current
# and forecast wind radii).
set auto_fc 1
set auto_radii 1

# set auto_update to 1 if you want JStrack to watch for storm
# data file updates in the background.
set auto_update 1

# If auto_load_new is set and is a non-zero value, new storms will
# be loaded automatically (if JStrack is running, of course).
set auto_load_new 1

# c_h and c_w are the height and width of the canvas
# ON YOUR SCREEN.  In other words, it's the size of the
# window in which the full-sized canvas is displayed.
# set c_w 1280
# set c_h 763

# text_font is the font for normal text in JStrack (default
# is {Courier 12}
set text_font {Courier 12}

# If show_ptrloc is set to a non-zero value, the current
# location of the mouse, in latt/long, will be displayed
# and updated as the mouse moves.  The default is to have
# this feature turned on.
set show_ptrloc 1

# OPTIONAL:  You may increase the number of lines kept in
# Tcl's history buffer (default is 20) by using the
# following command:
#     history keep {n}
# where {n} is the (integer) number of lines to keep, e.g.,
#     history keep 50
history keep 20

# If you want JStrack to warn you when either the current position is
# within a given range (the default is 60 nm) or the forecast track
# takes it within the same range, set warn_at_nm to the range you want
# to use (must be in nautical miles).  Remember, miles = nm * 1.15.
# The setting below shows the system's default setting of 60 nm.
#
# set warn_at_nm 60

set warn_at_nm 60

# PROGRAMS ASSOCIATED WITH EVENTS

# If you want an external program (e.g., some type of sound file, etc.)
# to be run when the storm data is reloaded by JStrack, i.e., when new
# data arrives for a storm currently in memory, set the update_prog
# variable to the value of the program you want to run.  For example:
#
# set update_prog "vplay /home/jim/tv/simpsons/doh.wav"

# If you want to pass the name of the storm to a script (e.g., to
# only sound off about data for a given storm, to use a voice synth.,
# etc.), use format shown below.
#
# NOTE THE USE OF '{' AND '}' INSTEAD OF PLAIN QUOTES---THIS IS REQUIRED
# TO PREVENT THE EXPANSION OF $nm (which is the name of the storm in all
# lowercase).  Another variable you have access to from the procedure that
# calls this is $name, which is the name of the storm in all uppercase (as
# it is used within the program).

# set update_prog {say new data on $nm}

set update_prog {}

# Likewise, if you want an alarm on a position estimate (when there
# was no full update), set pos_est_prog to the external command you
# want run.  $nm and $name apply exactly as for $update_prog.

# set pos_est_prog {say new data on $nm}

set pos_est_prog {}

# Normally, warnings associated with proximity of a storm (to the
# home coordinates you define) will only be a text message and a red
# background behind the menus.  If you want an alarm to sound, etc.,
# using some external program, define it here.  The first variable,
# current_prog, is for times when the storm's current position is
# within $warn_at_nm nautical miles from your location.  The second
# variable, forecast_prog, is when the forecast track takes it
# within that distance from your location.
#
# Variables available (from the command line, as for update_prog and
# pos_est_prog):
#       name       --- storm name (uppercase)
#       nm         --- storm name (lowercase)
#       timestamp  --- current time for latest advisory (e.g., 02/0900Z)
#       warn_at_nm --- within this distance (in nm) from home

# set current_prog {say $nm is now within $warn_at_nm nautical miles}
# set forecast_prog \\
#       {say $nm is expected to come within $warn_at_nm nautical miles}

set current_prog {}
set forecast_prog {}


#########################################################################
# DEFINITION OF jstrackrc VARIABLE
#########################################################################

# NOTE:  jstrackrc should not need to be changed under UNIX.
# Likewise, users on Windows NT/2k/XP (and possibly 95/98---I don't
# have those to test) shouldn't need to change this, either.
#
# HOWEVER, anyone trying to run this under a Mac, etc., may want to
# change this variable to a more suitable value.  This variable points
# to individual users' config files.  It must be defined, but it does
# not have to point to an existing file (i.e., if the file doesn't
# exist, it just isn't opened).
#
# Oh, one more thing....  If this value points to a filename that can't
# be opened (for append) on your system, the ``Save Config'' option will
# not work.

set sys_os $tcl_platform(platform)

if {$sys_os == "unix" && [info exists env(HOME)]} {
   set jstrackrc $env(HOME)/.jstrackrc
} elseif {$sys_os == "windows" && [info exists env(USERPROFILE)]} {
   set d "$env(USERPROFILE)/Application Data/JStrack"
   if {[file exists $d ] && ![file isdirectory $d]} {
      catch { file delete $d }
   }
   if {![file exists $d]} { file mkdir $d }
   set jstrackrc $d/jstrackrc
} else {
   set jstrackrc jstrackrc
}


