Modifier Keys?

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

SparkOut
Posts: 2943
Joined: Sun Sep 23, 2007 4:58 pm

Re: Modifier Keys?

Post by SparkOut » Thu Jul 17, 2025 7:49 pm

richmond62 wrote:
Thu Jul 17, 2025 6:43 pm
and how would ctrl-alt-shift + key go down with Windows users?
Personally, I would say likely better than using Shift Lock.
But, what's the target user? Is it a user of non Roman alphabets (eg your Devawriter user base)? Or more of a Unicode power user tinkering with the character sets?
Either way, I think if you stated what the complications are, they would understand, and appreciate your efforts to make things as simple as possible. Depending on who it is you're writing this for might give you priorities in one direction over another.
Perhaps one modifier key could have a choice of actions, and an on screen button in the user interface coukd toggle between those choices?
Maybe "all the options at once" is a step too far? I think in the circumstances of what you're trying to achieve, most people would forgive a little extra required effort for the least frequently chosen options.

dunbarx
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 10305
Joined: Wed May 06, 2009 2:28 pm

Re: Modifier Keys?

Post by dunbarx » Thu Jul 17, 2025 9:47 pm

Richmond.

Calm down. :shock:

There are four "no-lock" control keys. That is six two-key combinations. You have five discrete needs. So, what am I missing?

Craig

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10080
Joined: Fri Feb 19, 2010 10:17 am

Re: Modifier Keys?

Post by richmond62 » Fri Jul 18, 2025 6:34 am

To start with I am not 'calmed up'. 8)

But several folk round these parts have started frothing at the mouth re using the capslock key as a modifier, and I can see why.

Hav8ng tried it myself I am aware of its shortcomings.

Oh, and re using ShiftLock: as I have no computrler built after 1989 woth that key it really cannot be considered. :D

So, Craig, it would be a great service if you could tell me those 6 2-key combinations.

stam
Posts: 3061
Joined: Sun Jun 04, 2006 9:39 pm

Re: Modifier Keys?

Post by stam » Fri Jul 18, 2025 9:24 am

richmond62 wrote:
Fri Jul 18, 2025 6:34 am
So, Craig, it would be a great service if you could tell me those 6 2-key combinations.
Weird how many here complain when newbies ask to be spoonfed code, but a simple question as to how you derive 6 pairs from 3 elements is an actual question.

The three elements:
shift key
alt (win) / option (Mac) key
powerkey (windows key, command key)

Basic combinations:
powerkey + shift
powerkey + alt
powerkey + ctrl
shift + ctrl
shift + alt
alt + ctrl

Not that hard.

And I'll re-iterate that 3 key combos (typically powerkey+alt+shift) are present in many apps on both Mac and Win (usually graphics apps where there are large number of menu commands mapped to key combos), so you have at least 4 more:
powerkey + alt + ctrl
powerkey + alt + shirt
powerkey + ctrl + shift
alt + ctrl + shift

And I have also used apps that use all 4: powerkey + alt + ctrl + shift.

I have not used any app ever that includes caps lock in a key combination.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10080
Joined: Fri Feb 19, 2010 10:17 am

Re: Modifier Keys?

Post by richmond62 » Fri Jul 18, 2025 10:59 am

Thank you.

I tried Capslock and was not happy with that, hence . . .

AND the reason I was having a prob. with '6' was I have always felt the powerkey/command was 'off'.

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10080
Joined: Fri Feb 19, 2010 10:17 am

Re: Modifier Keys?

Post by richmond62 » Sat Jul 19, 2025 2:36 pm

I have tried all the 2 modifier keys combos I have not used, and they do NOT work, so:
-

Code: Select all

 if ctrlKey() is down and shiftkey() is down and altKey() is down then
      put numToCodePoint(122966) after fld "OOT"
      exit mouseUp
   end if
   if altKey() is down and shiftKey() is down then
      put numToCodePoint(122933) after fld "OOT"
      exit mouseUp
   end if
   if altKey() is down then
      put numToCodePoint(11767) after fld "OOT"
   else
      if shiftkey() is up then
         put numToCodePoint(1077) after fld "OOT"
      else
         if shiftkey() is down then
            put numToCodePoint(1045) after fld "OOT"
         end if
      end if
   end if
Like it or not:

if ctrlKey() is down and shiftkey() is down and altKey() is down then

richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 10080
Joined: Fri Feb 19, 2010 10:17 am

Re: Modifier Keys?

Post by richmond62 » Sat Jul 19, 2025 3:07 pm

Screenshot 2025-07-19 at 17.06.16.png

Post Reply