Difference between revisions of "Swkbd.rpl"
Jump to navigation
Jump to search
(Add "Logic" (aka maths) functions, data (getters/setters) all that's left, will do later) |
|||
Line 86: | Line 86: | ||
| | | | ||
|Returns a value from an internal subroutine (presumably the response from the math operation). | |Returns a value from an internal subroutine (presumably the response from the math operation). | ||
+ | |} | ||
+ | |||
+ | ===Data=== | ||
+ | {|class="wikitable" | ||
+ | !Prototype | ||
+ | !Symbol name (5.5.1) | ||
+ | !Description | ||
+ | !Reverse-Engineering Notes | ||
+ | |- | ||
+ | |<code>void SwkbdGetDrawStringInfo(nn::swkbd::DrawStringInfo*)</code> | ||
+ | |<code>SwkbdGetDrawStringInfo__3RplFPQ3_2nn5swkbd14DrawStringInfo</code> | ||
+ | | | ||
+ | |No clear return value. | ||
+ | |- | ||
+ | |<code>int SwkbdGetInputFormString()</code> | ||
+ | |<code>SwkbdGetInputFormString__3RplFv</code> | ||
+ | | | ||
+ | |Returns 0 or a status code from a subroutine. | ||
+ | |- | ||
+ | |<code>void SwkbdGetKeyboardCondition(nn::swkbd::KeyboardCondition *)</code> | ||
+ | |<code>SwkbdGetKeyboardCondition__3RplFPQ3_2nn5swkbd17KeyboardCondition</code> | ||
+ | | | ||
+ | |No clear return value. Split into several chunks. Makes use of a function pointer from the stack. | ||
+ | |- | ||
+ | |<code>int SwkbdGetStateInputForm()</code> | ||
+ | |<code>SwkbdGetStateInputForm__3RplFv</code> | ||
+ | | | ||
+ | |Returns 0, 1, 2, or 3. Split into several chunks. | ||
+ | |- | ||
+ | |<code>int SwkbdGetStateKeyboard()</code> | ||
+ | |<code>SwkbdGetStateKeyboard__3RplFv</code> | ||
+ | | | ||
+ | |Returns 0, 1, 2, or 3. | ||
+ | |- | ||
+ | |<code>int SwkbdIsCoveredWithSubWindow()</code> | ||
+ | |<code>SwkbdIsCoveredWithSubWindow__3RplFv</code> | ||
+ | | | ||
+ | |Returns 0 or a status code from a subroutine. | ||
+ | |- | ||
+ | |<code>int SwkbdIsDecideCancelButton(bool*)</code> | ||
+ | |<code>SwkbdIsDecideCancelButton__3RplFPb</code> | ||
+ | | | ||
+ | |Returns 0 or a value from memory. | ||
+ | |- | ||
+ | |<code>int SwkbdIsDecideOkButton(bool*)</code> | ||
+ | |<code>SwkbdIsDecideOkButton__3RplFPb</code> | ||
+ | | | ||
+ | |Similar to IsDecideCancelButton. Returns 0 or a value from memory. | ||
+ | |- | ||
+ | |<code>int SwkbdIsKeyboardTarget(nn::swkbd::IEventReceiver*)</code> | ||
+ | |<code>SwkbdIsKeyboardTarget__3RplFPQ3_2nn5swkbd14IEventReceiver</code> | ||
+ | | | ||
+ | |Returns 0 or a value from memory. | ||
+ | |- | ||
+ | |<code>int SwkbdIsNeedCalcSubThreadFont()</code> | ||
+ | |<code>SwkbdIsNeedCalcSubThreadFont__3RplFv</code> | ||
+ | | | ||
+ | |Returns a value from a subroutine. | ||
+ | |- | ||
+ | |<code>bool SwkbdIsNeedCalcSubThreadPredict()</code> | ||
+ | |<code>SwkbdIsNeedCalcSubThreadPredict__3RplFv</code> | ||
+ | | | ||
+ | |Returns 1 or 0 (bool) | ||
+ | |- | ||
+ | |<code>bool SwkbdIsSelectCursorActive()</code> | ||
+ | |<code>SwkbdIsSelectCursorActive__3RplFv</code> | ||
+ | | | ||
+ | |Returns 1 or 0 (bool) | ||
+ | |- | ||
+ | |<code>int SwkbdSetControllerRemo(nn::swkbd::ControllerType)</code> | ||
+ | |<code>SwkbdSetControllerRemo__3RplFQ3_2nn5swkbd14ControllerType</code> | ||
+ | | | ||
+ | |Returns 0 or a status code from a subroutine. | ||
+ | |- | ||
+ | |<code>int SwkbdSetCursorPos(int)</code> | ||
+ | |<code>SwkbdSetCursorPos__3RplFi</code> | ||
+ | | | ||
+ | |Returns a value from a subroutine. | ||
+ | |- | ||
+ | |<code>int SwkbdSetEnableOkButton(bool)</code> | ||
+ | |<code>SwkbdSetEnableOkButton__3RplFb</code> | ||
+ | | | ||
+ | |Returns a value from a subroutine. | ||
+ | |- | ||
+ | |<code>int SwkbdSetInputFormString(wchar_t const *)</code> | ||
+ | |<code>SwkbdSetInputFormString__3RplFPCw</code> | ||
+ | | | ||
+ | |Returns a value from a subroutine | ||
+ | |- | ||
+ | |<code>int SwkbdSetReceiver(nn::swkbd::ReceiverArg const &)</code> | ||
+ | |<code>SwkbdSetReceiver__3RplFRCQ3_2nn5swkbd11ReceiverArg</code> | ||
+ | | | ||
+ | |Returns a value from a subroutine | ||
+ | |- | ||
+ | |<code>void SwkbdSetSelectFrom(int)</code> | ||
+ | |<code>SwkbdSetSelectFrom__3RplFi</code> | ||
+ | | | ||
+ | |No return value. Returns argument 1 due to lazy programming. | ||
+ | |- | ||
+ | |<code>void SwkbdSetUserControllerEventObj(nn::swkbd::IControllerEventObj*)</code> | ||
+ | |SwkbdSetUserControllerEventObj__3RplFPQ3_2nn5swkbd19IControllerEventObj</code> | ||
+ | | | ||
+ | |No return value. Returns argument 1 due to lazy programming. | ||
+ | |- | ||
+ | |<code>void SwkbdSetUserSoundObj(nn::swkbd::ISoundObj*)</code> | ||
+ | |<code>SwkbdSetUserSoundObj__3RplFPQ3_2nn5swkbd9ISoundObj</code> | ||
+ | | | ||
+ | |No return value. Returns argument 1 due to lazy programming. | ||
+ | |- | ||
+ | |<code>void SwkbdSetVersion(int)</code> | ||
+ | |<code>SwkbdSetVersion__3RplFi</code> | ||
+ | | | ||
+ | |No return value. Returns whatever OSReport returns due to lazy programming. | ||
|} | |} |
Revision as of 02:14, 29 August 2016
swkbd.rpl is the system library that allows applications to use the Wii U's on-screen keyboard. It is one of the only libraries to export C++ functions; thus it isn't known how to use them in homebrew at this point.
Functions
All the swkbd functions are C++ functions in the namespace Rpl::
. To export them with OSDynLoad, you have to use their C symbol names (as listed).
Initialisation
Prototype | Symbol name (5.5.1) | Description | Reverse-Engineering Notes |
---|---|---|---|
void SwkbdCreate(unsigned char*, nn::swkbd::RegionType, unsigned int, FSClient*)
|
SwkbdCreate__3RplFPUcQ3_2nn5swkbd10RegionTypeUiP8FSClient
|
Sets up a structure in memory | No clear return value. Will return a mutex pointer (1004D294 on 5.5.1) from memory due to lazy programming. |
void SwkbdDestroy()
|
SwkbdDestroy__3RplFv
|
No clear return value. |
Keyboard Control
Prototype | Symbol name (5.5.1) | Description | Reverse-Engineering Notes |
---|---|---|---|
int SwkbdAppearInputForm(nn::swkbd::AppearArg const &)
|
SwkbdAppearInputForm__3RplFRCQ3_2nn5swkbd9AppearArg
|
Returns 0 or a status code from a subroutine. | |
int SwkbdAppearKeyboard(nn:swkbd::KeyboardArg)
|
SwkbdAppearKeyboard__3RplFRCQ3_2nn5swkbd11KeyboardArg
|
Returns 0 or a status code from a subroutine. | |
int SwkbdDisappearInputForm()
|
SwkbdDisappearInputForm__3RplFv
|
Returns 0 or a status code from a subroutine. | |
int SwkbdDissappearKeyboard()
|
SwkbdDisappearKeyboard__3RplFv
|
Returns 0 or a status code from a subroutine. | |
void SwkbdInactivateSelectCursor()
|
SwkbdInactivateSelectCursor__3RplFv
|
Disables selection? | No clear return value. Will return a pointer to some kind of internal struct due to lazy programming. Split up over several chunks. |
int SwkbdInitLearnDic(void*)
|
SwkbdInitLearnDic__3RplFPv
|
Enables self-learning predictive text? | Returns 0 or a status code from a subroutine. |
void SwkbdMuteAllSound(bool)
|
SwkbdMuteAllSound__3RplFb
|
Writes argument 1 to an internal struct, returns argument 1 due to lazy programming. |
Logic
Prototype | Symbol name (5.5.1) | Description | Reverse-Engineering Notes |
---|---|---|---|
int SwkbdCalc(nn:swkbd::ControllerInfo const &)
|
SwkbdCalc__3RplFRCQ3_2nn5swkbd14ControllerInfo
|
Returns a value from an internal subroutine (presumably the response from the math operation). | |
int SwkbdCalcSubThreadFont(void)
|
SwkbdCalcSubThreadFont__3RplFv
|
Returns a value from an internal subroutine (presumably the response from the math operation). | |
int SwkbdCalcSubThreadPredict(void)
|
SwkbdCalcSubThreadPredict__3RplFv
|
Returns a value from an internal subroutine (presumably the response from the math operation). |
Data
Prototype | Symbol name (5.5.1) | Description | Reverse-Engineering Notes |
---|---|---|---|
void SwkbdGetDrawStringInfo(nn::swkbd::DrawStringInfo*)
|
SwkbdGetDrawStringInfo__3RplFPQ3_2nn5swkbd14DrawStringInfo
|
No clear return value. | |
int SwkbdGetInputFormString()
|
SwkbdGetInputFormString__3RplFv
|
Returns 0 or a status code from a subroutine. | |
void SwkbdGetKeyboardCondition(nn::swkbd::KeyboardCondition *)
|
SwkbdGetKeyboardCondition__3RplFPQ3_2nn5swkbd17KeyboardCondition
|
No clear return value. Split into several chunks. Makes use of a function pointer from the stack. | |
int SwkbdGetStateInputForm()
|
SwkbdGetStateInputForm__3RplFv
|
Returns 0, 1, 2, or 3. Split into several chunks. | |
int SwkbdGetStateKeyboard()
|
SwkbdGetStateKeyboard__3RplFv
|
Returns 0, 1, 2, or 3. | |
int SwkbdIsCoveredWithSubWindow()
|
SwkbdIsCoveredWithSubWindow__3RplFv
|
Returns 0 or a status code from a subroutine. | |
int SwkbdIsDecideCancelButton(bool*)
|
SwkbdIsDecideCancelButton__3RplFPb
|
Returns 0 or a value from memory. | |
int SwkbdIsDecideOkButton(bool*)
|
SwkbdIsDecideOkButton__3RplFPb
|
Similar to IsDecideCancelButton. Returns 0 or a value from memory. | |
int SwkbdIsKeyboardTarget(nn::swkbd::IEventReceiver*)
|
SwkbdIsKeyboardTarget__3RplFPQ3_2nn5swkbd14IEventReceiver
|
Returns 0 or a value from memory. | |
int SwkbdIsNeedCalcSubThreadFont()
|
SwkbdIsNeedCalcSubThreadFont__3RplFv
|
Returns a value from a subroutine. | |
bool SwkbdIsNeedCalcSubThreadPredict()
|
SwkbdIsNeedCalcSubThreadPredict__3RplFv
|
Returns 1 or 0 (bool) | |
bool SwkbdIsSelectCursorActive()
|
SwkbdIsSelectCursorActive__3RplFv
|
Returns 1 or 0 (bool) | |
int SwkbdSetControllerRemo(nn::swkbd::ControllerType)
|
SwkbdSetControllerRemo__3RplFQ3_2nn5swkbd14ControllerType
|
Returns 0 or a status code from a subroutine. | |
int SwkbdSetCursorPos(int)
|
SwkbdSetCursorPos__3RplFi
|
Returns a value from a subroutine. | |
int SwkbdSetEnableOkButton(bool)
|
SwkbdSetEnableOkButton__3RplFb
|
Returns a value from a subroutine. | |
int SwkbdSetInputFormString(wchar_t const *)
|
SwkbdSetInputFormString__3RplFPCw
|
Returns a value from a subroutine | |
int SwkbdSetReceiver(nn::swkbd::ReceiverArg const &)
|
SwkbdSetReceiver__3RplFRCQ3_2nn5swkbd11ReceiverArg
|
Returns a value from a subroutine | |
void SwkbdSetSelectFrom(int)
|
SwkbdSetSelectFrom__3RplFi
|
No return value. Returns argument 1 due to lazy programming. | |
void SwkbdSetUserControllerEventObj(nn::swkbd::IControllerEventObj*)
|
SwkbdSetUserControllerEventObj__3RplFPQ3_2nn5swkbd19IControllerEventObj | No return value. Returns argument 1 due to lazy programming. | |
void SwkbdSetUserSoundObj(nn::swkbd::ISoundObj*)
|
SwkbdSetUserSoundObj__3RplFPQ3_2nn5swkbd9ISoundObj
|
No return value. Returns argument 1 due to lazy programming. | |
void SwkbdSetVersion(int)
|
SwkbdSetVersion__3RplFi
|
No return value. Returns whatever OSReport returns due to lazy programming. |