Files
create/src/Gui/CommandPy.xml
2021-05-13 13:10:40 +02:00

98 lines
3.0 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<GenerateModel xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="generateMetaModel_Module.xsd">
<PythonExport
Father="PyObjectBase"
Name="CommandPy"
Twin="Command"
TwinPointer="Command"
Include="Gui/Command.h"
FatherInclude="Base/PyObjectBase.h"
Namespace="Gui"
FatherNamespace="Base">
<Documentation>
<Author Licence="LGPL" Name="Werner Mayer" EMail="wmayer[at]users.sourceforge.net" />
<UserDocu>FreeCAD Python wrapper of Command functions</UserDocu>
</Documentation>
<Methode Name="get" Static='true'>
<Documentation>
<UserDocu>Get a given command by name or None if it doesn't exist.
get(string) -> Command
</UserDocu>
</Documentation>
</Methode>
<Methode Name="update" Static='true'>
<Documentation>
<UserDocu>Update active status of all commands.
update() -> None
</UserDocu>
</Documentation>
</Methode>
<Methode Name="listAll" Static='true'>
<Documentation>
<UserDocu>Returns the name of all commands.
listAll() -> list of strings
</UserDocu>
</Documentation>
</Methode>
<Methode Name="listByShortcut" Static='true'>
<Documentation>
<UserDocu>Returns a list of all commands, filtered by shortcut.
listByShortcut(string, bool bUseRegExp=False) -> list of strings
--
Shortcuts are converted to uppercase and spaces removed prior to comparison.
</UserDocu>
</Documentation>
</Methode>
<Methode Name="run">
<Documentation>
<UserDocu>Runs the given command.
run() -> None
</UserDocu>
</Documentation>
</Methode>
<Methode Name="isActive" Const="true">
<Documentation>
<UserDocu>Returns True if the command is active, False otherwise.
isActive() -> bool
</UserDocu>
</Documentation>
</Methode>
<Methode Name="getShortcut">
<Documentation>
<UserDocu>Returns string representing shortcut key accelerator for command.
getShortcut() -> string
</UserDocu>
</Documentation>
</Methode>
<Methode Name="setShortcut">
<Documentation>
<UserDocu>Sets shortcut for given command, returns bool True for success.
setShortcut(string) -> bool
</UserDocu>
</Documentation>
</Methode>
<Methode Name="resetShortcut">
<Documentation>
<UserDocu>Resets shortcut for given command back to the default, returns bool True for success.
resetShortcut() -> bool
</UserDocu>
</Documentation>
</Methode>
<Methode Name="getInfo">
<Documentation>
<UserDocu>Return information about this command.
getInfo() -> list of strings
--
Usage: menuText, tooltipText, whatsThisText, statustipText, pixmapText, shortcutText.
</UserDocu>
</Documentation>
</Methode>
<Methode Name="getAction">
<Documentation>
<UserDocu>Return the associated QAction object.
getAction() -> list of QAction</UserDocu>
</Documentation>
</Methode>
</PythonExport>
</GenerateModel>