tmc2 hacks

2021-12-27 Thread Mike Kerner via use-livecode
tmc2 still gives me better ui's than native widgets do.
i have been messing with it for a while, including experimenting with
breaking it into SOS's to see if i can get it to play nicely with levure.
today's conversation about keyboards on mobile reminded me that it would be
good to add some of those properties.
has anyone else been modding/hacking tmc2?
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode


Re: (area used by) Keyboard in iOS 15.x

2021-12-27 Thread Mark Smith via use-livecode
Thank you Sean and Jacque, 

I’ve not had a chance to work on a complete solution but thought I would make a 
test run to see what “the effective working screenrect” was returning and as 
the following indicates, it does in fact take into consideration the keyboard. 
I just coded up one line to  run whenever the status of the keyboard changed 
and tried it both with and without the “predictive” option turned on. As you 
can see, it was very sensitive to this change…

without predictive:

9:37:14 PM keyboardActivated 0,0,375,451
9:37:15 PM keyboardDeactivated 0,0,375,667
9:37:18 PM keyboardActivated 0,0,375,451
9:37:19 PM keyboardDeactivated 0,0,375,667
9:37:19 PM keyboardActivated 0,0,375,451
9:37:23 PM keyboardDeactivated 0,0,375,667


with predictive: 

9:56:54 PM keyboardActivated 0,0,375,407
9:56:55 PM keyboardDeactivated 0,0,375,667
9:56:55 PM keyboardActivated 0,0,375,407
9:56:57 PM keyboardDeactivated 0,0,375,667

In my particular case not all 4 value are immediately useful. For example, I 
have a fixed header and footer that need to be accommodated so the correct 
“useable” rect for me is:

0,69, 377, 618 (for no predictive)
0,69,377,456 ( for predictive)

but this can easily be accommodated since the header/footer values don’t 
change. The beauty is I now have a rect lower bound (ie. keyboard height) that 
actually reflects where the keyboard is. 

Brilliant!! Thank you both,

Mark

Sean, I tried iPhoneSafeAreaInsets() but it appears it returns a constant set 
of values regardless of keyboard position on my iPhone 12

11:51:22 AM keyboardActivated 0,47,0,34
11:51:22 AM keyboardDeactivated 0,47,0,34
11:51:26 AM keyboardActivated 0,47,0,34
11:51:26 AM keyboardDeactivated 0,47,0,34

And didn’t change when I added / subtracted “predictive”. So, just the 
available usable space at the top and bottom of the screen. I haven’t adjusted 
my app yet to fully take advantage of the larger screen on a 12 (it was 
developed on a 6S) but when I get to more response design this will be useful 
to know where the usable top and bottom are. 

Cheers!!







> On Dec 25, 2021, at 5:25 PM, Sean Cole via use-livecode 
>  wrote:
> 
> Another addendum to this I just noticed is in the latest RC, LC9.6.6RC1,
> which has iphoneSafeAreaInsets for discerning the safe area from furniture
> like the notch and so on. I haven't tested this but that may also include
> things like the keyboard and predictive areas. I just thought it was worth
> a mention here.
> 
> Regards
> Sean
> 
> On Fri, 24 Dec 2021 at 20:44, J. Landman Gay via use-livecode <
> use-livecode@lists.runrev.com> wrote:
> 
>> On 12/24/21 2:16 PM, Sean Cole via use-livecode wrote:
>>> Just adding to what Jacquie wrote, there is also the effective working
>>> screenrect.
>> 
>> You're right, "effective" was added to account for the keyboard on mobile.
>> I'd start with that.
>> 
>> --
>> Jacqueline Landman Gay | jac...@hyperactivesw.com
>> HyperActive Software   | http://www.hyperactivesw.com
>> 
>> ___
>> use-livecode mailing list
>> use-livecode@lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>> 
> ___
> use-livecode mailing list
> use-livecode@lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription 
> preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode

___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode