wxMaxima
Classes | Public Types | Public Member Functions | Static Public Member Functions | List of all members
AutoComplete Class Reference

Public Types

enum  autoCompletionType {
  command, tmplte, loadfile, demofile,
  generalfile, esccommand, unit
}
 All types of things we can autocomplete. More...
 
using WordList = std::vector< wxString >
 

Public Member Functions

 AutoComplete (Configuration *configuration)
 
 ~AutoComplete ()
 The destructor of AutoComplete.
 
void LoadSymbols ()
 Load all autocomplete symbols wxMaxima knows about by itself.
 
bool LoadBuiltinSymbols ()
 
void AddSymbol (wxString fun, autoCompletionType type=command)
 Manually add an autocompletable symbol to our symbols lists.
 
void AddSymbols (wxString xml)
 Interprets the XML autocompletable symbol list maxima can send us.
 
void AddSymbols_Backgroundtask (wxString xml)
 The real work of AddSymbols is made here and in the background.
 
void UpdateDemoFiles (wxString partial, wxString maximaDir)
 Replace the list of files in the directory the worksheet file is in to the demo files list.
 
void UpdateLoadFiles (wxString partial, wxString maximaDir)
 Replace the list of files in the directory the worksheet file is in to the load files list.
 
void UpdateGeneralFiles (wxString partial, wxString maximaDir)
 Assemble a list of files.
 
void AddWorksheetWords (const WordList &words)
 Add words to the list of words that appear in the workSheet's code cells.
 
void AddWorksheetWords (WordList::const_iterator begin, WordList::const_iterator end)
 
void ClearWorksheetWords ()
 Clear the list of words that appear in the workSheet's code cells.
 
void ClearDemofileList ()
 Clear the list of files demo() can be applied on.
 
wxArrayString CompleteSymbol (wxString partial, autoCompletionType type=command)
 Returns a list of possible autocompletions for the string "partial". More...
 

Static Public Member Functions

static wxString FixTemplate (wxString templ)
 Basically runs a regex over templates. More...
 

Member Enumeration Documentation

◆ autoCompletionType

All types of things we can autocomplete.

Enumerator
tmplte 

Command names.

Attention
Must be the first entry in this enum
loadfile 

Function templates.

demofile 

loadable files

generalfile 

loadable files

esccommand 

general files

unit 

Esc commands describing symbols.

Unit names.

Attention
Must be the last entry in this enum

Member Function Documentation

◆ CompleteSymbol()

wxArrayString AutoComplete::CompleteSymbol ( wxString  partial,
autoCompletionType  type = command 
)

Returns a list of possible autocompletions for the string "partial".

Returns a string array with functions which start with partial.

◆ FixTemplate()

wxString AutoComplete::FixTemplate ( wxString  templ)
static

Basically runs a regex over templates.

This will change optional arguments

◆ LoadBuiltinSymbols()

bool AutoComplete::LoadBuiltinSymbols ( )

Makes wxMaxima know all its builtin symbols.

This function might cause a compiler warning because it is suspiciously long. For the same reason it has been split into a separate file.

Add wxMaxima functions


The documentation for this class was generated from the following files: