/* **********************************************************************
 * *                                                                    *
 * *         PCF Header file                                            *
 * *                                                                    *
 * **********************************************************************
 * File: iris/xuif/pcf.h
 *
 *                  COPYRIGHT (c) 1999, 2002, 2004  BY
 *          SIGMET INCORPORATED, WESTFORD MASSACHUSETTS, U.S.A.
 * 
 * THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED
 * ONLY  IN  ACCORDANCE WITH  THE  TERMS  OF  SUCH  LICENSE  AND WITH THE
 * INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE  OR  ANY OTHER
 * COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY
 * OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY
 * TRANSFERED.
 */

#define PCH_H

#ifdef PCF_ALLOCATE
#define EXTERN
#else
#define EXTERN extern
#endif



/*  Memory allocation for the hot pcf ( which is the highlighed item in the
    list ) and equivalent text, and the corresponding xmstring.
*/
EXTERN SINT2    ipcf_ptype_c;  /* menu product type */

EXTERN struct   serv_product_configuration  pcf_c;
EXTERN struct   server_scales_setup         pcf_scales_c;
EXTERN char     spcf_c[160];
EXTERN XmString xpcf_c;

EXTERN IHD_LNG  pcfhottcf_c;
EXTERN char     spcfhottcf_c[160];
EXTERN XmString xpcfhottcf_c;


/* PCF */
EXTERN Widget pcf_mainbar;
EXTERN Widget pcf_filebtn, pcf_filepdw;
EXTERN Widget pcf_menubtn, pcf_menupdw;
EXTERN Widget pcf_typebtn, pcf_typepdw;
EXTERN Widget pcf_cmdsbtn, pcf_cmdspdw;
EXTERN Widget pcf_helpbtn, pcf_helppdw;
EXTERN Widget pcf_printpdw;


void new_pcf_tcf( char *stcf_a, UINT4 ilen_a );
void new_pcf_tcfndop1( char *stcf_a, UINT4 ilen_a );
void new_pcf_tcfndop2( char *stcf_a, UINT4 ilen_a );

void new_pcf_tcfndop3( char *stcf_a, UINT4 ilen_a );
void   pcf_file_cbf();
void   pcf_menu_cbf();
void   pcf_type_cbf();
void   pcf_cmds_cbf();

void   pcf_prodtype_list( SINT2 *icnt, char *prodtype_list);
EXTERN XsFLB* pcf_type;  
void   pcf_switch_type(SINT2 inew);

void   pcf_openlist( char *sptr_a, UINT4 ilen_a );
EXTERN XsFLB* pcf_open;
void   pcf_openflb_cbf();

EXTERN Widget pcf_svaspop;
EXTERN Widget pcfhelp_fnampop;
void   pcf_svaspop_ok_cbf();   
void   pcf_svaspop_help_cbf();   

void   pcf_delelist( char *sptr_a, UINT4 ilen_a );
EXTERN XsFLB* pcf_dele;
void   pcf_deleflb_cbf();

EXTERN UINT4 task_sum_menu_called_from;
#define TASK_SUM_MENU    0
#define TASK_SUM_NDOP1   1
#define TASK_SUM_NDOP2   2
#define TASK_SUM_NDOP3   3


/* Tcf Summary */
EXTERN Widget pcf_tcofrm,
       pcf_tcosumalab,
       pcf_tasklab, pcf_taskbtn, pcf_tasktxt;
void   pcf_tasklist( char *sptr_a, UINT4 ilen_a );
EXTERN XsFLB* pcf_task;
void   pcf_taskflb_cbf();
EXTERN Widget pcf_checkbtn,
       pcf_scanlab,   pcf_scantxt,
       pcf_angslab,   pcf_angstxt,
       pcf_datalab,   pcf_datatxt,
       pcf_tcornglab, pcf_tcorngtxt;
void   pcf_taskbtn_cbf();
void   pcf_tasktxt_cbf();

EXTERN UINT4 site_list_called_from;
#define SITE_LIST_NDOP1     1
#define SITE_LIST_NDOP2     2
#define SITE_LIST_NDOP3     3
#define SITE_LIST_COMP      4

EXTERN XsFLB* pcf_site;
void   pcf_siteflb_cbf();

/* Projection  Parameters */
EXTERN Widget pcf_prjfrm;

#ifdef SIGMET_PROJECTION_H
EXTERN Widget pcf_prjtypelab, pcf_prjtypeopt,  pcf_prjtypebtns[1+MAPROJ_COUNT]; 
#endif  /* #ifdef SIGMET_PROJECTION_H */
void   pcf_prjtypeopt_cbf();
EXTERN Widget pcf_prjnamelab,  pcf_prjnamebtn, pcf_prjnametxt;  
void   pcf_prjnamebtn_cbf();
EXTERN XsFLB* pcf_prjopen;
void   pcf_prjopenflb_cbf();
void   pcf_prjopenlist( char *sptr_a, UINT4 ilen_a );
void   pcf_prjload
(const struct projection_configuration *sptr_a,
 UINT4 insize_a );



/* Display Parameters */
EXTERN Widget    pcf_dispfrm,  pcf_displab;
EXTERN Widget    pcf_unitslab,   pcf_unitstxt;


