The game console.
More...
#include <Console.h>
◆ Console()
◆ ~Console()
◆ AddInputToHistory()
void Console::AddInputToHistory |
( |
| ) |
|
Adds a console input to the console history.
◆ AddTextToOutput()
void Console::AddTextToOutput |
( |
const Ogre::String & |
text, |
|
|
const Ogre::ColourValue & |
colour = Ogre::ColourValue::White |
|
) |
| |
Writes text to the console.
- Parameters
-
[in] | text | Text to write. |
[in] | colour | Color for the text. Default is white. |
◆ AddToHistory()
void Console::AddToHistory |
( |
const Ogre::String & |
history | ) |
|
|
private |
Adds a string to the console input history.
◆ CompleteInput()
void Console::CompleteInput |
( |
| ) |
|
Autocompletes the current input.
◆ ExecuteCommand()
void Console::ExecuteCommand |
( |
const Ogre::String & |
command | ) |
|
Executes a command in the console.
- Parameters
-
[in] | command | Command to execute. |
◆ ExecuteScript()
void Console::ExecuteScript |
( |
| ) |
|
- Todo:
- Understand and document.
◆ Input()
Processes an input event.
- Parameters
-
[in] | event | Event to process. |
◆ IsVisible()
bool Console::IsVisible |
( |
| ) |
const |
Checks if the console is currently visible.
- Returns
- TRue if the console is visible, false otherwise.
◆ LoadHistory()
void Console::LoadHistory |
( |
| ) |
|
|
private |
Loads the console input history.
◆ messageLogged()
void Console::messageLogged |
( |
const Ogre::String & |
message, |
|
|
Ogre::LogMessageLevel |
lml, |
|
|
bool |
maskDebug, |
|
|
const Ogre::String & |
logName, |
|
|
bool & |
skipThisMessage |
|
) |
| |
|
virtual |
Logs a message to the console.
- Parameters
-
[in] | message | The message to log. |
[in] | lml | Log level for the message. |
[in] | maskDebug | Indicates if the mesage is being printed to the console or not. |
[in] | logName | Name of the log. |
[in] | skipThisMessage | If true, the message will not be logged. |
◆ OnResize()
void Console::OnResize |
( |
| ) |
|
Processes a console resizing event.
◆ ResetAutoCompletion()
void Console::ResetAutoCompletion |
( |
| ) |
|
Clears the autocompletion list.
◆ SaveHistory()
void Console::SaveHistory |
( |
| ) |
|
|
private |
Saves the console input history.
◆ SetInputLineFromHistory()
void Console::SetInputLineFromHistory |
( |
| ) |
|
Sets a line from the history as the current input.
◆ SetToHide()
void Console::SetToHide |
( |
| ) |
|
◆ SetToVisible()
void Console::SetToVisible |
( |
| ) |
|
◆ TranslateNumpad()
Translates numpad key events to regular number events.
- Parameters
-
[in] | event | Event to translate. |
◆ Update()
◆ UpdateDraw()
void Console::UpdateDraw |
( |
| ) |
|
◆ UpdateNotification()
void Console::UpdateNotification |
( |
| ) |
|
Notifies the console to update itself.
◆ auto_completition_
Ogre::StringVector Console::auto_completition_ |
|
private |
List of strings available for autocompletion.
◆ auto_completition_line_
unsigned int Console::auto_completition_line_ |
|
private |
Index of the currently displayed autocompletion option.
◆ console_height_
int Console::console_height_ |
|
private |
◆ console_width_
int Console::console_width_ |
|
private |
◆ cursor_blink_time_
float Console::cursor_blink_time_ |
|
private |
Cursor blink frequency, in seconds.
◆ cursor_position_
unsigned int Console::cursor_position_ |
|
private |
Position of the cursor in the active line.
◆ display_line_
unsigned int Console::display_line_ |
|
private |
The bottom line of the console, the active one.
◆ height_
Line height of the console.
◆ history_
std::list<Ogre::String> Console::history_ |
|
private |
The console input history.
◆ history_line_cycle_index_
int Console::history_line_cycle_index_ |
|
private |
Currently selected line of the input history.
◆ input_line_
Ogre::String Console::input_line_ |
|
private |
◆ letter_width_
int Console::letter_width_ |
|
private |
The width of each letter in the console.
◆ line_width_
unsigned int Console::line_width_ |
|
private |
The width of each line in the console.
◆ max_history_size_
unsigned int Console::max_history_size_ |
|
private |
Maximum number of inputs to save to the history.
◆ max_output_line_
unsigned int Console::max_output_line_ |
|
private |
Max number of lines in output list.
◆ output_line_
Listof lines in the console.
◆ to_visible_
bool Console::to_visible_ |
|
private |
Indicates if the console is being made visible.
◆ visible_
Indicates if the console is currently visible.
The documentation for this class was generated from the following files: