Index: trunk/doc/conf/tree/editor.html =================================================================== --- trunk/doc/conf/tree/editor.html (revision 29396) +++ trunk/doc/conf/tree/editor.html (revision 29397) @@ -46,7 +46,6 @@ io_incomp_popup boolean 0 wether to enable popping up the io incompatibility list dialog on save incompatibility errors io_incomp_style string 0 view listing style (list or simple), when io_incomp_popup is true click_time integer 0 default time for click expiration, in ms - enable_stroke boolean 0 Enable libstroke gestures on middle mouse button when non-zero live_routing boolean 0 autorouter shows tracks in progress beep_when_finished boolean 0 flag if a signal should be produced when searching of connections is done undo_warning_size integer 0 warn the user when undo list exceeds this amount of kilobytes in memory @@ -60,4 +59,5 @@ auto_place boolean 0 [hidlib] force placement of GUI windows (dialogs), trying to override the window manager fullscreen boolean 0 [hidlib] hide widgets to make more room for the drawing crosshair_shape_idx integer 0 [hidlib] crosshair shape as defined in pcb_crosshair_shape_e + enable_stroke boolean 0 [hidlib] Enable libstroke gestures on middle mouse button when non-zero Index: trunk/src/conf_core.h =================================================================== --- trunk/src/conf_core.h (revision 29396) +++ trunk/src/conf_core.h (revision 29397) @@ -69,11 +69,10 @@ CFT_BOOLEAN symmetric_negative; /* selection box behaviour: when set, the selection direction is considered negative only if the box has negative size in the X direction */ } selection; - /* these two would need to be moved in the router plugin.... There are two - reasons to keep them here: - - the original pcb and pcb-rnd file formats already have named/numbered flags for these, so io_pcb needs these - - more than one router plugin may share these */ - CFT_BOOLEAN enable_stroke; /* Enable libstroke gestures on middle mouse button when non-zero */ + /* this would need to be moved in the router plugin.... There are two + reasons to keep it here: + - the original pcb and pcb-rnd file formats already have named/numbered flags for it, so io_pcb needs it + - more than one router plugins may share it */ CFT_BOOLEAN live_routing; /* autorouter shows tracks in progress */ /* Keep it here instead of the router plugin: more than one router plugin may share these */ Index: trunk/src/crosshair.c =================================================================== --- trunk/src/crosshair.c (revision 29396) +++ trunk/src/crosshair.c (revision 29397) @@ -67,7 +67,6 @@ pcb_crosshair_t pcb_crosshair; /* information about cursor settings */ pcb_mark_t pcb_marked; -pcb_mark_t pcb_grabbed; pcb_crosshair_note_t pcb_crosshair_note; @@ -962,7 +961,7 @@ } PCB->hidlib.ch_x = pcb_crosshair.X = snap_data.x; - PCB->hidlib.ch_x = pcb_crosshair.Y = snap_data.y; + PCB->hidlib.ch_y = pcb_crosshair.Y = snap_data.y; if (conf_core.editor.highlight_on_point) onpoint_work(&pcb_crosshair, pcb_crosshair.X, pcb_crosshair.Y); Index: trunk/src/crosshair.h =================================================================== --- trunk/src/crosshair.h (revision 29396) +++ trunk/src/crosshair.h (revision 29397) @@ -33,6 +33,7 @@ #include "config.h" #include "vtonpoint.h" #include +#include #include "obj_line.h" #include "obj_poly.h" #include "route.h" @@ -54,12 +55,6 @@ pcb_coord_t radius; } pcb_attached_object_t; -typedef struct { - pcb_bool status; - pcb_coord_t X, Y; - unsigned user_placed:1; /* if 1, the user has explicitly placed the mark - do not move it */ -} pcb_mark_t; - typedef struct { /* holds crosshair, cursor and crosshair-attachment information */ pcb_hid_gc_t GC; /* GC for cursor drawing */ pcb_hid_gc_t AttachGC; /* and for displaying buffer contents */ Index: trunk/src/gui_act.c =================================================================== --- trunk/src/gui_act.c (revision 29396) +++ trunk/src/gui_act.c (revision 29397) @@ -232,7 +232,7 @@ break; case F_ToggleStroke: - conf_toggle_editor(enable_stroke); + conf_toggle_heditor(enable_stroke); break; case F_ToggleShowDRC: @@ -380,86 +380,7 @@ PCB_ACT_FAIL(Display); } -/* --------------------------------------------------------------------------- */ -static const char pcb_acts_Tool[] = - "Tool(Arc|Arrow|Copy|InsertPoint|Line|Lock|Move|None|PasteBuffer)\n" - "Tool(Poly|Rectangle|Remove|Rotate|Text|Thermal|Via)\n" "Tool(Press|Release|Cancel|Stroke)\n" "Tool(Save|Restore)"; - -static const char pcb_acth_Tool[] = "Change or use the tool mode."; -/* DOC: tool.html */ -static fgw_error_t pcb_act_Tool(fgw_arg_t *res, int argc, fgw_arg_t *argv) -{ - pcb_hidlib_t *hidlib = PCB_ACT_HIDLIB; - const char *cmd; - PCB_ACT_IRES(0); - PCB_ACT_CONVARG(1, FGW_STR, Tool, cmd = argv[1].val.str); - - /* it is okay to use crosshair directly here, the mode command is called from a click when it needs coords */ - hidlib->tool_x = hidlib->ch_x; - hidlib->tool_y = hidlib->ch_y; - pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_false); - switch(pcb_funchash_get(cmd, NULL)) { - case F_Cancel: - pcb_tool_select_by_id(PCB_ACT_HIDLIB, pcbhl_conf.editor.mode); - break; - case F_Escape: - escape:; - { - const pcb_tool_t *t = pcb_tool_get(pcbhl_conf.editor.mode); - if ((t == NULL) || (t->escape == NULL)) { - pcb_tool_select_by_name(PCB_ACT_HIDLIB, "arrow"); - hidlib->tool_hit = hidlib->tool_click = 0; /* if the mouse button is still pressed, don't start selecting a box */ - } - else - t->escape(PCB_ACT_HIDLIB); - } - break; - - case F_Press: - case F_Notify: - pcb_press_mode(PCB_ACT_HIDLIB); - break; - case F_Release: - if (conf_core.editor.enable_stroke) { - int handled = 0; - pcb_event(PCB_ACT_HIDLIB, PCB_EVENT_STROKE_FINISH, "p", &handled); - if (handled) { - /* Ugly hack: returning 1 here will break execution of the - action script, so actions after this one could do things - that would be executed only after non-recognized gestures */ - pcb_release_mode(PCB_ACT_HIDLIB); - pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_true); - return 1; - } - } - pcb_release_mode(PCB_ACT_HIDLIB); - break; - case F_Stroke: - if (conf_core.editor.enable_stroke) { - pcb_event(PCB_ACT_HIDLIB, PCB_EVENT_STROKE_START, "cc", hidlib->tool_x, hidlib->tool_y); - break; - } - - /* Right mouse button restarts drawing mode. */ - goto escape; - - case F_Restore: /* restore the last saved tool */ - pcb_tool_restore(PCB_ACT_HIDLIB); - break; - - case F_Save: /* save currently selected tool */ - pcb_tool_save(PCB_ACT_HIDLIB); - break; - - default: - if (pcb_tool_select_by_name(PCB_ACT_HIDLIB, cmd) != 0) - pcb_message(PCB_MSG_ERROR, "No such tool: '%s'\n", cmd); - } - pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_true); - return 0; -} - /* ---------------------------------------------------------------- */ static const char pcb_acts_CycleDrag[] = "CycleDrag()\n"; static const char pcb_acth_CycleDrag[] = "Cycle through which object is being dragged"; @@ -1743,8 +1664,6 @@ {"FullScreen", pcb_act_FullScreen, pcb_acth_FullScreen, pcb_acts_FullScreen}, {"MarkCrosshair", pcb_act_MarkCrosshair, pcb_acth_MarkCrosshair, pcb_acts_MarkCrosshair}, {"Message", pcb_act_Message, pcb_acth_Message, pcb_acts_Message}, - {"Tool", pcb_act_Tool, pcb_acth_Tool, pcb_acts_Tool}, - {"Mode", pcb_act_Tool, pcb_acth_Tool, pcb_acts_Tool}, {"SetSame", pcb_act_SetSame, pcb_acth_SetSame, pcb_acts_SetSame}, {"RouteStyle", pcb_act_RouteStyle, pcb_acth_RouteStyle, pcb_acts_RouteStyle}, {"CreateMenu", pcb_act_CreateMenu, pcb_acth_CreateMenu, pcb_acts_CreateMenu}, Index: trunk/src/librnd/core/event.c =================================================================== --- trunk/src/librnd/core/event.c (revision 29396) +++ trunk/src/librnd/core/event.c (revision 29397) @@ -42,6 +42,8 @@ "pcbev_load_post", "pcbeb_new_tool", "pcbeb_tool_select_pre", + "pcbeb_tool_release", + "pcbeb_tool_press", "pcbev_board_changed", "pcbev_board_meta_changed", "pcbev_board_fn_changed", Index: trunk/src/librnd/core/event.h =================================================================== --- trunk/src/librnd/core/event.h (revision 29396) +++ trunk/src/librnd/core/event.h (revision 29397) @@ -41,6 +41,8 @@ PCB_EVENT_TOOL_REG, /* called after a new tool has been registered; arg is (pcb_tool_t *) of the new tool */ PCB_EVENT_TOOL_SELECT_PRE, /* called before a tool is selected; arg is (int *ok, int toolid); if ok is non-zero if the selection is accepted */ + PCB_EVENT_TOOL_RELEASE, /* no arg */ + PCB_EVENT_TOOL_PRESS, /* no arg */ PCB_EVENT_BOARD_CHANGED, /* called after the board being edited got _replaced_ (used to be the PCBChanged action) */ PCB_EVENT_BOARD_META_CHANGED, /* called if the metadata of the board has changed */ Index: trunk/src/librnd/core/hid_init.c =================================================================== --- trunk/src/librnd/core/hid_init.c (revision 29396) +++ trunk/src/librnd/core/hid_init.c (revision 29397) @@ -321,6 +321,7 @@ extern void pcb_hid_dlg_init2(void); extern void pcb_hid_nogui_init2(void); extern void rnd_conf_act_init2(void); +extern void rnd_tool_act_init2(void); void pcb_hidlib_init2(const pup_buildin_t *buildins, const pup_buildin_t *local_buildins) { @@ -368,6 +369,7 @@ pcb_hid_dlg_init2(); pcb_hid_nogui_init2(); rnd_conf_act_init2(); + rnd_tool_act_init2(); } Index: trunk/src/librnd/core/hidlib_conf.h =================================================================== --- trunk/src/librnd/core/hidlib_conf.h (revision 29396) +++ trunk/src/librnd/core/hidlib_conf.h (revision 29397) @@ -94,6 +94,7 @@ CFT_BOOLEAN auto_place; /* force placement of GUI windows (dialogs), trying to override the window manager */ CFT_BOOLEAN fullscreen; /* hide widgets to make more room for the drawing */ CFT_INTEGER crosshair_shape_idx; /* crosshair shape as defined in pcb_crosshair_shape_e */ + CFT_BOOLEAN enable_stroke; /* Enable libstroke gestures on middle mouse button when non-zero */ const struct { CFT_BOOLEAN flip_x; /* view: flip the board along the X (horizontal) axis */ Index: trunk/src/librnd/core/tool.c =================================================================== --- trunk/src/librnd/core/tool.c (revision 29396) +++ trunk/src/librnd/core/tool.c (revision 29397) @@ -2,6 +2,8 @@ * COPYRIGHT * * pcb-rnd, interactive printed circuit board design + * Copyright (C) 1994,1995,1996 Thomas Nau + * Copyright (C) 1997, 1998, 1999, 2000, 2001 Harry Eaton * Copyright (C) 2017,2019,2020 Tibor 'Igor2' Palinkas * * This program is free software; you can redistribute it and/or modify @@ -31,9 +33,13 @@ #include #include #include +#include +#include #define PCB_MAX_MODESTACK_DEPTH 16 /* maximum depth of mode stack */ +pcb_bool pcb_tool_is_saved = pcb_false; + vtp0_t pcb_tools; pcb_toolid_t pcb_tool_prev_id; @@ -254,4 +260,112 @@ wrap_retv(redo_act, return pcb_true, (hl)); } +pcb_mark_t pcb_grabbed; /* TEMPORARY */ +static void do_release(pcb_hidlib_t *hidlib) +{ + if (pcbhl_conf.temp.click_cmd_entry_active && (pcb_cli_mouse(hidlib, 0) == 0)) + return; + pcb_grabbed.status = pcb_false; + + pcb_tool_release(hidlib); + + if (pcb_tool_is_saved) + pcb_tool_restore(hidlib); + pcb_tool_is_saved = pcb_false; + pcb_event(hidlib, PCB_EVENT_TOOL_RELEASE, NULL); +} + +void pcb_tool_do_press(pcb_hidlib_t *hidlib) +{ + if (pcbhl_conf.temp.click_cmd_entry_active && (pcb_cli_mouse(hidlib, 1) == 0)) + return; + + pcb_grabbed.X = hidlib->tool_x; + pcb_grabbed.Y = hidlib->tool_y; + + pcb_tool_press(hidlib); + pcb_event(hidlib, PCB_EVENT_TOOL_PRESS, NULL); +} + + +static const char pcb_acts_Tool[] = + "Tool(Arc|Arrow|Copy|InsertPoint|Line|Lock|Move|None|PasteBuffer)\n" + "Tool(Poly|Rectangle|Remove|Rotate|Text|Thermal|Via)\n" "Tool(Press|Release|Cancel|Stroke)\n" "Tool(Save|Restore)"; + +static const char pcb_acth_Tool[] = "Change or use the tool mode."; +/* DOC: tool.html */ +static fgw_error_t pcb_act_Tool(fgw_arg_t *res, int argc, fgw_arg_t *argv) +{ + pcb_hidlib_t *hidlib = PCB_ACT_HIDLIB; + const char *cmd; + PCB_ACT_IRES(0); + PCB_ACT_CONVARG(1, FGW_STR, Tool, cmd = argv[1].val.str); + + /* it is okay to use crosshair directly here, the mode command is called from a click when it needs coords */ + hidlib->tool_x = hidlib->ch_x; + hidlib->tool_y = hidlib->ch_y; + pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_false); + if (pcb_strcasecmp(cmd, "Cancel") == 0) { + pcb_tool_select_by_id(PCB_ACT_HIDLIB, pcbhl_conf.editor.mode); + } + else if (pcb_strcasecmp(cmd, "Escape") == 0) { + const pcb_tool_t *t; + escape:; + t = pcb_tool_get(pcbhl_conf.editor.mode); + if ((t == NULL) || (t->escape == NULL)) { + pcb_tool_select_by_name(PCB_ACT_HIDLIB, "arrow"); + hidlib->tool_hit = hidlib->tool_click = 0; /* if the mouse button is still pressed, don't start selecting a box */ + } + else + t->escape(PCB_ACT_HIDLIB); + } + else if ((pcb_strcasecmp(cmd, "Press") == 0) || (pcb_strcasecmp(cmd, "Notify") == 0)) { + pcb_tool_do_press(PCB_ACT_HIDLIB); + } + else if (pcb_strcasecmp(cmd, "Release") == 0) { + if (pcbhl_conf.editor.enable_stroke) { + int handled = 0; + pcb_event(PCB_ACT_HIDLIB, PCB_EVENT_STROKE_FINISH, "p", &handled); + if (handled) { + /* Ugly hack: returning 1 here will break execution of the + action script, so actions after this one could do things + that would be executed only after non-recognized gestures */ + do_release(PCB_ACT_HIDLIB); + pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_true); + return 1; + } + } + do_release(PCB_ACT_HIDLIB); + } + else if (pcb_strcasecmp(cmd, "Stroke") == 0) { + if (pcbhl_conf.editor.enable_stroke) + pcb_event(PCB_ACT_HIDLIB, PCB_EVENT_STROKE_START, "cc", hidlib->tool_x, hidlib->tool_y); + else + goto escape; /* Right mouse button restarts drawing mode. */ + } + else if (pcb_strcasecmp(cmd, "Restore") == 0) { /* restore the last saved tool */ + pcb_tool_restore(PCB_ACT_HIDLIB); + } + else if (pcb_strcasecmp(cmd, "Save") == 0) { /* save currently selected tool */ + pcb_tool_save(PCB_ACT_HIDLIB); + } + else { + if (pcb_tool_select_by_name(PCB_ACT_HIDLIB, cmd) != 0) + pcb_message(PCB_MSG_ERROR, "No such tool: '%s'\n", cmd); + } + pcb_hid_notify_crosshair_change(PCB_ACT_HIDLIB, pcb_true); + return 0; +} + +static pcb_action_t tool_action_list[] = { + {"Tool", pcb_act_Tool, pcb_acth_Tool, pcb_acts_Tool}, + {"Mode", pcb_act_Tool, pcb_acth_Tool, pcb_acts_Tool} +}; + +void rnd_tool_act_init2(void) +{ + PCB_REGISTER_ACTIONS(tool_action_list, NULL); +} + + Index: trunk/src/librnd/core/tool.h =================================================================== --- trunk/src/librnd/core/tool.h (revision 29396) +++ trunk/src/librnd/core/tool.h (revision 29397) @@ -71,9 +71,16 @@ unsigned long user_flags; } pcb_tool_t; +typedef struct pcb_mark_s { + pcb_bool status; + pcb_coord_t X, Y; + unsigned user_placed:1; /* if 1, the user has explicitly placed the mark - do not move it */ +} pcb_mark_t; + extern vtp0_t pcb_tools; extern pcb_toolid_t pcb_tool_prev_id; extern pcb_toolid_t pcb_tool_next_id; +extern pcb_bool pcb_tool_is_saved; /* (un)initialize the tool subsystem */ void pcb_tool_init(void); @@ -115,6 +122,9 @@ pcb_bool pcb_tool_redo_act(pcb_hidlib_t *hl); +/* fake a click */ +void pcb_tool_do_press(pcb_hidlib_t *hidlib); + /**** Low level, for internal use ****/ /* Get the tool pointer of a tool by id */ Index: trunk/src/obj_line_drcenf.c =================================================================== --- trunk/src/obj_line_drcenf.c (revision 29396) +++ trunk/src/obj_line_drcenf.c (revision 29397) @@ -519,7 +519,7 @@ pcb_conf_setf(CFR_DESIGN, "editor/line_refraction", -1, "%d", 2); } } - pcb_crosshair.X = r45.X; - pcb_crosshair.Y = r45.Y; + pcb->hidlib.ch_x = pcb_crosshair.X = r45.X; + pcb->hidlib.ch_y = pcb_crosshair.Y = r45.Y; } } Index: trunk/src/remove_act.c =================================================================== --- trunk/src/remove_act.c (revision 29396) +++ trunk/src/remove_act.c (revision 29397) @@ -76,7 +76,7 @@ pcb_hid_get_coords("Click on object to delete", &hidlib->tool_x, &hidlib->tool_y, 0); pcb_tool_save(PCB_ACT_HIDLIB); pcb_tool_select_by_name(PCB_ACT_HIDLIB, "remove"); - pcb_press_mode(PCB_ACT_HIDLIB); + pcb_tool_do_press(PCB_ACT_HIDLIB); pcb_tool_restore(PCB_ACT_HIDLIB); } break; Index: trunk/src/tool_logic.c =================================================================== --- trunk/src/tool_logic.c (revision 29396) +++ trunk/src/tool_logic.c (revision 29397) @@ -42,6 +42,8 @@ #include "tool_logic.h" static void tool_logic_chg_layer(pcb_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]); +static void pcb_release_mode(pcb_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]); +static void pcb_press_mode(pcb_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]); /*** Generic part, all rnd apps should do something like this ***/ @@ -78,6 +80,8 @@ } pcb_event_bind(PCB_EVENT_TOOL_SELECT_PRE, tool_logic_chg_tool, NULL, tool_logic_cookie); + pcb_event_bind(PCB_EVENT_TOOL_RELEASE, pcb_release_mode, NULL, tool_logic_cookie); + pcb_event_bind(PCB_EVENT_TOOL_PRESS, pcb_press_mode, NULL, tool_logic_cookie); pcb_event_bind(PCB_EVENT_LAYERVIS_CHANGED, tool_logic_chg_layer, NULL, tool_logic_cookie); } @@ -98,8 +102,6 @@ was_rat = PCB->RatDraw; } -pcb_bool pcb_tool_is_saved = pcb_false; - static void get_grid_lock_coordinates(int type, void *ptr1, void *ptr2, void *ptr3, pcb_coord_t * x, pcb_coord_t * y) { switch (type) { @@ -181,34 +183,18 @@ /*** old helpers ***/ -void pcb_release_mode(pcb_hidlib_t *hidlib) +static void pcb_release_mode(pcb_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]) { - if (pcbhl_conf.temp.click_cmd_entry_active && (pcb_cli_mouse(hidlib, 0) == 0)) - return; - - pcb_grabbed.status = pcb_false; - pcb_tool_release(hidlib); - - if (pcb_tool_is_saved) - pcb_tool_restore(hidlib); - pcb_tool_is_saved = pcb_false; pcb_draw(); } -void pcb_press_mode(pcb_hidlib_t *hidlib) +static void pcb_press_mode(pcb_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]) { pcb_board_t *pcb = (pcb_board_t *)hidlib; - if (pcbhl_conf.temp.click_cmd_entry_active && (pcb_cli_mouse(hidlib, 1) == 0)) - return; - - pcb_grabbed.X = pcb_crosshair.X; - pcb_grabbed.Y = pcb_crosshair.Y; - if (conf_core.temp.rat_warn) { if (pcb_data_clear_flag(pcb->Data, PCB_FLAG_WARN, 1, 0) > 0) pcb_board_set_changed_flag(pcb_true); } - pcb_tool_press(hidlib); pcb_draw(); } Index: trunk/src/tool_logic.h =================================================================== --- trunk/src/tool_logic.h (revision 29396) +++ trunk/src/tool_logic.h (revision 29397) @@ -37,16 +37,5 @@ void pcb_tool_attach_for_copy(pcb_hidlib_t *hl, pcb_coord_t PlaceX, pcb_coord_t PlaceY, pcb_bool do_rubberband); void pcb_tool_notify_block(void); /* create first or second corner of a marked block (when clicked) */ -extern pcb_bool pcb_tool_is_saved; -/**** old helpers ****/ - -/* does what's appropriate for the current mode setting (when clicked). This - normally means creation of an object at the current crosshair location. - new created objects are added to the create undo list of course */ -void pcb_press_mode(pcb_hidlib_t *hidlib); - -void pcb_release_mode(pcb_hidlib_t *hidlib); - - #endif Index: trunk/src_plugins/tool_std/tool_arc.c =================================================================== --- trunk/src_plugins/tool_std/tool_arc.c (revision 29396) +++ trunk/src_plugins/tool_std/tool_arc.c (revision 29397) @@ -91,9 +91,9 @@ pcb_arc_t *arc; pcb_coord_t wx, wy; pcb_angle_t sa, dir; - wx = hl->tool_x - pcb_crosshair.AttachedBox.Point1.X; wy = hl->tool_y - pcb_crosshair.AttachedBox.Point1.Y; +pcb_trace("arc: %mm %mm wh %mm %mm\n", hl->tool_x, hl->tool_y, wx, wy); if (PCB_XOR(pcb_crosshair.AttachedBox.otherway, coord_abs(wy) > coord_abs(wx))) { pcb_crosshair.AttachedBox.Point2.X = pcb_crosshair.AttachedBox.Point1.X + coord_abs(wy) * PCB_SGNZ(wx); sa = (wx >= 0) ? 0 : 180; Index: trunk/util/gsch2pcb-rnd/glue.c =================================================================== --- trunk/util/gsch2pcb-rnd/glue.c (revision 29396) +++ trunk/util/gsch2pcb-rnd/glue.c (revision 29397) @@ -35,7 +35,6 @@ const char *pcb_hidlib_default_embedded_menu = ""; -void pcb_tool_gui_init(void) { } void pcb_hidlib_crosshair_move_to(pcb_coord_t abs_x, pcb_coord_t abs_y, int mouse_mot) { }