ScummVM API documentation
Ultima::Ultima4::ReadStringController Class Reference

#include <read_string_controller.h>

Inheritance diagram for Ultima::Ultima4::ReadStringController:
Ultima::Ultima4::WaitableController< Common::String > Ultima::Ultima4::Controller Ultima::Ultima4::ReadIntController

Public Member Functions

 ReadStringController (int maxlen, int screenX, int screenY, const Common::String &accepted_chars="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890 \\0")
 
 ReadStringController (int maxlen, TextView *view, const Common::String &accepted_chars="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890 \\0")
 
bool keyPressed (int key) override
 
- Public Member Functions inherited from Ultima::Ultima4::WaitableController< Common::String >
 WaitableController (Common::String defaultValue)
 
virtual Common::String getValue ()
 
virtual Common::String waitFor ()
 
virtual bool mousePressed (const Common::Point &mousePos)
 
- Public Member Functions inherited from Ultima::Ultima4::Controller
 Controller (int timerInterval=1)
 
virtual bool isCombatController () const
 
bool notifyKeyPressed (int key)
 
bool notifyMousePress (const Common::Point &mousePos)
 
int getTimerInterval ()
 
virtual void setActive ()
 
virtual void keybinder (KeybindingAction action)
 
virtual void timerFired ()
 
bool shouldQuit () const
 

Static Public Member Functions

static Common::String get (int maxlen, int screenX, int screenY, EventHandler *eh=nullptr)
 
static Common::String get (int maxlen, TextView *view, EventHandler *eh=nullptr)
 
- Static Public Member Functions inherited from Ultima::Ultima4::Controller
static void timerCallback (void *data)
 

Protected Attributes

int _maxLen
 
int _screenX
 
int _screenY
 
TextView_view
 
Common::String _accepted
 
- Protected Attributes inherited from Ultima::Ultima4::WaitableController< Common::String >
Common::String _value
 

Additional Inherited Members

- Protected Member Functions inherited from Ultima::Ultima4::WaitableController< Common::String >
void doneWaiting ()
 

Detailed Description

A controller to read a Common::String, terminated by the enter key.

Constructor & Destructor Documentation

◆ ReadStringController()

Ultima::Ultima4::ReadStringController::ReadStringController ( int  maxlen,
int  screenX,
int  screenY,
const Common::String accepted_chars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890 \\0" 
)
Parameters
maxlenthe maximum length of the Common::String
screenXthe screen column where to begin input
screenYthe screen row where to begin input
accepted_charsa Common::String characters to be accepted for input

Member Function Documentation

◆ keyPressed()

bool Ultima::Ultima4::ReadStringController::keyPressed ( int  key)
overridevirtual

Key was pressed

Reimplemented from Ultima::Ultima4::Controller.


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