Index: trunk/doc/conf/tree/appearance.html =================================================================== --- trunk/doc/conf/tree/appearance.html (revision 30945) +++ trunk/doc/conf/tree/appearance.html (revision 30946) @@ -3,14 +3,14 @@

subtree: appearance

node name type flags description -
compact boolean 0 when set: optimize GUI widget arrangement for small screen; may be wasting some screen space on large screen -
rat_thickness coord 0 -
mark_size coord 0 relative marker size -
text_host_bbox boolean 0 when moving a text object, the outline thin-draw should also include the bounding box -
term_label_size real 0 size of terminal labels, in pcb font scale (100 is for the normal size) -
subc_layer_per_side boolean 0 hide top or bottom placed subcircuit annotations if the view is showing the other side -
invis_other_groups boolean 0 render non-current group layers with the inivisble color -
black_current_group boolean 0 render all layers of the current group black, for maximum contrast -
layer_alpha real 0 [hidlib] alpha value for layer drawing -
drill_alpha real 0 [hidlib] alpha value for drill drawing +
compact rnd_cfn_boolean 0 when set: optimize GUI widget arrangement for small screen; may be wasting some screen space on large screen +
rat_thickness rnd_cfn_coord 0 +
mark_size rnd_cfn_coord 0 relative marker size +
text_host_bbox rnd_cfn_boolean 0 when moving a text object, the outline thin-draw should also include the bounding box +
term_label_size rnd_cfn_real 0 size of terminal labels, in pcb font scale (100 is for the normal size) +
subc_layer_per_side rnd_cfn_boolean 0 hide top or bottom placed subcircuit annotations if the view is showing the other side +
invis_other_groups rnd_cfn_boolean 0 render non-current group layers with the inivisble color +
black_current_group rnd_cfn_boolean 0 render all layers of the current group black, for maximum contrast +
layer_alpha rnd_cfn_real 0 [hidlib] alpha value for layer drawing +
drill_alpha rnd_cfn_real 0 [hidlib] alpha value for drill drawing
Index: trunk/doc/conf/tree/appearance_color.html =================================================================== --- trunk/doc/conf/tree/appearance_color.html (revision 30945) +++ trunk/doc/conf/tree/appearance_color.html (revision 30946) @@ -3,30 +3,30 @@

subtree: appearance/color

node name type flags description -
crosshair color 0 obsolete - DO NOT USE - kept for compatibility (use appearance/color/cross instead) -
attached color 0 color of the non-layer corsshair-attached objects drawn in XOR (e.g. when padstack or buffer outline before placed; layer-objects like lines and arcs typically onherit the layer color) -
drc color 0 color of the on-screen drc clearance indication while routing -
mark color 0 color of the on-screen marks (user placed mark and automatic 'grabbed' mark) -
selected color 0 generic object selection color -
via color 0 non-terminal padstack shape on current layer -
via_far color 0 non-terminal padstack shape on non-current ('far side') layer -
pin color 0 terminal padstack shape on current layer -
pin_far color 0 terminal padstack shape on non-current ('far side') layer -
pin_name color 0 on-screen terminal number/name labels -
subc color 0 on-screen subcircuit marks -
subc_nonetlist color 0 on-screen subcircuit marks for subcircuits with the nonetlist flag -
extobj color 0 on-screen marks of extended objects -
padstackmark color 0 on-screen center mark cross for padstacks -
rat color 0 on-screen rat lines -
invisible_objects color 0 other-side objects and padstack shapes on non-current layer -
connected color 0 'connected' highlight (galvanic connections found) -
warn color 0 warning highlight (e.g. object found to cause a short) -
layer color 0 default layer colors; when a new layer is created, a color from this list is assigned initially -
mask color 0 default mask layer color (when a new mask layer is created) -
paste color 0 default paste layer color (when a new paste layer is created) -
element color 0 default silk layer color (when a new silk layer is created) -
background color 0 [hidlib] background and cursor color ... -
off_limit color 0 [hidlib] on-screen background beyond the configured drawing area -
grid color 0 [hidlib] on-screen grid -
cross color 0 [hidlib] on-screen crosshair color (inverted) +
crosshair rnd_cfn_color 0 obsolete - DO NOT USE - kept for compatibility (use appearance/color/cross instead) +
attached rnd_cfn_color 0 color of the non-layer corsshair-attached objects drawn in XOR (e.g. when padstack or buffer outline before placed; layer-objects like lines and arcs typically onherit the layer color) +
drc rnd_cfn_color 0 color of the on-screen drc clearance indication while routing +
mark rnd_cfn_color 0 color of the on-screen marks (user placed mark and automatic 'grabbed' mark) +
selected rnd_cfn_color 0 generic object selection color +
via rnd_cfn_color 0 non-terminal padstack shape on current layer +
via_far rnd_cfn_color 0 non-terminal padstack shape on non-current ('far side') layer +
pin rnd_cfn_color 0 terminal padstack shape on current layer +
pin_far rnd_cfn_color 0 terminal padstack shape on non-current ('far side') layer +
pin_name rnd_cfn_color 0 on-screen terminal number/name labels +
subc rnd_cfn_color 0 on-screen subcircuit marks +
subc_nonetlist rnd_cfn_color 0 on-screen subcircuit marks for subcircuits with the nonetlist flag +
extobj rnd_cfn_color 0 on-screen marks of extended objects +
padstackmark rnd_cfn_color 0 on-screen center mark cross for padstacks +
rat rnd_cfn_color 0 on-screen rat lines +
invisible_objects rnd_cfn_color 0 other-side objects and padstack shapes on non-current layer +
connected rnd_cfn_color 0 'connected' highlight (galvanic connections found) +
warn rnd_cfn_color 0 warning highlight (e.g. object found to cause a short) +
layer rnd_cfn_color 0 default layer colors; when a new layer is created, a color from this list is assigned initially +
mask rnd_cfn_color 0 default mask layer color (when a new mask layer is created) +
paste rnd_cfn_color 0 default paste layer color (when a new paste layer is created) +
element rnd_cfn_color 0 default silk layer color (when a new silk layer is created) +
background rnd_cfn_color 0 [hidlib] background and cursor color ... +
off_limit rnd_cfn_color 0 [hidlib] on-screen background beyond the configured drawing area +
grid rnd_cfn_color 0 [hidlib] on-screen grid +
cross rnd_cfn_color 0 [hidlib] on-screen crosshair color (inverted)
Index: trunk/doc/conf/tree/appearance_loglevels.html =================================================================== --- trunk/doc/conf/tree/appearance_loglevels.html (revision 30945) +++ trunk/doc/conf/tree/appearance_loglevels.html (revision 30946) @@ -3,12 +3,12 @@

subtree: appearance/loglevels

node name type flags description -
debug_tag string 0 [hidlib] log style tag of debug messages -
debug_popup boolean 0 [hidlib] whether a debug line should pop up the log window -
info_tag string 0 [hidlib] log style tag of info messages -
info_popup boolean 0 [hidlib] whether an info line should pop up the log window -
warning_tag string 0 [hidlib] log style tag of warnings -
warning_popup boolean 0 [hidlib] whether a warning should pop up the log window -
error_tag string 0 [hidlib] log style tag of errors -
error_popup boolean 0 [hidlib] whether an error should pop up the log window +
debug_tag rnd_cfn_string 0 [hidlib] log style tag of debug messages +
debug_popup rnd_cfn_boolean 0 [hidlib] whether a debug line should pop up the log window +
info_tag rnd_cfn_string 0 [hidlib] log style tag of info messages +
info_popup rnd_cfn_boolean 0 [hidlib] whether an info line should pop up the log window +
warning_tag rnd_cfn_string 0 [hidlib] log style tag of warnings +
warning_popup rnd_cfn_boolean 0 [hidlib] whether a warning should pop up the log window +
error_tag rnd_cfn_string 0 [hidlib] log style tag of errors +
error_popup rnd_cfn_boolean 0 [hidlib] whether an error should pop up the log window
Index: trunk/doc/conf/tree/appearance_messages.html =================================================================== --- trunk/doc/conf/tree/appearance_messages.html (revision 30945) +++ trunk/doc/conf/tree/appearance_messages.html (revision 30946) @@ -3,5 +3,5 @@

subtree: appearance/messages

node name type flags description -
char_per_line integer 0 width of an output line in characters (used by separator drawing in find.c) +
char_per_line rnd_cfn_integer 0 width of an output line in characters (used by separator drawing in find.c)
Index: trunk/doc/conf/tree/appearance_misc.html =================================================================== --- trunk/doc/conf/tree/appearance_misc.html (revision 30945) +++ trunk/doc/conf/tree/appearance_misc.html (revision 30946) @@ -3,5 +3,5 @@

subtree: appearance/misc

node name type flags description -
volume integer 0 the speakers volume -100..100 +
volume rnd_cfn_integer 0 the speakers volume -100..100
Index: trunk/doc/conf/tree/appearance_padstack.html =================================================================== --- trunk/doc/conf/tree/appearance_padstack.html (revision 30945) +++ trunk/doc/conf/tree/appearance_padstack.html (revision 30946) @@ -3,6 +3,6 @@

subtree: appearance/padstack

node name type flags description -
cross_thick integer 0 cross thickness in pixels - 0 means disable crosses -
cross_size coord 0 cross size in word coords - size of one arm of the cross (minus the hole radius) +
cross_thick rnd_cfn_integer 0 cross thickness in pixels - 0 means disable crosses +
cross_size rnd_cfn_coord 0 cross size in word coords - size of one arm of the cross (minus the hole radius)
Index: trunk/doc/conf/tree/appearance_subc.html =================================================================== --- trunk/doc/conf/tree/appearance_subc.html (revision 30945) +++ trunk/doc/conf/tree/appearance_subc.html (revision 30946) @@ -3,5 +3,5 @@

subtree: appearance/subc

node name type flags description -
dash_freq integer 0 how dense the dashed outline should be; -1 means do not display the dashed outline; 0 means solid outline; 1..32 means dashed outline +
dash_freq rnd_cfn_integer 0 how dense the dashed outline should be; -1 means do not display the dashed outline; 0 means solid outline; 1..32 means dashed outline
Index: trunk/doc/conf/tree/design.html =================================================================== --- trunk/doc/conf/tree/design.html (revision 30945) +++ trunk/doc/conf/tree/design.html (revision 30946) @@ -3,21 +3,21 @@

subtree: design

node name type flags description -
via_thickness coord 0 -
via_drilling_hole coord 0 -
line_thickness coord 0 -
clearance coord 0 -
bloat coord 0 minimum space between copper features on different networks -
shrink coord 0 minimum overlap between connected copper features -
min_wid coord 0 minimum copper width -
min_slk coord 0 minimum silk width -
min_drill coord 0 minimum drill diameter -
min_ring coord 0 minimum annular ring -
text_scale integer 0 text scaling in % -
text_thickness coord 0 override stroke font text thickness -
text_font_id integer 0 -
poly_isle_area real 0 polygon min area -
fab_author string 0 Full name of author for FAB drawings -
initial_layer_stack string 0 deprecated. -
paste_adjust coord 0 Adjust paste thickness +
via_thickness rnd_cfn_coord 0 +
via_drilling_hole rnd_cfn_coord 0 +
line_thickness rnd_cfn_coord 0 +
clearance rnd_cfn_coord 0 +
bloat rnd_cfn_coord 0 minimum space between copper features on different networks +
shrink rnd_cfn_coord 0 minimum overlap between connected copper features +
min_wid rnd_cfn_coord 0 minimum copper width +
min_slk rnd_cfn_coord 0 minimum silk width +
min_drill rnd_cfn_coord 0 minimum drill diameter +
min_ring rnd_cfn_coord 0 minimum annular ring +
text_scale rnd_cfn_integer 0 text scaling in % +
text_thickness rnd_cfn_coord 0 override stroke font text thickness +
text_font_id rnd_cfn_integer 0 +
poly_isle_area rnd_cfn_real 0 polygon min area +
fab_author rnd_cfn_string 0 Full name of author for FAB drawings +
initial_layer_stack rnd_cfn_string 0 deprecated. +
paste_adjust rnd_cfn_coord 0 Adjust paste thickness
Index: trunk/doc/conf/tree/editor.html =================================================================== --- trunk/doc/conf/tree/editor.html (revision 30945) +++ trunk/doc/conf/tree/editor.html (revision 30946) @@ -3,61 +3,61 @@

subtree: editor