EXTERN Widget pcf_unilab;  
EXTERN Widget pcf_uniopt,  pcf_unibtns[9];  /* Uniform, or 8 Custom Levels */
void   pcf_uniopt_cbf();

EXTERN Widget pcf_lvlslab;  
EXTERN Widget pcf_lvlsopt,  pcf_lvlsbtns[15];  /* Num of Levels */
void   pcf_lvlsopt_cbf();

EXTERN Widget    pcf_level1lab, pcf_level1txt, pcf_steptxt;
void      pcf_lvl1txt_cbf();
void      pcf_steptxt_cbf();



EXTERN XsPDW_TXT pcf_reso;  /* Display First Level  */
EXTERN Widget    pcf_resotxt1;
void      pcf_resopdw_cbf();
void      pcf_resotxt_cbf();
void      pcf_resotxt1_cbf();

void pcfup_disp(void);
void pcfup_displvls(void);
void pcfup_displvl1(void);
void pcfup_dispstep(void);
void pcfup_dispreso(void);


EXTERN Widget pcf_parsfrm[35]; /* Last Product PROD_HMAX */
EXTERN Widget pcf_dtdppop, pcf_dtdplst, pcf_dtdpexitbtn;

/* CAPPI */
EXTERN Widget
  pcfcap_parslab,
  pcfcap_dtdplab,  pcfcap_dtdpbtn, pcfcap_dtdptxt,
  pcfcap_maxlab,   pcfcap_maxtxt,
  pcfcap_hgtlab,   pcfcap_hgttxt,
  pcfcap_fillab,   pcfcap_filtgl,
  pcfcap_xyfirlab, pcfcap_xyfirtxt,
  pcfcap_firlab,   pcfcap_firtxt,
  pcfcap_typelab,  pcfcap_typeopt, pcfcap_typebtns[7],  /* Rad, Azm, Com, El */
  pcfcap_vvptgl, pcfcap_vvplab,   pcfcap_vvpbtn,  pcfcap_vvptxt,
  pcfcap_vvpagelab, pcfcap_vvpagetxt;

EXTERN XsPDW_TXT pcfcap_zrz;  /* ZR Relation  */
EXTERN XsFLB* pcfcap_vvppop;
void pcfcap_txt_cbf();

void pcf_up_caphgt(void) ;
void pcf_up_captype( SINT4 iptype_a );
void pcf_up_capvvptgl(void);
void pcf_up_capvvp(void);
void pcf_up_capvvpage(void);



/* MAX */
EXTERN Widget
  pcfmax_parslab,
  pcfmax_dtdplab,  pcfmax_dtdpbtn, pcfmax_dtdptxt,
  pcfmax_maxlab,   pcfmax_maxtxt,
  pcfmax_toplab,   pcfmax_toptxt,
  pcfmax_botlab,   pcfmax_bottxt,
  pcfmax_fillab,   pcfmax_filopt,  pcfmax_filpop, pcfmax_filbtns[2],
  pcfmax_xyfirlab, pcfmax_xyfirtxt,
  pcfmax_xzfirlab, pcfmax_xzfirtxt;

EXTERN XsPDW_TXT pcfmax_zrz;  /* ZR Relation  */

/* PPI */
EXTERN Widget
  pcfppi_parslab,
  pcfppi_dtdplab,  pcfppi_dtdpbtn, pcfppi_dtdptxt,
  pcfppi_maxlab,   pcfppi_maxtxt,
  pcfppi_elvlab,   pcfppi_elvtxt,
  pcfppi_cliprnglab,   pcfppi_cliprngtxt,
  pcfppi_cliphgtlab,   pcfppi_cliphgttxt,
  pcfppi_xyfirlab, pcfppi_xyfirtxt;

EXTERN XsPDW_TXT pcfppi_zrz;  /* ZR Relation  */

/* Rain1  */
EXTERN Widget
  pcfrn1_parslab,
  pcfrn1_dtdplab,  pcfrn1_dtdpbtn, pcfrn1_dtdptxt,
  pcfrn1_maplab,   pcfrn1_maptgl,
  pcfrn1_xyfirlab, pcfrn1_xyfirtxt,
  pcfrn1_mindbzlab, pcfrn1_mindbztxt,
  pcfrn1_gagelab,   pcfrn1_gagetgl,
  pcfrn1_diaglab,   pcfrn1_diagtgl;

EXTERN XsPDW_TXT pcfrn1_zrz;  /* ZR Relation  */

EXTERN XsBTN_TXT pcfrn1_type;
EXTERN Widget  pcfrn1_prodtxt;

void      pcfrn1_pom_find( const char *sptr_a, UINT4 ilen_a, const char *sError_a );
void      pcf_up_rn1cappi(void);
void      pcfrn1_mindbztxt_cbf(Widget wgt, XtPointer tag, XtPointer cbd);

/* RainN */
EXTERN Widget    pcfrnn_parslab;

EXTERN XsBTN_TXT pcfrnn_rn1;   
EXTERN XsFLB*    pcfrnn_rn1p;
void      pcfrnn_rn1btn_cbf( Widget wgt,char* tag,XmAnyCallbackStruct* cbd);
void      pcfrnn_rn1txt_cbf( Widget wgt,char* tag,XmListCallbackStruct* cbd);
void      pcfrnn_rn1flb_cbf( Widget wgt,char* tag,XmListCallbackStruct* cbd);
void      pcfrnn_rn1list( char *sptr_a, UINT4 ilen_a );
void      pcfrnn_load_rn1( char *sptr_a, UINT4 ilen_a );
void      pcf_up_rnnrn1(void);

