Plot Save: Difference between revisions

From FreeCAD Documentation
(/it)
(translate)
Line 1: Line 1:
<translate>
{{GuiCommand|Name=Plot Save|Workbenches=[[Plot Module|Plot]]|MenuLocation=Plot -> Save plot}}
{{GuiCommand|Name=Plot Save|Workbenches=[[Plot Module|Plot]]|MenuLocation=Plot Save plot}}


==Description==
==Description==

Plot save tool saves the active plot at desired location. With this tool you can also select the size and resolution of output image.
Plot save tool saves the active plot at desired location. With this tool you can also select the size and resolution of output image.


Line 8: Line 8:


==How to use==
==How to use==

Select the plot tab that you want to save, and run this tool. Use path selector button in order to show a file dialog where you can choose the output image place and format.
Select the plot tab that you want to save, and run this tool. Use path selector button in order to show a file dialog where you can choose the output image place and format.


Line 15: Line 14:


==Options==
==Options==

* '''File path''': You can set the output image path (including format extension) inserting it at text line too.
* '''File path''': You can set the output image path (including format extension) inserting it at text line too.
* '''Size''': You can specify output image width and height (inches).
* '''Size''': You can specify output image width and height (inches).
Line 21: Line 19:


==Scripting==
==Scripting==

Plot save tool can be used in [[macros]] and from Python console by using the following function:
Plot save tool can be used in [[macros]] and from Python console by using the following function:


Line 27: Line 24:


Example:
Example:
</translate>

{{Code|code=
import Plot
import Plot
Plot.save("~/example.pdf", (12.8, 9.6), 50)
Plot.save("~/example.pdf", (12.8, 9.6), 50)

}}
<translate>
That will save a pdf image of 12.8x9.6 inches, with 640x480 pixels.
That will save a pdf image of 12.8x9.6 inches, with 640x480 pixels.


</translate>
{{languages | {{es|Plot Save/es}} {{fr|Plot Save/fr}} {{it|Plot Save/it}} }}
{{clear}}
<languages/>

Revision as of 21:36, 23 January 2015

Plot Save

Menu location
Plot → Save plot
Workbenches
Plot
Default shortcut
None
Introduced in version
-
See also
None

Description

Plot save tool saves the active plot at desired location. With this tool you can also select the size and resolution of output image.

How to use

Select the plot tab that you want to save, and run this tool. Use path selector button in order to show a file dialog where you can choose the output image place and format.

Path selection button Path selection button

Options

  • File path: You can set the output image path (including format extension) inserting it at text line too.
  • Size: You can specify output image width and height (inches).
  • dpi: You can set the image resolution (Dots Per Inch). Final resolution (in pixels) will be the multiplication of width and height by dpi.

Scripting

Plot save tool can be used in macros and from Python console by using the following function:

save(str, (float, float), float) : Saves the plot at path, width the size specified in inches, and the resolution specified in Dots Per Inch.

Example:

import Plot
Plot.save("~/example.pdf", (12.8, 9.6), 50)

That will save a pdf image of 12.8x9.6 inches, with 640x480 pixels.