src/eric7/Plugins/PluginEricdoc.py

branch
eric7
changeset 10437
2f70ca07f0af
parent 10315
4102a69604eb
child 10439
21c28b0f9e41
equal deleted inserted replaced
10436:f6881d10e995 10437:2f70ca07f0af
50 """ 50 """
51 Public method to support the display of some executable info. 51 Public method to support the display of some executable info.
52 52
53 @return dictionary containing the data to query the presence of 53 @return dictionary containing the data to query the presence of
54 the executable 54 the executable
55 @rtype dict
55 """ 56 """
56 dataList = [] 57 dataList = []
57 58
58 # 1. eric7_doc 59 # 1. eric7_doc
59 exe = "eric7_doc" 60 exe = "eric7_doc"
139 140
140 def __init__(self, ui): 141 def __init__(self, ui):
141 """ 142 """
142 Constructor 143 Constructor
143 144
144 @param ui reference to the user interface object (UI.UserInterface) 145 @param ui reference to the user interface object
146 @type UserInterface
145 """ 147 """
146 super().__init__(ui) 148 super().__init__(ui)
147 self.__ui = ui 149 self.__ui = ui
148 self.__initialize() 150 self.__initialize()
149 151
156 158
157 def activate(self): 159 def activate(self):
158 """ 160 """
159 Public method to activate this plugin. 161 Public method to activate this plugin.
160 162
161 @return tuple of None and activation status (boolean) 163 @return tuple of None and activation status
164 @rtype bool
162 """ 165 """
163 menu = ericApp().getObject("Project").getMenu("Apidoc") 166 menu = ericApp().getObject("Project").getMenu("Apidoc")
164 if menu: 167 if menu:
165 self.__projectAct = EricAction( 168 self.__projectAct = EricAction(
166 self.tr("Generate documentation (eric7_doc)"), 169 self.tr("Generate documentation (eric7_doc)"),
202 def __projectShowMenu(self, menuName, menu): # noqa: U100 205 def __projectShowMenu(self, menuName, menu): # noqa: U100
203 """ 206 """
204 Private slot called, when the the project menu or a submenu is 207 Private slot called, when the the project menu or a submenu is
205 about to be shown. 208 about to be shown.
206 209
207 @param menuName name of the menu to be shown (string) 210 @param menuName name of the menu to be shown
208 @param menu reference to the menu (QMenu) 211 @type str
212 @param menu reference to the menu
213 @type QMenu
209 """ 214 """
210 if menuName == "Apidoc" and self.__projectAct is not None: 215 if menuName == "Apidoc" and self.__projectAct is not None:
211 self.__projectAct.setEnabled( 216 self.__projectAct.setEnabled(
212 ericApp().getObject("Project").getProjectLanguage() 217 ericApp().getObject("Project").getProjectLanguage()
213 in ["Python", "Python3", "Ruby", "MicroPython"] 218 in ["Python", "Python3", "Ruby", "MicroPython"]

eric ide

mercurial