EXTERN Widget    pcfrnn_hourslab, pcfrnn_hourstxt;
EXTERN Widget    pcfrnn_xyfirlab, pcfrnn_xyfirtxt;
void      pcf_up_rnnhrs(void);

/* Raw */
EXTERN Widget pcfraw_formatlab;
EXTERN Widget pcfraw_formatopt, pcfraw_formatbtns[3];
void   pcfraw_formatopt_cbf();

EXTERN Widget pcfraw_sweeplab, pcfraw_sweeptgl;
void   pcfraw_sweeptgl_cbf();

EXTERN Widget pcfraw_filterlab;
EXTERN Widget pcfraw_filteropt, pcfraw_filterbtns[2];
void   pcfraw_filteropt_cbf();

#define PCFRAW_DATA_COUNT (18)
EXTERN Widget 
  pcfraw_datalab,   pcfraw_databtn,   pcfraw_datatxt,
  pcfraw_datapop, pcfraw_datapoprc,
  pcfraw_datapoptgls[PCFRAW_DATA_COUNT],  pcfraw_datapopclrbtns, pcfraw_datapopbtns;

void pcfraw_datatgl_cbf();
void pcfraw_databtn_cbf();
void pcfraw_dataexit_cbf();
void pcfraw_dataclr_cbf();
void pcfraw_up_data_txtf();


/* RHI   */
EXTERN Widget
  pcfrhi_parslab,
  pcfrhi_dtdplab,  pcfrhi_dtdpbtn, pcfrhi_dtdptxt,
  pcfrhi_maxlab,   pcfrhi_maxtxt,
  pcfrhi_azmlab,   pcfrhi_azmtxt,
  pcfrhi_hgtlab,   pcfrhi_hgttxt,
  pcfrhi_xyfirlab, pcfrhi_xyfirtxt,
  pcfrhi_firlab,   pcfrhi_firtxt;

EXTERN XsPDW_TXT pcfrhi_zrz;  /* ZR Relation  */

/*SHEAR */
EXTERN Widget
  pcfshr_parslab,
  pcfshr_dtdplab,  pcfshr_dtdpbtn, pcfshr_dtdptxt,
  pcfshr_maxlab,   pcfshr_maxtxt,
  pcfshr_elvlab,   pcfshr_elvtxt,
  pcfshr_firlab,   pcfshr_firtxt,
  pcfshr_xyfirlab, pcfshr_xyfirtxt,
  pcfshr_typelab,  pcfshr_typeopt, pcfshr_typebtns[7],  /* Rad, Azm, Com, El */
  pcfshr_vvptgl, pcfshr_vvplab,   pcfshr_vvpbtn,  pcfshr_vvptxt,
  pcfshr_vvpagelab, pcfshr_vvpagetxt;

EXTERN XsFLB* pcfshr_vvppop;
void pcfshr_txt_cbf();
void pcfshr_typeopt_cbf();
void pcfshr_vvptgl_cbf();
void pcfshr_vvpbtn_cbf();
void pcfshr_vvptxt_cbf();
void pcfshr_vvpagetxt_cbf();
void pcfshr_vvplist( char *sptr_a, UINT4 ilen_a );
void pcfshr_vvppopflb_cbf();
void pcf_up_shrtype( SINT4 iptype_a );
void pcf_up_shrvvptgl(void);
void pcf_up_shrvvp(void);
void pcf_up_shrvvpage(void);

EXTERN XsFLB*  pcf_arealstshl;
void pcf_areabtn_cbf();
void pcf_arealstshl_cbf();

/*SLINE */
#define PCF_SLN_TIME_STEP 1
#define PCF_SLN_TIME_FORE 2
EXTERN int pcfsln_timetype, pcfsln_itime_c;

EXTERN Widget
  pcfsln_parslab,
  pcfsln_dtdplab,  pcfsln_dtdpbtn, pcfsln_dtdptxt,
  pcfsln_maxlab,   pcfsln_maxtxt,
  pcfsln_elvlab,   pcfsln_elvtxt,
  pcfsln_firlab,   pcfsln_firtxt,
  pcfsln_xyfirlab, pcfsln_xyfirtxt,
  pcfsln_typelab,  pcfsln_typeopt, pcfsln_typebtns[7],  /*Rad, Azm, Com */
  pcfsln_vvptgl, pcfsln_vvplab,   pcfsln_vvpbtn,  pcfsln_vvptxt,
  pcfsln_vvpagelab, pcfsln_vvpagetxt;

void pcfsln_txt_cbf();
void pcf_up_slnvvptgl(void);
void pcf_up_slnvvp(void);
void pcf_up_slnvvpage(void);

EXTERN Widget
  pcfsln_forefrm,
  pcfsln_foreparamlab,
  pcfsln_shearparamlab,
  pcfsln_cntforelab, pcfsln_cntopt, pcfsln_cntbtns[2],
  pcfsln_forelab,
  pcfsln_timeshl, pcfsln_timeshltxt,
  pcfsln_shearlab,
  pcfsln_sheartxt,
  pcfsln_steplab,
  pcfsln_arealab,
  pcfsln_areatxt,
  pcfsln_vellab,
  pcfsln_veltxt,
  pcfsln_tollab,
  pcfsln_toltxt,
  pcfsln_minlenlab,
  pcfsln_minlentxt,
  pcfsln_protlab,
  pcfsln_areabtn, pcfsln_arealst,
  pcfsln_tdwrlab, pcfsln_tdwrtgl,
  pcfsln_saywrnlab, pcfsln_saywrntgl,
  pcfsln_diaglab, pcfsln_diagtgl;


EXTERN XsBTN_TXT pcfsln_fore;
EXTERN XsBTN_TXT pcfsln_step;

void pcfsln_cntopt_cbf();
void pcfsln_forebtn_cbf();
void pcfsln_foretxt_cbf();
void pcfsln_sheartxt_cbf();
void pcfsln_stepbtn_cbf();
void pcfsln_steptxt_cbf();
void pcfsln_areatxt_cbf();
void pcfsln_timeshl_cbf();
void pcfsln_veltxt_cbf();
void pcfsln_toltxt_cbf();
void pcfsln_minlentxt_cbf();
void pcfsln_disp_arealst(void);
void pcfsln_tdwrtgl_cbf();
void pcfsln_saywrntgl_cbf();
void pcfsln_diagtgl_cbf();


/*TOPS */
EXTERN Widget
  pcftop_parslab,
  pcftop_dtdplab,  pcftop_dtdpbtn, pcftop_dtdptxt,
  pcftop_maxlab,   pcftop_maxtxt,
  pcftop_dbzlab,   pcftop_dbztxt,
  pcftop_xyfirlab, pcftop_xyfirtxt;

/* TRACK  */
#define PCF_TRK_TIME_SPAN 1
#define PCF_TRK_TIME_STEP 2
#define PCF_TRK_TIME_FORE 3
EXTERN int pcftrk_timetype, pcftrk_itime_c;

EXTERN Widget
  pcftrk_charlab,
  pcftrk_legendlab,
  pcftrk_prodtxt,
  pcftrk_centlab,
  pcftrk_centtxt,
  pcftrk_arealab,
  pcftrk_areatxt,
  pcftrk_paramlab,
  pcftrk_spanlab,
  pcftrk_steplab,
  pcftrk_forelab,
  pcftrk_timeshl, pcftrk_timeshltxt,
  pcftrk_vellab,
  pcftrk_veltxt,
  pcftrk_tollab,
  pcftrk_toltxt,
  pcftrk_parslab,
  pcftrk_areabtn, pcftrk_arealst,
  pcftrk_tdwrlab, pcftrk_tdwrtgl,
  pcftrk_saywrnlab, pcftrk_saywrntgl,
  pcftrk_diaglab, pcftrk_diagtgl;


EXTERN XsBTN_TXT pcftrk_type;
EXTERN XsBTN_TXT pcftrk_span;
EXTERN XsBTN_TXT pcftrk_step;
EXTERN XsBTN_TXT pcftrk_fore;


void      pcftrk_prodtxt_cbf();
void      pcftrk_centtxt_cbf();
void      pcftrk_areatxt_cbf();
void      pcftrk_spanbtn_cbf();
void      pcftrk_spantxt_cbf();
void      pcftrk_stepbtn_cbf();
void      pcftrk_steptxt_cbf();
void      pcftrk_forebtn_cbf();
void      pcftrk_foretxt_cbf();
void      pcftrk_timeshl_cbf();
void      pcftrk_veltxt_cbf();
void      pcftrk_toltxt_cbf();
void      pcftrk_disp_arealst(void);
void      pcftrk_tdwrtgl_cbf();
void      pcftrk_saywrntgl_cbf();
void      pcftrk_diagtgl_cbf();


/* VIL */
EXTERN Widget
  pcfvil_parslab,
  pcfvil_dtdplab,  pcfvil_dtdpbtn, pcfvil_dtdptxt,
  pcfvil_maxlab,   pcfvil_maxtxt,
  pcfvil_toplab,   pcfvil_toptxt,
  pcfvil_botlab,   pcfvil_bottxt,
  pcfvil_zrzlab,   pcfvil_zrztxt,
  pcfvil_xyfirlab, pcfvil_xyfirtxt;

/* VVP */
EXTERN Widget
  pcfvvp_parslab,
  pcfvvp_dtdplab,  pcfvvp_dtdpbtn, pcfvvp_dtdptxt,
  pcfvvp_maxlab,   pcfvvp_maxtxt,
  pcfvvp_hgtlab,   pcfvvp_hgttxt,
  pcfvvp_interslab, pcfvvp_interstxt,
  pcfvvp_binslab,  pcfvvp_binstxt,
  pcfvvp_foldlab,  pcfvvp_foldtgl;
void pcf_up_vvprng(void);
void pcf_up_vvphgt(void);
void pcf_up_vvpinters(void);
void pcf_up_vvpbins(void);


EXTERN Widget
    pcfvvp_tglfrm, pcfvvptgl_lab, 
    pcfvvptgl_reflectlab, pcfvvptgl_reflecttgl,
    pcfvvptgl_vertvellab, pcfvvptgl_vertveltgl,
    pcfvvptgl_diverglab,  pcfvvptgl_divergtgl,
    pcfvvptgl_deformlab,  pcfvvptgl_deformtgl;

