|
OldSchool Library
|
Data Structures | |
| struct | OSL_KEYBOARD |
| Structure representing the on-screen keyboard (OSK) parameters. More... | |
Macros | |
| #define | OSL_OSK_RESULT_UNCHANGED PSP_UTILITY_OSK_RESULT_UNCHANGED |
| Indicates that the OSK result is unchanged. | |
| #define | OSL_OSK_RESULT_CANCELLED PSP_UTILITY_OSK_RESULT_CANCELLED |
| Indicates that the OSK operation was cancelled. | |
| #define | OSL_OSK_RESULT_CHANGED PSP_UTILITY_OSK_RESULT_CHANGED |
| Indicates that the OSK result has changed. | |
| #define | OSL_OSK_CANCEL PSP_UTILITY_OSK_RESULT_CANCELLED |
| OSK cancel result. | |
| #define | OSL_OSK_CHANGED PSP_UTILITY_OSK_RESULT_CHANGED |
| OSK changed result. | |
| #define | OSL_OSK_UNCHANGED PSP_UTILITY_OSK_RESULT_UNCHANGED |
| OSK unchanged result. | |
Functions | |
| OSL_KEYBOARD * | oslInitOskEx (int nData, int language) |
| Initializes the on-screen keyboard with specified parameters. | |
| int | oslInitOskDataEx (OSL_KEYBOARD *kbd, int idx, unsigned short *desc, unsigned short *intext, int textLimit, int linesNumber) |
| Initializes specific OSK data. | |
| int | oslActivateOskEx (OSL_KEYBOARD *kbd, int waitcycle) |
| Activates the on-screen keyboard. | |
| int | oslOskIsActiveEx (OSL_KEYBOARD *kbd) |
| Checks if the on-screen keyboard is active. | |
| void | oslDeActivateOskEx (OSL_KEYBOARD *kbd) |
| Deactivates the on-screen keyboard. | |
| int | oslOskGetResultEx (OSL_KEYBOARD *kbd, int idx) |
| Gets the result of the on-screen keyboard interaction. | |
| unsigned short * | oslOskOutTextEx (OSL_KEYBOARD *kbd, int idx) |
| Retrieves the text output from the on-screen keyboard. | |
| void | oslEndOskEx (OSL_KEYBOARD *kbd) |
| Ends the on-screen keyboard session and releases resources. | |
| void | oslInitOsk (char *descStr, char *initialStr, int textLimit, int linesNumber, int language) |
| Initializes the OSK with basic parameters. | |
| void | oslDrawOsk () |
| Draws the OSK on the screen. | |
| int | oslOskIsActive () |
| Checks if the OSK is currently active. | |
| int | oslGetOskStatus () |
| Returns the current OSK status. | |
| int | oslOskGetResult () |
| Returns the result of the OSK interaction. | |
| void | oslOskGetText (char *text) |
| Retrieves the text inserted by the user in the OSK. | |
| void | oslOskGetTextUCS2 (unsigned short *text) |
| Retrieves the text inserted by the user in the OSK (UCS2). | |
| void | oslEndOsk () |
| Ends the OSK session. | |
Variables | |
| OSL_KEYBOARD * | osl_osk |
| Global instance of the on-screen keyboard. | |
Functions to display Sony's On Screen Keyboard.
| #define OSL_OSK_RESULT_UNCHANGED PSP_UTILITY_OSK_RESULT_UNCHANGED |
Indicates that the OSK result is unchanged.
This macro maps to PSP_UTILITY_OSK_RESULT_UNCHANGED, which is used to indicate that the user did not modify the text in the On-Screen Keyboard.
| #define OSL_OSK_RESULT_CANCELLED PSP_UTILITY_OSK_RESULT_CANCELLED |
Indicates that the OSK operation was cancelled.
This macro maps to PSP_UTILITY_OSK_RESULT_CANCELLED, which is used to indicate that the user cancelled the On-Screen Keyboard without making changes.
| #define OSL_OSK_RESULT_CHANGED PSP_UTILITY_OSK_RESULT_CHANGED |
Indicates that the OSK result has changed.
This macro maps to PSP_UTILITY_OSK_RESULT_CHANGED, which is used to indicate that the user modified the text in the On-Screen Keyboard.
| #define OSL_OSK_CANCEL PSP_UTILITY_OSK_RESULT_CANCELLED |
OSK cancel result.
|
extern |
Initializes the on-screen keyboard with specified parameters.
| nData | Number of data entries to initialize. |
| language | Language of the on-screen keyboard. |
|
extern |
Initializes specific OSK data.
| kbd | Pointer to the OSL_KEYBOARD structure. |
| idx | Index of the data entry. |
| desc | Description text (UTF-16). |
| intext | Initial text input (UTF-16). |
| textLimit | Maximum number of characters. |
| linesNumber | Number of lines for input. |
|
extern |
Activates the on-screen keyboard.
| kbd | Pointer to the OSL_KEYBOARD structure. |
| waitcycle | Time to wait before the OSK is fully activated. |
|
extern |
Checks if the on-screen keyboard is active.
| kbd | Pointer to the OSL_KEYBOARD structure. |
|
extern |
Deactivates the on-screen keyboard.
| kbd | Pointer to the OSL_KEYBOARD structure. |
|
extern |
Gets the result of the on-screen keyboard interaction.
| kbd | Pointer to the OSL_KEYBOARD structure. |
| idx | Index of the data entry. |
|
extern |
Retrieves the text output from the on-screen keyboard.
| kbd | Pointer to the OSL_KEYBOARD structure. |
| idx | Index of the data entry. |
|
extern |
Ends the on-screen keyboard session and releases resources.
| kbd | Pointer to the OSL_KEYBOARD structure. |
| void oslInitOsk | ( | char * | descStr, |
| char * | initialStr, | ||
| int | textLimit, | ||
| int | linesNumber, | ||
| int | language | ||
| ) |
Initializes the OSK with basic parameters.
| descStr | Text shown as a description (bottom right corner). |
| initialStr | Initial text in the OSK. |
| textLimit | Maximum number of characters. |
| linesNumber | Number of lines. |
| language | Language for the OSK.
|
| void oslDrawOsk | ( | ) |
Draws the OSK on the screen.
After drawing it, you should check if the user has closed it. Remember to call oslEndOsk to properly terminate the OSK.
| int oslOskIsActive | ( | ) |
Checks if the OSK is currently active.
| int oslGetOskStatus | ( | ) |
Returns the current OSK status.
| int oslOskGetResult | ( | ) |
Returns the result of the OSK interaction.
| void oslOskGetText | ( | char * | text | ) |
Retrieves the text inserted by the user in the OSK.
| text | Pointer to the buffer where the text will be stored (UTF-8). |
| void oslOskGetTextUCS2 | ( | unsigned short * | text | ) |
Retrieves the text inserted by the user in the OSK (UCS2).
| text | Pointer to the buffer where the text will be stored (UTF-16). |
| void oslEndOsk | ( | ) |
Ends the OSK session.
This function should be called after the OSK is closed to clean up resources.