25 #ifndef ENGINES_AURORA_CONSOLE_H 26 #define ENGINES_AURORA_CONSOLE_H 32 #include <boost/noncopyable.hpp> 33 #include <boost/function.hpp> 71 bool isIn(
float x,
float y)
const;
72 bool isIn(
float x,
float y,
float z)
const;
138 std::vector<Graphics::Aurora::Text *>
_lines;
178 bool getPosition(
int cursorX,
int cursorY,
float &x,
float &y);
184 void notifyResized(
int oldWidth,
int oldHeight,
int newWidth,
int newHeight);
230 void printList(
const std::vector<Common::UString> &list,
size_t maxSize = 0);
252 typedef std::map<Common::UString, Command, Common::UString::iless>
CommandMap;
320 #endif // ENGINES_AURORA_CONSOLE_H void printLine(const Common::UString &line)
float getContentHeight() const
Common::ScopedPtr< Graphics::Aurora::Text > _input
std::vector< Common::UString > _sounds
bool setRedirect(Common::UString redirect="")
float getContentWidth() const
Common::UString disableReason
void highlightLine(int x, int y)
void updateHelpArguments()
void cmdDumpTGA(const CommandLine &cl)
void updateScrollbarLength()
A class holding an UTF-8 string.
bool isIn(float x, float y) const
Is that point within the object?
void updateScrollbarPosition()
static void splitArguments(Common::UString argLine, std::vector< Common::UString > &args)
Graphics::Aurora::FontHandle _font
static size_t findWordStart(const Common::UString &line, size_t pos)
bool _printedCompleteWarning
void cmdListLangs(const CommandLine &cl)
bool printHints(const Common::UString &command)
void stopHighlight(int x, int y)
void highlightClip(size_t &x, size_t &y) const
std::vector< Common::UString > _videos
void execute(const Common::UString &line)
void cmdDumpAll2DA(const CommandLine &cl)
void setPrompt(const Common::UString &prompt)
void calculateDistance()
Calculate the object's distance.
Exception that provides a stack of explanations.
Common::UString getHighlight() const
A simple scoped smart pointer template.
Common::ScopedPtr< Graphics::Aurora::Text > _prompt
void cmdSetOption(const CommandLine &cl)
void cmdDumpResList(const CommandLine &cl)
virtual void showCallback()
Basic exceptions to throw.
void disableCommand(const Common::UString &cmd, const Common::UString &reason="")
void cmdListSounds(const CommandLine &cl)
size_t getColumns() const
void cmdClose(const CommandLine &cl)
Common::ScopedPtr< ConsoleWindow > _console
std::map< Common::UString, Command, Common::UString::iless > CommandMap
void cmdGetCamera(const CommandLine &cl)
void cmdGetString(const CommandLine &cl)
Basic Aurora graphics types.
void cmdSilence(const CommandLine &cl)
void cmdPlayVideo(const CommandLine &cl)
void cmdGetLang(const CommandLine &cl)
void print(const Common::UString &line)
void cmdSetCamera(const CommandLine &cl)
Common::ScopedPtr< Common::ReadLine > _readLine
A handle to an Aurora font.
void setInput(const Common::UString &input, size_t cursorPos, bool overwrite)
void printList(const std::vector< Common::UString > &list, size_t maxSize=0)
Low-level type definitions to handle fixed width types portably.
ConsoleWindow(const Common::UString &font, size_t lines, size_t history, int fontHeight=0)
A class that can be notified by the NotificationManager.
void cmdSetLang(const CommandLine &cl)
void highlightWord(int x, int y)
bool getPosition(int cursorX, int cursorY, float &x, float &y)
void printException(Common::Exception &e, const Common::UString &prefix="ERROR: ")
void enableCommand(const Common::UString &cmd)
The base class for an engine within BioWare's Aurora family.
Common::WriteFile _redirect
void cmdShowFPS(const CommandLine &cl)
void cmdDumpRes(const CommandLine &cl)
static size_t findWordEnd(const Common::UString &line, size_t pos)
void show()
Show the object.
void cmdListVideos(const CommandLine &cl)
Console(Engine &engine, const Common::UString &font, int fontHeight=0)
std::list< Common::UString > _history
void scrollDown(size_t n=1)
void render(Graphics::RenderPass pass)
Render the object.
void cmdGetOption(const CommandLine &cl)
void printf(const char *s,...) GCC_PRINTF(2
Implementing the stream writing interfaces for files.
bool processEvent(const Events::Event &event)
Common::ScopedPtr< Graphics::Aurora::GUIQuad > _cursor
void cmdPlaySound(const CommandLine &cl)
void print(const Common::UString &line)
void cmdDump2DA(const CommandLine &cl)
size_t _historySizeCurrent
ptrdiff_t _highlightLength
Common::UString _inputText
void cmdClear(const CommandLine &cl)
virtual void updateCaches()
void printCommandHelp(const Common::UString &cmd)
void startHighlight(int x, int y)
void cmdHelp(const CommandLine &cl)
boost::function< void(const CommandLine &cl)> CommandCallback
size_t getColumns() const
Common::ScopedPtr< Graphics::Aurora::GUIQuad > _highlight
A simple streaming file writing class.
Common::WriteFile _logFile
void setArguments(const Common::UString &cmd, const std::vector< Common::UString > &args)
void notifyResized(int oldWidth, int oldHeight, int newWidth, int newHeight)
bool registerCommand(const Common::UString &cmd, const CommandCallback &callback, const Common::UString &help)
void cmdQuit(const CommandLine &cl)
std::vector< Graphics::Aurora::Text * > _lines
void hide()
Hide the object.
void scrollUp(size_t n=1)