void pcfvvptgl_tgl_cbf();

/* WARN */
EXTERN Widget
  pcfwrn_parslab,
  pcfwrn_symblab,  pcfwrn_symbtxt,
  pcfwrn_sqkmlab,  pcfwrn_sqkmtxt,
  pcfwrn_legendlab,
  pcfwrn_prodtxt,
  pcfwrn_timeshl, pcfwrn_timeshltxt,
  pcfwrn_thrstxt,
  pcfwrn_applybtn,
  pcfwrn_clrbtn,
  pcfwrn_wrnlst,
  pcfwrn_areabtn, pcfwrn_arealst,
  pcfwrn_tdwrlab, pcfwrn_tdwrtgl,
  pcfwrn_saywrnlab, pcfwrn_saywrntgl,
  pcfwrn_diaglab, pcfwrn_diagtgl;


EXTERN XsBTN_TXT pcfwrn_type;
EXTERN XsFOLB*   pcfwrn_prodp;
EXTERN XsBTN_TXT pcfwrn_time;


void      pcfwrn_symbtxt_cbf();
void      pcfwrn_sqkmtxt_cbf();
void      pcfwrn_typebtn_cbf();
void      pcfwrn_prodfolb_cbf();
void      pcfwrn_prodlist( char *sptr_a, UINT4 ilen_a );
void      pcfwrn_prodtxt_cbf();
void      pcfwrn_timebtn_cbf();
void      pcfwrn_timeshl_cbf();
void      pcfwrn_thrstxt_cbf();
void      pcfwrn_applybtn_cbf();
void      pcfwrn_clrbtn_cbf();
void      pcfwrn_wrnlst_cbf();
void      pcfwrn_alignlst(SINT4 item_num);
void      pcfwrn_disp_arealst(void);
void      pcfwrn_tdwrtgl_cbf();
void      pcfwrn_saywrntgl_cbf();
void      pcfwrn_diagtgl_cbf();

EXTERN UINT4 warn_item_num;

EXTERN UINT4 warn_temp_prod;
EXTERN char  warn_temp_spname[16];
EXTERN SINT4 warn_temp_seconds;
EXTERN SINT4 warn_temp_thresh;
EXTERN UINT1 warn_temp_lessthan ;

#define PCFWRN_INDEX_X_P     0
#define PCFWRN_TYPE_X_P      3
#define PCFWRN_PNAME_X_P    11
#define PCFWRN_TIME_X_P     27 
#define PCFWRN_THRES_X_P    38 


/* WIND */

EXTERN Widget
    pcfwnd_rnglab, pcfwnd_rngtxt,
    pcfwnd_defbtn ,
    pcfwnd_hgtlab, pcfwnd_hgttxt,
    pcfwnd_rngsplab, pcfwnd_rngsptxt,
    pcfwnd_sectlenlab, pcfwnd_sectlentxt,
    pcfwnd_azsplab, pcfwnd_azsptxt,
    pcfwnd_sectwidlab, pcfwnd_sectwidtxt;

void pcfwnd_rnghgttxt_cbf();
void pcf_up_wndrng(void);
void pcf_up_wndhgt(void);

void pcfwnd_defbtn_cbf();

void pcfwnd_splentxt_cbf();
void pcf_up_wndrngsp(void);
void pcf_up_wndazsp(void);
void pcf_up_wndsectlen(void);
void pcf_up_wndsectwid(void);

EXTERN Widget
  pcftra_parslab;

/* XSECT */
EXTERN Widget
  pcfxec_parslab,
  pcfxec_dtdplab,  pcfxec_dtdpbtn, pcfxec_dtdptxt,
  pcfxec_hgtlab,   pcfxec_hgttxt,
  pcfxec_ctrlab,   pcfxec_ctrtxt,
  pcfxec_anglab,   pcfxec_angtxt,
  pcfxec_xyfirlab, pcfxec_xyfirtxt;

EXTERN XsPDW_TXT pcfxec_zrz;  /* ZR Relation  */

void pcf_up_crshgt(void);
void pcf_up_crsctr(void);
void pcf_up_crsazm(void);

/* BEAM */
EXTERN Widget
  pcfbeam_parslab,
  pcfbeam_dtdplab,  pcfbeam_dtdpbtn, pcfbeam_dtdptxt,
  pcfbeam_rnglab,   pcfbeam_rngtxt,
  pcfbeam_ellab,   pcfbeam_eltxt,
  pcfbeam_interlab,   pcfbeam_intertxt,
  pcfbeam_azelfirlab, pcfbeam_azelfirtxt;

void pcf_beamrngtxt_cbf();
void pcf_beameltxt_cbf();
void pcf_beamintertxt_cbf();
void pcf_beamazelfirtxt_cbf();


/*
void pcf_up_crshgt(void);
void pcf_up_crsctr(void);
void pcf_up_crsazm(void);
*/

/* FCAST */
EXTERN Widget
  pcffcast_prodlab, pcffcast_prodtxt,
  pcffcast_centlab, pcffcast_centtxt,
  pcffcast_corlab, pcffcast_cortxt,
  pcffcast_vellab, pcffcast_veltxt,
  pcffcast_steplab, pcffcast_steptxt,
  pcffcast_reslab, pcffcast_restxt;

