[Development] QPlatformInputContext needs more informations

BogDan bog_dan_ro at yahoo.com
Mon Apr 16 10:17:07 CEST 2012


> From: Samuel Rødal <samuel.rodal at nokia.com>

> To: development at qt-project.org
> Cc: 
> Sent: Monday, April 16, 2012 10:48 AM
> Subject: Re: [Development] QPlatformInputContext needs more informations
> 
> On 04/14/2012 09:26 PM, ext BogDan wrote:
>>>  From: "lars.knoll at nokia.com" <lars.knoll at nokia.com>
>> 
>>>  To: bog_dan_ro at yahoo.com; development at qt-project.org
>>>  Cc: 
>>>  Sent: Saturday, April 14, 2012 9:40 PM
>>>  Subject: Re: [Development] QPlatformInputContext needs more 
> informations
>>> 
>>> 
>>>  On 4/14/12 8:29 PM, "ext BogDan" <bog_dan_ro at yahoo.com> 
> wrote:
>>> 
>>>>  Hello,
>>>> 
>>>>  I checked QPlatformInputContext interface and I think it needs more
>>>>  informations
>>> 
>>>  Not sure what you're missing. QPlatformInputContext is only there 
> to
>>>  implement support for an input method, and has received quite some 
> testing.
>>> 
>> 
>>  In order to be sure the user sees the entire control and its content I need 
> to know
>>  the control position and its size, otherwise the virtual keyboard may cover 
> the 
>>  control and its content.
> 
> Isn't that what QPlatformInputContext::keyboardRect() is for?
> 

On Android platform the keyboard rect is unknown, because is an external service.
The only way to be sure the user will see the entire control and its content,
is to create a dummy transparent Android native widget in the same position and 
with the same size as the qt control, I pass that widget to the keyboard service, 
then the Android window manager will do the magic for me, it will pan the screen or 
it will resize it if necessary.
Please check the video I posted on youtube [1].

BogDan.

[1] http://www.youtube.com/watch?v=qX157pS64BA



More information about the Development mailing list