/* * Khoros: $Id$ */ #if !defined(__lint) && !defined(__CODECENTER__) static char rcsid[] = "Khoros: $Id$"; #endif /* * Copyright (C) 1997, INPE. Sergio Donizete Faria, Gerald Jean Francis Banon * All rights reserved. See $K_PROG/repos/license/License. */ #include "kgeoutm.h" /*----------------------------------------------------------- | | Routine Name: kgeoutm_get_args | | Purpose: Gets command line args for kgeoutm | | Input: None | | Output: None | Written By: ghostwriter -oname kgeoutm | Date: July 1, 1997 | Modifications: | ------------------------------------------------------------*/ void kgeoutm_get_args( kaddr opane) { static char *sync_error_mesg = "Generated code for kgeoutm is out of sync with arguments specified in kgeoutm's *.pane file; please rerun ghostwriter on kgeoutm."; kform *pane = (kform *) opane; /* * allocate the kgeoutm structure */ clui_info = (clui_info_struct *) kcalloc((size_t)1, sizeof (clui_info_struct)); if (!(kclui_get_double(pane, "a", &(clui_info->a_double), &(clui_info->a_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "e", &(clui_info->e_double), &(clui_info->e_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "lat0", &(clui_info->lat0_double), &(clui_info->lat0_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "long0", &(clui_info->long0_double), &(clui_info->long0_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "k0", &(clui_info->k0_double), &(clui_info->k0_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "lat", &(clui_info->lat_double), &(clui_info->lat_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_double(pane, "long", &(clui_info->long_double), &(clui_info->long_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } if (!(kclui_get_outfile(pane, "f", &(clui_info->f_file), &(clui_info->f_flag)))) { kerror(NULL, "kgeoutm_get_args", sync_error_mesg); kexit(KEXIT_FAILURE); } } /* * internal representation of clui UIS file */ char *clui_uis[] = { "-F 4.3 1 0 52x1+0+0 +0+0 'Cantata' cantata", "-M 1 1 52x1+0+0 +1+0 'GEO -> UTM ' subform", "-P 1 0 52x1+0+1 +0+0 ' ' kgeoutm", "-D 1 0 9x1+0+0 'Options' _gui_options", "-H 1 6x1+0+0 'License' 'license' $BOOTSTRAP/repos/license/License license", "-E", "-R 1 0 1 5x1+35+0 'Run' 'execute operation' $MATCHINGBIN/kgeoutm", "-H 1 5x1+41+0 'Help' 'help page' $MATCHING/objects/kroutine/kgeoutm/help help", "-Q 1 0 5.25x1+47+0 'Close'", "-h 1 0 0 1 0 31x1+21+2.5 1 1 6.37839e+06 10 0 0 'a' 'Semi-eixo maior do elipsoide' a", "-h 1 0 0 1 0 31x1+21+3.5 1 1 0.0819919 10 0 0 'e' 'Excentricidade do elipsoide' e", "-h 1 0 0 1 0 31x1+21+5 0 0 0 10 0 0 'Lat0' 'Latitude da origem' lat0", "-h 1 0 0 1 0 31x1+21+6 0 0 -45 10 0 0 'Long0' 'Longitude do meridiano central' long0", "-h 1 0 0 1 0 31x1+21+7 1 1 0.9996 10 0 0 'k0' 'Coeficinte de deformacao' k0", "-h 1 0 0 1 0 31x1+21+8.5 0 0 0 10 0 0 'Lat' 'Latitude do ponto' lat", "-h 1 0 0 1 0 31x1+21+9.5 0 0 0 10 0 0 'Long' 'LOngitude do ponto' long", "-O 1 0 0 1 0 1 52x1+0+11 ' ' 'ASCII Output' 'Formatted ASCII output file' f", "-b +1+3 'Parametros do Elipsoide:' b1", "-b +1+6 'Parametros da origem:' b2", "-b +1+8.5 'Coordenadas do ponto:' b3", "-E", "-E", "-E", }; size_t clui_line_lookup[] = { 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20, 21,22,23,}; size_t clui_file_lookup[] = { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, 0,0,0,}; /* * array of uis filenames and line numbers for error messaging */ char *clui_filenames[] = { "$MATCHING/objects/kroutine/kgeoutm/uis/kgeoutm.pane", }; /* * UIS struct for clui */ uis_struct clui_uis_spec = { clui_uis, 23, clui_file_lookup, clui_line_lookup, clui_filenames, 1, 512};