EXTERN XsBTN_TXT pcffcast_type;

void pcffcast_prodtxt_cbf();
void pcffcast_centtxt_cbf();
void pcffcast_cortxt_cbf();
void pcffcast_veltxt_cbf();
void pcffcast_steptxt_cbf();
void pcffcast_restxt_cbf();


/* NDOP */
EXTERN Widget pcfndop_tcofrm;
EXTERN Widget pcfndop_sitelab;
EXTERN Widget
        pcfndop_site1btn, pcfndop_site1txt,
        pcfndop_site2btn, pcfndop_site2txt,
        pcfndop_site3btn, pcfndop_site3txt;

/*
EXTERN XsPDW_TXT pcfndop_site1;
EXTERN XsPDW_TXT pcfndop_site2;
EXTERN XsPDW_TXT pcfndop_site3;
*/

EXTERN Widget pcfndop_tasklab,
        pcfndop_task1btn, pcfndop_task1txt,
        pcfndop_task2btn, pcfndop_task2txt,
        pcfndop_task3btn, pcfndop_task3txt,
        pcfndop_inputlab;

EXTERN XsBTN_TXT pcfndop_input1;   
EXTERN XsBTN_TXT pcfndop_input2;   
EXTERN XsBTN_TXT pcfndop_input3;   

EXTERN Widget pcfndop_maxlab,
        pcfndop_max1txt, pcfndop_max2txt, 
        pcfndop_max3txt,
        pcfndop_winlab, pcfndop_wintxt;


EXTERN Widget pcfndop_maxrlab, pcfndop_maxrtxt,
        pcfndop_hgtlab, pcfndop_hgttxt,
        pcfndop_xyfirlab, pcfndop_xyfirtxt,
        pcfndop_mincrslab, pcfndop_mincrstxt,
        pcfndop_diaglab, pcfndop_diagtgl,
        pcfndop_resotxt1,
        pcfndop_xyoutlab, pcfndop_xyouttxt;

EXTERN Widget pcfndop_spangrdlab,
       pcfndop_rnglab, pcfndop_rngspantxt, 
       pcfndop_rnggrdtxt, pcfndop_rngrestxt, 
       pcfndop_hgtlab, pcfndop_hgtspantxt, 
       pcfndop_hgtgrdtxt, pcfndop_hgtrestxt;

void   pcfndop_sitebtn_cbf();
void   pcfndop_site1txt_cbf();
void   pcfndop_site2txt_cbf();
void   pcfndop_site3txt_cbf();
void   pcfndop_input1btn_cbf();
void   pcfndop_input2btn_cbf();
void   pcfndop_input3btn_cbf();

void   pcfndop_wintxt_cbf();


void   pcfndop_rngspantxt_cbf();
void   pcfndop_rnggrdtxt_cbf( Widget wgt, XtPointer tag, XtPointer cbd );
void   pcfndop_hgtspantxt_cbf();
void   pcfndop_hgtgrdtxt_cbf();
void   pcfndop_mincrstxt_cbf();
void   pcfndop_diagtgl_cbf();


/* COMP */
EXTERN Widget pcfcomp_inputfrm, pcfcomp_inputlab;
EXTERN Widget pcfcomp_prodlab, pcfcomp_prodtxt;
EXTERN XsBTN_TXT pcfcomp_type;
EXTERN Widget pcfcomp_radarlab, pcfcomp_radarbtn, pcfcomp_radarlst;
EXTERN Widget pcfcomp_sitelab, pcfcomp_sitebtn, pcfcomp_sitetxt;

EXTERN Widget pcfcomp_geomfrm, pcfcomp_geomlab;
#ifdef SIGMET_PROJECTION_H
EXTERN Widget pcfcomp_prjtypelab,pcfcomp_prjtypeopt,pcfcomp_prjtypebtns[1+MAPROJ_COUNT]; 
#endif  /* #ifdef SIGMET_PROJECTION_H */
EXTERN Widget pcfcomp_prjnamelab,pcfcomp_prjnamebtn,pcfcomp_prjnametxt;  
EXTERN Widget pcfcomp_maxrnglab, pcfcomp_maxrngtxt;
EXTERN XsPDW_TXT pcfcomp_reso;

EXTERN Widget pcfcomp_genfrm, pcfcomp_prodgenlab,
              pcfcomp_maxtimelab, pcfcomp_maxtimetxt,
              pcfcomp_comblab, pcfcomp_combopt, pcfcomp_combbtns[3],
              pcfcomp_xysmthlab, pcfcomp_xysmthtxt;

void pcfcomp_prodtxt_cbf();
void pcfcomp_radarbtn_cbf();

void pcfcomp_sitebtn_cbf();
void pcfcomp_sitetxt_cbf();
void pcfcomp_maxtimetxt_cbf();
void pcfcomp_combopt_cbf();

void pcfcomp_up_radarlst(void);


/* RTI   */
EXTERN Widget
  pcfrti_parslab,
  pcfrti_dtdplab,  pcfrti_dtdpbtn, pcfrti_dtdptxt,
  pcfrti_maxlab,   pcfrti_maxtxt,
  pcfrti_azmlab,   pcfrti_azmtxt,
  pcfrti_xyfirlab, pcfrti_xyfirtxt;

