Index: trunk/src/draw.c =================================================================== --- trunk/src/draw.c (revision 5494) +++ trunk/src/draw.c (revision 5495) @@ -157,12 +157,12 @@ int plated, unplated; pcb_board_count_holes(&plated, &unplated, drawn_area); - if (plated && pcb_gui->set_layer("plated-drill", SL(PDRILL, 0), 0)) { + if (plated && pcb_gui->set_layer_old("plated-drill", SL(PDRILL, 0), 0)) { DrawHoles(pcb_true, pcb_false, drawn_area); pcb_gui->end_layer(); } - if (unplated && pcb_gui->set_layer("unplated-drill", SL(UDRILL, 0), 0)) { + if (unplated && pcb_gui->set_layer_old("unplated-drill", SL(UDRILL, 0), 0)) { DrawHoles(pcb_false, pcb_true, drawn_area); pcb_gui->end_layer(); } @@ -202,7 +202,7 @@ * first draw all 'invisible' stuff */ if (!conf_core.editor.check_planes - && pcb_gui->set_layer("invisible", SL(INVISIBLE, 0), 0)) { + && pcb_gui->set_layer_old("invisible", SL(INVISIBLE, 0), 0)) { side = PCB_SWAP_IDENT ? PCB_COMPONENT_SIDE : PCB_SOLDER_SIDE; if (PCB->ElementOn) { pcb_r_search(PCB->Data->element_tree, drawn_area, NULL, draw_element_callback, &side, NULL); @@ -217,7 +217,7 @@ for (i = ngroups - 1; i >= 0; i--) { int group = drawn_groups[i]; - if (pcb_gui->set_layer(0, group, 0)) { + if (pcb_gui->set_layer_old(0, group, 0)) { DrawLayerGroup(group, drawn_area); pcb_gui->end_layer(); } @@ -233,22 +233,22 @@ DrawEverything_holes(drawn_area); /* Draw the solder mask if turned on */ - if (pcb_gui->set_layer("componentmask", SL(MASK, TOP), 0)) { + if (pcb_gui->set_layer_old("componentmask", SL(MASK, TOP), 0)) { DrawMask(PCB_COMPONENT_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("soldermask", SL(MASK, BOTTOM), 0)) { + if (pcb_gui->set_layer_old("soldermask", SL(MASK, BOTTOM), 0)) { DrawMask(PCB_SOLDER_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("topsilk", SL(SILK, TOP), 0)) { + if (pcb_gui->set_layer_old("topsilk", SL(SILK, TOP), 0)) { DrawSilk(PCB_COMPONENT_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("bottomsilk", SL(SILK, BOTTOM), 0)) { + if (pcb_gui->set_layer_old("bottomsilk", SL(SILK, BOTTOM), 0)) { DrawSilk(PCB_SOLDER_SIDE, drawn_area); pcb_gui->end_layer(); } @@ -261,7 +261,7 @@ if (PCB->PinOn) pcb_r_search(PCB->Data->element_tree, drawn_area, NULL, draw_element_mark_callback, NULL, NULL); /* Draw rat lines on top */ - if (pcb_gui->set_layer("rats", SL(RATS, 0), 0)) { + if (pcb_gui->set_layer_old("rats", SL(RATS, 0), 0)) { DrawRats(drawn_area); pcb_gui->end_layer(); } @@ -268,28 +268,28 @@ } paste_empty = pcb_layer_is_paste_empty(PCB_COMPONENT_SIDE); - if (pcb_gui->set_layer("toppaste", SL(PASTE, TOP), paste_empty)) { + if (pcb_gui->set_layer_old("toppaste", SL(PASTE, TOP), paste_empty)) { DrawPaste(PCB_COMPONENT_SIDE, drawn_area); pcb_gui->end_layer(); } paste_empty = pcb_layer_is_paste_empty(PCB_SOLDER_SIDE); - if (pcb_gui->set_layer("bottompaste", SL(PASTE, BOTTOM), paste_empty)) { + if (pcb_gui->set_layer_old("bottompaste", SL(PASTE, BOTTOM), paste_empty)) { DrawPaste(PCB_SOLDER_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("topassembly", SL(ASSY, TOP), 0)) { + if (pcb_gui->set_layer_old("topassembly", SL(ASSY, TOP), 0)) { PrintAssembly(PCB_COMPONENT_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("bottomassembly", SL(ASSY, BOTTOM), 0)) { + if (pcb_gui->set_layer_old("bottomassembly", SL(ASSY, BOTTOM), 0)) { PrintAssembly(PCB_SOLDER_SIDE, drawn_area); pcb_gui->end_layer(); } - if (pcb_gui->set_layer("fab", SL(FAB, 0), 0)) { + if (pcb_gui->set_layer_old("fab", SL(FAB, 0), 0)) { pcb_stub_draw_fab(Output.fgGC); pcb_gui->end_layer(); } Index: trunk/src/hid.h =================================================================== --- trunk/src/hid.h (revision 5494) +++ trunk/src/hid.h (revision 5495) @@ -209,13 +209,14 @@ functions should be called. If it returns pcb_true (nonzero), the items in that layer [group] should be drawn using the various drawing functions. In addition to the MAX_LAYERS copper layer - groups, you may select layers indicated by the macros SL_* - defined above, or any others with an index of -1. For copper + groups, you may select virtual layers with an index of -1. For copper layer groups, you may pass NULL for name to have a name fetched - from the PCB struct. The EMPTY argument is a hint - if set, the + from the PCB struct. The _empty argument is a hint - if set, the layer is empty, if zero it may be non-empty. */ - int (*set_layer) (const char *name_, int group_, int _empty); + int (*set_layer_old) (const char *name_, int group_, int _empty); +/* int (*set_layer) (const char *name_, pcb_layergrp_id_t group_, int _empty);*/ + /* Tell the GUI the layer last selected has been finished with */ void (*end_layer) (void); Index: trunk/src/hid_extents.c =================================================================== --- trunk/src/hid_extents.c (revision 5494) +++ trunk/src/hid_extents.c (revision 5495) @@ -10,7 +10,7 @@ int width; } hid_gc_s; -static int extents_set_layer(const char *name, int group, int empty) +static int extents_set_layer_old(const char *name, int group, int empty) { int idx = group; if (idx >= 0 && idx < pcb_max_group) { @@ -135,7 +135,7 @@ extents_hid.description = "used to calculate extents"; extents_hid.poly_before = 1; - extents_hid.set_layer = extents_set_layer; + extents_hid.set_layer_old = extents_set_layer_old; extents_hid.make_gc = extents_make_gc; extents_hid.destroy_gc = extents_destroy_gc; extents_hid.use_mask = extents_use_mask; Index: trunk/src/hid_nogui.c =================================================================== --- trunk/src/hid_nogui.c (revision 5494) +++ trunk/src/hid_nogui.c (revision 5495) @@ -406,7 +406,7 @@ hid->parse_arguments = nogui_parse_arguments; hid->invalidate_lr = nogui_invalidate_lr; hid->invalidate_all = nogui_invalidate_all; - hid->set_layer = nogui_set_layer; + hid->set_layer_old = nogui_set_layer; hid->end_layer = nogui_end_layer; hid->make_gc = nogui_make_gc; hid->destroy_gc = nogui_destroy_gc; Index: trunk/src_plugins/export_dxf/dxf.c =================================================================== --- trunk/src_plugins/export_dxf/dxf.c (revision 5494) +++ trunk/src_plugins/export_dxf/dxf.c (revision 5495) @@ -5955,7 +5955,7 @@ dxf_hid.get_export_options = dxf_get_export_options; dxf_hid.do_export = dxf_do_export; dxf_hid.parse_arguments = dxf_parse_arguments; - dxf_hid.set_layer = dxf_set_layer; + dxf_hid.set_layer_old = dxf_set_layer; dxf_hid.calibrate = dxf_calibrate; dxf_hid.set_crosshair = dxf_set_crosshair; dxf_hid.show_item = dxf_show_item; Index: trunk/src_plugins/export_gcode/gcode.c =================================================================== --- trunk/src_plugins/export_gcode/gcode.c (revision 5494) +++ trunk/src_plugins/export_gcode/gcode.c (revision 5495) @@ -891,7 +891,7 @@ gcode_hid.get_export_options = gcode_get_export_options; gcode_hid.do_export = gcode_do_export; gcode_hid.parse_arguments = gcode_parse_arguments; - gcode_hid.set_layer = gcode_set_layer; + gcode_hid.set_layer_old = gcode_set_layer; gcode_hid.make_gc = gcode_make_gc; gcode_hid.destroy_gc = gcode_destroy_gc; gcode_hid.use_mask = gcode_use_mask; Index: trunk/src_plugins/export_gerber/gerber.c =================================================================== --- trunk/src_plugins/export_gerber/gerber.c (revision 5494) +++ trunk/src_plugins/export_gerber/gerber.c (revision 5495) @@ -1205,7 +1205,7 @@ gerber_hid.get_export_options = gerber_get_export_options; gerber_hid.do_export = gerber_do_export; gerber_hid.parse_arguments = gerber_parse_arguments; - gerber_hid.set_layer = gerber_set_layer; + gerber_hid.set_layer_old = gerber_set_layer; gerber_hid.make_gc = gerber_make_gc; gerber_hid.destroy_gc = gerber_destroy_gc; gerber_hid.use_mask = gerber_use_mask; Index: trunk/src_plugins/export_nelma/nelma.c =================================================================== --- trunk/src_plugins/export_nelma/nelma.c (revision 5494) +++ trunk/src_plugins/export_nelma/nelma.c (revision 5495) @@ -1000,7 +1000,7 @@ nelma_hid.get_export_options = nelma_get_export_options; nelma_hid.do_export = nelma_do_export; nelma_hid.parse_arguments = nelma_parse_arguments; - nelma_hid.set_layer = nelma_set_layer; + nelma_hid.set_layer_old = nelma_set_layer; nelma_hid.make_gc = nelma_make_gc; nelma_hid.destroy_gc = nelma_destroy_gc; nelma_hid.use_mask = nelma_use_mask; Index: trunk/src_plugins/export_openscad/scad.c =================================================================== --- trunk/src_plugins/export_openscad/scad.c (revision 5494) +++ trunk/src_plugins/export_openscad/scad.c (revision 5495) @@ -1144,7 +1144,7 @@ scad_hid.get_export_options = scad_get_export_options; scad_hid.do_export = scad_do_export; scad_hid.parse_arguments = scad_parse_arguments; - scad_hid.set_layer = scad_set_layer; + scad_hid.set_layer_old = scad_set_layer; scad_hid.calibrate = scad_calibrate; scad_hid.set_crosshair = scad_set_crosshair; Index: trunk/src_plugins/export_png/png.c =================================================================== --- trunk/src_plugins/export_png/png.c (revision 5494) +++ trunk/src_plugins/export_png/png.c (revision 5495) @@ -1505,7 +1505,7 @@ png_hid.get_export_options = png_get_export_options; png_hid.do_export = png_do_export; png_hid.parse_arguments = png_parse_arguments; - png_hid.set_layer = png_set_layer; + png_hid.set_layer_old = png_set_layer; png_hid.make_gc = png_make_gc; png_hid.destroy_gc = png_destroy_gc; png_hid.use_mask = png_use_mask; Index: trunk/src_plugins/export_ps/eps.c =================================================================== --- trunk/src_plugins/export_ps/eps.c (revision 5494) +++ trunk/src_plugins/export_ps/eps.c (revision 5495) @@ -615,7 +615,7 @@ eps_hid.get_export_options = eps_get_export_options; eps_hid.do_export = eps_do_export; eps_hid.parse_arguments = eps_parse_arguments; - eps_hid.set_layer = eps_set_layer; + eps_hid.set_layer_old = eps_set_layer; eps_hid.make_gc = eps_make_gc; eps_hid.destroy_gc = eps_destroy_gc; eps_hid.use_mask = eps_use_mask; Index: trunk/src_plugins/export_ps/ps.c =================================================================== --- trunk/src_plugins/export_ps/ps.c (revision 5494) +++ trunk/src_plugins/export_ps/ps.c (revision 5495) @@ -1569,7 +1569,7 @@ hid->get_export_options = ps_get_export_options; hid->do_export = ps_do_export; hid->parse_arguments = ps_parse_arguments; - hid->set_layer = ps_set_layer; + hid->set_layer_old = ps_set_layer; hid->make_gc = ps_make_gc; hid->destroy_gc = ps_destroy_gc; hid->use_mask = ps_use_mask; Index: trunk/src_plugins/export_svg/svg.c =================================================================== --- trunk/src_plugins/export_svg/svg.c (revision 5494) +++ trunk/src_plugins/export_svg/svg.c (revision 5495) @@ -711,7 +711,7 @@ svg_hid.get_export_options = svg_get_export_options; svg_hid.do_export = svg_do_export; svg_hid.parse_arguments = svg_parse_arguments; - svg_hid.set_layer = svg_set_layer; + svg_hid.set_layer_old = svg_set_layer; svg_hid.make_gc = svg_make_gc; svg_hid.destroy_gc = svg_destroy_gc; svg_hid.use_mask = svg_use_mask; Index: trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid.c =================================================================== --- trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid.c (revision 5494) +++ trunk/src_plugins/gpmi/pcb-gpmi/gpmi_plugin/gpmi_pkg/hid/hid.c (revision 5495) @@ -52,7 +52,7 @@ h->hid->do_export = gpmi_hid_do_export; h->hid->parse_arguments = gpmi_hid_parse_arguments; h->hid->set_crosshair = gpmi_hid_set_crosshair; - h->hid->set_layer = gpmi_hid_set_layer; + h->hid->set_layer_old = gpmi_hid_set_layer; h->hid->set_color = gpmi_hid_set_color; h->hid->set_line_cap = gpmi_hid_set_line_cap; h->hid->set_line_width = gpmi_hid_set_line_width; Index: trunk/src_plugins/hid_batch/batch.c =================================================================== --- trunk/src_plugins/hid_batch/batch.c (revision 5494) +++ trunk/src_plugins/hid_batch/batch.c (revision 5495) @@ -342,7 +342,7 @@ batch_hid.parse_arguments = batch_parse_arguments; batch_hid.invalidate_lr = batch_invalidate_lr; batch_hid.invalidate_all = batch_invalidate_all; - batch_hid.set_layer = batch_set_layer; + batch_hid.set_layer_old = batch_set_layer; batch_hid.make_gc = batch_make_gc; batch_hid.destroy_gc = batch_destroy_gc; batch_hid.use_mask = batch_use_mask; Index: trunk/src_plugins/hid_gtk/gtkhid-main.c =================================================================== --- trunk/src_plugins/hid_gtk/gtkhid-main.c (revision 5494) +++ trunk/src_plugins/hid_gtk/gtkhid-main.c (revision 5495) @@ -2068,7 +2068,7 @@ ghid_hid.invalidate_all = ghid_invalidate_all; ghid_hid.notify_crosshair_change = ghid_notify_crosshair_change; ghid_hid.notify_mark_change = ghid_notify_mark_change; - ghid_hid.set_layer = ghid_set_layer; + ghid_hid.set_layer_old = ghid_set_layer; ghid_hid.make_gc = ghid_make_gc; ghid_hid.destroy_gc = ghid_destroy_gc; ghid_hid.use_mask = ghid_use_mask; Index: trunk/src_plugins/hid_lesstif/main.c =================================================================== --- trunk/src_plugins/hid_lesstif/main.c (revision 5494) +++ trunk/src_plugins/hid_lesstif/main.c (revision 5495) @@ -3787,7 +3787,7 @@ lesstif_hid.invalidate_all = lesstif_invalidate_all; lesstif_hid.notify_crosshair_change = lesstif_notify_crosshair_change; lesstif_hid.notify_mark_change = lesstif_notify_mark_change; - lesstif_hid.set_layer = lesstif_set_layer; + lesstif_hid.set_layer_old = lesstif_set_layer; lesstif_hid.make_gc = lesstif_make_gc; lesstif_hid.destroy_gc = lesstif_destroy_gc; lesstif_hid.use_mask = lesstif_use_mask; Index: trunk/src_plugins/hid_remote/remote.c =================================================================== --- trunk/src_plugins/hid_remote/remote.c (revision 5494) +++ trunk/src_plugins/hid_remote/remote.c (revision 5495) @@ -390,7 +390,7 @@ remote_hid.parse_arguments = remote_parse_arguments; remote_hid.invalidate_lr = remote_invalidate_lr; remote_hid.invalidate_all = remote_invalidate_all; - remote_hid.set_layer = remote_set_layer; + remote_hid.set_layer_old = remote_set_layer; remote_hid.make_gc = remote_make_gc; remote_hid.destroy_gc = remote_destroy_gc; remote_hid.use_mask = remote_use_mask; Index: trunk/src_plugins/loghid/hid-logger.c =================================================================== --- trunk/src_plugins/loghid/hid-logger.c (revision 5494) +++ trunk/src_plugins/loghid/hid-logger.c (revision 5495) @@ -48,7 +48,7 @@ static int log_set_layer(const char *name, int group, int empty) { pcb_fprintf(out_, "set_layer(name=%s, group=%d, empty=%s", name, group, empty ? "true" : "false"); - return delegatee_->set_layer(name, group, empty); + return delegatee_->set_layer_old(name, group, empty); } static void log_end_layer() {