Files
flatcam-wsl/assets/examples/open_file.FlatScript
Marius Stanciu 3a97cd3880 - modified the way the status bar icon is set
- Drilling Tool - fixed missing feedrate code when the toolchange is Off
- AppTextEditor - working on syntax highlighting
- App - trying to speed up the new project creation
- Tcl Shell - Browser Edit - added Undo/Redo, Cut and Delete selection
- replace all the exec_() calls with exec() (except one situation in Tcl where I'm not sure of the effect)
2020-12-20 16:56:14 +02:00

26 lines
1.2 KiB
Plaintext

# #####################################################################################
# DESCRIPTION:
# Will open a Gerber (and Excellon) file in FlatCAM
# #####################################################################################
puts "\n**************** RUNNING an EXAMPLE SCRIPT = Open a file *******************\n"
# ----------- START: This is needed only for the examples ----------------
# first set the default location where to search for the files to be open and store it to the ROOT_FOLDER variable
set ROOT_FOLDER [get_sys root_folder_path]
# calculate the resources path for the examples we need to run and store it inside the PATH varaible
set PATH ${ROOT_FOLDER}/assets/examples/files
# ----------- END: This is needed only for the examples ----------------
# set the working path to the path that holds the files we are going to work with
set_path $PATH
# load the GERBER file and rename it to a known name so we can use it further
open_gerber test.gbr -outname gerber_obj
# load the Excellon file and rename it to a known name so we can use it further
open_excellon test.txt -outname excellon_obj
# plot them all so we can see them on canvas
plot_all