===================================================== Liste_Funktionen_Beginn: ED_query_CmdMode aktuelle Zeile into ED_buf1 einlesen, ihren Typ feststellen ED_new_File Ein Datei ins Hauptprog laden ED_add_File Insert Datei filnam in den Hauptbuffer an Position cpos ED_add_Def einen DefText (zB "P123=" in die Datei einfuegen; ED_add_Line eine komplette Line zufuegen und abarbeiten ED_add_Text entscheiden ob kompl. Zeile und nur zufuegen oder auch abarb ED_Get_LineNr Zeilennunmmer der aktuellen Curpos (ED_lnr_act) holen. ED_GetNxtLin ED_Read_Line Read aus File|Mem ED_work_END das "RUN" ED_work_CurSet Cursor wurde in Editor-Line new_lnr_act gesetzt .. ED_work_Update work from startingLineNr to end ED_Run Wird vom GO/STEP/END-Button gerufen. ED_newPos cursor in new line; ED_work_ENTER ED_work_STEP ED_work_CAD ED_work_GO ED_cont_file ED_work_file ED_update Filesize changed - update Mem (Edi -> Memory) ED_set_lnr_act ED_get_lnr_act see also ED_Get_LineNr ED_get_actPos get position of active Line (ED_lnr_act) in mem ED_lnr_bis__ ED_lnr_bis setzen ED_del_on ED_del_off ED_del_block delete Block; In: first line, last line. ED_query_mode ED_skip_end ED_skip_start ED_enter ED_step ED_go ED_lnr_reset ED_PP_run ED_work_PP ED_work_dyn ED_get_mac_fil ED_Init_All ED_Init ED_Reset ED_addRange decode ObjRanges and add them to MemTab(ObjRange) Liste_Funktionen_Ende: ===================================================== See also APED_ (APED_dec_defLn ..)
#include "MS_Def0.h"
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "../ut/ut_geo.h"
#include "../ut/ut_txt.h"
#include "../ut/ut_TX.h"
#include "../ut/ut_os.h"
#include "../ut/ut_txfil.h"
#include "../ut/ut_memTab.h"
#include "../gtk/ut_gtk.h"
#include "../gtk/ut_gtkEd.h"
#include "../gr/ut_UI.h"
#include "../gr/ut_DL.h"
#include "../gr/ut_gr.h"
#include "../ci/NC_Main.h"
#include "../db/ut_DB.h"
#include "xa.h"
#include "xa_mem.h"
#include "xa_ui.h"
#include "xa_ed.h"
#include "xa_undo.h"
Defines | |
#define | ED_delIndmax 10 |
Functions | |
typedef_MemTab (ObjRange) | |
int | ED_setLnr (long lNr) |
================================================================ | |
int | ED_update (long ipos) |
================================================================ | |
int | ED_newPos () |
================================================================ | |
int | ED_lnr_bis__ (int lNr) |
================================================================ | |
int | ED_query_CmdMode () |
=========================================================================== | |
int | ED_new_File (char *filnam) |
====================================================================== | |
int | ED_add_File (char *filnam, int cpos) |
====================================================================== | |
int | ED_add_Def (char *buf) |
====================================================================== | |
int | ED_add_Line (char *buf) |
====================================================================== | |
int | ED_add_Text (int typ, long ind, char *buf) |
====================================================================== | |
int | ED_Init_All () |
====================================================================== | |
int | ED_get_delay () |
int | ED_Init () |
====================================================================== | |
int | ED_Reset () |
========================================================================== | |
void | ED_del_on () |
=========================================================================== | |
void | ED_del_off () |
=========================================================================== | |
int | ED_del_block (int mode, char *fromLn, char *toLn) |
================================================================ | |
int | ED_query_mode () |
========================================================================== | |
int | ED_skip_end () |
========================================================================== | |
int | ED_skip_start () |
========================================================================== | |
int | ED_enter () |
========================================================================== | |
int | ED_step () |
========================================================================== | |
int | ED_go () |
========================================================================== | |
int | ED_Get_LineNr () |
************************************************************************** | |
int | ED_GetNxtLin (int *lnr, char *lbuf) |
========================================================================== | |
int | ED_Read_Line (char *buf) |
************************************************************************* | |
int | ED_lnr_mac (int mode) |
============================================================= | |
int | ED_lnr_reset () |
========================================================================== | |
void | ED_work_PP () |
======================================================================= | |
int | ED_work_dyn () |
================================================================ | |
int | ED_work_END (int mode) |
================================================================ | |
void | ED_work_ENTER () |
========================================================================== | |
int | ED_work_STEP () |
========================================================================== | |
int | ED_work_CAD (int lNr, char *cbuf) |
=========================================================================== | |
int | ED_work_CurSet (int new_lnr_act) |
=========================================================================== | |
int | ED_work_GO () |
========================================================================== | |
int | ED_cont_file () |
========================================================================= | |
int | ED_file__ (int mode, char *fNam) |
================================================================ | |
int | ED_work_file (char *filnam) |
========================================================================= | |
int | ED_set_lnr_von (int lNr) |
========================================================================= | |
int | ED_set_lnr_act (int lnr_act) |
========================================================================= | |
int | ED_get_lnr_act () |
========================================================================= | |
char * | ED_get_actPos () |
================================================================ | |
int | ED_get_mac_fil () |
========================================================================= | |
int | ED_work_Update (int lNr) |
int | ED_Run () |
************************************************************************* | |
void | ED_set_delay (int delaytime) |
========================================================================== | |
void | ED_PP_run (char *ppnam) |
************************************************************************ | |
int | ED_addRange (MemTab(ObjRange)*rTab, char *lBuf) |
Variables | |
AP_STAT | AP_stat |
progress of Start | |
char | WC_modnam [128] |
active Modelname - without path | |
int | WC_stat_bound |
ON OFF; Draw boundary of Flächen J/N. | |
int | AP_src |
AP_SRC_MEM or AP_SRC_EDI. | |
int | WC_mod_stat |
-1=primary Model is active; | |
ColRGB | AP_defcol |
die DefaultColor des aktiven (sub)Model | |
int | AP_indCol |
der DL-Index der aktuellen defCol | |
int | WC_sur_ind |
Der Index auf die ActiveConstrPlane. | |
GIO_WinEd | winED |
int | UI_InpMode |
int | xa_fl_TxMem |
int | UI_InpSM |
int | APT_stat_act |
int | UP_level |
static char | AP_filnam [256] |
static int | ED_mode |
static int | ED_mode_old |
static int | ED_delay = 0 |
static FILE * | maclun = NULL |
int | APT_mac_fil = OFF |
static int | ED_lnr_act |
static int | ED_lnr_von |
static int | ED_lnr_bis |
static int | ED_lnr_max |
static char | cmdBuf [1024] |
static char | ED_buf1 [256] |
static int | ED_buf1Len |
long | UI_Ed_fsiz |
static int | ED_delInd |
static int | ED_delStat |
#define ED_delIndmax 10 |
typedef_MemTab | ( | ObjRange | ) |
int ED_setLnr | ( | long | lNr | ) |
================================================================
================================================================
int ED_update | ( | long | ipos | ) |
================================================================
================================================================ Filesize changed - update Mem (Edi -> Memory) SOFORT !
int ED_newPos | ( | ) |
================================================================
================================================================ ED_newPos cursor in new line; use in UI_EdButtonRelease (click into Line) use in UI_EdKeyRelease (CurUp/Dwn)
int ED_lnr_bis__ | ( | int | lNr | ) |
================================================================
================================================================ lNr >= 0 - setzen lNr = -1 - lesen
int ED_query_CmdMode | ( | ) |
===========================================================================
=========================================================================== aktuelle Zeile into ED_buf1 einlesen, ihren Typ feststellen Retcod: -1=LeereZeile, 0=Defline, 1=Direktcommand, 2=IndirektCommand
int ED_new_File | ( | char * | filnam | ) |
======================================================================
====================================================================== Ein Datei ins Hauptprog laden
int ED_add_File | ( | char * | filnam, | |
int | cpos | |||
) |
======================================================================
====================================================================== Insert Datei filnam in den Hauptbuffer an Position cpos. cpos < 0: hintanhaengen !
int ED_add_Def | ( | char * | buf | ) |
======================================================================
====================================================================== einen DefText (zB "P123=" in die Datei einfuegen; muss am Beginn einer zeile liegen.
int ED_add_Line | ( | char * | buf | ) |
======================================================================
====================================================================== eine komplette Line zufuegen und abarbeiten
int ED_add_Text | ( | int | typ, | |
long | ind, | |||
char * | buf | |||
) |
======================================================================
======================================================================
int ED_Init_All | ( | ) |
======================================================================
======================================================================
int ED_get_delay | ( | ) |
int ED_Init | ( | ) |
======================================================================
======================================================================
int ED_Reset | ( | ) |
==========================================================================
==========================================================================
void ED_del_on | ( | ) |
===========================================================================
===========================================================================
void ED_del_off | ( | ) |
===========================================================================
===========================================================================
int ED_del_block | ( | int | mode, | |
char * | fromLn, | |||
char * | toLn | |||
) |
================================================================
================================================================ ED_del_block delete Block; In: first line, last line. Input: mode = 0 do not delete toLn 1 also delete toLn
int ED_query_mode | ( | ) |
==========================================================================
========================================================================== 1=ED_mode_go=Run, 3=ED_mode_enter=Edit
int ED_skip_end | ( | ) |
==========================================================================
==========================================================================
int ED_skip_start | ( | ) |
==========================================================================
==========================================================================
int ED_enter | ( | ) |
==========================================================================
========================================================================== CR by Keyboard; es daf kein CRLF zugefuegt werden ! (sonst doppelt)
int ED_step | ( | ) |
==========================================================================
==========================================================================
int ED_go | ( | ) |
==========================================================================
==========================================================================
int ED_Get_LineNr | ( | ) |
**************************************************************************
int ED_GetNxtLin | ( | int * | lnr, | |
char * | lbuf | |||
) |
==========================================================================
========================================================================== Liefert naechste Zeile und ZeilenNr. Als Retcod = ihre Länge Dzt nur used for read Fortsetzungszeilen von APT_decode_cv
int ED_Read_Line | ( | char * | buf | ) |
*************************************************************************
int ED_lnr_mac | ( | int | mode | ) |
=============================================================
============================================================= 0 = save ED_lnr_bis (beim CALL) und set to 999999 1 = restor ED_lnr_bis (nach dem END MAC)
int ED_lnr_reset | ( | ) |
==========================================================================
==========================================================================
void ED_work_PP | ( | ) |
=======================================================================
=======================================================================
int ED_work_dyn | ( | ) |
================================================================
================================================================
int ED_work_END | ( | int | mode | ) |
================================================================
================================================================ das "RUN" mode unused !
void ED_work_ENTER | ( | ) |
==========================================================================
========================================================================== es wurde CR am Keyb eingegeben
int ED_work_STEP | ( | ) |
==========================================================================
==========================================================================
int ED_work_CAD | ( | int | lNr, | |
char * | cbuf | |||
) |
===========================================================================
=========================================================================== 1) bei jedem Tab wenn alle Inputs fertig 2) mit OK (CR) wenn alle Inputs fertig
int ED_work_CurSet | ( | int | new_lnr_act | ) |
===========================================================================
=========================================================================== Cursor wurde in Editor-Line new_lnr_act gesetzt. Alle Zeilen bis einschliesslich Zeile new_lnr_act anzeigen (ausfuehren). Obj der Zeile new_lnr_act hiliten
von der zuletzt bearbeiteten Zeile bis zu lNr new_lnr_act abarbeiten
int ED_work_GO | ( | ) |
==========================================================================
==========================================================================
int ED_cont_file | ( | ) |
=========================================================================
=========================================================================
int ED_file__ | ( | int | mode, | |
char * | fNam | |||
) |
================================================================
================================================================ 0 = clear/init; 1 = openNext 2 = closeActive 3 = rewindActive (zB fuer JUMP)
int ED_work_file | ( | char * | filnam | ) |
=========================================================================
========================================================================= nächster call an ED_Read_Line soll nicht die nächste aktuelle Zeile liefern sondern zuerst das File filnam abarbeiten CloseFile macht auch ED_Read_Line.
Bei subModel UP_level=-1
int ED_set_lnr_von | ( | int | lNr | ) |
=========================================================================
========================================================================= see also AP_lNr_set
int ED_set_lnr_act | ( | int | lnr_act | ) |
=========================================================================
========================================================================= see also AP_lNr_set
int ED_get_lnr_act | ( | ) |
=========================================================================
========================================================================= see also AP_lNr_set
char* ED_get_actPos | ( | ) |
================================================================
================================================================ get position of active Line (ED_lnr_act) in mem
int ED_get_mac_fil | ( | ) |
=========================================================================
=========================================================================
int ED_work_Update | ( | int | lNr | ) |
int ED_Run | ( | ) |
*************************************************************************
void ED_set_delay | ( | int | delaytime | ) |
==========================================================================
========================================================================== An den Beginn der Datei rücksetzen; aber kein WC_Init (für JUMP's usw)
void ED_PP_run | ( | char * | ppnam | ) |
************************************************************************
************************************************************************
int ED_addRange | ( | MemTab(ObjRange)* | rTab, | |
char * | lBuf | |||
) |
char WC_modnam[128] |
active Modelname - without path
int WC_stat_bound |
ON OFF; Draw boundary of Flächen J/N.
int AP_src |
AP_SRC_MEM or AP_SRC_EDI.
int WC_mod_stat |
-1=primary Model is active;
int AP_indCol |
der DL-Index der aktuellen defCol
int WC_sur_ind |
Der Index auf die ActiveConstrPlane.
int UI_InpMode |
int xa_fl_TxMem |
int UI_InpSM |
int APT_stat_act |
int UP_level |
char AP_filnam[256] [static] |
int ED_mode [static] |
int ED_mode_old [static] |
int ED_delay = 0 [static] |
FILE* maclun = NULL [static] |
int APT_mac_fil = OFF |
int ED_lnr_act [static] |
int ED_lnr_von [static] |
int ED_lnr_bis [static] |
int ED_lnr_max [static] |
char cmdBuf[1024] [static] |
char ED_buf1[256] [static] |
int ED_buf1Len [static] |
long UI_Ed_fsiz |
int ED_delInd [static] |
int ED_delStat [static] |