Index: trunk/src/crosshair.c =================================================================== --- trunk/src/crosshair.c (revision 30977) +++ trunk/src/crosshair.c (revision 30978) @@ -1058,7 +1058,7 @@ pcb_render->set_color(pcb_crosshair.GC, &pcbhl_conf.appearance.color.cross); pcb_hid_set_draw_xor(pcb_crosshair.GC, 1); - pcb_hid_set_line_cap(pcb_crosshair.GC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_crosshair.GC, rnd_cap_round); pcb_hid_set_line_width(pcb_crosshair.GC, 1); } Index: trunk/src/draw.c =================================================================== --- trunk/src/draw.c (revision 30977) +++ trunk/src/draw.c (revision 30978) @@ -273,7 +273,7 @@ pcb_render->set_drawing_mode(pcb_render, PCB_HID_COMP_RESET, pcb_draw_out.direct, info->drawn_area); pcb_render->set_drawing_mode(pcb_render, PCB_HID_COMP_POSITIVE_XOR, pcb_draw_out.direct, info->drawn_area); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_hid_set_draw_xor(pcb_draw_out.fgGC, 1); if (PCB->SubcOn) { @@ -312,7 +312,7 @@ /* Draw pins' and pads' names */ pcb_render->set_drawing_mode(pcb_render, PCB_HID_COMP_RESET, pcb_draw_out.direct, info->drawn_area); pcb_render->set_drawing_mode(pcb_render, PCB_HID_COMP_POSITIVE, pcb_draw_out.direct, info->drawn_area); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.fgGC, 0); if (PCB->SubcOn) { info->objcb.subc.per_side = per_side; @@ -743,7 +743,7 @@ if (lflg & PCB_LYT_COPPER) { delayed_terms_enabled = pcb_true; pcb_hid_set_line_width(pcb_draw_out.fgGC, 1); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_square); pcb_r_search(Layer->polygon_tree, info->drawn_area, NULL, pcb_poly_draw_term_callback, info, NULL); delayed_terms_enabled = pcb_false; may_have_delayed = 1; @@ -1094,11 +1094,11 @@ hid->set_color(pcb_draw_out.backpadGC, &conf_core.appearance.color.invisible_objects); hid->set_color(pcb_draw_out.padselGC, &conf_core.appearance.color.selected); pcb_hid_set_line_width(pcb_draw_out.backpadGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.backpadGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.backpadGC, rnd_cap_square); pcb_hid_set_line_width(pcb_draw_out.padselGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.padselGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.padselGC, rnd_cap_square); pcb_hid_set_line_width(pcb_draw_out.padGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.padGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.padGC, rnd_cap_square); } static void expose_end(pcb_output_t *save) Index: trunk/src/draw_ly_spec.c =================================================================== --- trunk/src/draw_ly_spec.c (revision 30977) +++ trunk/src/draw_ly_spec.c (revision 30978) @@ -291,7 +291,7 @@ pcb_render->set_drawing_mode(pcb_render, PCB_HID_COMP_POSITIVE, pcb_draw_out.direct, info->drawn_area); pcb_render->set_color(pcb_draw_out.fgGC, &PCB->Data->Layer[goutl->lid[0]].meta.real.color); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.fgGC, conf_core.design.min_wid); pcb_render->draw_rect(pcb_draw_out.fgGC, 0, 0, PCB->hidlib.size_x, PCB->hidlib.size_y); Index: trunk/src/librnd/core/hid.h =================================================================== --- trunk/src/librnd/core/hid.h (revision 30977) +++ trunk/src/librnd/core/hid.h (revision 30978) @@ -1,5 +1,5 @@ -#ifndef PCB_HID_H -#define PCB_HID_H +#ifndef RND_HID_H +#define RND_HID_H #include #include @@ -11,18 +11,18 @@ #include /* attribute dialog properties */ -typedef enum pcb_hat_property_e { - PCB_HATP_GLOBAL_CALLBACK, - PCB_HATP_max -} pcb_hat_property_t; +typedef enum rnd_hat_property_e { + RND_HATP_GLOBAL_CALLBACK, + RND_HATP_max +} rnd_hat_property_t; typedef enum { - PCB_HID_MOUSE_PRESS, - PCB_HID_MOUSE_RELEASE, - PCB_HID_MOUSE_MOTION, - PCB_HID_MOUSE_POPUP /* "right click", open context-specific popup */ -} pcb_hid_mouse_ev_t; + RND_HID_MOUSE_PRESS, + RND_HID_MOUSE_RELEASE, + RND_HID_MOUSE_MOTION, + RND_HID_MOUSE_POPUP /* "right click", open context-specific popup */ +} rnd_hid_mouse_ev_t; /* Human Interface Device */ @@ -48,10 +48,10 @@ /* Line end cap styles. The cap *always* extends beyond the coordinates given, by half the width of the line. */ typedef enum { - pcb_cap_invalid = -1, - pcb_cap_square, /* square pins or pads when drawn using a line */ - pcb_cap_round /* for normal traces, round pins */ -} pcb_cap_style_t; + rnd_cap_invalid = -1, + rnd_cap_square, /* square pins or pads when drawn using a line */ + rnd_cap_round /* for normal traces, round pins */ +} rnd_cap_style_t; /* The HID may need something more than an "int" for colors, timers, etc. So it passes/returns one of these, which is castable to a @@ -59,18 +59,18 @@ typedef union { long lval; void *ptr; -} pcb_hidval_t; +} rnd_hidval_t; typedef struct { rnd_coord_t width; /* as set by set_line_width */ - pcb_cap_style_t cap; /* as set by set_line_cap */ + rnd_cap_style_t cap; /* as set by set_line_cap */ int xor; /* as set by set_draw_xor */ int faded; /* as set by set_draw_faded */ rnd_hid_t *hid; /* the HID that owns this gc */ -} pcb_core_gc_t; +} rnd_core_gc_t; -#define PCB_HIDCONCAT(a,b) a##b +#define RND_HIDCONCAT(a,b) a##b /* File Watch flags */ /* Based upon those in dbus/dbus-connection.h */ @@ -283,7 +283,7 @@ A GUI hid should set the coord_per_pix value here for proper optimization. */ void (*render_burst)(rnd_hid_t *hid, pcb_burst_op_t op, const rnd_rnd_box_t *screen); - /*** gc vs. rnd_hid_t *: pcb_core_gc_t contains ->hid, so these calls don't + /*** gc vs. rnd_hid_t *: rnd_core_gc_t contains ->hid, so these calls don't need to get it as first arg. ***/ /* Sets a color. Can be one of the special colors like rnd_color_drill. @@ -295,7 +295,7 @@ /* Sets the line style. While calling this is cheap, calling it with different values each time may be expensive, so grouping items by line style is helpful. */ - void (*set_line_cap)(rnd_hid_gc_t gc, pcb_cap_style_t style); + void (*set_line_cap)(rnd_hid_gc_t gc, rnd_cap_style_t style); void (*set_line_width)(rnd_hid_gc_t gc, rnd_coord_t width); void (*set_draw_xor)(rnd_hid_gc_t gc, int xor); /* Blends 20% or so color with 80% background. Only used for @@ -351,9 +351,9 @@ timer during the callback for the first. user_data_ can be anything, it's just passed to func. Times are not guaranteed to be accurate. */ - pcb_hidval_t (*add_timer)(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data); + rnd_hidval_t (*add_timer)(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data); /* Use this to stop a timer that hasn't triggered yet. */ - void (*stop_timer)(rnd_hid_t *hid, pcb_hidval_t timer); + void (*stop_timer)(rnd_hid_t *hid, rnd_hidval_t timer); /* Causes func_ to be called when some condition occurs on the file descriptor passed. Conditions include data for reading, writing, @@ -360,10 +360,10 @@ hangup, and errors. user_data_ can be anything, it's just passed to func. If the watch function returns pcb_true, the watch is kept, else it is removed. */ - pcb_hidval_t (*watch_file)(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), pcb_hidval_t user_data); + rnd_hidval_t (*watch_file)(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), rnd_hidval_t user_data); /* Use this to stop a file watch; must not be called from within a GUI callback! */ - void (*unwatch_file)(rnd_hid_t *hid, pcb_hidval_t watch); + void (*unwatch_file)(rnd_hid_t *hid, rnd_hidval_t watch); /* Run the file selection dialog. Return a string the caller needs to free(). @@ -412,7 +412,7 @@ /* Set a property of an attribute dialog (typical call is between attr_dlg_new() and attr_dlg_run()) */ - void (*attr_dlg_property)(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val); + void (*attr_dlg_property)(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val); /* Disable or enable a widget of an active attribute dialog; if enabled is Index: trunk/src/librnd/core/hid_dad.h =================================================================== --- trunk/src/librnd/core/hid_dad.h (revision 30977) +++ trunk/src/librnd/core/hid_dad.h (revision 30978) @@ -122,7 +122,7 @@ void *user_ctx; void (*user_free_cb)(rnd_hid_attribute_t *attrib, void *user_ctx, void *hid_ctx); void (*user_expose_cb)(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e); - rnd_bool (*user_mouse_cb)(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); /* returns true if redraw is needed */ + rnd_bool (*user_mouse_cb)(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); /* returns true if redraw is needed */ /* optional callbacks HIDs may set after widget creation */ void *hid_wdata; Index: trunk/src/librnd/core/hid_dlg.c =================================================================== --- trunk/src/librnd/core/hid_dlg.c (revision 30977) +++ trunk/src/librnd/core/hid_dlg.c (revision 30978) @@ -146,7 +146,7 @@ pcb_hid_progress(0, 0, cancel); } -static void progress_refresh_cb(pcb_hidval_t user_data) +static void progress_refresh_cb(rnd_hidval_t user_data) { pcb_hid_progress(0, 0, refresh); } @@ -154,7 +154,7 @@ static int pcb_gui_progress(long so_far, long total, const char *message) { double now; - static pcb_hidval_t timer; + static rnd_hidval_t timer; static int active = 0, cancelled = 0; static int wp, have_timer = 0; static rnd_hid_attr_val_t val; Index: trunk/src/librnd/core/hid_inlines.h =================================================================== --- trunk/src/librnd/core/hid_inlines.h (revision 30977) +++ trunk/src/librnd/core/hid_inlines.h (revision 30978) @@ -33,11 +33,11 @@ RND_INLINE rnd_hid_gc_t pcb_hid_make_gc(void) { rnd_hid_gc_t res; - pcb_core_gc_t *hc; + rnd_core_gc_t *hc; res = pcb_render->make_gc(pcb_gui); - hc = (pcb_core_gc_t *)res; /* assumes first field is pcb_core_gc_t */ + hc = (rnd_core_gc_t *)res; /* assumes first field is rnd_core_gc_t */ hc->width = RND_MAX_COORD; - hc->cap = pcb_cap_invalid; + hc->cap = rnd_cap_invalid; hc->xor = 0; hc->faded = 0; hc->hid = pcb_gui; @@ -49,9 +49,9 @@ pcb_render->destroy_gc(gc); } -RND_INLINE void pcb_hid_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +RND_INLINE void pcb_hid_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { - pcb_core_gc_t *hc = (pcb_core_gc_t *)gc; + rnd_core_gc_t *hc = (rnd_core_gc_t *)gc; if (hc->cap != style) { hc->cap = style; pcb_render->set_line_cap(gc, style); @@ -60,7 +60,7 @@ RND_INLINE void pcb_hid_set_line_width(rnd_hid_gc_t gc, rnd_coord_t width) { - pcb_core_gc_t *hc = (pcb_core_gc_t *)gc; + rnd_core_gc_t *hc = (rnd_core_gc_t *)gc; if (hc->width != width) { hc->width = width; pcb_render->set_line_width(gc, width); @@ -69,7 +69,7 @@ RND_INLINE void pcb_hid_set_draw_xor(rnd_hid_gc_t gc, int xor) { - pcb_core_gc_t *hc = (pcb_core_gc_t *)gc; + rnd_core_gc_t *hc = (rnd_core_gc_t *)gc; if (hc->xor != xor) { hc->xor = xor; pcb_render->set_draw_xor(gc, xor); @@ -78,7 +78,7 @@ RND_INLINE void pcb_hid_set_draw_faded(rnd_hid_gc_t gc, int faded) { - pcb_core_gc_t *hc = (pcb_core_gc_t *)gc; + rnd_core_gc_t *hc = (rnd_core_gc_t *)gc; if (hc->faded != faded) { hc->faded = faded; pcb_render->set_draw_faded(gc, faded); Index: trunk/src/librnd/core/hid_nogui.c =================================================================== --- trunk/src/librnd/core/hid_nogui.c (revision 30977) +++ trunk/src/librnd/core/hid_nogui.c (revision 30978) @@ -115,7 +115,7 @@ CRASH("set_color"); } -static void nogui_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void nogui_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { CRASH("set_line_cap"); } @@ -196,28 +196,28 @@ { } -static pcb_hidval_t nogui_add_timer(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +static rnd_hidval_t nogui_add_timer(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { - pcb_hidval_t rv; + rnd_hidval_t rv; CRASH("add_timer"); rv.lval = 0; return rv; } -static void nogui_stop_timer(rnd_hid_t *hid, pcb_hidval_t timer) +static void nogui_stop_timer(rnd_hid_t *hid, rnd_hidval_t timer) { CRASH("stop_timer"); } -static pcb_hidval_t nogui_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func) (pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), pcb_hidval_t user_data) +static rnd_hidval_t nogui_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func) (rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), rnd_hidval_t user_data) { - pcb_hidval_t rv; + rnd_hidval_t rv; CRASH("watch_file"); rv.lval = 0; return rv; } -static void nogui_unwatch_file(rnd_hid_t *hid, pcb_hidval_t watch) +static void nogui_unwatch_file(rnd_hid_t *hid, rnd_hidval_t watch) { CRASH("unwatch_file"); } @@ -375,7 +375,7 @@ CRASH("attr_dlg_free"); } -static void nogui_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val) +static void nogui_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val) { CRASH("attr_dlg_dlg_property"); } Index: trunk/src/librnd/pcb_compat.h =================================================================== --- trunk/src/librnd/pcb_compat.h (revision 30977) +++ trunk/src/librnd/pcb_compat.h (revision 30978) @@ -541,3 +541,19 @@ #define pcb_heap_replace rnd_heap_replace #define pcb_heap_is_empty rnd_heap_is_empty #define pcb_heap_size rnd_heap_size +#define pcb_hat_property_e rnd_hat_property_e +#define pcb_hat_property_t rnd_hat_property_t +#define pcb_hid_mouse_ev_t rnd_hid_mouse_ev_t +#define PCB_HATP_max RND_HATP_max +#define PCB_HATP_GLOBAL_CALLBACK RND_HATP_GLOBAL_CALLBACK +#define PCB_HID_MOUSE_PRESS RND_HID_MOUSE_PRESS +#define PCB_HID_MOUSE_RELEASE RND_HID_MOUSE_RELEASE +#define PCB_HID_MOUSE_MOTION RND_HID_MOUSE_MOTION +#define PCB_HID_MOUSE_POPUP RND_HID_MOUSE_POPUP +#define rnd_cap_invalid rnd_cap_invalid +#define rnd_cap_square rnd_cap_square +#define rnd_cap_round rnd_cap_round +#define rnd_cap_style_t rnd_cap_style_t +#define pcb_core_gc_t rnd_core_gc_t +#define pcb_hidval_t rnd_hidval_t +#define PCB_HIDCONCAT RND_HIDCONCAT Index: trunk/src/obj_arc.c =================================================================== --- trunk/src/obj_arc.c (revision 30977) +++ trunk/src/obj_arc.c (revision 30978) @@ -1066,7 +1066,7 @@ if (!info->xform->thin_draw && !info->xform->wireframe) { if ((allow_term_gfx) && pcb_draw_term_need_gfx(arc) && pcb_draw_term_hid_permission()) { - pcb_hid_set_line_cap(pcb_draw_out.active_padGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.active_padGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.active_padGC, thickness); pcb_render->draw_arc(pcb_draw_out.active_padGC, arc->X, arc->Y, arc->Width, arc->Height, arc->StartAngle, arc->Delta); pcb_hid_set_line_width(pcb_draw_out.fgGC, PCB_DRAW_TERM_GFX_WIDTH); @@ -1073,13 +1073,13 @@ } else pcb_hid_set_line_width(pcb_draw_out.fgGC, thickness); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_render->draw_arc(pcb_draw_out.fgGC, arc->X, arc->Y, arc->Width, arc->Height, arc->StartAngle, arc->Delta); } else { pcb_hid_set_line_width(pcb_draw_out.fgGC, 0); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); if(info->xform->thin_draw) pcb_render->draw_arc(pcb_draw_out.fgGC, arc->X, arc->Y, arc->Width, arc->Height, arc->StartAngle, arc->Delta); Index: trunk/src/obj_common.h =================================================================== --- trunk/src/obj_common.h (revision 30977) +++ trunk/src/obj_common.h (revision 30978) @@ -321,7 +321,7 @@ rnd_coord_t radius = PCB_MM_TO_COORD(0.2); \ int selected = PCB_FLAG_TEST(PCB_FLAG_SELECTED, obj); \ pcb_render->set_color(pcb_draw_out.fgGC, selected ? &conf_core.appearance.color.selected : &conf_core.appearance.color.subc); \ - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); \ + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); \ pcb_hid_set_line_width(pcb_draw_out.fgGC, -2); \ pcb_render->draw_line(pcb_draw_out.fgGC, cx-radius, cy-radius, cx+radius, cy+radius); \ pcb_render->draw_line(pcb_draw_out.fgGC, cx+radius, cy-radius, cx-radius, cy+radius); \ Index: trunk/src/obj_gfx.c =================================================================== --- trunk/src/obj_gfx.c (revision 30977) +++ trunk/src/obj_gfx.c (revision 30978) @@ -635,7 +635,7 @@ color = &conf_core.appearance.color.selected; pcb_render->set_color(pcb_draw_out.fgGC, color); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.fgGC, -2); pcb_render->draw_line(pcb_draw_out.fgGC, gfx->cox[0], gfx->coy[0], gfx->cox[1], gfx->coy[1]); pcb_render->draw_line(pcb_draw_out.fgGC, gfx->cox[1], gfx->coy[1], gfx->cox[2], gfx->coy[2]); @@ -646,7 +646,7 @@ if ((gfx->pxm_neutral == NULL) || (pcb_render->draw_pixmap == NULL)) { pcb_render->set_color(pcb_draw_out.fgGC, &conf_core.appearance.color.warn); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.fgGC, PCB_MM_TO_COORD(0.1)); pcb_render->draw_line(pcb_draw_out.fgGC, gfx->cox[0], gfx->coy[0], gfx->cox[2], gfx->coy[2]); pcb_render->draw_line(pcb_draw_out.fgGC, gfx->cox[1], gfx->coy[1], gfx->cox[3], gfx->coy[3]); Index: trunk/src/obj_line.c =================================================================== --- trunk/src/obj_line.c (revision 30977) +++ trunk/src/obj_line.c (revision 30978) @@ -1178,10 +1178,10 @@ } PCB_DRAW_BBOX(line); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); if (!info->xform->thin_draw && !info->xform->wireframe) { if ((allow_term_gfx) && pcb_draw_term_need_gfx(line) && pcb_draw_term_hid_permission()) { - pcb_hid_set_line_cap(pcb_draw_out.active_padGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.active_padGC, rnd_cap_round); pcb_hid_set_line_width(pcb_draw_out.active_padGC, thickness); pcb_render->draw_line(pcb_draw_out.active_padGC, line->Point1.X, line->Point1.Y, line->Point2.X, line->Point2.Y); pcb_hid_set_line_width(pcb_draw_out.fgGC, PCB_DRAW_TERM_GFX_WIDTH); Index: trunk/src/obj_poly.c =================================================================== --- trunk/src/obj_poly.c (revision 30977) +++ trunk/src/obj_poly.c (revision 30978) @@ -1244,7 +1244,7 @@ pcb_render->set_color(pcb_draw_out.fgGC, &conf_core.appearance.color.pin_name); pcb_hid_set_line_width(pcb_draw_out.fgGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); if (poly->HoleIndexN > 0) np = poly->HoleIndex[0]; @@ -1348,7 +1348,7 @@ int i; pcb_dhlp_fill_pcb_polygon(pcb_draw_out.active_padGC, polygon, info->drawn_area); head = polygon->Clipped->contours->head; - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_square); for(n = head, i = 0; (n != head) || (i == 0); n = n->next, i++) { rnd_coord_t x, y, r; x = (n->prev->point[0] + n->point[0] + n->next->point[0]) / 3; @@ -1357,7 +1357,7 @@ TODO("subc: check if x;y is within the poly, but use a cheaper method than the official") r = PCB_DRAW_TERM_GFX_WIDTH; pcb_hid_set_line_width(pcb_draw_out.fgGC, r); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_square); pcb_render->draw_line(pcb_draw_out.fgGC, x, y, x, y); } } Index: trunk/src/obj_poly_draw_helper.c =================================================================== --- trunk/src/obj_poly_draw_helper.c (revision 30977) +++ trunk/src/obj_poly_draw_helper.c (revision 30978) @@ -98,7 +98,7 @@ if (i < 3) { pcb_hid_set_line_width(gc, PCB_MM_TO_COORD(0.01)); - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); pcb_render->draw_line(gc, last_x, last_y, this_x, this_y); } else @@ -114,7 +114,7 @@ pcb_hid_set_line_width(gc, 0); - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); /* If the contour is round, use an arc drawing routine. */ if (pl->is_round) { Index: trunk/src/obj_pstk.c =================================================================== --- trunk/src/obj_pstk.c (revision 30977) +++ trunk/src/obj_pstk.c (revision 30978) @@ -423,7 +423,7 @@ if (shape->data.poly.pa == NULL) pcb_pstk_shape_update_pa(&shape->data.poly); - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); if (dthick != 0) { /* slow - but would be used on export mostly, not on-screen drawing */ pcb_polo_t *p, p_st[32]; @@ -491,13 +491,13 @@ pcb_pstk_draw_poly(info, gc, ps, shape, 1, dthick); break; case PCB_PSSH_LINE: - pcb_hid_set_line_cap(gc, shape->data.line.square ? pcb_cap_square : pcb_cap_round); + pcb_hid_set_line_cap(gc, shape->data.line.square ? rnd_cap_square : rnd_cap_round); pcb_hid_set_line_width(gc, MAX(shape->data.line.thickness + dthick, 1)); pcb_render->draw_line(gc, ps->x + shape->data.line.x1, ps->y + shape->data.line.y1, ps->x + shape->data.line.x2, ps->y + shape->data.line.y2); break; case PCB_PSSH_CIRC: r = MAX(shape->data.circ.dia/2 + dthick/2, 1); - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); pcb_render->fill_circle(gc, ps->x + shape->data.circ.x, ps->y + shape->data.circ.y, r); break; case PCB_PSSH_HSHADOW: @@ -508,7 +508,7 @@ static void pcb_pstk_draw_shape_thin(pcb_draw_info_t *info, rnd_hid_gc_t gc, pcb_pstk_t *ps, pcb_pstk_shape_t *shape) { rnd_coord_t r, dthick = 0; - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); if ((info != NULL) && (info->xform != NULL) && (info->xform->bloat != 0)) dthick = info->xform->bloat; @@ -586,7 +586,7 @@ /* mark is a cross in the middle, right on the hole; cross size should extend beyond the hole */ - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_round); mark = conf_core.appearance.padstack.cross_size; proto = pcb_pstk_get_proto(ps); if (proto != NULL) @@ -667,7 +667,7 @@ /* actual hole */ pcb_hid_set_line_width(pcb_draw_out.drillGC, 0); - pcb_hid_set_line_cap(pcb_draw_out.drillGC, pcb_cap_round); + pcb_hid_set_line_cap(pcb_draw_out.drillGC, rnd_cap_round); pcb_render->fill_circle(pcb_draw_out.drillGC, ps->x, ps->y, proto->hdia / 2); /* indicate unplated holes with an arc; unplated holes are more rare Index: trunk/src/obj_text.c =================================================================== --- trunk/src/obj_text.c (revision 30977) +++ trunk/src/obj_text.c (revision 30978) @@ -1141,7 +1141,7 @@ } else { pcb_hid_set_line_width(pcb_draw_out.fgGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_square); cheap_text_line(pcb_draw_out.fgGC, mx, 0, h/2, w, h/2, 0, 0); } return 1; @@ -1157,7 +1157,7 @@ else { h /= 4; pcb_hid_set_line_width(pcb_draw_out.fgGC, -1); - pcb_hid_set_line_cap(pcb_draw_out.fgGC, pcb_cap_square); + pcb_hid_set_line_cap(pcb_draw_out.fgGC, rnd_cap_square); cheap_text_line(pcb_draw_out.fgGC, mx, 0, h, w, h, 0, 0); cheap_text_line(pcb_draw_out.fgGC, mx, 0, h, w, h*3, 0, 0); cheap_text_line(pcb_draw_out.fgGC, mx, 0, h*3, w, h*3, 0, 0); Index: trunk/src/plug_io.c =================================================================== --- trunk/src/plug_io.c (revision 30977) +++ trunk/src/plug_io.c (revision 30978) @@ -838,7 +838,7 @@ /*** Autosave ***/ -static pcb_hidval_t backup_timer; +static rnd_hidval_t backup_timer; /* * If the backup interval is > 0 then set another timer. Otherwise @@ -845,7 +845,7 @@ * we do nothing and it is up to the GUI to call pcb_enable_autosave() * after setting conf_core.rc.backup_interval > 0 again. */ -static void backup_cb(pcb_hidval_t data) +static void backup_cb(rnd_hidval_t data) { backup_timer.ptr = NULL; pcb_backup(); @@ -855,7 +855,7 @@ void pcb_enable_autosave(void) { - pcb_hidval_t x; + rnd_hidval_t x; x.ptr = NULL; Index: trunk/src/stub_draw.c =================================================================== --- trunk/src/stub_draw.c (revision 30977) +++ trunk/src/stub_draw.c (revision 30978) @@ -45,7 +45,7 @@ pcb_text_draw_(info, &t, 0, 0, PCB_TXT_TINY_ACCURATE); } -static rnd_bool dummy_mouse(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool dummy_mouse(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return 0; } @@ -77,7 +77,7 @@ void (*pcb_stub_draw_csect)(rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e) = dummy_draw_csect; -rnd_bool (*pcb_stub_draw_csect_mouse_ev)(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) = dummy_mouse; +rnd_bool (*pcb_stub_draw_csect_mouse_ev)(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) = dummy_mouse; /****** font selector GUI ******/ @@ -86,11 +86,11 @@ dummy_draw_text(NULL, gc, "Can't render the font selector: the draw_fontsel plugin is not compiled and/or not loaded"); } -static rnd_bool dummy_mouse_fontsel(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) +static rnd_bool dummy_mouse_fontsel(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) { return 0; } void (*pcb_stub_draw_fontsel)(rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e, pcb_text_t *txt) = dummy_draw_fontsel; -rnd_bool (*pcb_stub_draw_fontsel_mouse_ev)(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) = dummy_mouse_fontsel; +rnd_bool (*pcb_stub_draw_fontsel_mouse_ev)(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) = dummy_mouse_fontsel; Index: trunk/src/stub_draw.h =================================================================== --- trunk/src/stub_draw.h (revision 30977) +++ trunk/src/stub_draw.h (revision 30978) @@ -42,10 +42,10 @@ /* csect */ extern void (*pcb_stub_draw_csect)(rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e); -extern rnd_bool (*pcb_stub_draw_csect_mouse_ev)(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); +extern rnd_bool (*pcb_stub_draw_csect_mouse_ev)(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); /* fontsel */ extern void (*pcb_stub_draw_fontsel)(rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e, pcb_text_t *txt); -extern rnd_bool (*pcb_stub_draw_fontsel_mouse_ev)(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt); +extern rnd_bool (*pcb_stub_draw_fontsel_mouse_ev)(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt); #endif Index: trunk/src_plugins/autoroute/autoroute.c =================================================================== --- trunk/src_plugins/autoroute/autoroute.c (revision 30977) +++ trunk/src_plugins/autoroute/autoroute.c (revision 30978) @@ -1389,7 +1389,7 @@ if (ddraw != NULL) { ddraw->set_line_width(ar_gc, thickness); - ddraw->set_line_cap(ar_gc, pcb_cap_round); + ddraw->set_line_cap(ar_gc, rnd_cap_round); ddraw->set_color(ar_gc, SLayer->Color); ddraw->draw_line(ar_gc, b.X1, b.Y1, b.X2, b.Y1); @@ -1428,7 +1428,7 @@ if (ddraw == NULL) return; - ddraw->set_line_cap(ar_gc, pcb_cap_round); + ddraw->set_line_cap(ar_gc, rnd_cap_round); ddraw->set_line_width(ar_gc, 1); ddraw->set_color(ar_gc, Settings.MaskColor); @@ -4606,7 +4606,7 @@ ddraw = pcb_gui->request_debug_draw(); if (ddraw != NULL) { ar_gc = ddraw->make_gc(); - ddraw->set_line_cap(ar_gc, pcb_cap_round); + ddraw->set_line_cap(ar_gc, rnd_cap_round); } #endif Index: trunk/src_plugins/ddraft/ddraft.c =================================================================== --- trunk/src_plugins/ddraft/ddraft.c (revision 30977) +++ trunk/src_plugins/ddraft/ddraft.c (revision 30978) @@ -444,7 +444,7 @@ void ddraft_tool_draw_attached(rnd_hidlib_t *hl) { int n; - pcb_render->set_line_cap(pcb_crosshair.GC, pcb_cap_round); + pcb_render->set_line_cap(pcb_crosshair.GC, rnd_cap_round); pcb_render->set_line_width(pcb_crosshair.GC, 1); pcb_render->set_color(pcb_crosshair.GC, rnd_color_grey33); for(n = 0; n < vtc0_len(&pcb_ddraft_attached.annot_lines); n += 4) { Index: trunk/src_plugins/dialogs/dlg_flag_edit.c =================================================================== --- trunk/src_plugins/dialogs/dlg_flag_edit.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_flag_edit.c (revision 30978) @@ -149,7 +149,7 @@ PCB_DAD_NEW("flags", dlg, "Edit flags", &ctx, pcb_true, NULL); val.func = fe_attr_chg; - pcb_gui->attr_dlg_property(dlg_hid_ctx, PCB_HATP_GLOBAL_CALLBACK, &val); + pcb_gui->attr_dlg_property(dlg_hid_ctx, RND_HATP_GLOBAL_CALLBACK, &val); PCB_DAD_RUN(dlg); Index: trunk/src_plugins/dialogs/dlg_fontsel.c =================================================================== --- trunk/src_plugins/dialogs/dlg_fontsel.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_fontsel.c (revision 30978) @@ -88,7 +88,7 @@ } } -rnd_bool fontsel_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +rnd_bool fontsel_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { fontsel_ctx_t *ctx = prv->user_ctx; @@ -255,9 +255,9 @@ } static int fontsel_timer_active = 0; -static pcb_hidval_t fontsel_timer; +static rnd_hidval_t fontsel_timer; -static void fontsel_timer_cb(pcb_hidval_t user_data) +static void fontsel_timer_cb(rnd_hidval_t user_data) { fontsel_ctx_t *c; Index: trunk/src_plugins/dialogs/dlg_layer_binding.c =================================================================== --- trunk/src_plugins/dialogs/dlg_layer_binding.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_layer_binding.c (revision 30978) @@ -371,7 +371,7 @@ PCB_DAD_DEFSIZE(dlg, 500, 500); PCB_DAD_NEW("layer_binding", dlg, "Layer bindings", &ctx, pcb_true, NULL); val.func = lb_attr_chg; - pcb_gui->attr_dlg_property(dlg_hid_ctx, PCB_HATP_GLOBAL_CALLBACK, &val); + pcb_gui->attr_dlg_property(dlg_hid_ctx, RND_HATP_GLOBAL_CALLBACK, &val); lb_data2dialog(dlg_hid_ctx, &ctx); PCB_DAD_RUN(dlg); Index: trunk/src_plugins/dialogs/dlg_lib_pstk.c =================================================================== --- trunk/src_plugins/dialogs/dlg_lib_pstk.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_lib_pstk.c (revision 30978) @@ -174,7 +174,7 @@ pcb_pstk_draw_preview(PCB, &ps, layers, 0, 0, &e->view); pcb_render->set_color(gc, rnd_color_black); - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); pcb_hid_set_line_width(gc, -1); x1 = ctx->drawbox.X1; Index: trunk/src_plugins/dialogs/dlg_library.c =================================================================== --- trunk/src_plugins/dialogs/dlg_library.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_library.c (revision 30978) @@ -64,7 +64,7 @@ pcb_subc_t *sc; pcb_board_t *prev_pcb; /* sc must be in here so buffer changes don't ruin it */ - pcb_hidval_t timer; + rnd_hidval_t timer; int timer_active; /* for the parametric */ @@ -193,7 +193,7 @@ pcb_gui->attr_dlg_widget_hide(ctx->dlg_hid_ctx, ctx->wnopend, 0); } -static void timed_update_preview_cb(pcb_hidval_t user_data) +static void timed_update_preview_cb(rnd_hidval_t user_data) { library_ctx_t *ctx = user_data.ptr; const char *otext = ctx->dlg[ctx->wfilt].val.str; @@ -210,7 +210,7 @@ } if (active) { - pcb_hidval_t user_data; + rnd_hidval_t user_data; user_data.ptr = ctx; ctx->timer = pcb_gui->add_timer(pcb_gui, timed_update_preview_cb, 500, user_data); ctx->timer_active = 1; @@ -633,7 +633,7 @@ } -static rnd_bool library_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool library_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return pcb_false; } Index: trunk/src_plugins/dialogs/dlg_loadsave.c =================================================================== --- trunk/src_plugins/dialogs/dlg_loadsave.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_loadsave.c (revision 30978) @@ -106,7 +106,7 @@ int tabs; /* number of option tabs, including the dummy 0th tab */ int wfmt, wguess, wguess_err, wopts; int pick, num_fmts; - pcb_hidval_t timer; + rnd_hidval_t timer; char last_ext[32]; unsigned fmt_chg_lock:1; unsigned timer_active:1; @@ -222,7 +222,7 @@ pcb_gui->attr_dlg_widget_hide(save->fmtsub->dlg_hid_ctx, save->wguess_err, 0); } -static void save_timer(pcb_hidval_t user_data) +static void save_timer(rnd_hidval_t user_data) { save_t *save = user_data.ptr; @@ -394,7 +394,7 @@ const char **extensions_param = NULL; int num_fmts, fmt, *fmt_param = NULL; save_t save; - pcb_hidval_t timer_ctx; + rnd_hidval_t timer_ctx; const char *default_pattern = NULL; pcb_plug_iot_t list_iot; pcb_io_list_ext_t list_ext; Index: trunk/src_plugins/dialogs/dlg_netlist.c =================================================================== --- trunk/src_plugins/dialogs/dlg_netlist.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_netlist.c (revision 30978) @@ -302,7 +302,7 @@ } } -static rnd_bool netlist_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool netlist_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return pcb_false; } Index: trunk/src_plugins/dialogs/dlg_pinout.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pinout.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_pinout.c (revision 30978) @@ -105,9 +105,9 @@ return PCB_R_DIR_NOT_FOUND; } -static rnd_bool pinout_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool pinout_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { - if (kind == PCB_HID_MOUSE_RELEASE) { + if (kind == RND_HID_MOUSE_RELEASE) { pinout_ctx_t *ctx = prv->user_ctx; void *r1, *r2, *r3; pcb_objtype_t type; Index: trunk/src_plugins/dialogs/dlg_pref_layer.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref_layer.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_pref_layer.c (revision 30978) @@ -39,7 +39,7 @@ pcb_stub_draw_csect(gc, e); } -rnd_bool layersel_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +rnd_bool layersel_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return pcb_stub_draw_csect_mouse_ev(kind, x, y); } Index: trunk/src_plugins/dialogs/dlg_test.c =================================================================== --- trunk/src_plugins/dialogs/dlg_test.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_test.c (revision 30978) @@ -64,7 +64,7 @@ static void cb_text_ro(void *hid_ctx, void *caller_data, rnd_hid_attribute_t *attr); static void prv_expose(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_gc_t gc, const rnd_hid_expose_ctx_t *e); -static rnd_bool prv_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); +static rnd_bool prv_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); static const char * test_xpm[] = { "8 8 4 1", @@ -517,10 +517,10 @@ } -static rnd_bool prv_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool prv_mouse(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { pcb_printf("Mouse %d %mm %mm\n", kind, x, y); - return (kind == PCB_HID_MOUSE_PRESS) || (kind == PCB_HID_MOUSE_RELEASE); + return (kind == RND_HID_MOUSE_PRESS) || (kind == RND_HID_MOUSE_RELEASE); } static void cb_color_print(void *hid_ctx, void *caller_data, rnd_hid_attribute_t *attr) Index: trunk/src_plugins/dialogs/dlg_view.c =================================================================== --- trunk/src_plugins/dialogs/dlg_view.c (revision 30977) +++ trunk/src_plugins/dialogs/dlg_view.c (revision 30978) @@ -256,7 +256,7 @@ } -static rnd_bool view_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool view_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return pcb_false; /* don't redraw */ } Index: trunk/src_plugins/draw_csect/draw_csect.c =================================================================== --- trunk/src_plugins/draw_csect/draw_csect.c (revision 30977) +++ trunk/src_plugins/draw_csect/draw_csect.c (revision 30978) @@ -676,13 +676,13 @@ } -static rnd_bool mouse_csect(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool mouse_csect(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { rnd_bool res = 0; rnd_layer_id_t lid; switch(kind) { - case PCB_HID_MOUSE_PRESS: + case RND_HID_MOUSE_PRESS: if (is_button(x, y, &btn_addoutline)) { drag_addoutline = 1; res = 1; @@ -736,7 +736,7 @@ } } break; - case PCB_HID_MOUSE_RELEASE: + case RND_HID_MOUSE_RELEASE: if (drag_addoutline) { if (is_button(x, y, &btn_addoutline)) { pcb_layergrp_t *g = pcb_get_grp_new_misc(PCB); @@ -867,12 +867,12 @@ drag_gid_subst = -1; } break; - case PCB_HID_MOUSE_MOTION: + case RND_HID_MOUSE_MOTION: cx = x; cy = y; res = DRAGGING; break; - case PCB_HID_MOUSE_POPUP: + case RND_HID_MOUSE_POPUP: lid = get_layer_coords(x, y); if (lid >= 0) { pcb_layervis_change_group_vis(&PCB->hidlib, lid, 1, 1); Index: trunk/src_plugins/draw_fab/draw_fab.c =================================================================== --- trunk/src_plugins/draw_fab/draw_fab.c (revision 30977) +++ trunk/src_plugins/draw_fab/draw_fab.c (revision 30978) @@ -225,7 +225,7 @@ yoff -= (4 - ds) * TEXT_LINE; } - pcb_hid_set_line_cap(gc, pcb_cap_round); + pcb_hid_set_line_cap(gc, rnd_cap_round); pcb_hid_set_line_width(gc, FAB_LINE_W); for (n = AllDrills->DrillN - 1; n >= 0; n--) { Index: trunk/src_plugins/draw_fontsel/draw_fontsel.c =================================================================== --- trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 30977) +++ trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 30978) @@ -160,13 +160,13 @@ return -1; } -static rnd_bool pcb_mouse_fontsel(pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) +static rnd_bool pcb_mouse_fontsel(rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y, pcb_text_t *txt) { pcb_font_id_t fid; int ymm; switch(kind) { - case PCB_HID_MOUSE_PRESS: + case RND_HID_MOUSE_PRESS: ymm = PCB_COORD_TO_MM(y); fid = lookup_fid_for_coord(ymm); if (fid >= 0) { Index: trunk/src_plugins/export_dxf/dxf.c =================================================================== --- trunk/src_plugins/export_dxf/dxf.c (revision 30977) +++ trunk/src_plugins/export_dxf/dxf.c (revision 30978) @@ -87,9 +87,9 @@ static dxf_ctx_t dxf_ctx; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; rnd_coord_t width; char *color; int drill; @@ -468,7 +468,7 @@ gc->drawing_hole = 1; } -static void dxf_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void dxf_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } Index: trunk/src_plugins/export_excellon/excellon.c =================================================================== --- trunk/src_plugins/export_excellon/excellon.c (revision 30977) +++ trunk/src_plugins/export_excellon/excellon.c (revision 30978) @@ -157,8 +157,8 @@ } warn; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; - pcb_cap_style_t style; + rnd_core_gc_t core_gc; + rnd_cap_style_t style; rnd_coord_t width; } rnd_hid_gc_s; @@ -358,7 +358,7 @@ { } -static void excellon_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void excellon_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->style = style; } @@ -383,7 +383,7 @@ static void use_gc(rnd_hid_gc_t gc, rnd_coord_t radius) { exc_drawn_objs++; - if ((gc->style != pcb_cap_round) && (!warn.nonround)) { + if ((gc->style != rnd_cap_round) && (!warn.nonround)) { warn.nonround = 1; rnd_message(RND_MSG_ERROR, "Excellon: can not set non-round aperture (some features may be missing from the export)\n"); } Index: trunk/src_plugins/export_gerber/gerber.c =================================================================== --- trunk/src_plugins/export_gerber/gerber.c (revision 30977) +++ trunk/src_plugins/export_gerber/gerber.c (revision 30978) @@ -137,8 +137,8 @@ static rnd_hid_t gerber_hid; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; - pcb_cap_style_t cap; + rnd_core_gc_t core_gc; + rnd_cap_style_t cap; int width; int color; int erase; @@ -622,7 +622,7 @@ static rnd_hid_gc_t gerber_make_gc(rnd_hid_t *hid) { rnd_hid_gc_t rv = (rnd_hid_gc_t) calloc(1, sizeof(*rv)); - rv->cap = pcb_cap_round; + rv->cap = rnd_cap_round; return rv; } @@ -652,7 +652,7 @@ } } -static void gerber_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void gerber_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -683,7 +683,7 @@ if (radius) { radius *= 2; - if (radius != linewidth || lastcap != pcb_cap_round) { + if (radius != linewidth || lastcap != rnd_cap_round) { aperture_t *aptr = find_aperture(curr_aptr_list, radius, ROUND); if (aptr == NULL) pcb_fprintf(stderr, "error: aperture for radius %$mS type ROUND is null\n", radius); @@ -690,7 +690,7 @@ else if (f != NULL) fprintf(f, "G54D%d*", aptr->dCode); linewidth = radius; - lastcap = pcb_cap_round; + lastcap = rnd_cap_round; } } else if (linewidth != gc->width || lastcap != gc->cap) { @@ -700,10 +700,10 @@ linewidth = gc->width; lastcap = gc->cap; switch (gc->cap) { - case pcb_cap_round: + case rnd_cap_round: shape = ROUND; break; - case pcb_cap_square: + case rnd_cap_square: shape = SQUARE; break; default: @@ -786,7 +786,7 @@ return; } - if (x1 != x2 && y1 != y2 && gc->cap == pcb_cap_square) { + if (x1 != x2 && y1 != y2 && gc->cap == rnd_cap_square) { rnd_coord_t x[5], y[5]; double tx, ty, theta; Index: trunk/src_plugins/export_openems/export_openems.c =================================================================== --- trunk/src_plugins/export_openems/export_openems.c (revision 30977) +++ trunk/src_plugins/export_openems/export_openems.c (revision 30978) @@ -62,9 +62,9 @@ #define MESH_NAME "openems" typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; int width; } rnd_hid_gc_s; @@ -728,7 +728,7 @@ { } -static void openems_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void openems_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -787,7 +787,7 @@ { wctx_t *ctx = ems_ctx; - if (gc->cap == pcb_cap_square) { + if (gc->cap == rnd_cap_square) { rnd_coord_t x[4], y[4]; pcb_line_t tmp; tmp.Point1.X = x1; Index: trunk/src_plugins/export_openscad/export_openscad.c =================================================================== --- trunk/src_plugins/export_openscad/export_openscad.c (revision 30977) +++ trunk/src_plugins/export_openscad/export_openscad.c (revision 30978) @@ -66,9 +66,9 @@ typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; int width; } rnd_hid_gc_s; @@ -453,7 +453,7 @@ { } -static void openscad_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void openscad_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -503,7 +503,7 @@ length = rnd_distance(x1, y1, x2, y2); angle = atan2((double)y2-y1, (double)x2-x1); - if (gc->cap == pcb_cap_square) + if (gc->cap == rnd_cap_square) cap_style = "sc"; else cap_style = "rc"; Index: trunk/src_plugins/export_png/png.c =================================================================== --- trunk/src_plugins/export_png/png.c (revision 30977) +++ trunk/src_plugins/export_png/png.c (revision 30978) @@ -114,9 +114,9 @@ } color_struct; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; int width, r, g, b; color_struct *color; gdImagePtr brush; @@ -858,7 +858,7 @@ { rnd_hid_gc_t rv = (rnd_hid_gc_t) calloc(sizeof(hid_gc_t), 1); rv->me_pointer = &png_hid; - rv->cap = pcb_cap_round; + rv->cap = rnd_cap_round; rv->width = 1; rv->color = (color_struct *) malloc(sizeof(color_struct)); rv->color->r = rv->color->g = rv->color->b = rv->color->a = 0; @@ -983,7 +983,7 @@ } } -static void png_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void png_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -1106,7 +1106,7 @@ if (r <= 1) gdImageFilledRectangle(agc->brush, 0, 0, 0, 0, fg); else { - if (agc->cap != pcb_cap_square) { + if (agc->cap != rnd_cap_square) { gdImageFilledEllipse(agc->brush, r / 2, r / 2, r, r, fg); /* Make sure the ellipse is the right exact size. */ gdImageSetPixel(agc->brush, 0, r / 2, fg); @@ -1168,7 +1168,7 @@ int x1o = 0, y1o = 0, x2o = 0, y2o = 0; if (x1 == x2 && y1 == y2 && !photo_mode) { rnd_coord_t w = gc->width / 2; - if (gc->cap != pcb_cap_square) + if (gc->cap != rnd_cap_square) png_fill_circle(gc, x1, y1, w); else png_fill_rect(gc, x1 - w, y1 - w, x1 + w, y1 + w); @@ -1194,7 +1194,7 @@ gdImageSetThickness(im, 0); linewidth = 0; - if (gc->cap != pcb_cap_square || x1 == x2 || y1 == y2) { + if (gc->cap != rnd_cap_square || x1 == x2 || y1 == y2) { gdImageLine(im, SCALE_X(x1) + x1o, SCALE_Y(y1) + y1o, SCALE_X(x2) + x2o, SCALE_Y(y2) + y2o, gdBrushed); } else { Index: trunk/src_plugins/export_ps/eps.c =================================================================== --- trunk/src_plugins/export_ps/eps.c (revision 30977) +++ trunk/src_plugins/export_ps/eps.c (revision 30978) @@ -29,8 +29,8 @@ static pcb_cam_t eps_cam; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; - pcb_cap_style_t cap; + rnd_core_gc_t core_gc; + rnd_cap_style_t cap; rnd_coord_t width; unsigned long color; int erase; @@ -432,7 +432,7 @@ static rnd_hid_gc_t eps_make_gc(rnd_hid_t *hid) { rnd_hid_gc_t rv = (rnd_hid_gc_t) malloc(sizeof(rnd_hid_gc_s)); - rv->cap = pcb_cap_round; + rv->cap = rnd_cap_round; rv->width = 0; rv->color = 0; return rv; @@ -487,7 +487,7 @@ gc->color = 0; } -static void eps_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void eps_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -512,10 +512,10 @@ if (lastcap != gc->cap) { int c; switch (gc->cap) { - case pcb_cap_round: + case rnd_cap_round: c = 1; break; - case pcb_cap_square: + case rnd_cap_square: c = 2; break; default: @@ -546,7 +546,7 @@ { rnd_coord_t w = gc->width / 2; if (x1 == x2 && y1 == y2) { - if (gc->cap == pcb_cap_square) + if (gc->cap == rnd_cap_square) eps_fill_rect(gc, x1 - w, y1 - w, x1 + w, y1 + w); else eps_fill_circle(gc, x1, y1, w); @@ -553,7 +553,7 @@ return; } use_gc(gc); - if (gc->erase && gc->cap != pcb_cap_square) { + if (gc->erase && gc->cap != rnd_cap_square) { double ang = atan2(y2 - y1, x2 - x1); double dx = w * sin(ang); double dy = -w * cos(ang); Index: trunk/src_plugins/export_ps/ps.c =================================================================== --- trunk/src_plugins/export_ps/ps.c (revision 30977) +++ trunk/src_plugins/export_ps/ps.c (revision 30978) @@ -36,9 +36,9 @@ static void use_gc(rnd_hid_gc_t gc); typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; rnd_coord_t width; unsigned char r, g, b; int erase; @@ -954,7 +954,7 @@ { rnd_hid_gc_t rv = (rnd_hid_gc_t) calloc(1, sizeof(rnd_hid_gc_s)); rv->me_pointer = &ps_hid; - rv->cap = pcb_cap_round; + rv->cap = rnd_cap_round; return rv; } @@ -991,7 +991,7 @@ } } -static void ps_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void ps_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -1032,10 +1032,10 @@ if (lastcap != gc->cap) { int c; switch (gc->cap) { - case pcb_cap_round: + case rnd_cap_round: c = 1; break; - case pcb_cap_square: + case rnd_cap_square: c = 2; break; default: @@ -1085,7 +1085,7 @@ /* If you're etching your own paste mask, this will reduce the amount of brass you need to etch by drawing outlines for large pads. See also ps_fill_rect. */ - if (is_paste && gc->width > 2500 && gc->cap == pcb_cap_square && (x1 == x2 || y1 == y2)) { + if (is_paste && gc->width > 2500 && gc->cap == rnd_cap_square && (x1 == x2 || y1 == y2)) { rnd_coord_t t, w; if (x1 > x2) { t = x1; @@ -1104,7 +1104,7 @@ #endif if (x1 == x2 && y1 == y2) { rnd_coord_t w = gc->width / 2; - if (gc->cap == pcb_cap_square) + if (gc->cap == rnd_cap_square) ps_fill_rect(gc, x1 - w, y1 - w, x1 + w, y1 + w); else ps_fill_circle(gc, x1, y1, w); @@ -1238,7 +1238,7 @@ /* See comment in ps_draw_line. */ if (is_paste && (x2 - x1) > 2500 && (y2 - y1) > 2500) { linewidth = 1000; - lastcap = pcb_cap_round; + lastcap = rnd_cap_round; fprintf(f, "1000 setlinewidth 1 setlinecap 1 setlinejoin\n"); fprintf(f, "%d %d moveto %d %d lineto %d %d lineto %d %d lineto closepath stroke\n", x1 + 500 - bloat, y1 + 500 - bloat, Index: trunk/src_plugins/export_svg/svg.c =================================================================== --- trunk/src_plugins/export_svg/svg.c (revision 30977) +++ trunk/src_plugins/export_svg/svg.c (revision 30978) @@ -69,9 +69,9 @@ static pcb_cam_t svg_cam; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; - pcb_cap_style_t cap; + rnd_cap_style_t cap; int width; char *color; int drill; @@ -78,12 +78,12 @@ unsigned warned_elliptical:1; } rnd_hid_gc_s; -static const char *CAPS(pcb_cap_style_t cap) +static const char *CAPS(rnd_cap_style_t cap) { switch (cap) { - case pcb_cap_round: + case rnd_cap_round: return "round"; - case pcb_cap_square: + case rnd_cap_square: return "square"; default: assert(!"unhandled cap"); @@ -475,7 +475,7 @@ { rnd_hid_gc_t rv = (rnd_hid_gc_t) calloc(sizeof(rnd_hid_gc_s), 1); rv->me_pointer = &svg_hid; - rv->cap = pcb_cap_round; + rv->cap = rnd_cap_round; rv->width = 1; rv->color = NULL; return rv; @@ -556,7 +556,7 @@ gc->color = rnd_strdup(name); } -static void svg_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void svg_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } Index: trunk/src_plugins/extedit/extedit.c =================================================================== --- trunk/src_plugins/extedit/extedit.c (revision 30977) +++ trunk/src_plugins/extedit/extedit.c (revision 30978) @@ -81,10 +81,10 @@ typedef struct { FILE *fc; int stay; - pcb_hidval_t wid; + rnd_hidval_t wid; } extedit_wait_t; -rnd_bool extedit_fd_watch(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data) +rnd_bool extedit_fd_watch(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data) { char tmp[128]; int res; @@ -125,7 +125,7 @@ int fd = rnd_fileno(fc); if (fd > 0) { int n = 0; - pcb_hidval_t hd; + rnd_hidval_t hd; extedit_wait_t ctx; ctx.stay = 1; Index: trunk/src_plugins/hid_batch/batch.c =================================================================== --- trunk/src_plugins/hid_batch/batch.c (revision 30977) +++ trunk/src_plugins/hid_batch/batch.c (revision 30978) @@ -31,7 +31,7 @@ non-GUI needs. */ typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; } rnd_hid_gc_s; static rnd_export_opt_t *batch_get_export_options(rnd_hid_t *hid, int *n_ret) @@ -176,7 +176,7 @@ static rnd_hid_gc_t batch_make_gc(rnd_hid_t *hid) { - static pcb_core_gc_t hc; + static rnd_core_gc_t hc; return (rnd_hid_gc_t)&hc; } @@ -188,7 +188,7 @@ { } -static void batch_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void batch_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { } @@ -255,27 +255,27 @@ { } -static pcb_hidval_t batch_add_timer(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +static rnd_hidval_t batch_add_timer(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { - pcb_hidval_t rv; + rnd_hidval_t rv; rv.lval = 0; return rv; } -static void batch_stop_timer(rnd_hid_t *hid, pcb_hidval_t timer) +static void batch_stop_timer(rnd_hid_t *hid, rnd_hidval_t timer) { } -pcb_hidval_t -batch_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func) (pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), - pcb_hidval_t user_data) +rnd_hidval_t +batch_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func) (rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), + rnd_hidval_t user_data) { - pcb_hidval_t ret; + rnd_hidval_t ret; ret.ptr = NULL; return ret; } -void batch_unwatch_file(rnd_hid_t *hid, pcb_hidval_t data) +void batch_unwatch_file(rnd_hid_t *hid, rnd_hidval_t data) { } Index: trunk/src_plugins/hid_gtk2_gdk/gtkhid-gdk.c =================================================================== --- trunk/src_plugins/hid_gtk2_gdk/gtkhid-gdk.c (revision 30977) +++ trunk/src_plugins/hid_gtk2_gdk/gtkhid-gdk.c (revision 30978) @@ -59,7 +59,7 @@ typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; GdkGC *pixel_gc; GdkGC *clip_gc; @@ -527,14 +527,14 @@ } } -static void ghid_gdk_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void ghid_gdk_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { switch (style) { - case pcb_cap_round: + case rnd_cap_round: gc->cap = GDK_CAP_ROUND; gc->join = GDK_JOIN_ROUND; break; - case pcb_cap_square: + case rnd_cap_square: gc->cap = GDK_CAP_PROJECTING; gc->join = GDK_JOIN_MITER; break; @@ -618,8 +618,8 @@ if (need_setup) { ghid_gdk_set_color(gc, &gc->pcolor); ghid_gdk_set_line_width(gc, gc->core_gc.width); - if ((need_pen) || (gc->core_gc.cap != pcb_cap_invalid)) - ghid_gdk_set_line_cap(gc, (pcb_cap_style_t) gc->core_gc.cap); + if ((need_pen) || (gc->core_gc.cap != rnd_cap_invalid)) + ghid_gdk_set_line_cap(gc, (rnd_cap_style_t) gc->core_gc.cap); ghid_gdk_set_draw_xor(gc, gc->xor_mask); gdk_gc_set_clip_origin(gc->pixel_gc, 0, 0); } Index: trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c =================================================================== --- trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c (revision 30977) +++ trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c (revision 30978) @@ -54,7 +54,7 @@ typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; const rnd_color_t *pcolor; @@ -402,7 +402,7 @@ set_gl_color_for_gc(gc); } -void ghid_gl_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +void ghid_gl_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { } Index: trunk/src_plugins/hid_lesstif/dialogs.c =================================================================== --- trunk/src_plugins/hid_lesstif/dialogs.c (revision 30977) +++ trunk/src_plugins/hid_lesstif/dialogs.c (revision 30978) @@ -183,7 +183,7 @@ Widget *wltop;/* the parent widget, which is different from wl if reparenting (extra boxes, e.g. for framing or scrolling) was needed */ Widget **btn; /* enum value buttons */ Widget dialog; - rnd_hid_attr_val_t property[PCB_HATP_max]; + rnd_hid_attr_val_t property[RND_HATP_max]; Dimension minw, minh; void (*close_cb)(void *caller_data, pcb_hid_attr_ev_t ev); char *id; @@ -264,11 +264,11 @@ attribute_dialog_readres(ctx, widx); - if ((ctx->attrs[widx].change_cb == NULL) && (ctx->property[PCB_HATP_GLOBAL_CALLBACK].func == NULL)) + if ((ctx->attrs[widx].change_cb == NULL) && (ctx->property[RND_HATP_GLOBAL_CALLBACK].func == NULL)) return; - if (ctx->property[PCB_HATP_GLOBAL_CALLBACK].func != NULL) - ctx->property[PCB_HATP_GLOBAL_CALLBACK].func(ctx, ctx->caller_data, &ctx->attrs[widx]); + if (ctx->property[RND_HATP_GLOBAL_CALLBACK].func != NULL) + ctx->property[RND_HATP_GLOBAL_CALLBACK].func(ctx, ctx->caller_data, &ctx->attrs[widx]); if (ctx->attrs[widx].change_cb != NULL) ctx->attrs[widx].change_cb(ctx, ctx->caller_data, &ctx->attrs[widx]); } @@ -767,10 +767,10 @@ free(ctx); } -void lesstif_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val) +void lesstif_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val) { lesstif_attr_dlg_t *ctx = hid_ctx; - if ((prop >= 0) && (prop < PCB_HATP_max)) + if ((prop >= 0) && (prop < RND_HATP_max)) ctx->property[prop] = *val; } Index: trunk/src_plugins/hid_lesstif/dlg_attr_misc.c =================================================================== --- trunk/src_plugins/hid_lesstif/dlg_attr_misc.c (revision 30977) +++ trunk/src_plugins/hid_lesstif/dlg_attr_misc.c (revision 30978) @@ -124,7 +124,7 @@ XQueryPointer(display, e->xmotion.window, &root, &child, &root_x, &root_y, &pos_x, &pos_y, &keys_buttons); pcb_ltf_preview_getxy(pd, pos_x, pos_y, &x, &y); - if (prv->user_mouse_cb(attr, prv, PCB_HID_MOUSE_MOTION, x, y)) + if (prv->user_mouse_cb(attr, prv, RND_HID_MOUSE_MOTION, x, y)) pcb_ltf_preview_redraw(pd); } @@ -134,17 +134,17 @@ rnd_hid_attribute_t *attr = pd->attr; pcb_hid_preview_t *prv = attr->wdata; rnd_coord_t x, y; - pcb_hid_mouse_ev_t kind = -1; + rnd_hid_mouse_ev_t kind = -1; if (prv->user_mouse_cb == NULL) return; if (cbs->event->xbutton.button == 1) { - if (cbs->event->type == ButtonPress) kind = PCB_HID_MOUSE_PRESS; - if (cbs->event->type == ButtonRelease) kind = PCB_HID_MOUSE_RELEASE; + if (cbs->event->type == ButtonPress) kind = RND_HID_MOUSE_PRESS; + if (cbs->event->type == ButtonRelease) kind = RND_HID_MOUSE_RELEASE; } else if (cbs->event->xbutton.button == 3) { - if (cbs->event->type == ButtonRelease) kind = PCB_HID_MOUSE_POPUP; + if (cbs->event->type == ButtonRelease) kind = RND_HID_MOUSE_POPUP; } if (kind < 0) Index: trunk/src_plugins/hid_lesstif/main.c =================================================================== --- trunk/src_plugins/hid_lesstif/main.c (revision 30977) +++ trunk/src_plugins/hid_lesstif/main.c (revision 30978) @@ -81,12 +81,12 @@ #define UUNIT pcbhl_conf.editor.grid_unit->allow typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; rnd_hid_t *me_pointer; Pixel color; rnd_color_t pcolor; int width; - pcb_cap_style_t cap; + rnd_cap_style_t cap; char xor_set; char erase; } rnd_hid_gc_s; @@ -2304,11 +2304,11 @@ pcb_printf("set_gc c%s %08lx w%#mS c%d x%d e%d\n", gc->colorname, gc->color, gc->width, gc->cap, gc->xor_set, gc->erase); #endif switch (gc->cap) { - case pcb_cap_square: + case rnd_cap_square: cap = CapProjecting; join = JoinMiter; break; - case pcb_cap_round: + case rnd_cap_round: cap = CapRound; join = JoinRound; break; @@ -2338,7 +2338,7 @@ } } -static void lesstif_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void lesstif_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { gc->cap = style; } @@ -2383,7 +2383,7 @@ y2 = dy2; set_gc(gc); - if (gc->cap == pcb_cap_square && x1 == x2 && y1 == y2) { + if (gc->cap == rnd_cap_square && x1 == x2 && y1 == y2) { XFillRectangle(display, pixmap, my_gc, x1 - vw / 2, y1 - vw / 2, vw, vw); if (use_mask()) XFillRectangle(display, mask_bitmap, mask_gc, x1 - vw / 2, y1 - vw / 2, vw, vw); @@ -2640,8 +2640,8 @@ } typedef struct { - void (*func) (pcb_hidval_t); - pcb_hidval_t user_data; + void (*func) (rnd_hidval_t); + rnd_hidval_t user_data; XtIntervalId id; } TimerStruct; @@ -2652,10 +2652,10 @@ free(ts); } -static pcb_hidval_t lesstif_add_timer(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +static rnd_hidval_t lesstif_add_timer(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { TimerStruct *t; - pcb_hidval_t rv; + rnd_hidval_t rv; t = (TimerStruct *) malloc(sizeof(TimerStruct)); rv.ptr = t; t->func = func; @@ -2664,7 +2664,7 @@ return rv; } -static void lesstif_stop_timer(rnd_hid_t *hid, pcb_hidval_t hv) +static void lesstif_stop_timer(rnd_hid_t *hid, rnd_hidval_t hv) { TimerStruct *ts = (TimerStruct *) hv.ptr; XtRemoveTimeOut(ts->id); @@ -2673,13 +2673,13 @@ typedef struct { - rnd_bool (*func) (pcb_hidval_t, int, unsigned int, pcb_hidval_t); - pcb_hidval_t user_data; + rnd_bool (*func) (rnd_hidval_t, int, unsigned int, rnd_hidval_t); + rnd_hidval_t user_data; int fd; XtInputId id; } WatchStruct; -void lesstif_unwatch_file(rnd_hid_t *hid, pcb_hidval_t data) +void lesstif_unwatch_file(rnd_hid_t *hid, rnd_hidval_t data) { WatchStruct *watch = (WatchStruct *) data.ptr; XtRemoveInput(watch->id); @@ -2692,7 +2692,7 @@ unsigned int pcb_condition = 0; struct pollfd fds; short condition; - pcb_hidval_t x; + rnd_hidval_t x; WatchStruct *watch = (WatchStruct *) client_data; fds.fd = watch->fd; @@ -2716,10 +2716,10 @@ return; } -pcb_hidval_t lesstif_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), pcb_hidval_t user_data) +rnd_hidval_t lesstif_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), rnd_hidval_t user_data) { WatchStruct *watch = (WatchStruct *)malloc(sizeof(WatchStruct)); - pcb_hidval_t ret; + rnd_hidval_t ret; unsigned int xt_condition = 0; if (condition & PCB_WATCH_READABLE) @@ -2746,7 +2746,7 @@ extern void lesstif_attr_dlg_raise(void *hid_ctx); extern void lesstif_attr_dlg_close(void *hid_ctx); extern void lesstif_attr_dlg_free(void *hid_ctx); -extern void lesstif_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val); +extern void lesstif_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val); extern int lesstif_attr_dlg_widget_state(void *hid_ctx, int idx, int enabled); extern int lesstif_attr_dlg_widget_hide(void *hid_ctx, int idx, rnd_bool hide); extern int lesstif_attr_dlg_set_value(void *hid_ctx, int idx, const rnd_hid_attr_val_t *val); Index: trunk/src_plugins/hid_lesstif/wt_preview.h =================================================================== --- trunk/src_plugins/hid_lesstif/wt_preview.h (revision 30977) +++ trunk/src_plugins/hid_lesstif/wt_preview.h (revision 30978) @@ -16,7 +16,7 @@ int v_width, v_height; /* widget dimensions in pixels */ rnd_hid_expose_ctx_t ctx; - rnd_bool (*mouse_ev)(void *widget, void *draw_data, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); + rnd_bool (*mouse_ev)(void *widget, void *draw_data, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); void (*pre_close)(struct pcb_ltf_preview_s *pd); pcb_hid_expose_t overlay_draw; unsigned resized:1; Index: trunk/src_plugins/hid_remote/remote.c =================================================================== --- trunk/src_plugins/hid_remote/remote.c (revision 30977) +++ trunk/src_plugins/hid_remote/remote.c (revision 30978) @@ -27,7 +27,7 @@ static rnd_hid_t remote_hid; typedef struct rnd_hid_gc_s { - pcb_core_gc_t core_gc; + rnd_core_gc_t core_gc; int nop; } rnd_hid_gc_s; @@ -213,7 +213,7 @@ /* r=round, s=square, b=beveled (octagon) */ static const char *cap_style_names = "rsrb"; -static void remote_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void remote_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { int idx = gc2idx(gc); int max = strlen(cap_style_names); @@ -326,27 +326,27 @@ { } -static pcb_hidval_t remote_add_timer(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +static rnd_hidval_t remote_add_timer(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { - pcb_hidval_t rv; + rnd_hidval_t rv; rv.lval = 0; return rv; } -static void remote_stop_timer(rnd_hid_t *hid, pcb_hidval_t timer) +static void remote_stop_timer(rnd_hid_t *hid, rnd_hidval_t timer) { } -pcb_hidval_t -remote_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), - pcb_hidval_t user_data) +rnd_hidval_t +remote_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, rnd_bool (*func)(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), + rnd_hidval_t user_data) { - pcb_hidval_t ret; + rnd_hidval_t ret; ret.ptr = NULL; return ret; } -void remote_unwatch_file(rnd_hid_t *hid, pcb_hidval_t data) +void remote_unwatch_file(rnd_hid_t *hid, rnd_hidval_t data) { } @@ -372,7 +372,7 @@ { } -static void remote_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val) +static void remote_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val) { } Index: trunk/src_plugins/import_sch2/import_sch_dlg.c =================================================================== --- trunk/src_plugins/import_sch2/import_sch_dlg.c (revision 30977) +++ trunk/src_plugins/import_sch2/import_sch_dlg.c (revision 30978) @@ -32,7 +32,7 @@ int len; int wfmt, wtab, warg_ctrl, wverbose; int warg[MAX_ARGS], warg_box[MAX_ARGS], warg_button[MAX_ARGS]; - pcb_hidval_t timer; + rnd_hidval_t timer; int arg_dirty; int active; /* already open - allow only one instance */ } isch_ctx_t; @@ -61,7 +61,7 @@ isch_ctx.arg_dirty = 0; } -static void isch_timed_update_cb(pcb_hidval_t user_data) +static void isch_timed_update_cb(rnd_hidval_t user_data) { isch_arg2pcb(); } @@ -226,7 +226,7 @@ static void isch_arg_chg_cb(void *hid_ctx, void *caller_data, rnd_hid_attribute_t *attr) { - pcb_hidval_t user_data; + rnd_hidval_t user_data; if (isch_ctx.arg_dirty) pcb_gui->stop_timer(pcb_gui, isch_ctx.timer); Index: trunk/src_plugins/lib_gtk_common/dlg_attr_misc.c =================================================================== --- trunk/src_plugins/lib_gtk_common/dlg_attr_misc.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/dlg_attr_misc.c (revision 30978) @@ -64,7 +64,7 @@ prv->user_expose_cb(prv->attrib, prv, gc, e); } -static rnd_bool ghid_preview_mouse(void *widget, void *draw_data, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool ghid_preview_mouse(void *widget, void *draw_data, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { pcb_hid_preview_t *prv = draw_data; if (prv->user_mouse_cb != NULL) Index: trunk/src_plugins/lib_gtk_common/dlg_attribute.c =================================================================== --- trunk/src_plugins/lib_gtk_common/dlg_attribute.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/dlg_attribute.c (revision 30978) @@ -58,7 +58,7 @@ int n_attrs; GtkWidget *dialog; int close_cb_called; - rnd_hid_attr_val_t property[PCB_HATP_max]; + rnd_hid_attr_val_t property[RND_HATP_max]; void (*close_cb)(void *caller_data, pcb_hid_attr_ev_t ev); char *id; gulong destroy_handler; @@ -70,8 +70,8 @@ #define change_cb(ctx, dst) \ do { \ - if (ctx->property[PCB_HATP_GLOBAL_CALLBACK].func != NULL) \ - ctx->property[PCB_HATP_GLOBAL_CALLBACK].func(ctx, ctx->caller_data, dst); \ + if (ctx->property[RND_HATP_GLOBAL_CALLBACK].func != NULL) \ + ctx->property[RND_HATP_GLOBAL_CALLBACK].func(ctx, ctx->caller_data, dst); \ if (dst->change_cb != NULL) \ dst->change_cb(ctx, ctx->caller_data, dst); \ } while(0) \ @@ -917,11 +917,11 @@ free(ctx); } -void ghid_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val) +void ghid_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val) { attr_dlg_t *ctx = hid_ctx; - if ((prop >= 0) && (prop < PCB_HATP_max)) + if ((prop >= 0) && (prop < RND_HATP_max)) ctx->property[prop] = *val; } Index: trunk/src_plugins/lib_gtk_common/dlg_attribute.h =================================================================== --- trunk/src_plugins/lib_gtk_common/dlg_attribute.h (revision 30977) +++ trunk/src_plugins/lib_gtk_common/dlg_attribute.h (revision 30978) @@ -7,7 +7,7 @@ void ghid_attr_dlg_raise(void *hid_ctx); void ghid_attr_dlg_close(void *hid_ctx); void ghid_attr_dlg_free(void *hid_ctx); -void ghid_attr_dlg_property(void *hid_ctx, pcb_hat_property_t prop, const rnd_hid_attr_val_t *val); +void ghid_attr_dlg_property(void *hid_ctx, rnd_hat_property_t prop, const rnd_hid_attr_val_t *val); int ghid_attr_dlg_widget_state(void *hid_ctx, int idx, int enabled); int ghid_attr_dlg_widget_hide(void *hid_ctx, int idx, rnd_bool hide); Index: trunk/src_plugins/lib_gtk_common/glue_hid.c =================================================================== --- trunk/src_plugins/lib_gtk_common/glue_hid.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/glue_hid.c (revision 30978) @@ -268,13 +268,13 @@ pcb_gtk_get_coords(gctx, &gctx->port.view, msg, x, y, force); } -pcb_hidval_t ghid_add_timer(rnd_hid_t *hid, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +rnd_hidval_t ghid_add_timer(rnd_hid_t *hid, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { return pcb_gtk_add_timer((pcb_gtk_t *)hid->hid_data, func, milliseconds, user_data); } -static pcb_hidval_t ghid_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, - rnd_bool (*func)(pcb_hidval_t, int, unsigned int, pcb_hidval_t), pcb_hidval_t user_data) +static rnd_hidval_t ghid_watch_file(rnd_hid_t *hid, int fd, unsigned int condition, + rnd_bool (*func)(rnd_hidval_t, int, unsigned int, rnd_hidval_t), rnd_hidval_t user_data) { return pcb_gtk_watch_file((pcb_gtk_t *)hid->hid_data, fd, condition, func, user_data); } Index: trunk/src_plugins/lib_gtk_common/util_timer.c =================================================================== --- trunk/src_plugins/lib_gtk_common/util_timer.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/util_timer.c (revision 30978) @@ -32,9 +32,9 @@ #include "glue_common.h" typedef struct pcb_gtk_timer_s { - void (*func)(pcb_hidval_t); + void (*func)(rnd_hidval_t); guint id; - pcb_hidval_t user_data; + rnd_hidval_t user_data; pcb_gtk_t *gctx; } pcb_gtk_timer_t; @@ -47,10 +47,10 @@ return FALSE; /* Turns timer off */ } -pcb_hidval_t pcb_gtk_add_timer(struct pcb_gtk_s *gctx, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data) +rnd_hidval_t pcb_gtk_add_timer(struct pcb_gtk_s *gctx, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data) { pcb_gtk_timer_t *timer = g_new0(pcb_gtk_timer_t, 1); - pcb_hidval_t ret; + rnd_hidval_t ret; timer->func = func; timer->user_data = user_data; @@ -60,7 +60,7 @@ return ret; } -void ghid_stop_timer(rnd_hid_t *hid, pcb_hidval_t timer) +void ghid_stop_timer(rnd_hid_t *hid, rnd_hidval_t timer) { void *ptr = timer.ptr; Index: trunk/src_plugins/lib_gtk_common/util_timer.h =================================================================== --- trunk/src_plugins/lib_gtk_common/util_timer.h (revision 30977) +++ trunk/src_plugins/lib_gtk_common/util_timer.h (revision 30978) @@ -1,5 +1,5 @@ #include #include "pcb_gtk.h" -pcb_hidval_t pcb_gtk_add_timer(struct pcb_gtk_s *gctx, void (*func)(pcb_hidval_t user_data), unsigned long milliseconds, pcb_hidval_t user_data); -void ghid_stop_timer(rnd_hid_t *hid, pcb_hidval_t timer); +rnd_hidval_t pcb_gtk_add_timer(struct pcb_gtk_s *gctx, void (*func)(rnd_hidval_t user_data), unsigned long milliseconds, rnd_hidval_t user_data); +void ghid_stop_timer(rnd_hid_t *hid, rnd_hidval_t timer); Index: trunk/src_plugins/lib_gtk_common/util_watch.c =================================================================== --- trunk/src_plugins/lib_gtk_common/util_watch.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/util_watch.c (revision 30978) @@ -32,8 +32,8 @@ #include "glue_common.h" typedef struct pcb_gtk_watch_s { - rnd_bool (*func)(pcb_hidval_t, int, unsigned int, pcb_hidval_t); - pcb_hidval_t user_data; + rnd_bool (*func)(rnd_hidval_t, int, unsigned int, rnd_hidval_t); + rnd_hidval_t user_data; int fd; GIOChannel *channel; gint id; @@ -44,7 +44,7 @@ static gboolean ghid_watch(GIOChannel *source, GIOCondition condition, gpointer data) { unsigned int pcb_condition = 0; - pcb_hidval_t x; + rnd_hidval_t x; pcb_gtk_watch_t *watch = (pcb_gtk_watch_t *)data; rnd_bool res; @@ -65,12 +65,12 @@ return res; } -pcb_hidval_t pcb_gtk_watch_file(pcb_gtk_t *gctx, int fd, unsigned int condition, - rnd_bool (*func)(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), - pcb_hidval_t user_data) +rnd_hidval_t pcb_gtk_watch_file(pcb_gtk_t *gctx, int fd, unsigned int condition, + rnd_bool (*func)(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), + rnd_hidval_t user_data) { pcb_gtk_watch_t *watch = g_new0(pcb_gtk_watch_t, 1); - pcb_hidval_t ret; + rnd_hidval_t ret; unsigned int glib_condition = 0; if (condition & PCB_WATCH_READABLE) @@ -93,7 +93,7 @@ return ret; } -void pcb_gtk_unwatch_file(rnd_hid_t *hid, pcb_hidval_t data) +void pcb_gtk_unwatch_file(rnd_hid_t *hid, rnd_hidval_t data) { pcb_gtk_watch_t *watch = (pcb_gtk_watch_t *)data.ptr; Index: trunk/src_plugins/lib_gtk_common/util_watch.h =================================================================== --- trunk/src_plugins/lib_gtk_common/util_watch.h (revision 30977) +++ trunk/src_plugins/lib_gtk_common/util_watch.h (revision 30978) @@ -1,9 +1,9 @@ #include #include "pcb_gtk.h" -pcb_hidval_t pcb_gtk_watch_file(pcb_gtk_t *gctx, int fd, unsigned int condition, - rnd_bool (*func)(pcb_hidval_t watch, int fd, unsigned int condition, pcb_hidval_t user_data), - pcb_hidval_t user_data); +rnd_hidval_t pcb_gtk_watch_file(pcb_gtk_t *gctx, int fd, unsigned int condition, + rnd_bool (*func)(rnd_hidval_t watch, int fd, unsigned int condition, rnd_hidval_t user_data), + rnd_hidval_t user_data); -void pcb_gtk_unwatch_file(rnd_hid_t *hid, pcb_hidval_t data); +void pcb_gtk_unwatch_file(rnd_hid_t *hid, rnd_hidval_t data); Index: trunk/src_plugins/lib_gtk_common/wt_preview.c =================================================================== --- trunk/src_plugins/lib_gtk_common/wt_preview.c (revision 30977) +++ trunk/src_plugins/lib_gtk_common/wt_preview.c (revision 30978) @@ -325,7 +325,7 @@ case PCB_MB_LEFT: if (preview->mouse_cb != NULL) { /* pcb_printf("bp %mm %mm\n", cx, cy); */ - if (preview->mouse_cb(w, draw_data, PCB_HID_MOUSE_PRESS, cx, cy)) + if (preview->mouse_cb(w, draw_data, RND_HID_MOUSE_PRESS, cx, cy)) gtk_widget_queue_draw(w); } break; @@ -411,13 +411,13 @@ preview->view.panning = 0; break; case PCB_MB_RIGHT: - if ((preview->mouse_cb != NULL) && (preview->mouse_cb(w, draw_data, PCB_HID_MOUSE_POPUP, cx, cy))) + if ((preview->mouse_cb != NULL) && (preview->mouse_cb(w, draw_data, RND_HID_MOUSE_POPUP, cx, cy))) gtk_widget_queue_draw(w); break; case PCB_MB_LEFT: if (preview->mouse_cb != NULL) { /* pcb_printf("br %mm %mm\n", cx, cy); */ - if (preview->mouse_cb(w, draw_data, PCB_HID_MOUSE_RELEASE, cx, cy)) + if (preview->mouse_cb(w, draw_data, RND_HID_MOUSE_RELEASE, cx, cy)) gtk_widget_queue_draw(w); } break; @@ -455,7 +455,7 @@ gtk_widget_queue_draw(w); } else if (preview->mouse_cb != NULL) { - if (preview->mouse_cb(w, draw_data, PCB_HID_MOUSE_MOTION, cx, cy)) + if (preview->mouse_cb(w, draw_data, RND_HID_MOUSE_MOTION, cx, cy)) gtk_widget_queue_draw(w); } Index: trunk/src_plugins/lib_gtk_common/wt_preview.h =================================================================== --- trunk/src_plugins/lib_gtk_common/wt_preview.h (revision 30977) +++ trunk/src_plugins/lib_gtk_common/wt_preview.h (revision 30978) @@ -58,7 +58,7 @@ typedef void (*pcb_gtk_init_drawing_widget_t)(GtkWidget *widget, void *port); typedef void (*pcb_gtk_preview_config_t)(pcb_gtk_preview_t *gp, GtkWidget *widget); typedef gboolean(*pcb_gtk_preview_expose_t)(GtkWidget *widget, pcb_gtk_expose_t *ev, pcb_hid_expose_t expcall, rnd_hid_expose_ctx_t *ctx); -typedef rnd_bool(*pcb_gtk_preview_mouse_ev_t)(void *widget, void *draw_data, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); +typedef rnd_bool(*pcb_gtk_preview_mouse_ev_t)(void *widget, void *draw_data, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y); struct pcb_gtk_preview_s { GtkDrawingArea parent_instance; Index: trunk/src_plugins/lib_hid_common/lead_user.c =================================================================== --- trunk/src_plugins/lib_hid_common/lead_user.c (revision 30977) +++ trunk/src_plugins/lib_hid_common/lead_user.c (revision 30978) @@ -40,10 +40,10 @@ static rnd_coord_t leadx, leady, step; static rnd_bool lead; -static pcb_hidval_t lead_timer; +static rnd_hidval_t lead_timer; static rnd_hidlib_t *lead_hidlib; -static void lead_cb(pcb_hidval_t user_data) +static void lead_cb(rnd_hidval_t user_data) { static double p; @@ -58,7 +58,7 @@ static void pcb_lead_user_to_location(rnd_hidlib_t *hidlib, rnd_coord_t x, rnd_coord_t y, rnd_bool enabled) { - pcb_hidval_t user_data; + rnd_hidval_t user_data; if (lead) { pcb_gui->stop_timer(pcb_gui, lead_timer); Index: trunk/src_plugins/lib_hid_gl/hidgl.c =================================================================== --- trunk/src_plugins/lib_hid_gl/hidgl.c (revision 30977) +++ trunk/src_plugins/lib_hid_gl/hidgl.c (revision 30978) @@ -352,11 +352,11 @@ } switch (cap) { - case pcb_cap_round: + case rnd_cap_round: circular_caps = 1; break; - case pcb_cap_square: + case rnd_cap_square: x1 -= deltax * width / 2. / length; y1 -= deltay * width / 2. / length; x2 += deltax * width / 2. / length; Index: trunk/src_plugins/lib_hid_pcbui/infobar.c =================================================================== --- trunk/src_plugins/lib_hid_pcbui/infobar.c (revision 30977) +++ trunk/src_plugins/lib_hid_pcbui/infobar.c (revision 30978) @@ -30,7 +30,7 @@ #include "conf_core.h" #include -static pcb_hidval_t infobar_timer; +static rnd_hidval_t infobar_timer; static int infobar_timer_active = 0; static double last_interval = -2; static double last_date = -1; @@ -46,7 +46,7 @@ } -static void infobar_tick(pcb_hidval_t user_data) +static void infobar_tick(rnd_hidval_t user_data) { if (conf_core.rc.file_changed_interval > 0) { infobar_timer = pcb_gui->add_timer(pcb_gui, infobar_tick, (conf_core.rc.file_changed_interval * 1000.0), user_data); Index: trunk/src_plugins/lib_hid_pcbui/layer_menu.c =================================================================== --- trunk/src_plugins/lib_hid_pcbui/layer_menu.c (revision 30977) +++ trunk/src_plugins/lib_hid_pcbui/layer_menu.c (revision 30978) @@ -221,9 +221,9 @@ } static int layer_menu_install_timer_active = 0; -static pcb_hidval_t layer_menu_install_timer; +static rnd_hidval_t layer_menu_install_timer; -static void layer_install_menu_cb(pcb_hidval_t user_data) +static void layer_install_menu_cb(rnd_hidval_t user_data) { ly_ctx_t ctx; @@ -241,7 +241,7 @@ static void layer_install_menu(void) { - pcb_hidval_t timerdata; + rnd_hidval_t timerdata; if ((pcb_gui == NULL) || (!pcb_gui->gui)) return; @@ -272,9 +272,9 @@ static int layer_menu_key_timer_active = 0; -static pcb_hidval_t layer_menu_key_timer; +static rnd_hidval_t layer_menu_key_timer; -static void timed_layer_menu_key_update_cb(pcb_hidval_t user_data) +static void timed_layer_menu_key_update_cb(rnd_hidval_t user_data) { /* rnd_trace("************ layer key update timer!\n");*/ layer_install_menu_keys(); @@ -284,7 +284,7 @@ void pcb_layer_menu_key_update_ev(rnd_hidlib_t *hidlib, void *user_data, int argc, rnd_event_arg_t argv[]) { - pcb_hidval_t timerdata; + rnd_hidval_t timerdata; /* rnd_trace("************ layer key update ev!\n");*/ Index: trunk/src_plugins/loghid/hid-logger.c =================================================================== --- trunk/src_plugins/loghid/hid-logger.c (revision 30977) +++ trunk/src_plugins/loghid/hid-logger.c (revision 30978) @@ -108,13 +108,13 @@ delegatee_->set_color(gc, color); } -static void log_set_line_cap(rnd_hid_gc_t gc, pcb_cap_style_t style) +static void log_set_line_cap(rnd_hid_gc_t gc, rnd_cap_style_t style) { const char *txt = "unknown"; switch (style) { - ENUM_LOG_TEXT(pcb_cap_square); - ENUM_LOG_TEXT(pcb_cap_round); - ENUM_LOG_TEXT(pcb_cap_invalid); + ENUM_LOG_TEXT(rnd_cap_square); + ENUM_LOG_TEXT(rnd_cap_round); + ENUM_LOG_TEXT(rnd_cap_invalid); } pcb_fprintf(out_, "set_line_cap(gc, %s)\n", txt); delegatee_->set_line_cap(gc, style); Index: trunk/src_plugins/propedit/propdlg.c =================================================================== --- trunk/src_plugins/propedit/propdlg.c (revision 30977) +++ trunk/src_plugins/propedit/propdlg.c (revision 30978) @@ -216,7 +216,7 @@ } -static rnd_bool prop_prv_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, pcb_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) +static rnd_bool prop_prv_mouse_cb(rnd_hid_attribute_t *attrib, pcb_hid_preview_t *prv, rnd_hid_mouse_ev_t kind, rnd_coord_t x, rnd_coord_t y) { return pcb_false; /* don't redraw */ } Index: trunk/src_plugins/script/timer.c =================================================================== --- trunk/src_plugins/script/timer.c (revision 30977) +++ trunk/src_plugins/script/timer.c (revision 30978) @@ -42,7 +42,7 @@ int timer_running = 0; static void start_timer(void); -static void timer_cb(pcb_hidval_t hv) +static void timer_cb(rnd_hidval_t hv) { long n, len; double now; @@ -109,7 +109,7 @@ static void start_timer(void) { - static pcb_hidval_t hv; + static rnd_hidval_t hv; timer_running = 1; pcb_gui->add_timer(pcb_gui, timer_cb, 100, hv); } Index: trunk/src_plugins/tool_std/tool_arrow.c =================================================================== --- trunk/src_plugins/tool_std/tool_arrow.c (revision 30977) +++ trunk/src_plugins/tool_std/tool_arrow.c (revision 30978) @@ -62,7 +62,7 @@ /* Called some time after the click if there was a release but no second click a.k.a. finalize single click (some things are already done in pcb_press_mode at the initial click event) */ -static void click_timer_cb(pcb_hidval_t hv) +static void click_timer_cb(rnd_hidval_t hv) { rnd_hidlib_t *hl = hv.ptr; pcb_board_t *pcb = hv.ptr; @@ -139,7 +139,7 @@ void *ptr1, *ptr2, *ptr3; int otype, type; int test; - pcb_hidval_t hv; + rnd_hidval_t hv; hl->tool_click = pcb_true; /* do something after click time */