gCAD3D 2.35
gui_gtk2/gtk_dialog.h File Reference

Go to the source code of this file.

Functions

int GUI_MsgBox (char *text)
 
void GUI_DialogYN (char *, void *)
 
int GUI_GetText (char *text, char *label, int, void *)
 
int GUI_GetTextCB (void *, void *)
 
int GUI_Color_select (int *ir, int *ig, int *ib)
 
int GUI_DialogYN_CB (void *parent, void *data)
 
void * GUI_Slider__ (void *parent, int typ, void *funcnam, double valMin, double valMax, double valStart, int siz)
 
double GUI_Slider_get (void *wsl1)
 
void GUI_Slider_set (void *wsl1, double newVal)
 
int GUI_File_cb (void *parent, void *event, void *data)
 
int GUI_Slider_cb (void *parent, void *data)
 

Function Documentation

int GUI_MsgBox ( char *  text)
display text, OK-Button.
Works also if GTK is not yet up.
display text, OK-Button.
Works also if GTK is not yet up.
void GUI_DialogYN ( char *  ,
void *   
)
GUI_DialogYN dialogWindow with text, OK-Button and Cancel-Button.
<funcnam> is called with int-value UI_FuncOK or UI_FuncCancel.
Input:
text multiple lines with \n
funcnam callbackfunktion for button-press
funcnam prototyp:
int funcnam (MemObj *parent, void **data);
Example:
GUI_DialogYN ("OK to save file xy", f_CB_save);
//=====================================================================
int f_CB_save (MemObj *mo, void **data) {
//=====================================================================
int idat;
printf("f_CB_save %d\n",idat);
switch(idat) {
case UI_FuncOK:
// save ...
break;
// skip saving ...
break;
}
return 0;
}
GUI_DialogYN dialogWindow with text, OK-Button and Cancel-Button.
<funcnam> is called with int-value UI_FuncOK or UI_FuncCancel.
Input:
text multiple lines with \n
funcnam callbackfunktion for button-press
funcnam prototyp:
int funcnam (MemObj *parent, void **data);
Example:
GUI_DialogYN ("OK to save file xy", f_CB_save);
//=====================================================================
int f_CB_save (MemObj *mo, void **data) {
//=====================================================================
int idat;
printf("f_CB_save %d\n",idat);
switch(idat) {
case UI_FuncOK:
// save ...
break;
// skip saving ...
break;
}
return 0;
}
int GUI_GetText ( char *  text,
char *  label,
int  ,
void *   
)
int GUI_GetTextCB ( void *  ,
void *   
)
int GUI_Color_select ( int *  ir,
int *  ig,
int *  ib 
)
GUI_Color_select select-color-Dialog. Modal (wait).
Returns 3 colors as 16-bit-integers.
Returncode 0=OK; -1=cancel.
GUI_Color_select select-color-Dialog. Modal (wait).
Returns 3 colors as 16-bit-integers.
Returncode 0=OK; -1=cancel.
int GUI_DialogYN_CB ( void *  parent,
void *  data 
)

INTERNAL callback of GUI_DialogYN

INTERNAL callback of GUI_DialogYN

void* GUI_Slider__ ( void *  parent,
int  typ,
void *  funcnam,
double  valMin,
double  valMax,
double  valStart,
int  siz 
)
double GUI_Slider_get ( void *  wsl1)
void GUI_Slider_set ( void *  wsl1,
double  newVal 
)
int GUI_File_cb ( void *  parent,
void *  event,
void *  data 
)
int GUI_Slider_cb ( void *  parent,
void *  data 
)