pcb 4.1.1
An interactive printed circuit board layout editor.
|
#include <stdio.h>
#include <stdarg.h>
#include <stdlib.h>
#include <string.h>
#include "xincludes.h"
#include "compat.h"
#include "global.h"
#include "data.h"
#include "set.h"
#include "misc.h"
#include "mymem.h"
#include "pcb-printf.h"
#include "hid.h"
#include "../hidint.h"
#include "lesstif.h"
Go to the source code of this file.
Data Structures | |
struct | StyleButtons |
Defines | |
#define | stdarg(t, v) XtSetArg(args[n], t, v); n++ |
Enumerations | |
enum | StyleValues { SSthick, SSdiam, SShole, SSkeep, SSNUM } |
Functions | |
static int | hash (char *cp) |
static int | RouteStylesChanged (int argc, char **argv, Coord x, Coord y) |
static void | update_one_value (int i, Coord v) |
static void | update_values () |
void | lesstif_styles_update_values () |
static void | update_style_buttons () |
static void | style_value_cb (Widget w, int i, void *cbs) |
static void | units_cb () |
static Widget | style_value (int i) |
static void | style_name_cb (Widget w, int i, XmToggleButtonCallbackStruct *cbs) |
static void | style_set_cb (Widget w, int i, XmToggleButtonCallbackStruct *cbs) |
static void | style_selected (Widget w, int i, XmToggleButtonCallbackStruct *cbs) |
static Widget | style_button (int i) |
static int | AdjustStyle (int argc, char **argv, Coord x, Coord y) |
void | lesstif_insert_style_buttons (Widget menu) |
Variables | |
static Arg | args [30] |
static int | n |
static Widget | style_dialog = 0 |
static Widget | style_values [SSNUM] |
static Widget | style_pb [NUM_STYLES] |
static Widget | units_pb [NUM_STYLES] |
static int | name_hashes [NUM_STYLES] |
static Widget | value_form |
static Widget | value_labels |
static Widget | value_texts |
static Widget | units_form |
static int | local_update = 0 |
XmString | xms_mm |
XmString | xms_mil |
static const Unit * | unit = 0 |
static XmString | ustr |
static StyleButtons * | style_button_list = 0 |
static int | num_style_buttons = 0 |
static char * | value_names [] |
static const char | adjuststyle_syntax [] = "AdjustStyle()" |
static const char | adjuststyle_help [] = "Displays the route style adjustment window." |
HID_Action | lesstif_styles_action_list [] |
Definition at line 48 of file styles.c.
Referenced by AdjustStyle(), lesstif_insert_style_buttons(), RouteStylesChanged(), style_button(), style_value(), and update_one_value().
enum StyleValues |
Definition at line 347 of file styles.c.
References args, SettingType::grid_unit, hash(), mainwind, n, RouteStyleType::Name, name_hashes, PCB, PCBType::RouteStyle, Settings, SSNUM, stdarg, style_button(), style_dialog, style_pb, style_value(), style_values, unit::suffix, units_form, update_style_buttons(), update_values(), ustr, value_form, value_labels, and value_texts.
static int hash | ( | char * | cp | ) | [static] |
Definition at line 69 of file styles.c.
Referenced by AdjustStyle(), edge_foreach_face(), edge_foreach_node(), get_vertex_bcl(), gts_edges_from_vertices(), gts_faces_from_edges(), gts_graph_foreach_edge(), gts_psurface_write(), gts_segments_from_vertices(), gts_triangles_from_edges(), gts_vertices_from_segments(), hid_cache_color(), RouteStylesChanged(), and vertex_foreach_face().
void lesstif_insert_style_buttons | ( | Widget | menu | ) |
Definition at line 440 of file styles.c.
References args, n, RouteStyleType::Name, num_style_buttons, PCB, realloc(), PCBType::RouteStyle, s, stdarg, style_selected(), update_style_buttons(), StyleButtons::w, and XmStringCreatePCB().
Referenced by add_resource_to_menu().
void lesstif_styles_update_values | ( | ) |
Definition at line 120 of file styles.c.
References SettingType::grid_unit, lesstif_update_status_line(), Settings, style_dialog, unit::suffix, update_values(), and ustr.
Referenced by SetUnits().
Definition at line 413 of file styles.c.
References args, hash(), n, RouteStyleType::Name, name_hashes, num_style_buttons, PCB, PCBType::RouteStyle, stdarg, style_dialog, style_pb, update_style_buttons(), update_values(), and XmStringCreatePCB().
Referenced by style_name_cb().
static Widget style_button | ( | int | i | ) | [static] |
Definition at line 295 of file styles.c.
References args, n, RouteStyleType::Name, PCB, PCBType::RouteStyle, stdarg, style_dialog, style_name_cb(), style_pb, style_selected(), style_set_cb(), value_form, and XmStringCreatePCB().
Referenced by AdjustStyle().
static void style_name_cb | ( | Widget | w, |
int | i, | ||
XmToggleButtonCallbackStruct * | cbs | ||
) | [static] |
Definition at line 240 of file styles.c.
References lesstif_prompt_for(), RouteStyleType::Name, PCB, PCBType::RouteStyle, and RouteStylesChanged().
Referenced by style_button().
static void style_selected | ( | Widget | w, |
int | i, | ||
XmToggleButtonCallbackStruct * | cbs | ||
) | [static] |
Definition at line 259 of file styles.c.
References RouteStyleType::Diameter, RouteStyleType::Hole, RouteStyleType::Keepaway, lesstif_update_status_line(), n, num_style_buttons, PCB, PCBType::RouteStyle, SetKeepawayWidth(), SetLineSize(), SetViaDrillingHole(), SetViaSize(), style, style_dialog, style_pb, RouteStyleType::Thick, and update_values().
Referenced by lesstif_insert_style_buttons(), and style_button().
static void style_set_cb | ( | Widget | w, |
int | i, | ||
XmToggleButtonCallbackStruct * | cbs | ||
) | [static] |
Definition at line 249 of file styles.c.
References RouteStyleType::Diameter, RouteStyleType::Hole, SettingType::Keepaway, RouteStyleType::Keepaway, SettingType::LineThickness, PCB, PCBType::RouteStyle, Settings, RouteStyleType::Thick, update_style_buttons(), SettingType::ViaDrillingHole, and SettingType::ViaThickness.
Referenced by style_button().
static Widget style_value | ( | int | i | ) | [static] |
Definition at line 196 of file styles.c.
References args, n, stdarg, style_value_cb(), units_cb(), units_form, units_pb, ustr, value_labels, value_names, and value_texts.
Referenced by AdjustStyle().
static void style_value_cb | ( | Widget | w, |
int | i, | ||
void * | cbs | ||
) | [static] |
Definition at line 157 of file styles.c.
References GetValueEx(), SettingType::Keepaway, SettingType::LineThickness, local_update, n, s, Settings, SSdiam, SShole, SSkeep, SSthick, unit::suffix, update_style_buttons(), SettingType::ViaDrillingHole, and SettingType::ViaThickness.
Referenced by style_value().
static void units_cb | ( | ) | [static] |
Definition at line 185 of file styles.c.
References get_unit_struct(), unit::suffix, update_values(), and ustr.
Referenced by style_value().
static void update_one_value | ( | int | i, |
Coord | v | ||
) | [static] |
Definition at line 96 of file styles.c.
References unit::allow, args, n, pcb_snprintf(), stdarg, style_values, units_pb, and ustr.
Referenced by update_values().
static void update_style_buttons | ( | ) | [static] |
Definition at line 133 of file styles.c.
References hid_get_flag(), n, num_style_buttons, style_dialog, and style_pb.
Referenced by AdjustStyle(), lesstif_insert_style_buttons(), RouteStylesChanged(), style_set_cb(), and style_value_cb().
static void update_values | ( | ) | [static] |
Definition at line 108 of file styles.c.
References SettingType::Keepaway, lesstif_update_status_line(), SettingType::LineThickness, local_update, Settings, SSdiam, SShole, SSkeep, SSthick, update_one_value(), SettingType::ViaDrillingHole, and SettingType::ViaThickness.
Referenced by AdjustStyle(), lesstif_styles_update_values(), RouteStylesChanged(), style_selected(), and units_cb().
const char adjuststyle_help[] = "Displays the route style adjustment window." [static] |
const char adjuststyle_syntax[] = "AdjustStyle()" [static] |
Arg args[30] [static] |
Definition at line 46 of file styles.c.
Referenced by AdjustStyle(), lesstif_insert_style_buttons(), RouteStylesChanged(), style_button(), style_value(), and update_one_value().
{ {"AdjustStyle", 0, AdjustStyle, adjuststyle_help, adjuststyle_syntax}, {"RouteStylesChanged", 0, RouteStylesChanged, routestyleschanged_help, routestyleschanged_syntax} }
int local_update = 0 [static] |
Definition at line 62 of file styles.c.
Referenced by style_value_cb(), and update_values().
int n [static] |
Definition at line 47 of file styles.c.
Referenced by AdjustStyle(), lesstif_insert_style_buttons(), RouteStylesChanged(), style_button(), style_selected(), style_value(), style_value_cb(), update_one_value(), and update_style_buttons().
int name_hashes[NUM_STYLES] [static] |
Definition at line 60 of file styles.c.
Referenced by AdjustStyle(), and RouteStylesChanged().
int num_style_buttons = 0 [static] |
Definition at line 87 of file styles.c.
Referenced by lesstif_insert_style_buttons(), RouteStylesChanged(), style_selected(), and update_style_buttons().
StyleButtons* style_button_list = 0 [static] |
Widget style_dialog = 0 [static] |
Definition at line 56 of file styles.c.
Referenced by AdjustStyle(), lesstif_styles_update_values(), RouteStylesChanged(), style_button(), style_selected(), and update_style_buttons().
Widget style_pb[NUM_STYLES] [static] |
Definition at line 58 of file styles.c.
Referenced by AdjustStyle(), RouteStylesChanged(), style_button(), style_selected(), and update_style_buttons().
Widget style_values[SSNUM] [static] |
Definition at line 57 of file styles.c.
Referenced by AdjustStyle(), and update_one_value().
Definition at line 65 of file styles.c.
Referenced by gcode_do_export(), ghid_coord_entry_new(), hid_parse_command_line(), hid_set_attribute(), and parse_optionv().
Widget units_form |
Definition at line 61 of file styles.c.
Referenced by AdjustStyle(), and style_value().
Widget units_pb[NUM_STYLES] [static] |
Definition at line 59 of file styles.c.
Referenced by style_value(), and update_one_value().
XmString ustr [static] |
Definition at line 66 of file styles.c.
Referenced by AdjustStyle(), lesstif_styles_update_values(), style_value(), units_cb(), and update_one_value().
Widget value_form [static] |
Definition at line 61 of file styles.c.
Referenced by AdjustStyle(), and style_button().
Widget value_labels |
Definition at line 61 of file styles.c.
Referenced by AdjustStyle(), and style_value().
char* value_names[] [static] |
{ "Thickness", "Diameter", "Hole", "Keepaway" }
Definition at line 89 of file styles.c.
Referenced by style_value().
Widget value_texts |
Definition at line 61 of file styles.c.
Referenced by AdjustStyle(), and style_value().