EXTERN XsPDW_TXT pcfrti_zrz;  /* ZR Relation  */

/* CATCH   */
EXTERN Widget    pcfcat_parslab;
EXTERN XsBTN_TXT pcfcat_rn1;   
EXTERN XsFLB*    pcfcat_rn1p;
EXTERN XsBTN_TXT pcfcat_subcat;   
EXTERN XsFLB*    pcfcat_subcatp;
EXTERN Widget    pcfcat_timelab, pcfcat_timetxt,
                 pcfcat_warnlab, pcfcat_warntgl,
                 pcfcat_offlab, pcfcat_offtxt,
                 pcfcat_multlab, pcfcat_multtxt;
void      pcfcat_rn1btn_cbf();
void      pcfcat_subcatbtn_cbf();
void      pcfcat_subcattxt_cbf();
void      pcfcat_subcatflb_cbf();
void      pcfcat_timetxt_cbf();
void      pcfcat_warntgl_cbf();
void      pcfcat_offtxt_cbf();
void      pcfcat_multtxt_cbf();

void      pcfcat_subcatlist( char *sptr_a, UINT4 ilen_a );
void      pcf_up_catrn1(void);
void      pcf_up_catsubcat(void);

/* DWELL */
#define SPEED_M_SEC 1
#define SPEED_KM_HR 2
#define SPEED_KNOTS 3
#define SPEED_MPH   4
EXTERN UINT4 iDwellSpeedUnits_c;
EXTERN FLT4 fDwellSpeedScale_c;

EXTERN Widget
  pcfdwe_inputfrm,
  pcfdwe_legendlab,
  pcfdwe_inputlab,
  pcfdwe_prodtxt,
  pcfdwe_timetxt,
  pcfdwe_datatxt;

EXTERN Widget
  pcfdwe_filtfrm,
  pcfdwe_filtlab,
  pcfdwe_minlab,
  pcfdwe_intlab,
  pcfdwe_intmintgl, pcfdwe_intmaxtgl,
  pcfdwe_intmintxt, pcfdwe_intmaxtxt,
  pcfdwe_threshlab,
  pcfdwe_conlab, pcfdwe_contgl,
  pcfdwe_contxt, pcfdwe_covtxt,
  pcfdwe_seplab, pcfdwe_septgl,
  pcfdwe_outlab, pcfdwe_outopt, pcfdwe_outbtns[2],
  pcfdwe_alglab, pcfdwe_algtgl;

EXTERN Widget
  pcfdwe_flockfrm,
  pcfdwe_flocklab,
  pcfdwe_flockminlab,
  pcfdwe_flockwarnlab,
  pcfdwe_flockwarntxt,
  pcfdwe_flockspeedlab,
  pcfdwe_flockspeedunitsbtn,
  pcfdwe_flockspeedmintxt,
  pcfdwe_flockspeedmaxtxt,
  pcfdwe_flockspeedsteptxt,
  pcfdwe_flocklinlab,
  pcfdwe_flocklintxt,
  pcfdwe_flockheadlab,
  pcfdwe_flockheadmintxt,
  pcfdwe_flockheadmaxtxt,
  pcfdwe_flockheadsteptxt,
  pcfdwe_flockhgtlab,
  pcfdwe_flockhgttgl,
  pcfdwe_flockhgtmaxtxt,
  pcfdwe_flockwindlab, pcfdwe_flockwindtgl,
  pcfdwe_flockvvplab, pcfdwe_flockvvptgl,
  pcfdwe_parslab,
  pcfdwe_areabtn, pcfdwe_arealst,
  pcfdwe_tdwrlab, pcfdwe_tdwrtgl,
  pcfdwe_saywrnlab, pcfdwe_saywrntgl,
  pcfdwe_diaglab, pcfdwe_diagtgl;


EXTERN XsBTN_TXT pcfdwe_type;

void      pcfdwe_prodtxt_cbf();
void      pcfdwe_timetxt_cbf();
void      pcfdwe_intmintgl_cbf();
void      pcfdwe_intmintxt_cbf();
void      pcfdwe_intmaxtgl_cbf();
void      pcfdwe_intmaxtxt_cbf();
void      pcfdwe_contgl_cbf();
void      pcfdwe_contxt_cbf();
void      pcfdwe_covtxt_cbf();
void      pcfdwe_septgl_cbf();
void      pcfdwe_outopt_cbf();
void      pcfdwe_algtgl_cbf();

void      pcfdwe_flockwarntxt_cbf();
void      pcfdwe_flockspeedunitsbtn_cbf();
void      pcfdwe_flockspeedmintxt_cbf();
void      pcfdwe_flockspeedmaxtxt_cbf();
void      pcfdwe_flockspeedsteptxt_cbf();

void      pcfdwe_flocklintxt_cbf();
void      pcfdwe_flockheadmintxt_cbf();
void      pcfdwe_flockheadmaxtxt_cbf();
void      pcfdwe_flockheadsteptxt_cbf();

void      pcfdwe_flockhgttgl_cbf();
void      pcfdwe_flockhgtmaxtxt_cbf();

void      pcfdwe_flockwindtgl_cbf();
void      pcfdwe_flockvvptgl_cbf();

