include/SDL_keyboard.h
changeset 6654 2ecfb25be1e2
parent 6392 fa7eb111f994
child 6820 0ce561f6c805
     1.1 --- a/include/SDL_keyboard.h	Sun Nov 04 20:20:53 2012 -0800
     1.2 +++ b/include/SDL_keyboard.h	Sun Nov 04 21:53:28 2012 -0800
     1.3 @@ -151,21 +151,34 @@
     1.4  
     1.5  /**
     1.6   *  \brief Start accepting Unicode text input events.
     1.7 + *         This function will show the on-screen keyboard if supported.
     1.8   *  
     1.9   *  \sa SDL_StopTextInput()
    1.10   *  \sa SDL_SetTextInputRect()
    1.11 + *  \sa SDL_HasScreenKeyboardSupport()
    1.12   */
    1.13  extern DECLSPEC void SDLCALL SDL_StartTextInput(void);
    1.14  
    1.15  /**
    1.16 + *  \brief Return whether or not Unicode text input events are enabled.
    1.17 + *
    1.18 + *  \sa SDL_StartTextInput()
    1.19 + *  \sa SDL_StopTextInput()
    1.20 + */
    1.21 +extern DECLSPEC SDL_bool SDLCALL SDL_IsTextInputActive(void);
    1.22 +
    1.23 +/**
    1.24   *  \brief Stop receiving any text input events.
    1.25 + *         This function will hide the on-screen keyboard if supported.
    1.26   *  
    1.27   *  \sa SDL_StartTextInput()
    1.28 + *  \sa SDL_HasScreenKeyboardSupport()
    1.29   */
    1.30  extern DECLSPEC void SDLCALL SDL_StopTextInput(void);
    1.31  
    1.32  /**
    1.33   *  \brief Set the rectangle used to type Unicode text inputs.
    1.34 + *         This is used as a hint for IME and on-screen keyboard placement.
    1.35   *  
    1.36   *  \sa SDL_StartTextInput()
    1.37   */
    1.38 @@ -174,60 +187,13 @@
    1.39  /**
    1.40   *  \brief Returns whether the platform has some screen keyboard support.
    1.41   *  
    1.42 - *  \param window The window for which screen keyboard should be checked.
    1.43 - *  
    1.44   *  \return SDL_TRUE if some keyboard support is available else SDL_FALSE.
    1.45   *  
    1.46   *  \note Not all screen keyboard functions are supported on all platforms.
    1.47   *  
    1.48 - *  \sa SDL_ShowScreenKeyboard()
    1.49 - *  \sa SDL_HideScreenKeyboard()
    1.50 - *  \sa SDL_IsScreenKeyboardShown()
    1.51 - *  \sa SDL_ToggleScreenKeyboard()
    1.52 - */
    1.53 -extern DECLSPEC SDL_bool SDLCALL SDL_HasScreenKeyboardSupport(SDL_Window *window);
    1.54 -
    1.55 -/**
    1.56 - *  \brief Requests to show a screen keyboard for given window.
    1.57 - *  
    1.58 - *  \param window The window for which screen keyboard should be shown.
    1.59 - *  
    1.60 - *  \return 0 if request will be processed or -1 on error (e.g. no support).
    1.61 - *  
    1.62 - *  \note Showing screen keyboards is asynchronous on some platforms.
    1.63 - *  
    1.64 - *  \sa SDL_HasScreenKeyboardSupport()
    1.65 - *  \sa SDL_HideScreenKeyboard()
    1.66 - */
    1.67 -extern DECLSPEC int SDLCALL SDL_ShowScreenKeyboard(SDL_Window *window);
    1.68 -
    1.69 -/**
    1.70 - *  \brief Requests to hide a screen keyboard for given window.
    1.71 - *  
    1.72 - *  \param window The window for which screen keyboard should be shown.
    1.73 - *  
    1.74 - *  \return 0 if request will be processed or -1 on error (e.g. no support).
    1.75 - *  
    1.76 - *  \note Hiding screen keyboards is asynchronous on some platforms.
    1.77 - *  
    1.78 - *  \sa SDL_HasScreenKeyboardSupport()
    1.79 - *  \sa SDL_ShowScreenKeyboard()
    1.80 - */
    1.81 -extern DECLSPEC int SDLCALL SDL_HideScreenKeyboard(SDL_Window *window);
    1.82 -
    1.83 -/**
    1.84 - *  \brief Requests to toggle a screen keyboard for given window.
    1.85 - *  
    1.86 - *  \param window The window for which screen keyboard should be toggled.
    1.87 - *  
    1.88 - *  \return 0 if request will be processed or -1 on error (e.g. no support).
    1.89 - *  
    1.90 - *  \note Showing and hiding screen keyboards is asynchronous on some platforms.
    1.91 - *  
    1.92 - *  \sa SDL_HasScreenKeyboardSupport()
    1.93   *  \sa SDL_IsScreenKeyboardShown()
    1.94   */
    1.95 -extern DECLSPEC int SDLCALL SDL_ToggleScreenKeyboard(SDL_Window * window);
    1.96 +extern DECLSPEC SDL_bool SDLCALL SDL_HasScreenKeyboardSupport();
    1.97  
    1.98  /**
    1.99   *  \brief Returns whether the screen keyboard is shown for given window.
   1.100 @@ -236,11 +202,7 @@
   1.101   *  
   1.102   *  \return SDL_TRUE if screen keyboard is shown else SDL_FALSE.
   1.103   *  
   1.104 - *  \note May always return SDL_FALSE on some platforms (not implemented there).
   1.105 - *  
   1.106   *  \sa SDL_HasScreenKeyboardSupport()
   1.107 - *  \sa SDL_ShowScreenKeyboard()
   1.108 - *  \sa SDL_HideScreenKeyboard()
   1.109   */
   1.110  extern DECLSPEC SDL_bool SDLCALL SDL_IsScreenKeyboardShown(SDL_Window *window);
   1.111