node name type flags description -
zoom real 0 default zoom -
buffer_number integer 0 number of the current buffer -
clear_line boolean 0 new lines/arc clear polygons. -
clear_polypoly boolean 0 new polygons clear polygons. -
full_poly boolean 0 new polygons are full polygons. -
unique_names boolean 0 OBSOLETE: force unique names -
snap_pin boolean 0 snap to pins and pads -
snap_offgrid_line boolean 0 Snap to certain off-grid points along a line. -
marker_snaps boolean 0 marker snaps to grid or snap points, as any other click -
highlight_on_point boolean 0 Highlight if crosshair is on endpoints. -
show_solder_side boolean 0 mirror output -
save_last_command boolean 0 OBSOLETE: use the session-persistent command line history instead (press the up arrow) -
line_refraction integer 0 value for line lookahead setting -
save_in_tmp boolean 0 emergency save unsaved PCB data (despite the user clicks don't save) when: user starts a new PCB; user quits pcb-rnd. Does not affect the on-crash emergency save. -
all_direction_lines boolean 0 enable lines to all directions -
rubber_band_mode boolean 0 move, rotate use rubberband connections -
rubber_band_keep_midlinedir boolean 0 keep line direction when a middle line is moved -
swap_start_direction boolean 0 change starting direction after each click -
show_drc boolean 0 show drc region on crosshair -
auto_drc boolean 0 when set, PCB doesn't let you place copper that violates DRC. -
conn_find_rat boolean 0 connection find includes rats; when off, only existing galvanic connections are mapped -
show_number boolean 0 OBSOLETE: pinout shows number -
orthogonal_moves boolean 0 move items orthogonally. -
reset_after_element boolean 0 OBSOLETE: reset connections after each element while saving all connections -
lock_names boolean 0 lock down text so they can not be moved or selected -
only_names boolean 0 lock down everything else but text so only text objects can be moved or selected -
thin_draw boolean 0 if set, objects on the screen are drawn as outlines (lines are drawn as center-lines). This lets you see line endpoints hidden under pins, for example. -
thin_draw_poly boolean 0 if set, polygons on the screen are drawn as outlines. -
as_drawn_poly boolean 0 if set, also draw the as-drawn outline of polygons -
wireframe_draw boolean 0 if set, lines and arcs on the screen are drawn as outlines. -
local_ref boolean 0 use local reference for moves, by setting the mark at the beginning of each move. -
check_planes boolean 0 when set, only polygons and their clearances are drawn, to see if polygons have isolated regions. -
hide_names boolean 0 when set, subc floater text objects (typical use case: refdes text) are not drawn. -
description boolean 0 obsolete - DO NOT USE - kept for compatibility -
name_on_pcb boolean 0 obsolete - DO NOT USE - kept for compatibility -
subc_id string 0 subcircuit ID template for diplaying the subcircuit label on the subcircuit layer; default to displaying the refes, if empty; syntax if the same as for DYNTEXT -
term_id string 0 terminal ID template for diplaying the subcircuit label on the subcircuit layer; default to displaying termid[intconn], if empty; syntax if the same as for DYNTEXT -
move_linepoint_uses_route boolean 0 Moving a line point calculates a new line route. This allows 45/90 line modes when editing lines. -
auto_via boolean 0 when drawing traces and switching layers or when moving an object from one layer to another, try to keep connections by automatically inserting vias. -
route_radius real 0 temporary: route draw helper's arc radius at corners (factor of the trace thickness) -
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 -
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 -
subc_conv_refdes string 0 automatic refdes value assigned to new subcircuits on conversion from objects - if empty, no refdes text or attribute is added; if the value is , the refdes text object is added but no refdes attribute is created -
mode integer 0 [hidlib] currently active tool -
grid_unit unit 0 [hidlib] select whether you draw in mm or mil -
grid coord 0 [hidlib] grid in pcb-units -
grids list 0 [hidlib] grid in grid-string format -
grids_idx integer 0 [hidlib] the index of the currently active grid from grids -
draw_grid boolean 0 [hidlib] draw grid points -
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 +
zoom rnd_cfn_real 0 default zoom +
buffer_number rnd_cfn_integer 0 number of the current buffer +
clear_line rnd_cfn_boolean 0 new lines/arc clear polygons. +
clear_polypoly rnd_cfn_boolean 0 new polygons clear polygons. +
full_poly rnd_cfn_boolean 0 new polygons are full polygons. +
unique_names rnd_cfn_boolean 0 OBSOLETE: force unique names +
snap_pin rnd_cfn_boolean 0 snap to pins and pads +
snap_offgrid_line rnd_cfn_boolean 0 Snap to certain off-grid points along a line. +
marker_snaps rnd_cfn_boolean 0 marker snaps to grid or snap points, as any other click +
highlight_on_point rnd_cfn_boolean 0 Highlight if crosshair is on endpoints. +
show_solder_side rnd_cfn_boolean 0 mirror output +
save_last_command rnd_cfn_boolean 0 OBSOLETE: use the session-persistent command line history instead (press the up arrow) +
line_refraction rnd_cfn_integer 0 value for line lookahead setting +
save_in_tmp rnd_cfn_boolean 0 emergency save unsaved PCB data (despite the user clicks don't save) when: user starts a new PCB; user quits pcb-rnd. Does not affect the on-crash emergency save. +
all_direction_lines rnd_cfn_boolean 0 enable lines to all directions +
rubber_band_mode rnd_cfn_boolean 0 move, rotate use rubberband connections +
rubber_band_keep_midlinedir rnd_cfn_boolean 0 keep line direction when a middle line is moved +
swap_start_direction rnd_cfn_boolean 0 change starting direction after each click +
show_drc rnd_cfn_boolean 0 show drc region on crosshair +
auto_drc rnd_cfn_boolean 0 when set, PCB doesn't let you place copper that violates DRC. +
conn_find_rat rnd_cfn_boolean 0 connection find includes rats; when off, only existing galvanic connections are mapped +
show_number rnd_cfn_boolean 0 OBSOLETE: pinout shows number +
orthogonal_moves rnd_cfn_boolean 0 move items orthogonally. +
reset_after_element rnd_cfn_boolean 0 OBSOLETE: reset connections after each element while saving all connections +
lock_names rnd_cfn_boolean 0 lock down text so they can not be moved or selected +
only_names rnd_cfn_boolean 0 lock down everything else but text so only text objects can be moved or selected +
thin_draw rnd_cfn_boolean 0 if set, objects on the screen are drawn as outlines (lines are drawn as center-lines). This lets you see line endpoints hidden under pins, for example. +
thin_draw_poly rnd_cfn_boolean 0 if set, polygons on the screen are drawn as outlines. +
as_drawn_poly rnd_cfn_boolean 0 if set, also draw the as-drawn outline of polygons +
wireframe_draw rnd_cfn_boolean 0 if set, lines and arcs on the screen are drawn as outlines. +
local_ref rnd_cfn_boolean 0 use local reference for moves, by setting the mark at the beginning of each move. +
check_planes rnd_cfn_boolean 0 when set, only polygons and their clearances are drawn, to see if polygons have isolated regions. +
hide_names rnd_cfn_boolean 0 when set, subc floater text objects (typical use case: refdes text) are not drawn. +
description rnd_cfn_boolean 0 obsolete - DO NOT USE - kept for compatibility +
name_on_pcb rnd_cfn_boolean 0 obsolete - DO NOT USE - kept for compatibility +
subc_id rnd_cfn_string 0 subcircuit ID template for diplaying the subcircuit label on the subcircuit layer; default to displaying the refes, if empty; syntax if the same as for DYNTEXT +
term_id rnd_cfn_string 0 terminal ID template for diplaying the subcircuit label on the subcircuit layer; default to displaying termid[intconn], if empty; syntax if the same as for DYNTEXT +
move_linepoint_uses_route rnd_cfn_boolean 0 Moving a line point calculates a new line route. This allows 45/90 line modes when editing lines. +
auto_via rnd_cfn_boolean 0 when drawing traces and switching layers or when moving an object from one layer to another, try to keep connections by automatically inserting vias. +
route_radius rnd_cfn_real 0 temporary: route draw helper's arc radius at corners (factor of the trace thickness) +
io_incomp_popup rnd_cfn_boolean 0 wether to enable popping up the io incompatibility list dialog on save incompatibility errors +
io_incomp_style rnd_cfn_string 0 view listing style (list or simple), when io_incomp_popup is true +
click_time rnd_cfn_integer 0 default time for click expiration, in ms +
live_routing rnd_cfn_boolean 0 autorouter shows tracks in progress +
beep_when_finished rnd_cfn_boolean 0 flag if a signal should be produced when searching of connections is done +
undo_warning_size rnd_cfn_integer 0 warn the user when undo list exceeds this amount of kilobytes in memory +
subc_conv_refdes rnd_cfn_string 0 automatic refdes value assigned to new subcircuits on conversion from objects - if empty, no refdes text or attribute is added; if the value is , the refdes text object is added but no refdes attribute is created +
mode rnd_cfn_integer 0 [hidlib] currently active tool +
grid_unit rnd_cfn_unit 0 [hidlib] select whether you draw in mm or mil +
grid rnd_cfn_coord 0 [hidlib] grid in pcb-units +
grids rnd_cfn_list 0 [hidlib] grid in grid-string format +
grids_idx rnd_cfn_integer 0 [hidlib] the index of the currently active grid from grids +
draw_grid rnd_cfn_boolean 0 [hidlib] draw grid points +
auto_place rnd_cfn_boolean 0 [hidlib] force placement of GUI windows (dialogs), trying to override the window manager +
fullscreen rnd_cfn_boolean 0 [hidlib] hide widgets to make more room for the drawing +
crosshair_shape_idx rnd_cfn_integer 0 [hidlib] crosshair shape as defined in pcb_crosshair_shape_e +
enable_stroke rnd_cfn_boolean 0 [hidlib] Enable libstroke gestures on middle mouse button when non-zero
Index: trunk/doc/conf/tree/editor_selection.html =================================================================== --- trunk/doc/conf/tree/editor_selection.html (revision 30945) +++ trunk/doc/conf/tree/editor_selection.html (revision 30946) @@ -3,6 +3,6 @@

subtree: editor/selection

node name type flags description -
disable_negative boolean 0 selection box behaviour: disable the negative-direction selection - any selection box will select only what's fully within the box -
symmetric_negative boolean 0 selection box behaviour: when set, the selection direction is considered negative only if the box has negative size in the X direction +
disable_negative rnd_cfn_boolean 0 selection box behaviour: disable the negative-direction selection - any selection box will select only what's fully within the box +
symmetric_negative rnd_cfn_boolean 0 selection box behaviour: when set, the selection direction is considered negative only if the box has negative size in the X direction
Index: trunk/doc/conf/tree/editor_view.html =================================================================== --- trunk/doc/conf/tree/editor_view.html (revision 30945) +++ trunk/doc/conf/tree/editor_view.html (revision 30946) @@ -3,6 +3,6 @@

subtree: editor/view

node name type flags description -
flip_x boolean 0 [hidlib] view: flip the board along the X (horizontal) axis -
flip_y boolean 0 [hidlib] view: flip the board along the Y (vertical) axis +
flip_x rnd_cfn_boolean 0 [hidlib] view: flip the board along the X (horizontal) axis +
flip_y rnd_cfn_boolean 0 [hidlib] view: flip the board along the Y (vertical) axis
Index: trunk/doc/conf/tree/import_footprint_placement.html =================================================================== --- trunk/doc/conf/tree/import_footprint_placement.html (revision 30945) +++ trunk/doc/conf/tree/import_footprint_placement.html (revision 30946) @@ -3,9 +3,9 @@

subtree: import/footprint_placement

node name type flags description -
method string 0 method/strategy of placement; one of: disperse, frame, fit -
location string 0 placement coordinate for methods that require it; if empty, use fixed coordinates at x,y; if non-empty, it may be: mark, center -
x coord 0 for some methods if location is empty, X coordinate of placement -
y coord 0 for some methods if location is empty, Y coordinate of placement -
disperse coord 0 dispersion distance for the disperse method +
method rnd_cfn_string 0 method/strategy of placement; one of: disperse, frame, fit +
location rnd_cfn_string 0 placement coordinate for methods that require it; if empty, use fixed coordinates at x,y; if non-empty, it may be: mark, center +
x rnd_cfn_coord 0 for some methods if location is empty, X coordinate of placement +
y rnd_cfn_coord 0 for some methods if location is empty, Y coordinate of placement +
disperse rnd_cfn_coord 0 dispersion distance for the disperse method
Index: trunk/doc/conf/tree/rc.html =================================================================== --- trunk/doc/conf/tree/rc.html (revision 30945) +++ trunk/doc/conf/tree/rc.html (revision 30946) @@ -3,37 +3,37 @@

subtree: rc

node name type flags description -
file_changed_interval real 0 how often to check if the file has changed on the disk (in seconds); 0 or negative means no check at all -
backup_interval integer 0 time between two backups in seconds; 0 means disabled (no backups) -
brave string 0 brave mode flags: when non-empty, enable various experimental (unstable) features - useful for testers -
font_command string 0 file name template; if not empty, run this command and read its output for loading the font; %f is the file name -
file_command string 0 file name template; if not empty, run this command and read its output for loading a pcb file; %f is the file name, %p is the conf setting rc.file_path -
file_path string 0 -
library_shell string 0 -
library_search_paths list 0 -
emergency_name string 0 file name template for emergency save anonymous .pcb files (when pcb-rnd crashes); optional field: %ld --> pid; must be shorter than 240 characters. Don't do emergency save if this item is empty. -
emergency_format string 0 if set, use this format for the backups; if unset, use the default format -
backup_name string 0 file name template for periodic backup of board files; optional fields (the usual % substitutions work) -
backup_format string 0 if set, use this format for the backups; if unset or set to 'original', use the original format -
save_command string 0 command to pipe the pcb, footprint or buffer file into, when saving (makes lihata persist impossible) -
keep_save_backups boolean 0 a copy is made before a save operation overwrites an existing file; if this setting is true, keep the copy even after a successful save -
default_font_file list 0 name of default font file (list of names to search) -
default_pcb_file list 0 -
silently_create_on_load boolean 0 do not generate an error message if the board does not exist on load from command line argument, silently create it in memory -
script_filename string 0 PCB Actions script to execute on startup -
action_string string 0 PCB Actions string to execute on startup -
rat_path string 0 -
rat_command string 0 file name template; if not empty, run this command and read its output for loading a rats; %f is the file name, %p is the rc.rat_path conf setting -
save_final_fallback_fmt string 0 when a new file is created (by running pcb-rnd with the file name) there won't be a known format; pcb-rnd will guess from the file name (extension) but eventhat may fail. This format is the final fallback that'll be used if no other guessing mechanism worked. The user can override this by save as. -
save_fp_fmt string 0 when saving a buffer element/subcircuit, prefer this format by default -
have_regex boolean 0 whether we have regex compiled in -
verbose integer 0 [hidlib] -
quiet integer 0 [hidlib] print only errors on stderr -
dup_log_to_stderr boolean 0 [hidlib] copy log messages to stderr even if there is a HID that can show them -
cli_prompt string 0 [hidlib] plain text prompt to prefix the command entry -
cli_backend string 0 [hidlib] command parser action -
export_basename boolean 0 [hidlib] if an exported file contains the source file name, remove path from it, keeping the basename only -
menu_file string 0 [hidlib] where to load the default menu file from. If empty/unset, fall back to the legacy 'per hid ow menu file' setup. If contains slash, take it as a full path, if no slash, do a normal menu search for pcb-menu-NAME.lht -
preferred_gui list 0 [hidlib] if set, try GUI HIDs in this order when no GUI is explicitly selected -
hid_fallback boolean 0 [hidlib] if there is no explicitly specified HID (--gui) and the preferred GUI fails, automatically fall back on other HIDs, eventually running in batch mode +
file_changed_interval rnd_cfn_real 0 how often to check if the file has changed on the disk (in seconds); 0 or negative means no check at all +
backup_interval rnd_cfn_integer 0 time between two backups in seconds; 0 means disabled (no backups) +
brave rnd_cfn_string 0 brave mode flags: when non-empty, enable various experimental (unstable) features - useful for testers +
font_command rnd_cfn_string 0 file name template; if not empty, run this command and read its output for loading the font; %f is the file name +
file_command rnd_cfn_string 0 file name template; if not empty, run this command and read its output for loading a pcb file; %f is the file name, %p is the conf setting rc.file_path +
file_path rnd_cfn_string 0 +
library_shell rnd_cfn_string 0 +
library_search_paths rnd_cfn_list 0 +
emergency_name rnd_cfn_string 0 file name template for emergency save anonymous .pcb files (when pcb-rnd crashes); optional field: %ld --> pid; must be shorter than 240 characters. Don't do emergency save if this item is empty. +
emergency_format rnd_cfn_string 0 if set, use this format for the backups; if unset, use the default format +
backup_name rnd_cfn_string 0 file name template for periodic backup of board files; optional fields (the usual % substitutions work) +
backup_format rnd_cfn_string 0 if set, use this format for the backups; if unset or set to 'original', use the original format +
save_command rnd_cfn_string 0 command to pipe the pcb, footprint or buffer file into, when saving (makes lihata persist impossible) +
keep_save_backups rnd_cfn_boolean 0 a copy is made before a save operation overwrites an existing file; if this setting is true, keep the copy even after a successful save +
default_font_file rnd_cfn_list 0 name of default font file (list of names to search) +
default_pcb_file rnd_cfn_list 0 +
silently_create_on_load rnd_cfn_boolean 0 do not generate an error message if the board does not exist on load from command line argument, silently create it in memory +
script_filename rnd_cfn_string 0 PCB Actions script to execute on startup +
action_string rnd_cfn_string 0 PCB Actions string to execute on startup +
rat_path rnd_cfn_string 0 +
rat_command rnd_cfn_string 0 file name template; if not empty, run this command and read its output for loading a rats; %f is the file name, %p is the rc.rat_path conf setting +
save_final_fallback_fmt rnd_cfn_string 0 when a new file is created (by running pcb-rnd with the file name) there won't be a known format; pcb-rnd will guess from the file name (extension) but eventhat may fail. This format is the final fallback that'll be used if no other guessing mechanism worked. The user can override this by save as. +
save_fp_fmt rnd_cfn_string 0 when saving a buffer element/subcircuit, prefer this format by default +
have_regex rnd_cfn_boolean 0 whether we have regex compiled in +
verbose rnd_cfn_integer 0 [hidlib] +
quiet rnd_cfn_integer 0 [hidlib] print only errors on stderr +
dup_log_to_stderr rnd_cfn_boolean 0 [hidlib] copy log messages to stderr even if there is a HID that can show them +
cli_prompt rnd_cfn_string 0 [hidlib] plain text prompt to prefix the command entry +
cli_backend rnd_cfn_string 0 [hidlib] command parser action +
export_basename rnd_cfn_boolean 0 [hidlib] if an exported file contains the source file name, remove path from it, keeping the basename only +
menu_file rnd_cfn_string 0 [hidlib] where to load the default menu file from. If empty/unset, fall back to the legacy 'per hid ow menu file' setup. If contains slash, take it as a full path, if no slash, do a normal menu search for pcb-menu-NAME.lht +
preferred_gui rnd_cfn_list 0 [hidlib] if set, try GUI HIDs in this order when no GUI is explicitly selected +
hid_fallback rnd_cfn_boolean 0 [hidlib] if there is no explicitly specified HID (--gui) and the preferred GUI fails, automatically fall back on other HIDs, eventually running in batch mode
Index: trunk/doc/conf/tree/rc_path.html =================================================================== --- trunk/doc/conf/tree/rc_path.html (revision 30945) +++ trunk/doc/conf/tree/rc_path.html (revision 30946) @@ -3,11 +3,11 @@

subtree: rc/path

node name type flags description -
prefix string 0 e.g. /usr/local -
lib string 0 e.g. /usr/lib/pcb-rnd -
bin string 0 e.g. /usr/bin -
share string 0 e.g. /usr/share/pcb-rnd -
design string 0 directory path of the current design, or if the current design doesn't have a file name yet -
home string 0 [hidlib] user's home dir, determined run-time -
exec_prefix string 0 [hidlib] exec prefix path (extracted from argv[0]) +
prefix rnd_cfn_string 0 e.g. /usr/local +
lib rnd_cfn_string 0 e.g. /usr/lib/pcb-rnd +
bin rnd_cfn_string 0 e.g. /usr/bin +
share rnd_cfn_string 0 e.g. /usr/share/pcb-rnd +
design rnd_cfn_string 0 directory path of the current design, or if the current design doesn't have a file name yet +
home rnd_cfn_string 0 [hidlib] user's home dir, determined run-time +
exec_prefix rnd_cfn_string 0 [hidlib] exec prefix path (extracted from argv[0])
Index: trunk/doc/conf/tree/temp.html =================================================================== --- trunk/doc/conf/tree/temp.html (revision 30945) +++ trunk/doc/conf/tree/temp.html (revision 30946) @@ -3,7 +3,7 @@

subtree: temp

node name type flags description -
rat_warn boolean 0 rats nest has set warnings -
clip_inhibit_chg boolean 0 dummy node to inform the menu about clip inhibit change -
click_cmd_entry_active boolean 0 [hidlib] true if the command line is active when the user click - this gives the command interpreter a chance to capture the click and use the coords +
rat_warn rnd_cfn_boolean 0 rats nest has set warnings +
clip_inhibit_chg rnd_cfn_boolean 0 dummy node to inform the menu about clip inhibit change +
click_cmd_entry_active rnd_cfn_boolean 0 [hidlib] true if the command line is active when the user click - this gives the command interpreter a chance to capture the click and use the coords
Index: trunk/src/board.c =================================================================== --- trunk/src/board.c (revision 30945) +++ trunk/src/board.c (revision 30946) @@ -86,7 +86,7 @@ for(i = 0; i < PCB_NUM_NETLISTS; i++) pcb_netlist_init(&(ptr->netlist[i])); - pcb_conf_set(CFR_INTERNAL, "design/poly_isle_area", -1, "200000000", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_INTERNAL, "design/poly_isle_area", -1, "200000000", RND_POL_OVERWRITE); ptr->RatDraw = pcb_false; Index: trunk/src/brave.c =================================================================== --- trunk/src/brave.c (revision 30945) +++ trunk/src/brave.c (revision 30946) @@ -85,7 +85,7 @@ /* truncate last comma */ gds_truncate(&tmp, gds_len(&tmp)-1); - pcb_conf_set(CFR_CLI, "rc/brave", 0, tmp.array, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/brave", 0, tmp.array, RND_POL_OVERWRITE); gds_uninit(&tmp); } @@ -185,9 +185,9 @@ /* Copy the config from CLI to USER and flush the file */ static void brave_dialog_save(void *hid_ctx, void *caller_data, pcb_hid_attribute_t *attr) { - pcb_conf_set(CFR_USER, "rc/brave", 0, conf_core.rc.brave, RND_POL_OVERWRITE); - if (pcb_conf_isdirty(CFR_USER)) - pcb_conf_save_file(&PCB->hidlib, NULL, NULL, CFR_USER, NULL); + pcb_conf_set(RND_CFR_USER, "rc/brave", 0, conf_core.rc.brave, RND_POL_OVERWRITE); + if (pcb_conf_isdirty(RND_CFR_USER)) + pcb_conf_save_file(&PCB->hidlib, NULL, NULL, RND_CFR_USER, NULL); } static int brave_interact(void) Index: trunk/src/buffer.c =================================================================== --- trunk/src/buffer.c (revision 30945) +++ trunk/src/buffer.c (revision 30946) @@ -290,7 +290,7 @@ pcb_layergrp_inhibit_inc(); /* new data isn't added to the undo list */ - if (!pcb_parse_pcb(newPCB, Filename, fmt, CFR_invalid, 0)) { + if (!pcb_parse_pcb(newPCB, Filename, fmt, RND_CFR_invalid, 0)) { pcb_data_t *tmpdata; /* clear data area and replace pointer */ Index: trunk/src/conf_core.c =================================================================== --- trunk/src/conf_core.c (revision 30945) +++ trunk/src/conf_core.c (revision 30946) @@ -37,7 +37,7 @@ gds_init(&tmp); pcb_conf_print_native_field((conf_pfn)pcb_append_printf, &tmp, 0, &nlegacy->val, nlegacy->type, nlegacy->prop, 0); if (tmp.used > 0) - pcb_conf_set(CFR_INTERNAL, dst_path, -1, tmp.array, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_INTERNAL, dst_path, -1, tmp.array, RND_POL_OVERWRITE); gds_uninit(&tmp); } Index: trunk/src/file_act.c =================================================================== --- trunk/src/file_act.c (revision 30945) +++ trunk/src/file_act.c (revision 30946) @@ -166,7 +166,7 @@ pcb_draw_inhibit_dec(); pcb_set_design_dir(NULL); - pcb_conf_set(CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); /* we have only one font now, make sure it is selected */ + pcb_conf_set(RND_CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); /* we have only one font now, make sure it is selected */ /* setup the new name and reset some values to default */ free(PCB->hidlib.name); Index: trunk/src/gui_act.c =================================================================== --- trunk/src/gui_act.c (revision 30945) +++ trunk/src/gui_act.c (revision 30946) @@ -112,9 +112,9 @@ if (id == F_SubcID) { /* change the displayed name of subcircuits */ if (argc > 1) - pcb_conf_set(CFR_DESIGN, "editor/subc_id", -1, str_dir, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/subc_id", -1, str_dir, RND_POL_OVERWRITE); else - pcb_conf_set(CFR_DESIGN, "editor/subc_id", -1, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/subc_id", -1, "", RND_POL_OVERWRITE); pcb_gui->invalidate_all(pcb_gui); /* doesn't change too often, isn't worth anything more complicated */ pcb_draw(); @@ -123,9 +123,9 @@ if (id == F_TermID) { /* change the displayed name of terminals */ if (argc > 1) - pcb_conf_set(CFR_DESIGN, "editor/term_id", -1, str_dir, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/term_id", -1, str_dir, RND_POL_OVERWRITE); else - pcb_conf_set(CFR_DESIGN, "editor/term_id", -1, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/term_id", -1, "", RND_POL_OVERWRITE); pcb_gui->invalidate_all(pcb_gui); /* doesn't change too often, isn't worth anything more complicated */ pcb_draw(); @@ -151,10 +151,10 @@ pcb_hid_notify_crosshair_change(RND_ACT_HIDLIB, pcb_false); if (conf_core.editor.all_direction_lines) { conf_toggle_editor(all_direction_lines); - pcb_conf_setf(CFR_DESIGN,"editor/line_refraction",-1,"%d",0); + pcb_conf_setf(RND_CFR_DESIGN,"editor/line_refraction",-1,"%d",0); } else { - pcb_conf_setf(CFR_DESIGN,"editor/line_refraction",-1,"%d",(conf_core.editor.line_refraction +1) % 3); + pcb_conf_setf(RND_CFR_DESIGN,"editor/line_refraction",-1,"%d",(conf_core.editor.line_refraction +1) % 3); } pcb_tool_adjust_attached(RND_ACT_HIDLIB); pcb_hid_notify_crosshair_change(RND_ACT_HIDLIB, pcb_true); @@ -162,9 +162,9 @@ case F_CycleCrosshair: pcb_hid_notify_crosshair_change(RND_ACT_HIDLIB, pcb_false); - pcb_conf_setf(CFR_CLI, "editor/crosshair_shape_idx", 0, "%d", CrosshairShapeIncrement(pcbhl_conf.editor.crosshair_shape_idx)); + pcb_conf_setf(RND_CFR_CLI, "editor/crosshair_shape_idx", 0, "%d", CrosshairShapeIncrement(pcbhl_conf.editor.crosshair_shape_idx)); if (pcb_ch_shape_NUM == pcbhl_conf.editor.crosshair_shape_idx) - pcb_conf_set(CFR_CLI, "editor/crosshair_shape_idx", 0, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "editor/crosshair_shape_idx", 0, "0", RND_POL_OVERWRITE); pcb_hid_notify_crosshair_change(RND_ACT_HIDLIB, pcb_true); break; @@ -1436,7 +1436,7 @@ tmp[0] = '0' + !conf_core.temp.clip_inhibit_chg; tmp[1] = '\0'; - pcb_conf_set(CFR_CLI, "temp/clip_inhibit_chg", 0, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "temp/clip_inhibit_chg", 0, tmp, RND_POL_OVERWRITE); RND_ACT_IRES(0); Index: trunk/src/librnd/core/actions.c =================================================================== --- trunk/src/librnd/core/actions.c (revision 30945) +++ trunk/src/librnd/core/actions.c (revision 30946) @@ -573,9 +573,9 @@ cli_push(pcbhl_conf.rc.cli_backend); cli_push(pcbhl_conf.rc.cli_prompt); - if (pcb_conf_set(CFR_CLI, "rc/cli_backend", 0, backend, RND_POL_OVERWRITE) != 0) + if (pcb_conf_set(RND_CFR_CLI, "rc/cli_backend", 0, backend, RND_POL_OVERWRITE) != 0) return -1; - return pcb_conf_set(CFR_CLI, "rc/cli_prompt", 0, prompt, RND_POL_OVERWRITE); + return pcb_conf_set(RND_CFR_CLI, "rc/cli_prompt", 0, prompt, RND_POL_OVERWRITE); } int rnd_cli_leave(void) @@ -584,15 +584,15 @@ char *prompt = NULL, *backend = NULL; prompt = cli_pop(); backend = cli_pop(); - pcb_conf_set(CFR_CLI, "rc/cli_backend", 0, backend, RND_POL_OVERWRITE); - pcb_conf_set(CFR_CLI, "rc/cli_prompt", 0, prompt, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/cli_backend", 0, backend, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/cli_prompt", 0, prompt, RND_POL_OVERWRITE); free(prompt); free(backend); return 0; } - pcb_conf_set(CFR_CLI, "rc/cli_backend", 0, "", RND_POL_OVERWRITE); - pcb_conf_set(CFR_CLI, "rc/cli_prompt", 0, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/cli_backend", 0, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/cli_prompt", 0, "", RND_POL_OVERWRITE); return -1; } Index: trunk/src/librnd/core/conf.c =================================================================== --- trunk/src/librnd/core/conf.c (revision 30945) +++ trunk/src/librnd/core/conf.c (revision 30946) @@ -63,10 +63,10 @@ /* The main conf: monolithic config files affecting all parts of the conf tree; By default every operation is done on these trees. */ -lht_doc_t *pcb_conf_main_root[CFR_max_alloc]; -long pcb_conf_main_root_replace_cnt[CFR_max_alloc]; /* number of times the root has been replaced */ -int pcb_conf_main_root_lock[CFR_max_alloc]; -int pcb_conf_lht_dirty[CFR_max_alloc]; +lht_doc_t *pcb_conf_main_root[RND_CFR_max_alloc]; +long rnd_conf_main_root_replace_cnt[RND_CFR_max_alloc]; /* number of times the root has been replaced */ +int pcb_conf_main_root_lock[RND_CFR_max_alloc]; +int pcb_conf_lht_dirty[RND_CFR_max_alloc]; /* Plugin config: only plugin configuration is accepted; never edited, only merged in. Merge takes two steps: first all files per role are merged into @@ -73,20 +73,20 @@ a single pcb_conf_plug_root[R] (lihata level merge), then pcb_conf_plug_root[R] is merged in using the normal conf merge mechanism. Plug roots are merged before main roots so main root overwrite are stronger. */ -lht_doc_t *pcb_conf_plug_root[CFR_max_alloc]; +lht_doc_t *pcb_conf_plug_root[RND_CFR_max_alloc]; htsp_t *pcb_conf_fields = NULL; -const int pcb_conf_default_prio[] = { -/* CFR_INTERNAL */ 100, -/* CFR_SYSTEM */ 200, -/* CFR_DEFAULTPCB */ 300, -/* CFR_USER */ 400, -/* CFR_ENV */ 500, -/* CFR_PROJECT */ 600, -/* CFR_DESIGN */ 700, -/* CFR_CLI */ 800, -0, 0, 0, 0, 0, 0, 0, 0, 0 /* make sure the array is addressable until CFR_max_alloc */ +const int rnd_conf_default_prio[] = { +/* RND_CFR_INTERNAL */ 100, +/* RND_CFR_SYSTEM */ 200, +/* RND_CFR_DEFAULTPCB */ 300, +/* RND_CFR_USER */ 400, +/* RND_CFR_ENV */ 500, +/* RND_CFR_PROJECT */ 600, +/* RND_CFR_DESIGN */ 700, +/* RND_CFR_CLI */ 800, +0, 0, 0, 0, 0, 0, 0, 0, 0 /* make sure the array is addressable until RND_CFR_max_alloc */ }; extern const char *pcb_conf_internal; @@ -125,7 +125,7 @@ d->root->doc = d; lht_tree_merge(d->root, root); pcb_conf_main_root[role] = d; - pcb_conf_main_root_replace_cnt[role]++; + rnd_conf_main_root_replace_cnt[role]++; return 0; } @@ -365,34 +365,34 @@ rnd_conf_role_t pcb_conf_role_parse(const char *s) { - if (rnd_strcasecmp(s, "internal") == 0) return CFR_INTERNAL; - if (rnd_strcasecmp(s, "system") == 0) return CFR_SYSTEM; - if (rnd_strcasecmp(s, "defaultpcb") == 0) return CFR_DEFAULTPCB; - if (rnd_strcasecmp(s, "user") == 0) return CFR_USER; - if (rnd_strcasecmp(s, "env") == 0) return CFR_ENV; - if (rnd_strcasecmp(s, "project") == 0) return CFR_PROJECT; - if (rnd_strcasecmp(s, "design") == 0) return CFR_DESIGN; - if (rnd_strcasecmp(s, "cli") == 0) return CFR_CLI; - return CFR_invalid; + if (rnd_strcasecmp(s, "internal") == 0) return RND_CFR_INTERNAL; + if (rnd_strcasecmp(s, "system") == 0) return RND_CFR_SYSTEM; + if (rnd_strcasecmp(s, "defaultpcb") == 0) return RND_CFR_DEFAULTPCB; + if (rnd_strcasecmp(s, "user") == 0) return RND_CFR_USER; + if (rnd_strcasecmp(s, "env") == 0) return RND_CFR_ENV; + if (rnd_strcasecmp(s, "project") == 0) return RND_CFR_PROJECT; + if (rnd_strcasecmp(s, "design") == 0) return RND_CFR_DESIGN; + if (rnd_strcasecmp(s, "cli") == 0) return RND_CFR_CLI; + return RND_CFR_invalid; } const char *pcb_conf_role_name(rnd_conf_role_t r) { switch(r) { - case CFR_INTERNAL: return "internal"; - case CFR_SYSTEM: return "system"; - case CFR_DEFAULTPCB: return "defaultpcb"; - case CFR_USER: return "user"; - case CFR_ENV: return "env"; - case CFR_PROJECT: return "project"; - case CFR_DESIGN: return "design"; - case CFR_CLI: return "cli"; - case CFR_file: return "(file)"; - case CFR_binary: return "(binary)"; + case RND_CFR_INTERNAL: return "internal"; + case RND_CFR_SYSTEM: return "system"; + case RND_CFR_DEFAULTPCB: return "defaultpcb"; + case RND_CFR_USER: return "user"; + case RND_CFR_ENV: return "env"; + case RND_CFR_PROJECT: return "project"; + case RND_CFR_DESIGN: return "design"; + case RND_CFR_CLI: return "cli"; + case RND_CFR_file: return "(file)"; + case RND_CFR_binary: return "(binary)"; - case CFR_max_alloc: - case CFR_max_real: - case CFR_invalid: return "(invalid role)"; + case RND_CFR_max_alloc: + case RND_CFR_max_real: + case RND_CFR_invalid: return "(invalid role)"; } return "(unknown role)"; } @@ -850,7 +850,7 @@ rnd_conf_native_t *target = pcb_conf_get_field(path); int res = 0; - if ((role == CFR_DESIGN) || (role == CFR_PROJECT)) { + if ((role == RND_CFR_DESIGN) || (role == RND_CFR_PROJECT)) { if (conf_board_ignore(path, n)) return 0; } @@ -970,7 +970,7 @@ m = vmst_alloc_append(&merge_subtree, 1); m->role = role; - m->prio = pcb_conf_default_prio[role]; + m->prio = rnd_conf_default_prio[role]; m->policy = RND_POL_invalid; pcb_conf_extract_poliprio(subtree_parent_root, &m->policy, &m->prio); @@ -1004,7 +1004,7 @@ int n, ret = 0; vmst_truncate(&merge_subtree, 0); - for(n = 0; n < CFR_max_real; n++) { + for(n = 0; n < RND_CFR_max_real; n++) { lht_node_t *cr; if (pcb_conf_main_root[n] != NULL) { cr = conf_lht_get_confroot(pcb_conf_main_root[n]->root); @@ -1158,9 +1158,9 @@ lht_node_t *pcb_conf_lht_get_first(rnd_conf_role_t target, int create) { - assert(target != CFR_invalid); + assert(target != RND_CFR_invalid); assert(target >= 0); - assert(target < CFR_max_alloc); + assert(target < RND_CFR_max_alloc); if (pcb_conf_main_root[target] == NULL) return NULL; return conf_lht_get_first_(pcb_conf_main_root[target]->root, POL_ANY, create); @@ -1168,9 +1168,9 @@ lht_node_t *pcb_conf_lht_get_first_plug(rnd_conf_role_t target, int create) { - assert(target != CFR_invalid); + assert(target != RND_CFR_invalid); assert(target >= 0); - assert(target < CFR_max_alloc); + assert(target < RND_CFR_max_alloc); if (pcb_conf_plug_root[target] == NULL) return NULL; return conf_lht_get_first_(pcb_conf_plug_root[target]->root, POL_ANY, create); @@ -1178,9 +1178,9 @@ lht_node_t *pcb_conf_lht_get_first_pol(rnd_conf_role_t target, rnd_conf_policy_t pol, int create) { - assert(target != CFR_invalid); + assert(target != RND_CFR_invalid); assert(target >= 0); - assert(target < CFR_max_alloc); + assert(target < RND_CFR_max_alloc); if (pcb_conf_main_root[target] == NULL) return NULL; return conf_lht_get_first_(pcb_conf_main_root[target]->root, pol, create); @@ -1249,21 +1249,21 @@ /* the ultimate fallback: all essential values are built in the executable on a low priority */ - pcb_conf_load_as(CFR_INTERNAL, pcb_conf_internal, 1); + pcb_conf_load_as(RND_CFR_INTERNAL, pcb_conf_internal, 1); /* load config files */ - pcb_conf_load_as(CFR_SYSTEM, pcbhl_conf_sys_path, 0); - pcb_conf_load_as(CFR_USER, pcphl_conf_user_path, 0); + pcb_conf_load_as(RND_CFR_SYSTEM, pcbhl_conf_sys_path, 0); + pcb_conf_load_as(RND_CFR_USER, pcphl_conf_user_path, 0); pc = pcb_conf_get_project_conf_name(project_fn, pcb_fn, &try); if (pc != NULL) - pcb_conf_load_as(CFR_PROJECT, pc, 0); + pcb_conf_load_as(RND_CFR_PROJECT, pc, 0); pcb_conf_merge_all(NULL); /* create the user config (in-memory-lht) if it does not exist on disk; this is needed so if the user makes config changes from the GUI things get saved. */ - if (pcb_conf_main_root[CFR_USER] == NULL) - pcb_conf_reset(CFR_USER, pcphl_conf_user_path); + if (pcb_conf_main_root[RND_CFR_USER] == NULL) + pcb_conf_reset(RND_CFR_USER, pcphl_conf_user_path); pcb_conf_in_production = 1; } @@ -1271,9 +1271,9 @@ void pcb_conf_load_extra(const char *project_fn, const char *pcb_fn) { int cnt; - cnt = conf_load_plug_files(CFR_SYSTEM, pcbhl_conf_sysdir_path); - cnt += conf_load_plug_files(CFR_USER, pcbhl_conf_userdir_path); - cnt += conf_load_plug_interns(CFR_INTERNAL); + cnt = conf_load_plug_files(RND_CFR_SYSTEM, pcbhl_conf_sysdir_path); + cnt += conf_load_plug_files(RND_CFR_USER, pcbhl_conf_userdir_path); + cnt += conf_load_plug_interns(RND_CFR_INTERNAL); if (cnt > 0) pcb_conf_merge_all(NULL); } @@ -1287,10 +1287,10 @@ pc = pcb_conf_get_project_conf_name(project_fn, pcb_fn, &try); if (pc != NULL) - if (pcb_conf_load_as(CFR_PROJECT, pc, 0) != 0) + if (pcb_conf_load_as(RND_CFR_PROJECT, pc, 0) != 0) pc = NULL; if (pc == NULL) - pcb_conf_reset(CFR_PROJECT, ""); + pcb_conf_reset(RND_CFR_PROJECT, ""); pcb_conf_update(NULL, -1); } @@ -1723,8 +1723,8 @@ } /* now that we have a clean path (arg) and a value, try to set the config */ - pcb_conf_lht_get_first_pol(CFR_CLI, pol, 1); /* make sure the root for the given policy is created */ - ret = pcb_conf_set(CFR_CLI, arg, -1, val, pol); + pcb_conf_lht_get_first_pol(RND_CFR_CLI, pol, 1); /* make sure the root for the given policy is created */ + ret = pcb_conf_set(RND_CFR_CLI, arg, -1, val, pol); if (ret != 0) *why = "invalid config path"; @@ -1800,7 +1800,7 @@ lht_node_t *dst = pcb_conf_lht_get_at(dst_role, dst_path, 1); lht_node_t *src, *new_src = NULL; - if (src_role == CFR_binary) { + if (src_role == RND_CFR_binary) { char *name; lht_node_t *ch = NULL; int isarr, i; @@ -1865,12 +1865,12 @@ pcb_conf_lht_dirty[dst_role]++; lht_tree_del(dst); - if (src_role == CFR_binary) + if (src_role == RND_CFR_binary) lht_dom_node_free(src); return 0; err:; - if (src_role == CFR_binary) + if (src_role == RND_CFR_binary) lht_dom_node_free(src); if (new_src != NULL) lht_dom_node_free(new_src); @@ -1891,10 +1891,10 @@ if (fn == NULL) { switch(role) { - case CFR_USER: + case RND_CFR_USER: fn = pcphl_conf_user_path; break; - case CFR_PROJECT: + case RND_CFR_PROJECT: fn = pcb_conf_get_project_conf_name(project_fn, pcb_fn, &try); if (fn == NULL) { rnd_message(PCB_MSG_ERROR, "Error: can not save config to project file: %s does not exist - please create an empty file there first\n", try); @@ -1909,7 +1909,7 @@ FILE *f; f = pcb_fopen_fn(hidlib, fn, "w", &efn); - if ((f == NULL) && (role == CFR_USER)) { + if ((f == NULL) && (role == RND_CFR_USER)) { /* create the directory and try again */ char *path = NULL, *end; @@ -2052,15 +2052,15 @@ rnd_conf_role_t pcb_conf_lookup_role(const lht_node_t *nd) { rnd_conf_role_t r; - for(r = 0; r < CFR_max_real; r++) + for(r = 0; r < RND_CFR_max_real; r++) if (pcb_conf_main_root[r] == nd->doc) return r; - for(r = 0; r < CFR_max_real; r++) + for(r = 0; r < RND_CFR_max_real; r++) if (pcb_conf_plug_root[r] == nd->doc) return r; - return CFR_invalid; + return RND_CFR_invalid; } void pcb_conf_reset(rnd_conf_role_t target, const char *source_fn) @@ -2186,12 +2186,12 @@ void pcb_conf_init(void) { - pcb_conf_reset(CFR_ENV, ""); - pcb_conf_reset(CFR_CLI, ""); - pcb_conf_reset(CFR_DESIGN, ""); + pcb_conf_reset(RND_CFR_ENV, ""); + pcb_conf_reset(RND_CFR_CLI, ""); + pcb_conf_reset(RND_CFR_DESIGN, ""); - pcb_conf_reset(CFR_file, ""); - pcb_conf_reset(CFR_binary, ""); + pcb_conf_reset(RND_CFR_file, ""); + pcb_conf_reset(RND_CFR_binary, ""); } void pcb_conf_uninit(void) @@ -2206,7 +2206,7 @@ pcb_conf_pcb_hid_uninit(); - for(n = 0; n < CFR_max_alloc; n++) { + for(n = 0; n < RND_CFR_max_alloc; n++) { if (pcb_conf_main_root[n] != NULL) lht_dom_uninit(pcb_conf_main_root[n]); if (pcb_conf_plug_root[n] != NULL) Index: trunk/src/librnd/core/conf.h =================================================================== --- trunk/src/librnd/core/conf.h (revision 30945) +++ trunk/src/librnd/core/conf.h (revision 30946) @@ -134,25 +134,25 @@ typedef enum { - CFR_INTERNAL, - CFR_SYSTEM, - CFR_DEFAULTPCB, /* default.pcb */ - CFR_USER, - CFR_ENV, /* env vars */ - CFR_PROJECT, /* project specific, from a local file */ - CFR_DESIGN, /* from the design file */ - CFR_CLI, /* from the command line */ - CFR_max_real, /* all the above are real files and should be merged */ + RND_CFR_INTERNAL, + RND_CFR_SYSTEM, + RND_CFR_DEFAULTPCB, /* default.pcb */ + RND_CFR_USER, + RND_CFR_ENV, /* env vars */ + RND_CFR_PROJECT, /* project specific, from a local file */ + RND_CFR_DESIGN, /* from the design file */ + RND_CFR_CLI, /* from the command line */ + RND_CFR_max_real, /* all the above are real files and should be merged */ /* these ones are not real roles and are used in internal communication in the GUI HIDs */ - CFR_file, /* custom file */ - CFR_binary, /* the in-memory binary representation */ - CFR_max_alloc, /* all the above should have a root */ + RND_CFR_file, /* custom file */ + RND_CFR_binary, /* the in-memory binary representation */ + RND_CFR_max_alloc, /* all the above should have a root */ - CFR_invalid + RND_CFR_invalid } rnd_conf_role_t; -extern const int pcb_conf_default_prio[]; -extern long pcb_conf_main_root_replace_cnt[CFR_max_alloc]; /* number of times the root has been replaced */ +extern const int rnd_conf_default_prio[]; +extern long rnd_conf_main_root_replace_cnt[RND_CFR_max_alloc]; /* number of times the root has been replaced */ void pcb_conf_init(void); void pcb_conf_uninit(void); @@ -175,8 +175,8 @@ return 0 on success and removes/invalidates root */ int pcb_conf_insert_tree_as(rnd_conf_role_t role, lht_node_t *root); -/* Load a project file into CFR_PROJECT. Both project_fn and pcb_fn can't be NULL. - Leaves an initialized but empty CFR_PROJECT root if no project file was +/* Load a project file into RND_CFR_PROJECT. Both project_fn and pcb_fn can't be NULL. + Leaves an initialized but empty RND_CFR_PROJECT root if no project file was found. Runs pcb_conf_update(NULL); */ void pcb_conf_load_project(const char *project_fn, const char *pcb_fn); @@ -243,7 +243,7 @@ /* Return the name of the policy - always a static string, even for invalid roles */ const char *pcb_conf_policy_name(rnd_conf_policy_t p); -/* convert a role text to role value - return CFR_invalid on error */ +/* convert a role text to role value - return RND_CFR_invalid on error */ rnd_conf_role_t pcb_conf_role_parse(const char *s); /* Return the name of the role - always a static string, even for invalid roles */ @@ -252,7 +252,7 @@ /* Lock/unlock the structure of a role. In a locked role value of existing fields may be modified but the structure of the tree is static (can't create or remove nodes). This is useful when an io_ file format supports - only a subset of settings: it can build the CFR_DESIGN tree, lock it so + only a subset of settings: it can build the RND_CFR_DESIGN tree, lock it so settings that it wouldn't know how to save won't appear. NOTE: io_pcb supports all settings via attributes so does not lock. */ void pcb_conf_lock(rnd_conf_role_t target); @@ -263,7 +263,7 @@ int pcb_conf_replace_subtree(rnd_conf_role_t dst_role, const char *dst_path, rnd_conf_role_t src_role, const char *src_path); /* Throw out a subtree (remove all nodes from the lihata representation). - Useful for io_ plugins, on CFR_DESIGN, before loading a new file. */ + Useful for io_ plugins, on RND_CFR_DESIGN, before loading a new file. */ void pcb_conf_reset(rnd_conf_role_t target, const char *source_fn); /* Save an in-memory lihata representation to the disk */ @@ -301,7 +301,7 @@ /****** utility ******/ #define rnd_conf_is_read_only(role) \ - (((role) == CFR_INTERNAL) || ((role) == CFR_SYSTEM) || ((role) == CFR_DEFAULTPCB)) + (((role) == RND_CFR_INTERNAL) || ((role) == RND_CFR_SYSTEM) || ((role) == RND_CFR_DEFAULTPCB)) void pcb_conf_setf(rnd_conf_role_t role, const char *path, int idx, const char *fmt, ...); @@ -333,13 +333,13 @@ /* helpers to make the code shorter */ #define conf_set_design(path, fmt, new_val) \ - pcb_conf_setf(CFR_DESIGN, path, -1, fmt, new_val) + pcb_conf_setf(RND_CFR_DESIGN, path, -1, fmt, new_val) #define conf_set_editor(field, val) \ - pcb_conf_set(CFR_DESIGN, "editor/" #field, -1, val ? "1" : "0", RND_POL_OVERWRITE) + pcb_conf_set(RND_CFR_DESIGN, "editor/" #field, -1, val ? "1" : "0", RND_POL_OVERWRITE) #define conf_set_editor_(sfield, val) \ - pcb_conf_set(CFR_DESIGN, sfield, -1, val ? "1" : "0", RND_POL_OVERWRITE) + pcb_conf_set(RND_CFR_DESIGN, sfield, -1, val ? "1" : "0", RND_POL_OVERWRITE) #define conf_toggle_editor(field) \ conf_set_editor(field, !conf_core.editor.field) Index: trunk/src/librnd/core/conf_act.c =================================================================== --- trunk/src/librnd/core/conf_act.c (revision 30945) +++ trunk/src/librnd/core/conf_act.c (revision 30946) @@ -69,7 +69,7 @@ const char *path, *val; char valbuff[128]; rnd_conf_policy_t pol = RND_POL_OVERWRITE; - rnd_conf_role_t role = CFR_invalid; + rnd_conf_role_t role = RND_CFR_invalid; int rs; if (argc < 4) { @@ -78,7 +78,7 @@ } if (argc > 4) { role = pcb_conf_role_parse(a3); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", a3); return FGW_ERR_ARG_CONV; } @@ -122,7 +122,7 @@ } } - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_conf_native_t *n = pcb_conf_get_field(a1); if (n == NULL) { rnd_message(PCB_MSG_ERROR, "Invalid conf field '%s': no such path\n", a1); @@ -173,7 +173,7 @@ else if (op == F_Toggle) { rnd_conf_native_t *n = pcb_conf_get_field(a1); const char *new_value; - rnd_conf_role_t role = CFR_invalid; + rnd_conf_role_t role = RND_CFR_invalid; int res; if (n == NULL) { @@ -190,7 +190,7 @@ } if (argc > 3) { role = pcb_conf_role_parse(a2); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", a2); return FGW_ERR_ARG_CONV; } @@ -199,7 +199,7 @@ new_value = "false"; else new_value = "true"; - if (role == CFR_invalid) + if (role == RND_CFR_invalid) res = pcb_conf_set_native(n, 0, new_value); else res = pcb_conf_set(role, a1, -1, new_value, RND_POL_OVERWRITE); @@ -214,7 +214,7 @@ else if (op == F_Reset) { rnd_conf_role_t role; role = pcb_conf_role_parse(a1); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", a1); return FGW_ERR_ARG_CONV; } Index: trunk/src/librnd/core/conf_regfile.c =================================================================== --- trunk/src/librnd/core/conf_regfile.c (revision 30945) +++ trunk/src/librnd/core/conf_regfile.c (revision 30946) @@ -62,7 +62,7 @@ e->value++; if (pcb_conf_in_production) { - if (conf_load_plug_interns(CFR_INTERNAL)) + if (conf_load_plug_interns(RND_CFR_INTERNAL)) pcb_conf_merge_all(NULL); } } Index: trunk/src/librnd/core/grid.c =================================================================== --- trunk/src/librnd/core/grid.c (revision 30945) +++ trunk/src/librnd/core/grid.c (revision 30946) @@ -191,7 +191,7 @@ if (dst < 0) return pcb_false; - pcb_conf_setf(CFR_DESIGN, "editor/grids_idx", -1, "%d", dst); + pcb_conf_setf(RND_CFR_DESIGN, "editor/grids_idx", -1, "%d", dst); li = pcb_conflist_nth((pcb_conflist_t *)&pcbhl_conf.editor.grids, dst); /* clamp */ @@ -217,6 +217,6 @@ void pcb_grid_inval(void) { if (pcbhl_conf.editor.grids_idx > 0) - pcb_conf_setf(CFR_DESIGN, "editor/grids_idx", -1, "%d", -1 - pcbhl_conf.editor.grids_idx); + pcb_conf_setf(RND_CFR_DESIGN, "editor/grids_idx", -1, "%d", -1 - pcbhl_conf.editor.grids_idx); } Index: trunk/src/librnd/core/gui_act.c =================================================================== --- trunk/src/librnd/core/gui_act.c (revision 30945) +++ trunk/src/librnd/core/gui_act.c (revision 30946) @@ -115,11 +115,11 @@ rnd_PCB_ACT_MAY_CONVARG(1, FGW_STR, FullScreen, cmd = argv[1].val.str); if ((cmd == NULL) || (rnd_strcasecmp(cmd, "Toggle") == 0)) - pcb_conf_setf(CFR_DESIGN, "editor/fullscreen", -1, "%d", !pcbhl_conf.editor.fullscreen, RND_POL_OVERWRITE); + pcb_conf_setf(RND_CFR_DESIGN, "editor/fullscreen", -1, "%d", !pcbhl_conf.editor.fullscreen, RND_POL_OVERWRITE); else if (rnd_strcasecmp(cmd, "On") == 0) - pcb_conf_set(CFR_DESIGN, "editor/fullscreen", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/fullscreen", -1, "1", RND_POL_OVERWRITE); else if (rnd_strcasecmp(cmd, "Off") == 0) - pcb_conf_set(CFR_DESIGN, "editor/fullscreen", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/fullscreen", -1, "0", RND_POL_OVERWRITE); else RND_ACT_FAIL(FullScreen); Index: trunk/src/librnd/core/hid_init.c =================================================================== --- trunk/src/librnd/core/hid_init.c (revision 30945) +++ trunk/src/librnd/core/hid_init.c (revision 30946) @@ -334,7 +334,7 @@ if (hidlib_conffile.used > 0) { int n; for(n = 0; n < hidlib_conffile.used; n++) { - rnd_conf_role_t role = CFR_CLI; + rnd_conf_role_t role = RND_CFR_CLI; char *srole, *sep, *fn = hidlib_conffile.array[n]; sep = strchr(fn, ';'); if (sep != NULL) { @@ -342,7 +342,7 @@ *sep = '\0'; fn = sep+1; role = pcb_conf_role_parse(srole); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { fprintf(stderr, "Can't load -C config file '%s': invalid role '%s'\n", fn, srole); free(hidlib_conffile.array[n]); continue; @@ -383,8 +383,8 @@ pcb_hidlib_event_uninit(); pcb_hid_dlg_uninit(); - if (pcb_conf_isdirty(CFR_USER)) - pcb_conf_save_file(NULL, NULL, NULL, CFR_USER, NULL); + if (pcb_conf_isdirty(RND_CFR_USER)) + pcb_conf_save_file(NULL, NULL, NULL, RND_CFR_USER, NULL); pcb_hid_uninit(); pcb_events_uninit(); Index: trunk/src/librnd/core/hidlib.h =================================================================== --- trunk/src/librnd/core/hidlib.h (revision 30945) +++ trunk/src/librnd/core/hidlib.h (revision 30946) @@ -120,11 +120,11 @@ will be substituted with "default" or the HID's short name. */ extern const char *pcbhl_menu_name_fmt; -/* path to the user's config directory and main config file (CFR_USER) */ +/* path to the user's config directory and main config file (RND_CFR_USER) */ extern const char *pcbhl_conf_userdir_path; extern const char *pcphl_conf_user_path; -/* path to the system (installed) config directory and main config file (CFR_SYSTEM) */ +/* path to the system (installed) config directory and main config file (RND_CFR_SYSTEM) */ extern const char *pcbhl_conf_sysdir_path; extern const char *pcbhl_conf_sys_path; Index: trunk/src/librnd/core/hidlib_conf.c =================================================================== --- trunk/src/librnd/core/hidlib_conf.c (revision 30945) +++ trunk/src/librnd/core/hidlib_conf.c (revision 30946) @@ -67,5 +67,5 @@ void pcb_hidlib_set_unit(rnd_hidlib_t *hidlib, const pcb_unit_t *new_unit) { if (new_unit != NULL && new_unit->allow != PCB_UNIT_NO_PRINT) - pcb_conf_set(CFR_DESIGN, "editor/grid_unit", -1, new_unit->suffix, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/grid_unit", -1, new_unit->suffix, RND_POL_OVERWRITE); } Index: trunk/src/librnd/core/tool.c =================================================================== --- trunk/src/librnd/core/tool.c (revision 30945) +++ trunk/src/librnd/core/tool.c (revision 30946) @@ -146,7 +146,7 @@ uninit_current_tool(); sprintf(id_s, "%d", id); tool_select_lock = 1; - pcb_conf_set(CFR_DESIGN, "editor/mode", -1, id_s, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/mode", -1, id_s, RND_POL_OVERWRITE); tool_select_lock = 0; init_current_tool(); Index: trunk/src/librnd/pcb_compat.h =================================================================== --- trunk/src/librnd/pcb_compat.h (revision 30945) +++ trunk/src/librnd/pcb_compat.h (revision 30946) @@ -249,3 +249,18 @@ #define confprop_t rnd_confprop_t #define conf_native_t rnd_conf_native_t #define conf_role_t rnd_conf_role_t +#define CFR_INTERNAL RND_CFR_INTERNAL +#define CFR_SYSTEM RND_CFR_SYSTEM +#define CFR_DEFAULTPCB RND_CFR_DEFAULTPCB +#define CFR_USER RND_CFR_USER +#define CFR_ENV RND_CFR_ENV +#define CFR_PROJECT RND_CFR_PROJECT +#define CFR_DESIGN RND_CFR_DESIGN +#define CFR_CLI RND_CFR_CLI +#define CFR_max_real RND_CFR_max_real +#define CFR_file RND_CFR_file +#define CFR_binary RND_CFR_binary +#define CFR_max_alloc RND_CFR_max_alloc +#define CFR_invalid RND_CFR_invalid +#define pcb_conf_default_prio rnd_conf_default_prio +#define pcb_conf_main_root_replace_cnt rnd_conf_main_root_replace_cnt Index: trunk/src/main.c =================================================================== --- trunk/src/main.c (revision 30945) +++ trunk/src/main.c (revision 30946) @@ -427,7 +427,7 @@ pcb_hidlib_init1(conf_core_init); pcb_event_init_app(); - pcb_conf_set(CFR_INTERNAL, "rc/path/exec_prefix", -1, exec_prefix, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_INTERNAL, "rc/path/exec_prefix", -1, exec_prefix, RND_POL_OVERWRITE); free(exec_prefix); pcb_layer_vis_init(); Index: trunk/src/main_act.c =================================================================== --- trunk/src/main_act.c (revision 30945) +++ trunk/src/main_act.c (revision 30946) @@ -135,8 +135,8 @@ u("\nGenerics:"); - u("-c conf/path=value set the value of a configuration item (in CFR_CLI)"); - u("-C conffile load config file (as CFR_CLI; after all -c's)"); + u("-c conf/path=value set the value of a configuration item (in RND_CFR_CLI)"); + u("-C conffile load config file (as RND_CFR_CLI; after all -c's)"); return 0; } Index: trunk/src/obj_line_drcenf.c =================================================================== --- trunk/src/obj_line_drcenf.c (revision 30945) +++ trunk/src/obj_line_drcenf.c (revision 30946) @@ -498,11 +498,11 @@ if (conf_core.editor.line_refraction != 0) { if (shift) { if (conf_core.editor.line_refraction !=2) - pcb_conf_setf(CFR_DESIGN, "editor/line_refraction", -1, "%d", 2); + pcb_conf_setf(RND_CFR_DESIGN, "editor/line_refraction", -1, "%d", 2); } else{ if (conf_core.editor.line_refraction != 1) - pcb_conf_setf(CFR_DESIGN, "editor/line_refraction", -1, "%d", 1); + pcb_conf_setf(RND_CFR_DESIGN, "editor/line_refraction", -1, "%d", 1); } } pcb->hidlib.ch_x = pcb_crosshair.X = rs.X; @@ -512,11 +512,11 @@ if (conf_core.editor.line_refraction !=0) { if (shift) { if (conf_core.editor.line_refraction != 1) - pcb_conf_setf(CFR_DESIGN, "editor/line_refraction", -1, "%d", 1); + pcb_conf_setf(RND_CFR_DESIGN, "editor/line_refraction", -1, "%d", 1); } else { if (conf_core.editor.line_refraction != 2) - pcb_conf_setf(CFR_DESIGN, "editor/line_refraction", -1, "%d", 2); + pcb_conf_setf(RND_CFR_DESIGN, "editor/line_refraction", -1, "%d", 2); } } pcb->hidlib.ch_x = pcb_crosshair.X = r45.X; Index: trunk/src/plug_io.c =================================================================== --- trunk/src/plug_io.c (revision 30945) +++ trunk/src/plug_io.c (revision 30946) @@ -204,7 +204,7 @@ int accepts[PCB_IO_MAX_FORMATS]; /* test-parse output */ int accept_total = 0; FILE *ft; - long design_root_cnt = pcb_conf_main_root_replace_cnt[CFR_DESIGN]; + long design_root_cnt = rnd_conf_main_root_replace_cnt[RND_CFR_DESIGN]; ft = pcb_fopen(&Ptr->hidlib, Filename, "r"); len = pcb_test_parse_all(ft, Filename, fmt, PCB_IOT_PCB, available, accepts, &accept_total, sizeof(available)/sizeof(available[0]), ignore_missing, load_settings); @@ -233,8 +233,8 @@ if ((res == 0) && (load_settings)) { - if (design_root_cnt == pcb_conf_main_root_replace_cnt[CFR_DESIGN]) /* the newly loaded board did not bring a design root */ - pcb_conf_reset(CFR_DESIGN, ""); + if (design_root_cnt == rnd_conf_main_root_replace_cnt[RND_CFR_DESIGN]) /* the newly loaded board did not bring a design root */ + pcb_conf_reset(RND_CFR_DESIGN, ""); pcb_conf_load_project(NULL, Filename); } @@ -244,7 +244,7 @@ if (load_settings) pcb_event(&PCB->hidlib, PCB_EVENT_LOAD_POST, "si", Filename, res); pcb_event(&PCB->hidlib, PCB_EVENT_ROUTE_STYLES_CHANGED, NULL); - pcb_conf_set(CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); /* we have only one font now, make sure it is selected */ + pcb_conf_set(RND_CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); /* we have only one font now, make sure it is selected */ pcb_plug_io_err(&Ptr->hidlib, res, "load pcb", Filename); return res; @@ -535,9 +535,9 @@ newPCB->fontkit.valid = pcb_false; switch(how & 0x0F) { - case 0: settings_dest = CFR_DESIGN; break; - case 1: settings_dest = CFR_DEFAULTPCB; break; - case 2: settings_dest = CFR_invalid; break; + case 0: settings_dest = RND_CFR_DESIGN; break; + case 1: settings_dest = RND_CFR_DEFAULTPCB; break; + case 2: settings_dest = RND_CFR_invalid; break; default: abort(); } @@ -577,7 +577,7 @@ /* geda/pcb compatibility: use attribute PCB::grid::unit as unit, if present */ unit_suffix = rnd_attrib_get(PCB, "PCB::grid::unit"); if (unit_suffix && *unit_suffix) { - lht_node_t *nat = pcb_conf_lht_get_at(CFR_DESIGN, "editor/grid_unit", 0); + lht_node_t *nat = pcb_conf_lht_get_at(RND_CFR_DESIGN, "editor/grid_unit", 0); if (nat == NULL) { const pcb_unit_t *new_unit = get_unit_struct(unit_suffix); if (new_unit) Index: trunk/src/plug_io.h =================================================================== --- trunk/src/plug_io.h (revision 30945) +++ trunk/src/plug_io.h (revision 30946) @@ -78,7 +78,7 @@ /* Attempt to load a pcb design from Filename to Ptr. Conf subtree at settings_dest is replaced by settings loaded from the - file unless it's CFR_invalid. + file unless it's RND_CFR_invalid. Return 0 on success. */ int (*parse_pcb)(pcb_plug_io_t *ctx, pcb_board_t *Ptr, const char *Filename, rnd_conf_role_t settings_dest); Index: trunk/src_plugins/ddraft/constraint_gui.c =================================================================== --- trunk/src_plugins/ddraft/constraint_gui.c (revision 30945) +++ trunk/src_plugins/ddraft/constraint_gui.c (revision 30946) @@ -190,7 +190,7 @@ cnstgui_ctx.inhibit_confchg++; nv = (cnstgui_ctx.dlg[cnstgui_ctx.alldir].val.lng) ? "1" : "0"; - pcb_conf_set(CFR_DESIGN, "editor/all_direction_lines", -1, nv, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/all_direction_lines", -1, nv, RND_POL_OVERWRITE); cnstgui_ctx.inhibit_confchg--; } Index: trunk/src_plugins/diag/diag.c =================================================================== --- trunk/src_plugins/diag/diag.c (revision 30945) +++ trunk/src_plugins/diag/diag.c (revision 30946) @@ -82,7 +82,7 @@ RND_PCB_ACT_CONVARG(2, FGW_STR, DumpConf, srole = argv[2].val.str); rnd_PCB_ACT_MAY_CONVARG(3, FGW_STR, DumpConf, prefix = argv[3].val.str); role = pcb_conf_role_parse(srole); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'\n", argv[1]); RND_ACT_IRES(1); return 0; @@ -129,13 +129,13 @@ } printf("Conf node %s\n", path); - for(role = 0; role < CFR_max_real; role++) { + for(role = 0; role < RND_CFR_max_real; role++) { lht_node_t *n; printf(" Role: %s\n", pcb_conf_role_name(role)); n = pcb_conf_lht_get_at(role, path, 0); if (n != NULL) { rnd_conf_policy_t pol = -1; - long prio = pcb_conf_default_prio[role]; + long prio = rnd_conf_default_prio[role]; if (pcb_conf_get_policy_prio(n, &pol, &prio) == 0) Index: trunk/src_plugins/dialogs/dlg_fontsel.c =================================================================== --- trunk/src_plugins/dialogs/dlg_fontsel.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_fontsel.c (revision 30946) @@ -138,7 +138,7 @@ return; } pcb_del_font(&PCB->fontkit, conf_core.design.text_font_id); - pcb_conf_set(CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/text_font_id", 0, "0", RND_POL_OVERWRITE); fontsel_preview_update((fontsel_ctx_t *)caller_data); } Index: trunk/src_plugins/dialogs/dlg_pref.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_pref.c (revision 30946) @@ -56,7 +56,7 @@ conf_hid_id_t pref_hid; static const char *role_names[] = { "user", "project", "design", "cli", NULL }; -static const rnd_conf_role_t roles[] = { CFR_USER, CFR_PROJECT, CFR_DESIGN, CFR_CLI, 0 }; +static const rnd_conf_role_t roles[] = { RND_CFR_USER, RND_CFR_PROJECT, RND_CFR_DESIGN, RND_CFR_CLI, 0 }; void pcb_pref_conf2dlg_item(rnd_conf_native_t *cn, pref_confitem_t *item) { @@ -325,7 +325,7 @@ PCB_DAD_NEW("preferences", pref_ctx.dlg, "pcb-rnd preferences", &pref_ctx, pcb_false, pref_close_cb); PCB_DAD_SET_VALUE(pref_ctx.dlg_hid_ctx, pref_ctx.wrole, lng, 2); - pref_ctx.role = CFR_DESIGN; + pref_ctx.role = RND_CFR_DESIGN; pcb_dlg_pref_lib_open(&pref_ctx); pcb_dlg_pref_color_open(&pref_ctx); Index: trunk/src_plugins/dialogs/dlg_pref_conf.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref_conf.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_pref_conf.c (revision 30946) @@ -145,12 +145,12 @@ pcb_dad_tree_clear(tree); - for(n = 0; n < CFR_max_real; n++) { + for(n = 0; n < RND_CFR_max_real; n++) { char *cell[5]= {NULL}; cell[0] = rnd_strdup(pcb_conf_role_name(n)); if (nat != NULL) { lht_node_t *nd; - long prio = pcb_conf_default_prio[n]; + long prio = rnd_conf_default_prio[n]; rnd_conf_policy_t pol = RND_POL_OVERWRITE; nd = pcb_conf_lht_get_at_mainplug(n, nat->hash_path, 1, 0); Index: trunk/src_plugins/dialogs/dlg_pref_confedit.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref_confedit.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_pref_confedit.c (revision 30946) @@ -180,9 +180,9 @@ val = ""; pcb_conf_set(ctx->role, ctx->nat->hash_path, ctx->idx, val, RND_POL_OVERWRITE); - if ((ctx->role == CFR_USER) || (ctx->role == CFR_PROJECT)) + if ((ctx->role == RND_CFR_USER) || (ctx->role == RND_CFR_PROJECT)) pcb_conf_save_file(&PCB->hidlib, NULL, (PCB == NULL ? NULL : PCB->hidlib.filename), ctx->role, NULL); - else if (ctx->role == CFR_DESIGN) + else if (ctx->role == RND_CFR_DESIGN) pcb_board_set_changed_flag(1); pcb_gui->invalidate_all(pcb_gui); Index: trunk/src_plugins/dialogs/dlg_pref_lib.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref_lib.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_pref_lib.c (revision 30946) @@ -177,7 +177,7 @@ pcb_conf_update("rc/library_search_paths", -1); pcb_conf_makedirty(ctx->role); /* low level lht_dom_node_alloc() wouldn't make user config to be saved! */ - if (ctx->role == CFR_DESIGN) + if (ctx->role == RND_CFR_DESIGN) pcb_board_set_changed_flag(1); ctx->lib.lock--; Index: trunk/src_plugins/dialogs/dlg_pref_win.c =================================================================== --- trunk/src_plugins/dialogs/dlg_pref_win.c (revision 30945) +++ trunk/src_plugins/dialogs/dlg_pref_win.c (revision 30946) @@ -84,17 +84,17 @@ static void pref_win_board_now_cb(void *hid_ctx, void *caller_data, pcb_hid_attribute_t *attr) { - pcb_wplc_save_to_role(CFR_USER); + pcb_wplc_save_to_role(RND_CFR_USER); } static void pref_win_project_now_cb(void *hid_ctx, void *caller_data, pcb_hid_attribute_t *attr) { - pcb_wplc_save_to_role(CFR_USER); + pcb_wplc_save_to_role(RND_CFR_USER); } static void pref_win_user_now_cb(void *hid_ctx, void *caller_data, pcb_hid_attribute_t *attr) { - pcb_wplc_save_to_role(CFR_USER); + pcb_wplc_save_to_role(RND_CFR_USER); } static void pref_win_file_now_cb(void *hid_ctx, void *caller_data, pcb_hid_attribute_t *attr) Index: trunk/src_plugins/draw_fontsel/draw_fontsel.c =================================================================== --- trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 30945) +++ trunk/src_plugins/draw_fontsel/draw_fontsel.c (revision 30946) @@ -173,7 +173,7 @@ if (txt == NULL) { char sval[128]; sprintf(sval, "%ld", fid); - pcb_conf_set(CFR_DESIGN, "design/text_font_id", 0, sval, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/text_font_id", 0, sval, RND_POL_OVERWRITE); } else { switch(txt->type) { Index: trunk/src_plugins/drc_query/dlg.c =================================================================== --- trunk/src_plugins/drc_query/dlg.c (revision 30945) +++ trunk/src_plugins/drc_query/dlg.c (revision 30946) @@ -48,7 +48,7 @@ } rule_edit_ctx_t; static const char *save_roles[] = {"user", "project", "design", "cli", NULL}; -static rnd_conf_role_t save_rolee[] = { CFR_USER, CFR_PROJECT, CFR_DESIGN, CFR_CLI}; +static rnd_conf_role_t save_rolee[] = { RND_CFR_USER, RND_CFR_PROJECT, RND_CFR_DESIGN, RND_CFR_CLI}; #define save_role_defaulti 2 gdl_list_t rule_edit_dialogs; @@ -193,7 +193,7 @@ MKDIR_ND(nd, nd, LHT_HASH, "plugins"); MKDIR_ND(nd, nd, LHT_HASH, "drc_query"); MKDIR_ND(nd, nd, LHT_LIST, "rules"); - if ((nd->data.list.first == NULL) && (role != CFR_USER)) { + if ((nd->data.list.first == NULL) && (role != RND_CFR_USER)) { gdl_iterator_t it; pcb_conf_listitem_t *i; @@ -337,7 +337,7 @@ srule = spath; role = pcb_conf_role_parse(srole); - if (role == CFR_invalid) + if (role == RND_CFR_invalid) RND_ACT_FAIL(DrcQueryEditRule); RND_ACT_IRES(pcb_dlg_rule_edit(role, srule)); @@ -452,7 +452,7 @@ return; \ } \ role = pcb_conf_role_parse(row->cell[1]); \ - if (role == CFR_invalid) { \ + if (role == RND_CFR_invalid) { \ rnd_message(PCB_MSG_ERROR, "internal error: invalid role %s\n", row->cell[0]); \ return; \ } \ Index: trunk/src_plugins/drc_query/drc_query.c =================================================================== --- trunk/src_plugins/drc_query/drc_query.c (revision 30945) +++ trunk/src_plugins/drc_query/drc_query.c (revision 30946) @@ -280,7 +280,7 @@ nat->random_flags.dyn_desc = 1; nat->random_flags.dyn_val = 1; vtp0_append(&free_drc_conf_nodes, nat); - pcb_conf_set(CFR_INTERNAL, path, -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_INTERNAL, path, -1, "0", RND_POL_OVERWRITE); } else free(path); @@ -337,7 +337,7 @@ if (slegacy != NULL) pcb_conf_legacy(path, slegacy); else if (sdefault != NULL) - pcb_conf_set(CFR_INTERNAL, path, -1, sdefault, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_INTERNAL, path, -1, sdefault, RND_POL_OVERWRITE); path = NULL; /* hash key shall not be free'd */ } fail:; Index: trunk/src_plugins/extedit/extedit.c =================================================================== --- trunk/src_plugins/extedit/extedit.c (revision 30945) +++ trunk/src_plugins/extedit/extedit.c (revision 30946) @@ -264,7 +264,7 @@ int res; void *udata; - pcb_conf_save_file(&PCB->hidlib, NULL, NULL, CFR_DESIGN, tmp_cfg_fn); + pcb_conf_save_file(&PCB->hidlib, NULL, NULL, RND_CFR_DESIGN, tmp_cfg_fn); f = pcb_fopen(&PCB->hidlib, tmp_fn, "w"); if (f == NULL) { Index: trunk/src_plugins/fontmode/fontmode.c =================================================================== --- trunk/src_plugins/fontmode/fontmode.c (revision 30945) +++ trunk/src_plugins/fontmode/fontmode.c (revision 30946) @@ -115,7 +115,7 @@ if (rnd_actionva(RND_ACT_HIDLIB, "New", "Font", 0)) return 1; - pcb_conf_set(CFR_DESIGN, "editor/grid_unit", -1, "mil", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "editor/grid_unit", -1, "mil", RND_POL_OVERWRITE); conf_set_design("design/min_wid", "%s", "1"); conf_set_design("design/min_slk", "%s", "1"); conf_set_design("design/text_font_id", "%s", "0"); Index: trunk/src_plugins/import_sch2/import_sch.c =================================================================== --- trunk/src_plugins/import_sch2/import_sch.c (revision 30945) +++ trunk/src_plugins/import_sch2/import_sch.c (revision 30946) @@ -65,7 +65,7 @@ src = rnd_attrib_get(PCB, tmp); if (src != NULL) { pcb_conf_grow("plugins/import_sch/args", idx+1); - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", idx, src, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", idx, src, RND_POL_OVERWRITE); idx++; } } @@ -74,7 +74,7 @@ mode = "gnetlist"; else if (strcmp(mode, "make") == 0) mode = "cmd"; - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/import_fmt", 0, mode, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/import_fmt", 0, mode, RND_POL_OVERWRITE); if (strcmp(mode, "cmd") == 0) { @@ -97,8 +97,8 @@ gds_append_str(&cmdline, target); pcb_conf_grow("plugins/import_sch/args", 2); - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", 0, outfile, RND_POL_OVERWRITE); - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", 1, cmdline.array, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", 0, outfile, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", 1, cmdline.array, RND_POL_OVERWRITE); gds_uninit(&cmdline); } @@ -179,10 +179,10 @@ return -1; } - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/import_fmt", 0, argv[0].val.str, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/import_fmt", 0, argv[0].val.str, RND_POL_OVERWRITE); pcb_conf_grow("plugins/import_sch/args", argc-1); for(n = 1; n < argc; n++) - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", n-1, argv[n].val.str, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", n-1, argv[n].val.str, RND_POL_OVERWRITE); return 0; } Index: trunk/src_plugins/import_sch2/import_sch_dlg.c =================================================================== --- trunk/src_plugins/import_sch2/import_sch_dlg.c (revision 30945) +++ trunk/src_plugins/import_sch2/import_sch_dlg.c (revision 30946) @@ -52,7 +52,7 @@ if (newval == NULL) newval = ""; if (strcmp(ci->val.string[0], newval) != 0) { - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", n, newval, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", n, newval, RND_POL_OVERWRITE); goto restart; /* elements may be deleted and added with different pointers... */ } } @@ -106,7 +106,7 @@ isch_conf_lock++; PCB_DAD_SET_VALUE(isch_ctx.dlg_hid_ctx, isch_ctx.wtab, lng, target); if (setconf && (p != NULL)) - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/import_fmt", 0, p->name, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/import_fmt", 0, p->name, RND_POL_OVERWRITE); if (p == NULL) { len = 0; @@ -116,7 +116,7 @@ len = pcb_conflist_length((pcb_conflist_t *)&conf_import_sch.plugins.import_sch.args); if (len < 1) { pcb_conf_grow("plugins/import_sch/args", 1); - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", 0, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", 0, "", RND_POL_OVERWRITE); } len = 1; controllable = 0; @@ -171,7 +171,7 @@ { int len = pcb_conflist_length((pcb_conflist_t *)&conf_import_sch.plugins.import_sch.args); if (len > 0) { - pcb_conf_del(CFR_DESIGN, "plugins/import_sch/args", len-1); + pcb_conf_del(RND_CFR_DESIGN, "plugins/import_sch/args", len-1); isch_pcb2dlg(); } } @@ -182,7 +182,7 @@ if (len < MAX_ARGS+1) { isch_conf_lock++; pcb_conf_grow("plugins/import_sch/args", len+1); - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", len, "", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", len, "", RND_POL_OVERWRITE); isch_pcb2dlg(); isch_conf_lock--; } @@ -211,7 +211,7 @@ return; isch_conf_lock++; - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/args", idx, name, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/args", idx, name, RND_POL_OVERWRITE); isch_pcb2dlg(); free(name); isch_conf_lock--; @@ -240,7 +240,7 @@ { const char *nv = isch_ctx.dlg[isch_ctx.wverbose].val.lng ? "1" : "0"; isch_conf_lock++; - pcb_conf_set(CFR_DESIGN, "plugins/import_sch/verbose", 0, nv, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/import_sch/verbose", 0, nv, RND_POL_OVERWRITE); isch_conf_lock--; } Index: trunk/src_plugins/io_eagle/read_dru.c =================================================================== --- trunk/src_plugins/io_eagle/read_dru.c (revision 30945) +++ trunk/src_plugins/io_eagle/read_dru.c (revision 30946) @@ -154,7 +154,7 @@ return; } if (d > curr_val) - pcb_conf_set(CFR_DESIGN, "design/min_drill", -1, val, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/min_drill", -1, val, RND_POL_OVERWRITE); } int io_eagle_read_pcb_dru(pcb_plug_io_t *ctx, pcb_board_t *pcb, const char *Filename, rnd_conf_role_t settings_dest) @@ -171,9 +171,9 @@ if (f == NULL) return -1; - pcb_conf_set(CFR_DESIGN, "design/bloat", -1, "0", RND_POL_OVERWRITE); - pcb_conf_set(CFR_DESIGN, "design/min_wid", -1, "0", RND_POL_OVERWRITE); - pcb_conf_set(CFR_DESIGN, "design/min_drill", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/bloat", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/min_wid", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "design/min_drill", -1, "0", RND_POL_OVERWRITE); memcpy(tmp, prefix, sizeof(prefix)); Index: trunk/src_plugins/io_kicad/read.c =================================================================== --- trunk/src_plugins/io_kicad/read.c (revision 30945) +++ trunk/src_plugins/io_kicad/read.c (revision 30946) @@ -2814,7 +2814,7 @@ st.pcb = NULL; st.fp_data = Ptr; st.Filename = fpst.filename; - st.settings_dest = CFR_invalid; + st.settings_dest = RND_CFR_invalid; st.auto_layers = 1; res = kicad_parse_file(f, &st.dom); Index: trunk/src_plugins/io_lihata/read.c =================================================================== --- trunk/src_plugins/io_lihata/read.c (revision 30945) +++ trunk/src_plugins/io_lihata/read.c (revision 30946) @@ -383,7 +383,7 @@ if (parse_coord(&tmp, nd) != 0) return -1; - if (cfg_dest != CFR_invalid) + if (cfg_dest != RND_CFR_invalid) pcb_conf_set(cfg_dest, path, -1, nd->data.text.value, RND_POL_OVERWRITE); return 0; } @@ -2215,7 +2215,7 @@ static void parse_conf(pcb_board_t *pcb, lht_node_t *sub) { - if (cfg_dest == CFR_invalid) + if (cfg_dest == RND_CFR_invalid) return; if (pcb_conf_insert_tree_as(cfg_dest, sub) != 0) rnd_message(PCB_MSG_ERROR, "Failed to insert the config subtree '%s' found in %s\n", sub->name, pcb->hidlib.filename); @@ -2394,7 +2394,7 @@ char *errmsg = NULL, *realfn; lht_doc_t *doc = NULL; - cfg_dest = CFR_invalid; + cfg_dest = RND_CFR_invalid; realfn = pcb_fopen_check(NULL, filename, "r"); if (realfn != NULL) @@ -2527,7 +2527,7 @@ FILE *f; pcb_subc_t *sc; - cfg_dest = CFR_invalid; + cfg_dest = RND_CFR_invalid; f = pcb_fp_fopen(&conf_core.rc.library_search_paths, name, &st, NULL); Index: trunk/src_plugins/io_lihata/write.c =================================================================== --- trunk/src_plugins/io_lihata/write.c (revision 30945) +++ trunk/src_plugins/io_lihata/write.c (revision 30946) @@ -1394,7 +1394,7 @@ return nls; } -extern lht_doc_t *pcb_conf_main_root[CFR_max_alloc]; +extern lht_doc_t *pcb_conf_main_root[RND_CFR_max_alloc]; static lht_node_t *build_conf() { const char **s, *del_paths[] = { "editor/mode", NULL }; @@ -1403,10 +1403,10 @@ if (conf_io_lihata.plugins.io_lihata.omit_config) return dummy_node("pcb-rnd-conf-v1"); - if ((pcb_conf_main_root[CFR_DESIGN] == NULL) || (pcb_conf_main_root[CFR_DESIGN]->root == NULL) || (pcb_conf_main_root[CFR_DESIGN]->root->type != LHT_LIST)) + if ((pcb_conf_main_root[RND_CFR_DESIGN] == NULL) || (pcb_conf_main_root[RND_CFR_DESIGN]->root == NULL) || (pcb_conf_main_root[RND_CFR_DESIGN]->root->type != LHT_LIST)) return lht_dom_node_alloc(LHT_LIST, "pcb-rnd-conf-v1"); - res = lht_dom_duptree(pcb_conf_main_root[CFR_DESIGN]->root); + res = lht_dom_duptree(pcb_conf_main_root[RND_CFR_DESIGN]->root); for(n = res->data.list.first; n != NULL; n = n->next) { for(s = del_paths; *s != NULL; s++) { @@ -1791,13 +1791,13 @@ int omit_styles = !!sub->dlg[save->womit_styles].val.lng; if (omit_font != !!conf_io_lihata.plugins.io_lihata.omit_font) - pcb_conf_setf(CFR_CLI, "plugins/io_lihata/omit_font", 0, "%d", omit_font); + pcb_conf_setf(RND_CFR_CLI, "plugins/io_lihata/omit_font", 0, "%d", omit_font); if (omit_config != !!conf_io_lihata.plugins.io_lihata.omit_config) - pcb_conf_setf(CFR_CLI, "plugins/io_lihata/omit_config", 0, "%d", omit_config); + pcb_conf_setf(RND_CFR_CLI, "plugins/io_lihata/omit_config", 0, "%d", omit_config); if (omit_styles != !!conf_io_lihata.plugins.io_lihata.omit_styles) - pcb_conf_setf(CFR_CLI, "plugins/io_lihata/omit_styles", 0, "%d", omit_styles); + pcb_conf_setf(RND_CFR_CLI, "plugins/io_lihata/omit_styles", 0, "%d", omit_styles); } free(save); Index: trunk/src_plugins/io_pcb/attribs.c =================================================================== --- trunk/src_plugins/io_pcb/attribs.c (revision 30945) +++ trunk/src_plugins/io_pcb/attribs.c (revision 30946) @@ -100,7 +100,7 @@ void io_pcb_attrib_c2a(pcb_board_t *pcb) { - lht_node_t *nmain = pcb_conf_lht_get_first(CFR_DESIGN, 0); + lht_node_t *nmain = pcb_conf_lht_get_first(RND_CFR_DESIGN, 0); c2a(pcb, nmain, ""); } @@ -123,12 +123,12 @@ *next = '\0'; next += strlen(LISTSEP); } - pcb_conf_set(CFR_DESIGN, pcb->Attributes.List[n].name + conf_attr_prefix_len, -1, curr, RND_POL_APPEND); + pcb_conf_set(RND_CFR_DESIGN, pcb->Attributes.List[n].name + conf_attr_prefix_len, -1, curr, RND_POL_APPEND); } free(tmp); } else /* assume plain string */ - pcb_conf_set(CFR_DESIGN, pcb->Attributes.List[n].name + conf_attr_prefix_len, -1, pcb->Attributes.List[n].value, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, pcb->Attributes.List[n].name + conf_attr_prefix_len, -1, pcb->Attributes.List[n].value, RND_POL_OVERWRITE); } } } Index: trunk/src_plugins/io_pcb/parse_l.c =================================================================== --- trunk/src_plugins/io_pcb/parse_l.c (revision 30945) +++ trunk/src_plugins/io_pcb/parse_l.c (revision 30946) @@ -2703,7 +2703,7 @@ /* set up the yy globals only after the pcb_fp_fopen() because it can also call Parse */ yy_parse_tags = 0; - yy_settings_dest = CFR_invalid; + yy_settings_dest = RND_CFR_invalid; yyPCB = NULL; yyData = Ptr; pcb_data_set_layer_parents(Ptr); @@ -2763,7 +2763,7 @@ yysubc = NULL; yy_settings_dest = settings_dest; - if (settings_dest != CFR_invalid) + if (settings_dest != RND_CFR_invalid) pcb_conf_reset(settings_dest, Filename); io_pcb_preproc_board(PCB); @@ -2772,10 +2772,10 @@ fcmd = conf_core.rc.file_command; retval = Parse(NULL, fcmd, conf_core.rc.file_path, Filename); - if ((settings_dest != CFR_invalid) && (retval == 0)) { + if ((settings_dest != RND_CFR_invalid) && (retval == 0)) { /* overwrite settings from the flags, mark them not-to-save */ pcb_conf_reset(settings_dest, ""); - pcb_conf_main_root_replace_cnt[settings_dest]++; + rnd_conf_main_root_replace_cnt[settings_dest]++; CONF_SET(settings_dest, "plugins/mincut/enable", -1, CONF_BOOL_FLAG(PCB_ENABLEPCB_FLAG_MINCUT, yy_pcb_flags), RND_POL_OVERWRITE); CONF_SET(settings_dest, "editor/show_number", -1, CONF_BOOL_FLAG(PCB_SHOWNUMBERFLAG, yy_pcb_flags), RND_POL_OVERWRITE); CONF_SET(settings_dest, "editor/show_drc", -1, CONF_BOOL_FLAG(PCB_SHOWPCB_FLAG_DRC, yy_pcb_flags), RND_POL_OVERWRITE); @@ -2869,7 +2869,7 @@ yysubc = NULL; yyFontReset = pcb_false; - yy_settings_dest = CFR_invalid; + yy_settings_dest = RND_CFR_invalid; fcmd = conf_core.rc.font_command; r = Parse(NULL, fcmd, NULL, Filename); if (r == 0) { Index: trunk/src_plugins/io_pcb/parse_l.l =================================================================== --- trunk/src_plugins/io_pcb/parse_l.l (revision 30945) +++ trunk/src_plugins/io_pcb/parse_l.l (revision 30946) @@ -320,7 +320,7 @@ /* set up the yy globals only after the pcb_fp_fopen() because it can also call Parse */ yy_parse_tags = 0; - yy_settings_dest = CFR_invalid; + yy_settings_dest = RND_CFR_invalid; yyPCB = NULL; yyData = Ptr; pcb_data_set_layer_parents(Ptr); @@ -380,7 +380,7 @@ yysubc = NULL; yy_settings_dest = settings_dest; - if (settings_dest != CFR_invalid) + if (settings_dest != RND_CFR_invalid) pcb_conf_reset(settings_dest, Filename); io_pcb_preproc_board(PCB); @@ -389,10 +389,10 @@ fcmd = conf_core.rc.file_command; retval = Parse(NULL, fcmd, conf_core.rc.file_path, Filename); - if ((settings_dest != CFR_invalid) && (retval == 0)) { + if ((settings_dest != RND_CFR_invalid) && (retval == 0)) { /* overwrite settings from the flags, mark them not-to-save */ pcb_conf_reset(settings_dest, ""); - pcb_conf_main_root_replace_cnt[settings_dest]++; + rnd_conf_main_root_replace_cnt[settings_dest]++; CONF_SET(settings_dest, "plugins/mincut/enable", -1, CONF_BOOL_FLAG(PCB_ENABLEPCB_FLAG_MINCUT, yy_pcb_flags), RND_POL_OVERWRITE); CONF_SET(settings_dest, "editor/show_number", -1, CONF_BOOL_FLAG(PCB_SHOWNUMBERFLAG, yy_pcb_flags), RND_POL_OVERWRITE); CONF_SET(settings_dest, "editor/show_drc", -1, CONF_BOOL_FLAG(PCB_SHOWPCB_FLAG_DRC, yy_pcb_flags), RND_POL_OVERWRITE); @@ -486,7 +486,7 @@ yysubc = NULL; yyFontReset = pcb_false; - yy_settings_dest = CFR_invalid; + yy_settings_dest = RND_CFR_invalid; fcmd = conf_core.rc.font_command; r = Parse(NULL, fcmd, NULL, Filename); if (r == 0) { Index: trunk/src_plugins/io_pcb/parse_y.c =================================================================== --- trunk/src_plugins/io_pcb/parse_y.c (revision 30945) +++ trunk/src_plugins/io_pcb/parse_y.c (revision 30946) @@ -1842,7 +1842,7 @@ #line 191 "parse_y.y" /* yacc.c:1652 */ { pcb_board_t *pcb_save = PCB; - if ((yy_settings_dest != CFR_invalid) && (layer_group_string != NULL)) + if ((yy_settings_dest != RND_CFR_invalid) && (layer_group_string != NULL)) pcb_conf_set(yy_settings_dest, "design/groups", -1, layer_group_string, RND_POL_OVERWRITE); pcb_board_new_postproc(yyPCB, 0); if (layer_group_string == NULL) { @@ -2018,7 +2018,7 @@ yyPCB->hidlib.grid = OU ((yyvsp[-4].measure)); yyPCB->hidlib.grid_ox = OU ((yyvsp[-3].measure)); yyPCB->hidlib.grid_oy = OU ((yyvsp[-2].measure)); - if (yy_settings_dest != CFR_invalid) { + if (yy_settings_dest != RND_CFR_invalid) { if ((yyvsp[-1].integer)) pcb_conf_set(yy_settings_dest, "editor/draw_grid", -1, "true", RND_POL_OVERWRITE); else @@ -2034,7 +2034,7 @@ yyPCB->hidlib.grid = NU ((yyvsp[-4].measure)); yyPCB->hidlib.grid_ox = NU ((yyvsp[-3].measure)); yyPCB->hidlib.grid_oy = NU ((yyvsp[-2].measure)); - if (yy_settings_dest != CFR_invalid) { + if (yy_settings_dest != RND_CFR_invalid) { if ((yyvsp[-1].integer)) pcb_conf_set(yy_settings_dest, "editor/draw_grid", -1, "true", RND_POL_OVERWRITE); else @@ -3354,7 +3354,7 @@ { char tmp[128]; pcb_sprintf(tmp, "%$mm", crd); - pcb_conf_set(CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); } static void load_meta_float(const char *path, double val) @@ -3361,5 +3361,5 @@ { char tmp[128]; pcb_sprintf(tmp, "%f", val); - pcb_conf_set(CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); } Index: trunk/src_plugins/io_pcb/parse_y.y =================================================================== --- trunk/src_plugins/io_pcb/parse_y.y (revision 30945) +++ trunk/src_plugins/io_pcb/parse_y.y (revision 30946) @@ -190,7 +190,7 @@ pcbnetlistpatch { pcb_board_t *pcb_save = PCB; - if ((yy_settings_dest != CFR_invalid) && (layer_group_string != NULL)) + if ((yy_settings_dest != RND_CFR_invalid) && (layer_group_string != NULL)) pcb_conf_set(yy_settings_dest, "design/groups", -1, layer_group_string, RND_POL_OVERWRITE); pcb_board_new_postproc(yyPCB, 0); if (layer_group_string == NULL) { @@ -350,7 +350,7 @@ yyPCB->hidlib.grid = OU ($3); yyPCB->hidlib.grid_ox = OU ($4); yyPCB->hidlib.grid_oy = OU ($5); - if (yy_settings_dest != CFR_invalid) { + if (yy_settings_dest != RND_CFR_invalid) { if ($6) pcb_conf_set(yy_settings_dest, "editor/draw_grid", -1, "true", RND_POL_OVERWRITE); else @@ -365,7 +365,7 @@ yyPCB->hidlib.grid = NU ($3); yyPCB->hidlib.grid_ox = NU ($4); yyPCB->hidlib.grid_oy = NU ($5); - if (yy_settings_dest != CFR_invalid) { + if (yy_settings_dest != RND_CFR_invalid) { if ($6) pcb_conf_set(yy_settings_dest, "editor/draw_grid", -1, "true", RND_POL_OVERWRITE); else @@ -1450,7 +1450,7 @@ { char tmp[128]; pcb_sprintf(tmp, "%$mm", crd); - pcb_conf_set(CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); } static void load_meta_float(const char *path, double val) @@ -1457,5 +1457,5 @@ { char tmp[128]; pcb_sprintf(tmp, "%f", val); - pcb_conf_set(CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); } Index: trunk/src_plugins/io_tedax/tdrc.c =================================================================== --- trunk/src_plugins/io_tedax/tdrc.c (revision 30945) +++ trunk/src_plugins/io_tedax/tdrc.c (revision 30946) @@ -124,7 +124,7 @@ } for(n = 0, r = rules; n < NUM_RULES; r++,n++) - pcb_conf_setf(CFR_DESIGN, r->conf, -1, "%$mm", val[n]); + pcb_conf_setf(RND_CFR_DESIGN, r->conf, -1, "%$mm", val[n]); return 0; } Index: trunk/src_plugins/lib_gtk_common/dlg_topwin.c =================================================================== --- trunk/src_plugins/lib_gtk_common/dlg_topwin.c (revision 30945) +++ trunk/src_plugins/lib_gtk_common/dlg_topwin.c (revision 30946) @@ -252,7 +252,7 @@ static void fullscreen_cb(GtkButton *btn, void *data) { - pcb_conf_setf(CFR_DESIGN, "editor/fullscreen", -1, "%d", !pcbhl_conf.editor.fullscreen, RND_POL_OVERWRITE); + pcb_conf_setf(RND_CFR_DESIGN, "editor/fullscreen", -1, "%d", !pcbhl_conf.editor.fullscreen, RND_POL_OVERWRITE); } /* XPM */ Index: trunk/src_plugins/lib_gtk_common/lib_gtk_config.c =================================================================== --- trunk/src_plugins/lib_gtk_common/lib_gtk_config.c (revision 30945) +++ trunk/src_plugins/lib_gtk_common/lib_gtk_config.c (revision 30946) @@ -94,7 +94,7 @@ int warned = 0; const char **p; static int dummy_gtk_conf_init; - int dirty[CFR_max_real] = {0}; + int dirty[RND_CFR_max_real] = {0}; rnd_conf_role_t r; ghid_conf_id = pcb_conf_hid_reg(lib_gtk_config_cookie, NULL); @@ -128,7 +128,7 @@ pcb_conf_setf(r, p[1], -1, "%d", nat->val.integer[0]); dirty[r] = 1; } - for(r = 0; r < CFR_max_real; r++) + for(r = 0; r < RND_CFR_max_real; r++) if (dirty[r]) pcb_wplc_load(r); } Index: trunk/src_plugins/lib_hid_common/dlg_comm_m.c =================================================================== --- trunk/src_plugins/lib_hid_common/dlg_comm_m.c (revision 30945) +++ trunk/src_plugins/lib_hid_common/dlg_comm_m.c (revision 30946) @@ -276,9 +276,9 @@ res->type = FGW_INT; PCB_DAD_AUTORUN("MayOverwriteFile", dlg, "File overwrite question", NULL, res->val.nat_int); if (dlg[wdontask].val.lng) { - pcb_conf_set(CFR_USER, "plugins/dialogs/file_overwrite_dialog/dont_ask", 0, "1", RND_POL_OVERWRITE); - if (pcb_conf_isdirty(CFR_USER)) - pcb_conf_save_file(hidlib, NULL, NULL, CFR_USER, NULL); + pcb_conf_set(RND_CFR_USER, "plugins/dialogs/file_overwrite_dialog/dont_ask", 0, "1", RND_POL_OVERWRITE); + if (pcb_conf_isdirty(RND_CFR_USER)) + pcb_conf_save_file(hidlib, NULL, NULL, RND_CFR_USER, NULL); } PCB_DAD_FREE(dlg); Index: trunk/src_plugins/lib_hid_common/place.c =================================================================== --- trunk/src_plugins/lib_hid_common/place.c (revision 30945) +++ trunk/src_plugins/lib_hid_common/place.c (revision 30946) @@ -202,9 +202,9 @@ char *end, *end2; switch(role) { - case CFR_USER: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_user) return; break; - case CFR_DESIGN: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_design) return; break; - case CFR_PROJECT: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_project) return; break; + case RND_CFR_USER: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_user) return; break; + case RND_CFR_DESIGN: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_design) return; break; + case RND_CFR_PROJECT: if (!force && !dialogs_conf.plugins.dialogs.auto_save_window_geometry.to_project) return; break; default: return; } @@ -225,7 +225,7 @@ } - if (role != CFR_DESIGN) { + if (role != RND_CFR_DESIGN) { int r = pcb_conf_save_file(hidlib, NULL, (hidlib == NULL ? NULL : hidlib->filename), role, NULL); if (r != 0) rnd_message(PCB_MSG_ERROR, "Failed to save window geometry in %s\n", pcb_conf_role_name(role)); @@ -237,14 +237,14 @@ info. */ static void place_save_pre(rnd_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]) { - place_maybe_save(hidlib, CFR_PROJECT, 0); - place_maybe_save(hidlib, CFR_DESIGN, 0); + place_maybe_save(hidlib, RND_CFR_PROJECT, 0); + place_maybe_save(hidlib, RND_CFR_DESIGN, 0); } static void place_load_post(rnd_hidlib_t *hidlib, void *user_data, int argc, pcb_event_arg_t argv[]) { - pcb_wplc_load(CFR_PROJECT); - pcb_wplc_load(CFR_DESIGN); + pcb_wplc_load(RND_CFR_PROJECT); + pcb_wplc_load(RND_CFR_DESIGN); } void pcb_wplc_save_to_role(rnd_hidlib_t *hidlib, rnd_conf_role_t role) @@ -293,7 +293,7 @@ pcb_conf_unreg_fields(BASEPATH); - place_maybe_save(NULL, CFR_USER, 0); + place_maybe_save(NULL, RND_CFR_USER, 0); for(e = htsw_first(&wingeo); e != NULL; e = htsw_next(&wingeo, e)) free((char *)e->key); @@ -310,9 +310,9 @@ htsw_init(&wingeo, strhash, strkeyeq); pcb_event_bind(PCB_EVENT_SAVE_PRE, place_save_pre, NULL, place_cookie); pcb_event_bind(PCB_EVENT_LOAD_POST, place_load_post, NULL, place_cookie); - pcb_wplc_load(CFR_INTERNAL); - pcb_wplc_load(CFR_ENV); - pcb_wplc_load(CFR_SYSTEM); - pcb_wplc_load(CFR_USER); - pcb_wplc_load(CFR_CLI); + pcb_wplc_load(RND_CFR_INTERNAL); + pcb_wplc_load(RND_CFR_ENV); + pcb_wplc_load(RND_CFR_SYSTEM); + pcb_wplc_load(RND_CFR_USER); + pcb_wplc_load(RND_CFR_CLI); } Index: trunk/src_plugins/lib_vfs/lib_vfs.c =================================================================== --- trunk/src_plugins/lib_vfs/lib_vfs.c (revision 30945) +++ trunk/src_plugins/lib_vfs/lib_vfs.c (revision 30946) @@ -522,7 +522,7 @@ *isdir = 0; if (wr) - return pcb_conf_set(CFR_DESIGN, path, 0, buff->array, RND_POL_OVERWRITE); + return pcb_conf_set(RND_CFR_DESIGN, path, 0, buff->array, RND_POL_OVERWRITE); else pcb_conf_print_native((conf_pfn)vfs_conf_printf, buff, NULL, 0, nat); Index: trunk/src_plugins/oldactions/oldactions.c =================================================================== --- trunk/src_plugins/oldactions/oldactions.c (revision 30945) +++ trunk/src_plugins/oldactions/oldactions.c (revision 30946) @@ -169,7 +169,7 @@ */ fgw_error_t pcb_act_djopt_set_auto_only(fgw_arg_t *res, int argc, fgw_arg_t *argv) { - conf_toggle(CFR_DESIGN, "plugins/djopt/auto_only"); + conf_toggle(RND_CFR_DESIGN, "plugins/djopt/auto_only"); RND_ACT_IRES(0); return 0; } @@ -189,7 +189,7 @@ */ fgw_error_t pcb_act_ToggleVendor(fgw_arg_t *res, int argc, fgw_arg_t *argv) { - conf_toggle(CFR_DESIGN, "plugins/vendor/enable"); + conf_toggle(RND_CFR_DESIGN, "plugins/vendor/enable"); RND_ACT_IRES(0); return 0; } @@ -208,7 +208,7 @@ */ fgw_error_t pcb_act_EnableVendor(fgw_arg_t *res, int argc, fgw_arg_t *argv) { - pcb_conf_set(CFR_DESIGN, "plugins/vendor/enable", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/vendor/enable", -1, "1", RND_POL_OVERWRITE); RND_ACT_IRES(0); return 0; } @@ -225,7 +225,7 @@ */ fgw_error_t pcb_act_DisableVendor(fgw_arg_t *res, int argc, fgw_arg_t *argv) { - pcb_conf_set(CFR_DESIGN, "plugins/vendor/enable", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/vendor/enable", -1, "0", RND_POL_OVERWRITE); RND_ACT_IRES(0); return 0; } Index: trunk/src_plugins/tool_std/tool_line.c =================================================================== --- trunk/src_plugins/tool_std/tool_line.c (revision 30945) +++ trunk/src_plugins/tool_std/tool_line.c (revision 30946) @@ -214,7 +214,7 @@ /* automatic swap of line refraction after each click - should work only if refraction is in effect (no ortho, no alldir) */ if (conf_core.editor.swap_start_direction && (conf_core.editor.line_refraction != 0) && !conf_core.editor.all_direction_lines) - pcb_conf_setf(CFR_DESIGN,"editor/line_refraction", -1, "%d",conf_core.editor.line_refraction ^ 3); + pcb_conf_setf(RND_CFR_DESIGN,"editor/line_refraction", -1, "%d",conf_core.editor.line_refraction ^ 3); if (conf_core.editor.orthogonal_moves) { /* set the mark to the new starting point so ortho works as expected and we can draw a perpendicular line from here */ @@ -325,7 +325,7 @@ if (conf_core.editor.swap_start_direction) { - pcb_conf_setf(CFR_DESIGN,"editor/line_refraction", -1, "%d",conf_core.editor.line_refraction ^ 3); + pcb_conf_setf(RND_CFR_DESIGN,"editor/line_refraction", -1, "%d",conf_core.editor.line_refraction ^ 3); } pcb_subc_as_board_update(PCB); } Index: trunk/src_plugins/vendordrill/vendor.c =================================================================== --- trunk/src_plugins/vendordrill/vendor.c (revision 30945) +++ trunk/src_plugins/vendordrill/vendor.c (revision 30946) @@ -97,7 +97,7 @@ { char tmp[128]; pcb_sprintf(tmp, "%$mm", crd); - pcb_conf_set(CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, path, -1, tmp, RND_POL_OVERWRITE); } static rnd_bool vendorIsSubcMappable(pcb_subc_t *subc); @@ -270,7 +270,7 @@ rnd_message(PCB_MSG_INFO, "Loaded %d vendor drills from %s\n", n_vendor_drills, fname); rnd_message(PCB_MSG_INFO, "Loaded %d RefDes skips, %d Value skips, %d Descr skips\n", n_refdes, n_value, n_descr); - pcb_conf_set(CFR_DESIGN, "plugins/vendor/enable", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_DESIGN, "plugins/vendor/enable", -1, "0", RND_POL_OVERWRITE); apply_vendor_map(); if (free_fname) @@ -345,7 +345,7 @@ /* Update the current Via */ if (conf_core.design.via_drilling_hole != vendorDrillMap(conf_core.design.via_drilling_hole)) { changed++; - pcb_conf_setf(CFR_DESIGN, "design/via_drilling_hole", -1, "%$mm", vendorDrillMap(conf_core.design.via_drilling_hole)); + pcb_conf_setf(RND_CFR_DESIGN, "design/via_drilling_hole", -1, "%$mm", vendorDrillMap(conf_core.design.via_drilling_hole)); rnd_message(PCB_MSG_INFO, "Adjusted active via hole size to be %ml mils\n", conf_core.design.via_drilling_hole); } Index: trunk/tests/conf/conftest.c =================================================================== --- trunk/tests/conf/conftest.c (revision 30945) +++ trunk/tests/conf/conftest.c (revision 30946) @@ -93,7 +93,7 @@ arg+=7; while(isspace(*arg)) arg++; role = pcb_conf_role_parse(arg); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", arg); return; } @@ -150,7 +150,7 @@ while(isspace(*fn)) fn++; role = pcb_conf_role_parse(arg); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", arg); return; } @@ -159,7 +159,7 @@ } rnd_conf_policy_t current_policy = RND_POL_OVERWRITE; -rnd_conf_role_t current_role = CFR_DESIGN; +rnd_conf_role_t current_role = RND_CFR_DESIGN; void cmd_policy(char *arg) { @@ -173,7 +173,7 @@ void cmd_role(char *arg) { rnd_conf_role_t nr = pcb_conf_role_parse(arg); - if (nr == CFR_invalid) + if (nr == RND_CFR_invalid) rnd_message(PCB_MSG_ERROR, "Invalid/unknown role: '%s'", arg); else current_role = nr; @@ -290,12 +290,12 @@ } else if (*arg == '*') { int n; - for(n = 0; n < CFR_max_real; n++) + for(n = 0; n < RND_CFR_max_real; n++) pcb_conf_reset(n, ""); } else { rnd_conf_role_t role = pcb_conf_role_parse(arg); - if (role == CFR_invalid) { + if (role == RND_CFR_invalid) { rnd_message(PCB_MSG_ERROR, "Invalid role: '%s'", arg); return; } @@ -353,8 +353,8 @@ pcb_conf_init(); conf_core_init(); pcb_hidlib_conf_init(); - pcb_conf_reset(CFR_SYSTEM, "
"); - pcb_conf_reset(CFR_USER, "
"); + pcb_conf_reset(RND_CFR_SYSTEM, "
"); + pcb_conf_reset(RND_CFR_USER, "
"); while(getline_cont(stdin)) { char *arg, *cmd = line; Index: trunk/tests/librnd/librnd_test.c =================================================================== --- trunk/tests/librnd/librnd_test.c (revision 30945) +++ trunk/tests/librnd/librnd_test.c (revision 30946) @@ -33,7 +33,7 @@ n += pcbhl_main_args_add(&ga, argv[n], argv[n+1]); pcb_hidlib_init2(pup_buildins, local_buildins); - pcb_conf_set(CFR_CLI, "editor/view/flip_y", 0, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "editor/view/flip_y", 0, "1", RND_POL_OVERWRITE); if (pcbhl_main_args_setup1(&ga) != 0) { fprintf(stderr, "setup1 fail\n"); Index: trunk/util/gsch2pcb-rnd/gsch2pcb.c =================================================================== --- trunk/util/gsch2pcb-rnd/gsch2pcb.c (revision 30945) +++ trunk/util/gsch2pcb-rnd/gsch2pcb.c (revision 30946) @@ -120,7 +120,7 @@ const char *suff = loc_str_has_suffix(sch, ".sch", 4); if (suff != NULL) { char *tmp = rnd_strndup(sch, suff - sch); - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/sch_basename", -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/sch_basename", -1, tmp, RND_POL_OVERWRITE); free(tmp); } } @@ -164,23 +164,23 @@ if (!strcmp(config, "remove-unfound") || !strcmp(config, "r")) { /* This is default behavior set in header section */ - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/remove_unfound_elements", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/remove_unfound_elements", -1, "1", RND_POL_OVERWRITE); return 0; } if (!strcmp(config, "keep-unfound") || !strcmp(config, "k")) { - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/remove_unfound_elements", -1, "0", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/remove_unfound_elements", -1, "0", RND_POL_OVERWRITE); return 0; } if (!strcmp(config, "quiet") || !strcmp(config, "q")) { - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/quiet_mode", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/quiet_mode", -1, "1", RND_POL_OVERWRITE); return 0; } if (!strcmp(config, "preserve") || !strcmp(config, "p")) { - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/preserve", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/preserve", -1, "1", RND_POL_OVERWRITE); return 0; } if (!strcmp(config, "elements-shell") || !strcmp(config, "s")) - pcb_conf_set(CFR_CLI, "rc/library_shell", -1, arg, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "rc/library_shell", -1, arg, RND_POL_OVERWRITE); else if (!strcmp(config, "elements-dir") || !strcmp(config, "d")) { static int warned = 0; if (!warned) { @@ -187,12 +187,12 @@ rnd_message(PCB_MSG_WARNING, "WARNING: using elements-dir from %s - this overrides the normal pcb-rnd configured library search paths\n", config); warned = 1; } - pcb_conf_set(CFR_CLI, "rc/library_search_paths", -1, arg, RND_POL_PREPEND); + pcb_conf_set(RND_CFR_CLI, "rc/library_search_paths", -1, arg, RND_POL_PREPEND); } else if (!strcmp(config, "output-name") || !strcmp(config, "o")) - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/sch_basename", -1, arg, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/sch_basename", -1, arg, RND_POL_OVERWRITE); else if (!strcmp(config, "default-pcb") || !strcmp(config, "P")) - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/default_pcb", -1, arg, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/default_pcb", -1, arg, RND_POL_OVERWRITE); else if (!strcmp(config, "schematics")) add_multiple_schematics(arg); else if (!strcmp(config, "gnetlist")) { @@ -202,7 +202,7 @@ gadl_append(&extra_gnetlist_list, n); } else if (!strcmp(config, "empty-footprint")) - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/empty_footprint_name", -1, arg, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/empty_footprint_name", -1, arg, RND_POL_OVERWRITE); else return -1; @@ -252,7 +252,7 @@ lihata_prj:; fclose(f); - if (pcb_conf_load_as(CFR_PROJECT, path, 0) != 0) { + if (pcb_conf_load_as(RND_CFR_PROJECT, path, 0) != 0) { rnd_message(PCB_MSG_ERROR, "Failed to parse project file %s.\n", path); exit(1); } @@ -298,7 +298,7 @@ else if (!strcmp(opt, "verbose") || !strcmp(opt, "v")) { char tmp[64]; sprintf(tmp, "%ld", conf_g2pr.utils.gsch2pcb_rnd.verbose + 1); - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/verbose", -1, tmp, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/verbose", -1, tmp, RND_POL_OVERWRITE); continue; } else if (!strcmp(opt, "m") || !strcmp(opt, "method")) { @@ -306,7 +306,7 @@ rnd_message(PCB_MSG_ERROR, "Error: can't use unknown method '%s'; try --help\n", arg); exit(1); } - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/method", -1, arg, RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/method", -1, arg, RND_POL_OVERWRITE); i++; continue; } @@ -320,7 +320,7 @@ continue; } else if (!strcmp(opt, "fix-elements")) { - pcb_conf_set(CFR_CLI, "utils/gsch2pcb_rnd/fix_elements", -1, "1", RND_POL_OVERWRITE); + pcb_conf_set(RND_CFR_CLI, "utils/gsch2pcb_rnd/fix_elements", -1, "1", RND_POL_OVERWRITE); continue; } else if (!strcmp(opt, "gnetlist-arg")) { @@ -424,7 +424,7 @@ rnd_message(PCB_MSG_ERROR, "Don't know what to do: no project or schematics given, no local project file %s found. Try %s --help\n", LOCAL_PROJECT_FILE, argv[0]); exit(1); } - if (pcb_conf_load_as(CFR_PROJECT, LOCAL_PROJECT_FILE, 0) != 0) { + if (pcb_conf_load_as(RND_CFR_PROJECT, LOCAL_PROJECT_FILE, 0) != 0) { rnd_message(PCB_MSG_ERROR, "Failed to load project file %s. Try %s --help\n", LOCAL_PROJECT_FILE, argv[0]); exit(1); }