GraphTool
1.0
Tool for analyzing and graphically visualizing code dependencies for Ericsson.
|
#include <search_box.h>
Signals | |
void | search (std::string searchTerm, std::string searchType) |
void | searchTypeChanged (std::string new_type) |
Public Member Functions | |
SearchBox (QWidget *parent=0) | |
std::string | search_term () |
std::string | search_type () |
void | setAutocompletionModel (GraphModel *new_model) |
void | setAutocompletionList (QStringList wordList) |
Protected Slots | |
void | on_searchButton_clicked (bool checked=false) |
void | on_searchText_returnPressed () |
void | on_searchType_currentIndexChanged (QString new_type) |
Widget created to generate the search box in the UI
SearchBox::SearchBox | ( | QWidget * | parent = 0 | ) |
Constructor for the SearchBox widget The SearchBox widget is the place in the GUI where the user can enter a search term and have suggestions appear. Once a search is completed the graph will change in order to show and focus on the searched SWU or run block
parent | Used for placement in the GUI |
|
protectedslot |
When the search button is clicked, the search string and type is emitted as a signal
checked | true if the button is kept pressed (visually), false if not. An option for buttons |
|
protectedslot |
When the enter key is pressed, the search string and type is emitted as a signal
|
protectedslot |
When something is being typed - a signal is emitted to enable search suggestions to appear
new_type | The string currently being typed |
|
signal |
The search signal to be emitted with the search string and type
searchTerm | The search-string entered in the search field |
searchType | The search-type being either SWU or run block |
std::string SearchBox::search_term | ( | ) |
Accesses the search string entered and type chosen in the widget by the user. The type can be either SWU or Run Block
|
signal |
When something is being typed - a signal is emitted to enable search suggestions to appear
new_type | The string currently being typed |
void SearchBox::setAutocompletionList | ( | QStringList | wordList | ) |
Method needed to set the suggestion / auto complete list
wordList | A list of strings to be displayed in the suggestion list |
void SearchBox::setAutocompletionModel | ( | GraphModel * | new_model | ) |
Method called by the setAutocompletionList to set the model. Needed to be set to show the list in the GUI. Deletes the previous model
new_model | Model to be set |