Index: trunk/src/hid.h =================================================================== --- trunk/src/hid.h (revision 17222) +++ trunk/src/hid.h (revision 17223) @@ -571,6 +571,11 @@ /* Optional: registers statistical info for a property */ void (*propedit_add_stat)(void *pe, const char *propname, void *propctx, const char *most_common, const char *min, const char *max, const char *avg); + + /* Optional: when non-zero, the core renderer may decide to draw cheaper + (simplified) approximation of some objects that would end up being too + small. For a GUI, this should depend on the zoom level */ + pcb_coord_t coord_per_pix; }; /* One of these functions (in the common code) will be called whenever the GUI Index: trunk/src_plugins/draw_csect/draw_csect.c =================================================================== --- trunk/src_plugins/draw_csect/draw_csect.c (revision 17222) +++ trunk/src_plugins/draw_csect/draw_csect.c (revision 17223) @@ -71,7 +71,7 @@ t.Scale = scale; t.fid = 0; /* use the default font */ t.Flags = pcb_no_flags(); - pcb_text_draw_(&t, 0, 0); + pcb_text_draw_(&t, 0, 0, PCB_TXT_TINY_ACCURATE); return &t; } @@ -87,7 +87,7 @@ t.Scale = scale; t.fid = 0; /* use the default font */ t.Flags = pcb_no_flags(); - pcb_text_draw_(&t, th, 0); + pcb_text_draw_(&t, th, 0, PCB_TXT_TINY_ACCURATE); return &t; } @@ -106,11 +106,11 @@ if (pcb_gui->gui) { /* it is unreadable on black&white and on most exporters */ pcb_gui->set_color(gc, bgcolor); - pcb_text_draw_(&t, 1000000, 0); + pcb_text_draw_(&t, 1000000, 0, PCB_TXT_TINY_ACCURATE); } pcb_gui->set_color(gc, fgcolor); - pcb_text_draw_(&t, 0, 0); + pcb_text_draw_(&t, 0, 0, PCB_TXT_TINY_ACCURATE); return &t; } Index: trunk/src_plugins/draw_fab/draw_fab.c =================================================================== --- trunk/src_plugins/draw_fab/draw_fab.c (revision 17222) +++ trunk/src_plugins/draw_fab/draw_fab.c (revision 17223) @@ -94,7 +94,7 @@ t.X -= w * (align & 3) / 2; if (t.X < 0) t.X = 0; - pcb_text_draw_(&t, 0,0); + pcb_text_draw_(&t, 0,0, PCB_TXT_TINY_ACCURATE); if (align & 8) fab_line(gc, t.X, t.Y + PCB_SCALE_TEXT(font->MaxHeight, t.Scale) + PCB_MIL_TO_COORD(10), @@ -307,7 +307,7 @@ PCB_END_LOOP; PCB_TEXT_LOOP(layer); { - pcb_text_draw_(text, 0, 0); + pcb_text_draw_(text, 0, 0, PCB_TXT_TINY_ACCURATE); } PCB_END_LOOP; pcb_hid_set_line_width(gc, FAB_LINE_W); Index: trunk/src_plugins/draw_fontsel/draw_fontsel.c =================================================================== --- trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 17222) +++ trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 17223) @@ -57,7 +57,7 @@ t.Scale = scale; t.fid = fid; t.Flags = pcb_no_flags(); - pcb_text_draw_(&t, 0, 0); + pcb_text_draw_(&t, 0, 0, PCB_TXT_TINY_ACCURATE); return &t; } Index: trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c =================================================================== --- trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c (revision 17222) +++ trunk/src_plugins/hid_gtk2_gl/gtkhid-gl.c (revision 17223) @@ -68,7 +68,7 @@ void ghid_gl_render_burst(pcb_burst_op_t op, const pcb_box_t *screen) { - + pcb_gui->coord_per_pix = ghid_port.coord_per_pix; } static const gchar *get_color_name(pcb_gtk_color_t * color) Index: trunk/src_plugins/hid_gtk3_cairo/gtkhid-cairo.c =================================================================== --- trunk/src_plugins/hid_gtk3_cairo/gtkhid-cairo.c (revision 17222) +++ trunk/src_plugins/hid_gtk3_cairo/gtkhid-cairo.c (revision 17223) @@ -565,6 +565,7 @@ static void ghid_cairo_render_burst(pcb_burst_op_t op, const pcb_box_t *screen) { + pcb_gui->coord_per_pix = ghid_port.coord_per_pix; } /* Drawing modes usually cycle from RESET to (POSITIVE | NEGATIVE) to FLUSH. screen is not used in this HID. */ Index: trunk/src_plugins/loghid/hid-logger.c =================================================================== --- trunk/src_plugins/loghid/hid-logger.c (revision 17222) +++ trunk/src_plugins/loghid/hid-logger.c (revision 17223) @@ -97,6 +97,7 @@ { pcb_fprintf(out_, "render_burst(%d,[%mm;%mm,%mm;%mm])\n", op, screen->X1, screen->Y1, screen->X2, screen->Y2); delegatee_->render_burst(op, screen); + pcb_gui->coord_per_pix = delegatee_->coord_per_pix; }