.. Automatically generated by KiBot, please don't edit this file .. index:: pair: PCB Print; pcb_print PCB Print ~~~~~~~~~ Prints the PCB using a mechanism that is more flexible than `pdf_pcb_print` and `svg_pcb_print`. Supports PDF, SVG, PNG, EPS and PS formats. |br| If you use custom fonts and/or colors please consult the `resources_dir` global variable. |br| Type: ``pcb_print`` Category: **PCB/docs** Parameters: - **comment** :index:`: ` [string=''] A comment for documentation purposes. It helps to identify the output. - **dir** :index:`: ` [string='./'] Output directory for the generated files. If it starts with `+` the rest is concatenated to the default dir. - **name** :index:`: ` [string=''] Used to identify this particular output definition. Avoid using `_` as first character. These names are reserved for KiBot. - **options** :index:`: ` [dict] Options for the `pcb_print` output. - Valid keys: - **color_theme** :index:`: ` [string='_builtin_classic'] Selects the color theme. Only applies to KiCad 6. To use the KiCad 6 default colors select `_builtin_default`. Usually user colors are stored as `user`, but you can give it another name. - **force_edge_cuts** :index:`: ` [boolean=false] Add the `Edge.Cuts` to all the pages. - **format** :index:`: ` [string='PDF'] [PDF,SVG,PNG,EPS,PS] Format for the output file/s. Note that for PS you need `ghostscript` which isn't part of the default docker images. - **output** :index:`: ` [string='%f-%i%I%v.%x'] Filename for the output (%i=assembly, %x=pdf/ps)/(%i=assembly_page_NN, %x=svg/png/eps). Consult the `page_number_as_extension` and `page_id` options. Affected by global options. - *output_name* :index:`: ` Alias for output. - **pages** :index:`: ` [list(dict)] List of pages to include in the output document. Each page contains one or more layers of the PCB. - Valid keys: - **layers** :index:`: ` [list(dict)|list(string)|string] List of layers printed in this page. Order is important, the last goes on top. You can reuse other layers lists, some options aren't used here, but they are valid. - Valid keys: - ``color`` :index:`: ` [string=''] Color used for this layer. - ``description`` :index:`: ` [string=''] A description for the layer, for documentation purposes. A default can be specified using the `layer_defaults` global option. - ``force_plot_invisible_refs_vals`` :index:`: ` [boolean=false] Include references and values even when they are marked as invisible. - ``layer`` :index:`: ` [string=''] Name of the layer. As you see it in KiCad. - ``plot_footprint_refs`` :index:`: ` [boolean=true] Include the footprint references. - ``plot_footprint_values`` :index:`: ` [boolean=true] Include the footprint values. - ``suffix`` :index:`: ` [string=''] Suffix used in file names related to this layer. Derived from the name if not specified. A default can be specified using the `layer_defaults` global option. - **scaling** :index:`: ` [number=1.0] Scale factor (0 means autoscaling). - **sort_layers** :index:`: ` [boolean=false] Try to sort the layers in the same order that uses KiCad for printing. - ``autoscale_margin_x`` :index:`: ` [number=0] Horizontal margin used for the autoscaling mode [mm]. - ``autoscale_margin_y`` :index:`: ` [number=0] Vertical margin used for the autoscaling mode [mm]. - ``colored_holes`` :index:`: ` [boolean=true] Change the drill holes to be colored instead of white. - ``exclude_pads_from_silkscreen`` :index:`: ` [boolean=false] Do not plot the component pads in the silk screen (KiCad 5.x only). - ``holes_color`` :index:`: ` [string='#000000'] Color used for the holes when `colored_holes` is enabled. - ``line_width`` :index:`: ` [number=0.1] [0.02,2] For objects without width [mm] (KiCad 5). - ``mirror`` :index:`: ` [boolean=false] Print mirrored (X axis inverted). - ``monochrome`` :index:`: ` [boolean=false] Print in gray scale. - ``negative_plot`` :index:`: ` [boolean=false] Invert black and white. Only useful for a single layer. - ``page_id`` :index:`: ` [string='%02d'] Text to differentiate the pages. Use %d (like in C) to get the page number. - ``repeat_for_layer`` :index:`: ` [string=''] Use this page as a pattern to create more pages. The other pages will change the layer mentioned here. This can be used to generate a page for each copper layer, here you put `F.Cu`. See `repeat_layers`. - ``repeat_inherit`` :index:`: ` [boolean=true] If we will inherit the options of the layer we are replacing. Disable it if you specify the options in `repeat_layers`, which is unlikely. - ``repeat_layers`` :index:`: ` [list(dict)|list(string)|string] List of layers to replace `repeat_for_layer`. This can be used to generate a page for each copper layer, here you put `copper`. - Valid keys: - ``color`` :index:`: ` [string=''] Color used for this layer. - ``description`` :index:`: ` [string=''] A description for the layer, for documentation purposes. A default can be specified using the `layer_defaults` global option. - ``force_plot_invisible_refs_vals`` :index:`: ` [boolean=false] Include references and values even when they are marked as invisible. - ``layer`` :index:`: ` [string=''] Name of the layer. As you see it in KiCad. - ``plot_footprint_refs`` :index:`: ` [boolean=true] Include the footprint references. - ``plot_footprint_values`` :index:`: ` [boolean=true] Include the footprint values. - ``suffix`` :index:`: ` [string=''] Suffix used in file names related to this layer. Derived from the name if not specified. A default can be specified using the `layer_defaults` global option. - ``sheet`` :index:`: ` [string='Assembly'] Text to use for the `sheet` in the title block. Pattern (%*) and text variables are expanded. In addition when you use `repeat_for_layer` the following patterns are available: %ln layer name, %ls layer suffix and %ld layer description. - ``sheet_reference_color`` :index:`: ` [string=''] Color to use for the frame and title block. - ``sketch_pad_line_width`` :index:`: ` [number=0.1] Line width for the sketched pads [mm], see `sketch_pads_on_fab_layers` (KiCad 6+) Note that this value is currently ignored by KiCad (6.0.9). - ``sketch_pads_on_fab_layers`` :index:`: ` [boolean=false] Draw only the outline of the pads on the \\*.Fab layers (KiCad 6+). - ``tent_vias`` :index:`: ` [boolean=true] Cover the vias. - ``title`` :index:`: ` [string=''] Text used to replace the sheet title. %VALUE expansions are allowed. If it starts with `+` the text is concatenated. - **plot_sheet_reference** :index:`: ` [boolean=true] Include the title-block (worksheet, frame, etc.). - **scaling** :index:`: ` [number=1.0] Default scale factor (0 means autoscaling). - ``add_background`` :index:`: ` [boolean=false] Add a background to the pages, see `background_color`. - ``autoscale_margin_x`` :index:`: ` [number=0] Default horizontal margin used for the autoscaling mode [mm]. - ``autoscale_margin_y`` :index:`: ` [number=0] Default vertical margin used for the autoscaling mode [mm]. - ``background_color`` :index:`: ` [string='#FFFFFF'] Color for the background when `add_background` is enabled. - ``background_image`` :index:`: ` [string=''] Background image, must be an SVG, only when `add_background` is enabled. - ``blind_via_color`` :index:`: ` [string=''] Color used for blind/buried `colored_vias`. - ``colored_pads`` :index:`: ` [boolean=true] Plot through-hole in a different color. Like KiCad GUI does. - ``colored_vias`` :index:`: ` [boolean=true] Plot vias in a different color. Like KiCad GUI does. - ``dnf_filter`` :index:`: ` [string|list(string)='_none'] Name of the filter to mark components as not fitted. A short-cut to use for simple cases where a variant is an overkill. - ``dpi`` :index:`: ` [number=360] [36,1200] Resolution (Dots Per Inch) for the output file. Most objects are vectors, but thing like the the solder mask are handled as images by the conversion tools. - ``drill_marks`` :index:`: ` [string='full'] [none,small,full] What to use to indicate the drill places, can be none, small or full (for real scale). - ``forced_edge_cuts_color`` :index:`: ` [string=''] Color used for the `force_edge_cuts` option. - ``frame_plot_mechanism`` :index:`: ` [string='internal'] [gui,internal,plot] Plotting the frame from Python is problematic. This option selects a workaround strategy. gui: uses KiCad GUI to do it. Is slow but you get the correct frame. But it can't keep track of page numbers. internal: KiBot loads the `.kicad_wks` and does the drawing work. Best option, but some details are different from what the GUI generates. plot: uses KiCad Python API. Only available for KiCad 6. You get the default frame and some substitutions doesn't work. - ``hide_excluded`` :index:`: ` [boolean=false] Hide components in the Fab layer that are marked as excluded by a variant. Affected by global options. - ``individual_page_scaling`` :index:`: ` [boolean=true] Tell KiCad to apply the scaling for each page as a separated entity. Disabling it the pages are coherent and can be superposed. - ``keep_temporal_files`` :index:`: ` [boolean=false] Store the temporal page and layer files in the output dir and don't delete them. - ``micro_via_color`` :index:`: ` [string=''] Color used for micro `colored_vias`. - ``pad_color`` :index:`: ` [string=''] Color used for `colored_pads`. - ``page_number_as_extension`` :index:`: ` [boolean=false] When enabled the %i is always `assembly`, the %x will be NN.FORMAT (i.e. 01.png). Note: page numbers can be customized using the `page_id` option for each page. - ``png_width`` :index:`: ` [number=1280] [0,7680] Width of the PNG in pixels. Use 0 to use as many pixels as the DPI needs for the page size. - ``pre_transform`` :index:`: ` [string|list(string)='_none'] Name of the filter to transform fields before applying other filters. A short-cut to use for simple cases where a variant is an overkill. - ``realistic_solder_mask`` :index:`: ` [boolean=true] Try to draw the solder mask as a real solder mask, not the negative used for fabrication. In order to get a good looking select a color with transparency, i.e. '#14332440'. PcbDraw must be installed in order to use this option. - ``sheet_reference_layout`` :index:`: ` [string=''] Worksheet file (.kicad_wks) to use. Leave empty to use the one specified in the project. - ``svg_precision`` :index:`: ` [number=4] [0,6] Scale factor used to represent 1 mm in the SVG (KiCad 6). The value is how much zeros has the multiplier (1 mm = 10 power `svg_precision` units). Note that for an A4 paper Firefox 91 and Chrome 105 can't handle more than 5. - ``title`` :index:`: ` [string=''] Text used to replace the sheet title. %VALUE expansions are allowed. If it starts with `+` the text is concatenated. - ``variant`` :index:`: ` [string=''] Board variant to apply. - ``via_color`` :index:`: ` [string=''] Color used for through-hole `colored_vias`. - **type** :index:`: ` [string=''] Type of output. - ``category`` :index:`: ` [string|list(string)=''] The category for this output. If not specified an internally defined category is used. Categories looks like file system paths, i.e. **PCB/fabrication/gerber**. The categories are currently used for `navigate_results`. - ``disable_run_by_default`` :index:`: ` [string|boolean] Use it to disable the `run_by_default` status of other output. Useful when this output extends another and you don't want to generate the original. Use the boolean true value to disable the output you are extending. - ``extends`` :index:`: ` [string=''] Copy the `options` section from the indicated output. Used to inherit options from another output of the same type. - ``groups`` :index:`: ` [string|list(string)=''] One or more groups to add this output. In order to catch typos we recommend to add outputs only to existing groups. You can create an empty group if needed. - ``output_id`` :index:`: ` [string=''] Text to use for the %I expansion content. To differentiate variations of this output. - ``priority`` :index:`: ` [number=50] [0,100] Priority for this output. High priority outputs are created first. Internally we use 10 for low priority, 90 for high priority and 50 for most outputs. - ``run_by_default`` :index:`: ` [boolean=true] When enabled this output will be created when no specific outputs are requested.