Example #1
0
    def __init__(self, parent, giface, menuModel):
        self.parent = parent  # GConsole
        self.panel = self.parent.GetPanel()

        self.promptRunCmd = Signal('GPrompt.promptRunCmd')

        # probably only subclasses need this
        self._menuModel = menuModel

        self.mapList = self._getListOfMaps()
        self.mapsetList = utils.ListOfMapsets()

        # auto complete items
        self.autoCompList = list()
        self.autoCompFilter = None

        # command description (gtask.grassTask)
        self.cmdDesc = None

        self._loadHistory()
        if giface:
            giface.currentMapsetChanged.connect(self._loadHistory)

        # list of traced commands
        self.commands = list()
Example #2
0
    def __init__(self, parent):
        self.parent = parent  # GMConsole
        self.panel = self.parent.GetPanel()

        if self.parent.parent.GetName() not in ("LayerManager", "Modeler"):
            self.standAlone = True
        else:
            self.standAlone = False

        # dictionary of modules (description, keywords, ...)
        if not self.standAlone:
            if self.parent.parent.GetName() == 'Modeler':
                self.moduleDesc = ManagerData().GetModules()
            else:
                self.moduleDesc = parent.parent.menubar.GetData().GetModules()
            self.moduleList = self._getListOfModules()
            self.mapList = self._getListOfMaps()
            self.mapsetList = utils.ListOfMapsets()
        else:
            self.moduleDesc = self.moduleList = self.mapList = None

        # auto complete items
        self.autoCompList = list()
        self.autoCompFilter = None

        # command description (gtask.grassTask)
        self.cmdDesc = None
        self.cmdbuffer = self._readHistory()
        self.cmdindex = len(self.cmdbuffer)

        # list of traced commands
        self.commands = list()
Example #3
0
    def __init__(self, parent, menuModel):
        self.parent = parent                 # GConsole
        self.panel  = self.parent.GetPanel()

        self.promptRunCmd = Signal('GPrompt.promptRunCmd')

        # probably only subclasses need this
        self._menuModel = menuModel

        self.mapList    = self._getListOfMaps()
        self.mapsetList = utils.ListOfMapsets()
        
        # auto complete items
        self.autoCompList   = list()
        self.autoCompFilter = None
        
        # command description (gtask.grassTask)
        self.cmdDesc   = None
        
        self.cmdbuffer = self._readHistory()
        self.cmdindex  = len(self.cmdbuffer)
        
        # list of traced commands
        self.commands = list()