gCAD3D 2.35
xa_grp.c File Reference

group functions (Grp_) More...

#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <stdarg.h>
#include <ctype.h>
#include "../gui/gui_types.h"
#include "../ut/ut_geo.h"
#include "../ut/ut_txt.h"
#include "../ut/ut_txfil.h"
#include "../ut/ut_os.h"
#include "../ut/ut_cast.h"
#include "../ut/ut_TX.h"
#include "../gr/ut_DL.h"
#include "../gr/ut_GL.h"
#include "xa.h"
#include "../xa/xa_mem.h"
#include "../xa/xa_uid.h"

Functions

int Grp_get__ (ObjDB **oTab)
 
int Grp_Start ()
 
int Grp_HiliClear ()
 
int Grp_Clear (int mode)
 
int Grp_init ()
 
int Grp_alloc ()
 
int Grp_realloc ()
 
int Grp_dump ()
 
int Grp_cbuf (char *cBuf, int cSiz)
 
int Grp_add__ (int typ, long dbi, long dli, int iUpd)
 
int Grp_add_all1 (int mod)
 
int Grp_del (int typ, long ind, int iUpd)
 
int Grp_typo_del (int typ)
 
int Grp_typ_del (int typ)
 
int Grp_res ()
 
int Grp_dlAdd ()
 
int Grp_hide (int mode)
 
int Grp_ck_def (int typ, long dbi)
 
int Grp_exp (char *fnam, char *dirNam)
 
int Grp_upd (int mode)
 
int Grp_get_nr ()
 

Variables

static ObjDBGrpTab = NULL
 
static int GrpMax = 0
 
static int GrpNr = 0
 

Detailed Description

group functions (Grp_)

=====================================================
List_functions_start:
Grp_ck_def check if obj is in group
Grp_init init obj-list
Grp_Start start filling group
Grp_Clear clear (reset) group
Grp_add__ add obj to obj-list
Grp_add_all1 add all objs to group (without hidden)
Grp_del remove obj from group
Grp_typ_del remove all objs of type from group
Grp_ck_def check if obj is in group
Grp_exp export (native) alle objects of obj-list --> file
Grp_res resolv list and add all parents to list
Grp_cbuf return list ob objs of group as text
Grp_dlAdd add all objs of group to DL-grp1
Grp_hide hide all objs of grp
Grp_upd Redraw &| update GrpNr-label
Grp_get_nr return nr of objs in group
List_functions_end:
=====================================================
see also
DL_grp1_copy copy all DL-obj with groupBit ON --> GroupList
UI_grpAdd

Function Documentation

int Grp_get__ ( ObjDB **  oTab)
RetCod = nr of objects in group
int Grp_Start ( )
int Grp_HiliClear ( )

unhilite all group-objects

int Grp_Clear ( int  mode)
Grp_Clear clear (reset) group
Input:
mode 2 unhili&redraw
1 Redraw
0 do not Redraw
int Grp_init ( )

init obj-list

int Grp_alloc ( )
int Grp_realloc ( )
int Grp_dump ( )
int Grp_cbuf ( char *  cBuf,
int  cSiz 
)
int Grp_add__ ( int  typ,
long  dbi,
long  dli,
int  iUpd 
)
add obj to GrpTab
Input:
dli -1 no dli (obj not visible)
-2 dli unknown (search)
iUpd 0 = update display;
1 = do not update display (yet)
2 = do not update display and do not test if already defined
see also DL_grp1__ (add obj to DL-group1 (hiliete) and to GrpTab)
int Grp_add_all1 ( int  mod)

Grp_add_all1 add all objs to group (without hidden) Input: mod modelNr to resolv; -1 = mainModel

int Grp_del ( int  typ,
long  ind,
int  iUpd 
)

remove obj from group iUpd 0=update display; 1=do not update display (yet)

int Grp_typo_del ( int  typ)
int Grp_typ_del ( int  typ)
int Grp_res ( )
obj-list Recursiv nach seinen Eltern absuchen und diese zufuegen
RetCod: nr of objs in group (GrpTab)
GrpTab[].stat = 0: newly added
GrpTab[].stat = 1: all parents searched and added ..
TODO: use APED_find_par__
int Grp_dlAdd ( )
int Grp_hide ( int  mode)
int Grp_ck_def ( int  typ,
long  dbi 
)
check if obj is in group
RetCod >= 0: yes, RetCod = index.
-1: no.
int Grp_exp ( char *  fnam,
char *  dirNam 
)
export (native) alle objects of obj-list --> file
int Grp_upd ( int  mode)
int Grp_get_nr ( )

Variable Documentation

ObjDB* GrpTab = NULL
static
int GrpMax = 0
static
int GrpNr = 0
static