From WikiPrizm
Revision as of 10:51, 31 July 2014 by Gbl08ma (talk | contribs) (Created page with "{{syscall | name = EditMBStringChar | header = fxcg/keyboard.h | index = 0x1224 | signature = int EditMBStringChar(unsigned char* MB_string, int posmax, int xpos, int char_to_...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search


Header: fxcg/keyboard.h
Syscall index: 0x1224
Function signature: int EditMBStringChar(unsigned char* MB_string, int posmax, int xpos, int char_to_insert)

Edits a multi-byte string according to the specified character key (where the GetKey code is lower than 30000) and cursor position. To be used in conjunction with DisplayMBString and EditMBStringCtrl.


  • MB_string - pointer to multi-byte string to edit. Must not be constant, as this syscall will modify the string contents, inserting a character.
  • posmax - maximum size, in bytes, the string can take; the size of the buffer MB_string points to should be taken into account, to avoid buffer overflows.
  • xpos - current cursor position (see the DisplayMBString cursor parameter).
  • char_to_insert -the GetKey code of the character key pressed.


The new cursor position - set the variable used on the xpos parameter to this value to advance the cursor.


This syscall is for when a character key is pressed during text editing. If the key pressed is not a character key, or in other words, if the GetKey code is equal or higher than 30000, use EditMBStringCtrl instead.