ARB
Classes | Macros | Functions
AW_button.cxx File Reference
#include "aw_at.hxx"
#include "aw_select.hxx"
#include "aw_awar.hxx"
#include "aw_window_Xm.hxx"
#include "aw_msg.hxx"
#include "aw_root.hxx"
#include "aw_xargs.hxx"
#include "aw_varupdate.hxx"
#include "aw_localdef.hxx"
#include <arb_algo.h>
#include <ad_cb.h>
#include <Xm/Frame.h>
#include <Xm/ToggleB.h>
#include <Xm/Label.h>
#include <Xm/List.h>
#include <Xm/PushB.h>
#include <Xm/Text.h>
#include <Xm/TextF.h>
#include <Xm/ScrolledW.h>
#include <Xm/Scale.h>
Include dependency graph for AW_button.cxx:

Go to the source code of this file.

Classes

struct  TrackedAwarChange
 
struct  aw_toggle_data
 

Macros

#define SCALER_MIN_VALUE   0
 
#define SCALER_MAX_VALUE   1000
 
#define MIN_RIGHT_OFFSET   10
 
#define MIN_BOTTOM_OFFSET   10
 
#define MAX_LINE_LENGTH   200
 
#define SPACE_BEHIND_LABEL   10
 
#define BUTTON_TEXT_X_PADDING   4
 
#define BUTTON_TEXT_Y_PADDING   10
 
#define BUTTON_GRAPHIC_PADDING   12
 
#define FLAT_GRAPHIC_PADDING   4
 

Functions

void AW_variable_update_callback (Widget, XtPointer variable_update_struct, XtPointer call_data)
 
static void track_awar_change_cb (GBDATA *gbd, TrackedAwarChange *tac, GB_CB_TYPE cb_type)
 
static int calculate_scaler_value (AW_awar *awar, AW_ScalerType scalerType)
 
static void write_scalervalue_to_awar (int scalerVal, AW_awar *awar, AW_ScalerType scalerType)
 
static void AW_value_changed_callback (Widget, XtPointer rooti, XtPointer)
 
void aw_attach_widget (Widget w, AW_at *_at, int default_width)
 
const charAW_get_pixmapPath (const char *pixmapName)
 
static charpixmapPath (const char *pixmapName)
 
static __ATTR__USERESULT GB_ERROR detect_bitmap_size (const char *pixmapname, int *width, int *height)
 
void calculate_textsize (const char *str, int *width, int *height)
 
void aw_detect_text_size (const char *text, size_t &width, size_t &height)
 
static void scalerChanged_cb (Widget scale, XtPointer variable_update_struct, XtPointer call_data)
 
static void scroll_sellist (Widget scrolledList, bool upwards)
 
static void scroll_sellist_up (Widget scrolledList, XEvent *, String *, Cardinal *)
 
static void scroll_sellist_dn (Widget scrolledList, XEvent *, String *, Cardinal *)
 

Macro Definition Documentation

#define SCALER_MIN_VALUE   0
#define SCALER_MAX_VALUE   1000
#define MIN_RIGHT_OFFSET   10

Referenced by aw_attach_widget().

#define MIN_BOTTOM_OFFSET   10

Referenced by aw_attach_widget().

#define MAX_LINE_LENGTH   200

Definition at line 277 of file AW_button.cxx.

Referenced by detect_bitmap_size().

#define SPACE_BEHIND_LABEL   10
#define BUTTON_TEXT_X_PADDING   4
#define BUTTON_TEXT_Y_PADDING   10
#define BUTTON_GRAPHIC_PADDING   12
#define FLAT_GRAPHIC_PADDING   4

Function Documentation

void AW_variable_update_callback ( Widget  ,
XtPointer  variable_update_struct,
XtPointer  call_data 
)
static void track_awar_change_cb ( GBDATA gbd,
TrackedAwarChange tac,
GB_CB_TYPE  cb_type 
)
static
static int calculate_scaler_value ( AW_awar awar,
AW_ScalerType  scalerType 
)
static
static void write_scalervalue_to_awar ( int  scalerVal,
AW_awar awar,
AW_ScalerType  scalerType 
)
static
static void AW_value_changed_callback ( Widget  ,
XtPointer  rooti,
XtPointer   
)
static

Definition at line 181 of file AW_button.cxx.

References AW_root::value_changed.

Referenced by AW_window::create_input_field(), and AW_window::create_text_field().

void aw_attach_widget ( Widget  w,
AW_at _at,
int  default_width 
)
const char* AW_get_pixmapPath ( const char pixmapName)
static char* pixmapPath ( const char pixmapName)
static

Definition at line 272 of file AW_button.cxx.

References AW_get_pixmapPath().

Referenced by detect_bitmap_size(), and AW_window::update_toggle().

static __ATTR__USERESULT GB_ERROR detect_bitmap_size ( const char pixmapname,
int width,
int height 
)
static
void calculate_textsize ( const char str,
int width,
int height 
)
inline

Definition at line 355 of file AW_button.cxx.

Referenced by AW_window::create_button().

void aw_detect_text_size ( const char text,
size_t width,
size_t height 
)
static void scalerChanged_cb ( Widget  scale,
XtPointer  variable_update_struct,
XtPointer  call_data 
)
static
static void scroll_sellist ( Widget  scrolledList,
bool  upwards 
)
static

Definition at line 1196 of file AW_button.cxx.

References force_in_range(), and NULp.

Referenced by scroll_sellist_dn(), and scroll_sellist_up().

static void scroll_sellist_up ( Widget  scrolledList,
XEvent *  ,
String *  ,
Cardinal *   
)
static

Definition at line 1212 of file AW_button.cxx.

References scroll_sellist().

Referenced by AW_window::create_selection_list().

static void scroll_sellist_dn ( Widget  scrolledList,
XEvent *  ,
String *  ,
Cardinal *   
)
static

Definition at line 1213 of file AW_button.cxx.

References scroll_sellist().

Referenced by AW_window::create_selection_list().