void      pcfdwe_alignlst(SINT4 item_num);
void      pcfdwe_disp_arealst(void);
void      pcfdwe_tdwrtgl_cbf();
void      pcfdwe_saywrntgl_cbf();
void      pcfdwe_diagtgl_cbf();

void      pcfdwe_pom_find( const char *sptr_a, UINT4 ilen_a, const char *serror_a );

void pcf_up_dwespeed( void );

EXTERN UINT2 dwe_prod_data_type;

/* SRI */
EXTERN Widget
  pcfsri_parslab,
  pcfsri_dtdplab,  pcfsri_dtdpbtn, pcfsri_dtdptxt,
  pcfsri_maxlab,   pcfsri_maxtxt,
  pcfsri_refhgtlab,  
  pcfsri_refhgtopt,   pcfsri_refhgtbtns[2],
  pcfsri_refhgttxt,
  pcfsri_hgtlab,   pcfsri_hgttxt,
  pcfsri_xyfirlab, pcfsri_xyfirtxt,
  pcfsri_proflab, pcfsri_proftgl,
  pcfsri_meltlab,  
  pcfsri_meltopt,   pcfsri_meltbtns[3],
  pcfsri_melttxt,
  pcfsri_convlab, pcfsri_convtgl,
  pcfsri_convdbzlab, pcfsri_convdbztxt,
  pcfsri_convhgtlab, pcfsri_convhgttxt;

EXTERN XsPDW_TXT pcfsri_zrz;  /* ZR Relation  */

void pcfsri_refhgtopt_cbf();
void pcfsri_refhgttxt_cbf();
void pcfsri_hgttxt_cbf();
void pcfsri_proftgl_cbf();
void pcfsri_meltopt_cbf();
void pcfsri_melttxt_cbf();
void pcfsri_convtgl_cbf();
void pcfsri_convdbztxt_cbf();
void pcfsri_convhgttxt_cbf();
void pcf_up_srihgt(void) ;


/*BASE */
EXTERN Widget
  pcfbase_parslab,
  pcfbase_dtdplab,  pcfbase_dtdpbtn, pcfbase_dtdptxt,
  pcfbase_maxlab,   pcfbase_maxtxt,
  pcfbase_dbzlab,   pcfbase_dbztxt,
  pcfbase_xyfirlab, pcfbase_xyfirtxt;

void pcfbase_txt_cbf();

/*HMAX */
EXTERN Widget
  pcfhmax_parslab,
  pcfhmax_dtdplab,  pcfhmax_dtdpbtn, pcfhmax_dtdptxt,
  pcfhmax_maxlab,   pcfhmax_maxtxt,
  pcfhmax_dbzlab,   pcfhmax_dbztxt,
  pcfhmax_xyfirlab, pcfhmax_xyfirtxt;

void pcfhmax_txt_cbf();

/* Function Prototype */

void create_pcf_site(void);
void create_pcf_prj(void);
void create_pcf_disp( int );
void create_pcf_pars( int );


void pcf_dtdpbtn_cbf();
void pcf_dtdplst_cbf();
void pcf_dtdpexitbtn_cbf();
void pcf_maxtxt_cbf();
void pcf_xyfirtxt_cbf();
void pcf_sidefirtxt_cbf();
void pcf_zrbtn_cbf(); 
void pcf_zrpdw_cbf(); 
void pcf_zrtxt_cbf();

void pcfcap_hgttxt_cbf();
void pcfcap_filtgl_cbf();

void pcfppi_elvtxt_cbf();
void pcfppi_cliprngtxt_cbf();
void pcfppi_cliphgttxt_cbf();

void pcfrhi_maxtxt_cbf();
void pcfrhi_hgttxt_cbf();
void pcfrhi_azmtxt_cbf();
void pcfrhi_firtxt_cbf();
void pcfrti_azmtxt_cbf();

void pcfcrs_txt_cbf();

void pcfrn1_maptgl_cbf();
void pcfrn1_gagetgl_cbf();
void pcfrn1_diagtgl_cbf();

void pcfrnn_txt_cbf();

void pcftop_txt_cbf();

void pcfvvp_txt_cbf();
void pcfvvp_foldtgl_cbf();

void pcfmax_txt_cbf();

void pcfvil_txt_cbf();

void pcf_tcf_request( char* );

void pcf_upall( void );
void pcf_up_title(void);
void pcf_upall_tcf(SINT2);
void pcf_upall_tcfndop1(SINT2);
void pcf_upall_tcfndop2(SINT2);
void pcf_upall_tcfndop3(SINT2);

void pcf_upall_prj(void);
void pcfcomp_upall_prj(void);
void pcf_up_rngtxt(void);
void pcf_up_dtdptxt(void);
void pcf_up_xyfir(void);
void pcf_up_zrtxt(void);

void update_fnum( Widget wgt, float fnum, char* sfmt );
void update_fnum2( Widget wgt, float fnum, float fnum2, char* sfmt );

/* SCC routines */

void pcf_load( char*, UINT4 );
void pcf_site_scales( char*, UINT4);



#define SMSG_DELESCHEDPCF "\
A scheduled product can not be deleted until\n\
it is removed from the task scheduler."

#define SMSG_DELEDEFLTPCF "\
The DEFAULT product can not be deleted."

#undef EXTERN
