Custom keyboard
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
Custom keyboard
It is pretty easy to generate a custom keyboard for a Livecode App but is it possible to generate a custom keyboard in LiveCode for use with other Apps such as WhatsApp?
Thanks,
Tom
Thanks,
Tom
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
I doubt it as LiveCode does not seem to be able to send key commands to other applications.
Re: Custom keyboard
Although I haven't experimented with doing what your talking about, I think what you'd be looking for is the "read from process" and "write to process" commands, along with the "open Process" and "close process" to initiate the program you'd be making this keyboard for..
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
Possibly misunderstanding this . . .
Tried this:
and Audacity did not start.
Equally:
Tried this:
Code: Select all
on mouseUp
open process "/Applications/Audacity/Contents/MacOS/Audacity"
end mouseUp
Equally:
Code: Select all
on mouseUp
open process Audacity
end mouseUp
That's the LiveCode Dictionary.Note: On OS X systems, you can use the open process command to start up an application, but not a Unix process. To work with a Unix process, use the shell func instead.
Re: Custom keyboard
Dunno, here on 'nix, I used the code listed in the dictionary and applied it to Mousepad ( a text editor, I can't really see needing a 'keystroke' from your program to work on something else ).
Mousepad launched immediately through the open process command. I did *not* get as far as actually sending keystrokes, but I only had 10 minutes before I had to leave.
Maybe some of the longer timers have done something similar, and will delight us with stories of years gone by
Mousepad launched immediately through the open process command. I did *not* get as far as actually sending keystrokes, but I only had 10 minutes before I had to leave.
Maybe some of the longer timers have done something similar, and will delight us with stories of years gone by
-
- VIP Livecode Opensource Backer
- Posts: 9850
- Joined: Sat Apr 08, 2006 7:05 am
- Location: Los Angeles
- Contact:
Re: Custom keyboard
The OP mentioned WhatsApp, so I'm assuming this is for mobile. Doable, but probably not in LC Script exclusively. Will likely need hooks to lower-level APIs in the OS, which might be doable with LC Builder, depending on whether the packaging requirements for keyboards are different than for other apps.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: Custom keyboard
I'll take your assumption, and raise you a "guess your right!" Never heard of whats app, but then, I don't own or do mobile either. Just found out through the searchy thingie that it is a facebook thang, which I don't do either but, being a messenger and cross platform, I'd guess it has a desktop variation you could test with, and, if you get it working there, you *might* then package it and test it on a whatever you using thingie
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
Whatsapp (which I use to communicate with my Mum) is NOT a "facebook thang," it is an app
that belongs to a family of apps that allow voice-calls and text messages: others include
Viber, Signal, Threema, Telegram, Wire and Riot.IM.
If Whatsapp is a "facebook thang," it is only insofar as Facebook own Whatsapp.
https://en.wikipedia.org/wiki/WhatsApp
There are what are called "Whatsapp clients" for Macintosh, Windows and (unofficially) Linux.
I regularly use the Macintosh one and the Linux one as fiddling around with my muckle thumbs
on a telephone keyboard is horrible.
HOWEVER, these 'clients' can only work when your telephone is open and near to your computer
as, somehow, the work you do with the client is routed through your telephone.
that belongs to a family of apps that allow voice-calls and text messages: others include
Viber, Signal, Threema, Telegram, Wire and Riot.IM.
If Whatsapp is a "facebook thang," it is only insofar as Facebook own Whatsapp.
https://en.wikipedia.org/wiki/WhatsApp
There are what are called "Whatsapp clients" for Macintosh, Windows and (unofficially) Linux.
I regularly use the Macintosh one and the Linux one as fiddling around with my muckle thumbs
on a telephone keyboard is horrible.
HOWEVER, these 'clients' can only work when your telephone is open and near to your computer
as, somehow, the work you do with the client is routed through your telephone.
I wonder who is going to be the next person to be accused of being snide and sarcastic?I'd guess it has a desktop variation you could test with, and, if you get it working there, you *might* then package it and test it on a whatever you using thingie
Re: Custom keyboard
I am also going to assume the OP wants a custom keyboard for typing into mobile apps. (Although desktop clients are available, it is a more typical use-case on mobile. Plus, what sort of custom keyboard would you program in LC for a desktop app?) Presumably if that's the case (mobile) then sandboxing would be another barrier if the keyboard was created and installed just as a basic LiveCode app.
I would guess you would need to install and register the app as a keyboard in the device settings. I wonder if that is possible under LCB hooking into low level APIs as Richard said.
I would guess you would need to install and register the app as a keyboard in the device settings. I wonder if that is possible under LCB hooking into low level APIs as Richard said.
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
That strange Scottish person who lives in Bulgaria would love to, so that end-users could use his Devawriter Pro to typewhat sort of custom keyboard would you program in LC for a desktop app?
directly into something like a LibreOffice Writer document . . . .
Re: Custom keyboard
richmond62 wrote: ↑Thu Nov 07, 2019 8:43 amWhatsapp (which I use to communicate with my Mum) is NOT a "facebook thang,"
You make an interesting distinction on when to consider something to be something else. My take, no matter *how* it started out or *what* it is used for, IF company xyz owns it, it is a company xyz thang. I don't know how you could see it as anything else.richmond62 wrote: ↑Thu Nov 07, 2019 8:43 amIf Whatsapp is a "facebook thang," it is only insofar as Facebook own Whatsapp.
It is a messenger? OK, then it is currently a facebook messenger service. Yahoo had one. Aim had one. Microsoft had one, then bought someone elses and, from all I understand, mostly killed off some of the spectacular parts of it. And there are a ton of devs that have made multi-tool versions that can tie into those hosted platforms, as well as others.
I've already been. For what it is worth, in the last thread where you were taken to be, I thought the poster was WAY out of line. From what I read, your answers looked to be generously helpful. I can't imagine how they were bent to be sarcastic, unlike many posts where you seem to go out of your way to bend the nail.richmond62 wrote: ↑Thu Nov 07, 2019 8:43 amI wonder who is going to be the next person to be accused of being snide and sarcastic?I'd guess it has a desktop variation you could test with, and, if you get it working there, you *might* then package it and test it on a whatever you using thingie
Myself, I never claimed not to be sarcastic, and on occasion my nickname might be changed to "Snidely Whiplash", I just try to not make it mean spirited snide sarcasm, despite my 'twisted-evil' smile
Heck, just a few posts back, RG thought I was tracking his posts down just to harangue him. Purely my fault, for not finding a better way to express myself.
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
Well:Heck, just a few posts back
1. Some people, let's call them the "meThree" people, are just looking for something to justify some of their own behaviour.
2. Some people are just plain ungrateful for help when it is offered: especially when it does not either:
2.1. solve their problem straight away.
2.2. does not fit their preconceptions as to what constitutes help.
3. Those people who start going on about 'snide' and 'sarcastic' should go away and take a course in reader-response theory.
I DO often make a point of trying "to bend the nail" (a lovely turn of phrase I have never come across before) because, sometimes,I can't imagine how they were bent to be sarcastic, unlike many posts where you seem to go out of your way to bend the nail.
I feel "the nail" has got a bit too set in its way, and those ways are not helping: and, as we all know, it takes a blacksmith with
a socking great hammer to "bend the nail." The fact that when I do attempt "to bend the nail" (Wow: I can't get enough of that phrase),
there is often a violent "blowback" could be taken as a signal that I have touched the nerve I set out to touch.
Of course, having successfully made a name for myself as "Sh*t-stirrer #1," that sh*t sticks under all circumstances, especially
in the minds of people not given to subtle thinking.
AND, this has got nothing to do whatsoever with custom keyboards, so let's stop "all this" at this point, and get back on-topic.
Last edited by richmond62 on Thu Nov 07, 2019 11:14 am, edited 1 time in total.
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
Quite possibly.no matter *how* it started out or *what* it is used for, IF company xyz owns it, it is a company xyz thang
What I would understand by a "facebook thang" is that, quite apart from being owned by Facebook, it was also,
in some way linked to Facebook: i.e. sharing data or somesuch.
Re: Custom keyboard
That part usually comes shortly after acquisition of said thang and either the firing or making the work place for the previous crew so horribly unbearable to them that they are all replaced by properly indoctrinated replacements who properly reflect the companies core values (or lack of any thereof).richmond62 wrote: ↑Thu Nov 07, 2019 11:08 amWhat I would understand by a "facebook thang" is that, quite apart from being owned by Facebook, it was also,
in some way linked to Facebook: i.e. sharing data or somesuch.
Since for all intents and purposes FB is a data gathering and exploiting company, I am sure it will not take long for them to make this a fine addition to their list of tools for doing such, if they haven't started already (but I believe there were some stories indicating they already had started).
*Edit - as far as lumping people into groups, I try to avoid it as it is counterproductive in almost all cases. All I can do is control my own input/output, so I adjust that, but the rest I take at face value for the most part.
-
- Livecode Opensource Backer
- Posts: 9445
- Joined: Fri Feb 19, 2010 10:17 am
- Location: Bulgaria
Re: Custom keyboard
My Devawriter Pro uses a custom font with about 5,000 glyphs in the Personal Private Use Area
(Wow: doesn't "Personal Private Use Area" sound like somewhere you go and do unmentionably
private things with your partner(s) of choice: 'kinky b*ggers' those Unicode people, obviously)
that are then "strained" through monster SWITCH statements inwith my program.
To effect the same with specialised keyboard drivers/layouts (and, of course, all
different for every platform) would be a serious uphill struggle that seems hardly
justified.
So, if there were a way that one could send the end results of all those monster SWITCH statements
directly to word-processing apps that would be amazing.
(Wow: doesn't "Personal Private Use Area" sound like somewhere you go and do unmentionably
private things with your partner(s) of choice: 'kinky b*ggers' those Unicode people, obviously)
that are then "strained" through monster SWITCH statements inwith my program.
To effect the same with specialised keyboard drivers/layouts (and, of course, all
different for every platform) would be a serious uphill struggle that seems hardly
justified.
So, if there were a way that one could send the end results of all those monster SWITCH statements
directly to word-processing apps that would be amazing.