GuiCommand model/es: Difference between revisions
(Updating to match new version of source page) |
(Updating to match new version of source page) |
||
Line 101: | Line 101: | ||
==Selectable block== |
==Selectable block== |
||
<nowiki><!--using lt and gt so that translate tags are not recognized in the translated pages--> |
|||
<nowiki> |
|||
{{UnfinishedDocu}} |
{{UnfinishedDocu}} |
||
<translate> |
|||
{{GuiCommand |
{{GuiCommand |
||
Line 121: | Line 121: | ||
Insert here a short description of what the command does. |
Insert here a short description of what the command does. |
||
</translate> |
|||
[[Image:Draft_Line_example.jpg|none|400px]] |
[[Image:Draft_Line_example.jpg|none|400px]] |
||
<translate> |
|||
{{Caption|Optional: add a caption below the image to explain what the tool is doing.}} |
{{Caption|Optional: add a caption below the image to explain what the tool is doing.}} |
||
Line 163: | Line 163: | ||
The ExampleCommandModel tool can be used in [[macros|macros]] and from the [[Python|Python]] console by using the following function: |
The ExampleCommandModel tool can be used in [[macros|macros]] and from the [[Python|Python]] console by using the following function: |
||
</translate> |
|||
{{Code|code= |
{{Code|code= |
||
Object = makeExampleCommandModel(Data1, Data2) |
Object = makeExampleCommandModel(Data1, Data2) |
||
}} |
}} |
||
<translate> |
|||
* Creates an {{incode|Object}} using {{incode|Data1}} and {{incode|Data2}}. |
* Creates an {{incode|Object}} using {{incode|Data1}} and {{incode|Data2}}. |
||
Line 173: | Line 173: | ||
Example: |
Example: |
||
</translate> |
|||
{{Code|code= |
{{Code|code= |
||
import FreeCAD, Base |
import FreeCAD, Base |
||
Line 179: | Line 179: | ||
Model = Base.makeExampleCommandModel(FreeCAD.Data1, FreeCAD.Data2) |
Model = Base.makeExampleCommandModel(FreeCAD.Data1, FreeCAD.Data2) |
||
}} |
}} |
||
<translate> |
|||
==Limitations== |
==Limitations== |
||
Line 189: | Line 189: | ||
Optional |
Optional |
||
</translate> |
|||
</nowiki> |
</nowiki> |
Revision as of 17:59, 9 January 2021
Base_ExampleCommandModel |
Ubicación en el Menú |
---|
Ninguno |
Entornos de trabajo |
Wb1,Wb2 |
Atajo de teclado por defecto |
Ninguno |
Introducido en versión |
- |
Ver también |
Ninguno |
Descripción
While the page is under construction, add the Template:UnfinishedDocu template at the top of the page by simply typing: {{UnfinishedDocu}}
Insert here a short description of what the command does.
Remember to use Template:Version, Template:VersionMinus, Template:VersionPlus and Template:Obsolete when applicable.
For example: The feature to utilize App::Link
introduced in version 0.19 allows linking between sub-assemblies etc...
Add an image if possible, and please follow the guidelines in WikiPages#Graphics. Example taken from Draft Line:
Optional: add a caption below the image to explain what the tool is doing.
Closing and opening translate tags should surround images, and other fixed elements, if they don't need to be translated. The caption should always be translated.
- Cómo se utiliza
- Cómo se utiliza
Opciones
- TASK Length:Tareas
{{PropertyTasks|Length}} (Código del título)
- Opciones
- List the command options here. Check out two examples, Draft Line and PartDesign Pad.
Propiedades
- DatosProperties:Propiedades
{{PropertyData|Length}} (Código del título)
- VistaProperties:Propiedades
{{PropertyView|Properties}} (Código del título)
Data
- DatosPropertyName1: Description of the property
View
- VistaPropertyName2: Description of the property
Example
Optional
Archivos de guión
See also: Category:API and FreeCAD Scripting Basics.
The ExampleCommandModel tool can be used in macros and from the Python console by using the following function:
Object = makeExampleCommandModel(Data1, Data2)
- Creates an
Object
usingData1
andData2
.
Ejemplo:
import FreeCAD, Base
Model = Base.makeExampleCommandModel(FreeCAD.Data1, FreeCAD.Data2)
Limitations
- Optional, use bullet list if multiple items
Otros (opcional)
!
Selectable block
<!--using lt and gt so that translate tags are not recognized in the translated pages--> {{UnfinishedDocu}} <translate> {{GuiCommand |Name=Base ExampleCommandModel |Icon=<!--filename of icon with extension (e.g. svg, png) if not the same name as command; delete this row if not used--> |MenuLocation=Menu → Submenu → Command |Workbenches=[[Workbench Name|Workbench]] |Shortcut={{KEY|F}} {{KEY|C}} <!--delete this row if not used--> |SeeAlso=<!--add links to similar commands; delete this row if not used--> |Version=0.17 }} ==Description== While the page is under construction, add the {{UnfinishedDocu}} template at the top of the page. Insert here a short description of what the command does. </translate> [[Image:Draft_Line_example.jpg|none|400px]] <translate> {{Caption|Optional: add a caption below the image to explain what the tool is doing.}} Closing and opening translate tags should surround images, and other fixed elements, if they don't need to be translated. The caption should always be translated. ==Usage== # There are several ways to invoke the command: #* The {{Button|[[Image:Std_Open.svg|16px]] [[GuiCommand model|Command name]]}} button from the toolbar (''Editor note:'' Using the [[Template:Button]] template, it is necessary to link to command as shown in this example) #* Using the {{MenuCommand|Menu → Submenu → Command}} from the top menu. (''Editor note:'' This uses the [[Template:MenuCommand]] wiki template) #* Use the keyboard shortcut {{KEY|F}} then {{KEY|C}} or {{KEY|Ctrl}} + {{KEY|Z}} (''Editor note:'' This uses the [[Template:KEY]] wiki template) #* (Optional) RMB (Right Mouse Button) context menu: {{MenuCommand|RMB → {{Button|[[Image:Std_Open.svg|16px]] [[GuiCommand model|Command name]]}}}} # Detailed steps as needed. Some steps may need {{KEY|Keyboard}} presses while others may require using the mouse to click on a {{Button|Button}} # Other commands may need to be referenced/used. Consider linking to their wiki pages along with their icons {{Button|[[Image:Draft_Line.svg|16px]] [[Draft Line|Draft Line]]}} or {{Button|[[Image:PartDesign_Pad.svg|16px]] [[PartDesign Pad|PartDesign Pad]]}} # Set options and press {{Button|OK}}. ==Options== * List the command options here. ==Properties== ===Data=== * {{PropertyData|PropertyName1}}: Description of the property ===View=== * {{PropertyView|PropertyName2}}: Description of the property ==Example== Optional ==Scripting== {{Emphasis|See also:}} [[:Category:API]] and [[FreeCAD Scripting Basics|FreeCAD Scripting Basics]]. The ExampleCommandModel tool can be used in [[macros|macros]] and from the [[Python|Python]] console by using the following function: </translate> {{Code|code= Object = makeExampleCommandModel(Data1, Data2) }} <translate> * Creates an {{incode|Object}} using {{incode|Data1}} and {{incode|Data2}}. Example: </translate> {{Code|code= import FreeCAD, Base Model = Base.makeExampleCommandModel(FreeCAD.Data1, FreeCAD.Data2) }} <translate> ==Limitations== * Optional, use bullet list if multiple items ==Other== Optional </translate>