Grrr...
Rick Murray (539) 13429 posts |
I’m writing something that needs access to the keyboard. Given there are plenty of alternative keypresses in the upper function key range (the one that sends 0,keycode), by what bizarre logic is CursorUp and Shift-PageUp the same code? (and likewise Shift-CursorUp and PageUp; likewise again for Down/PageDown). |
Steve Pampling (1551) 7961 posts |
When the focus is with your application or with the desktop? Asking because the desktop currently has very few active keypress actions (unless you run QuickFiler) and it’s something that needs remedying to match the RO4.x stream. I’ve done a few twiddles so far and then got busy at work, then recently started looking again.
Yeah, I mapped out all the combinations – damned if I can find the printout at the moment – but some of the duplications are a pain. |
Rick Murray (539) 13429 posts |
Running outside of the desktop world. |
Steve Fryatt (216) 2053 posts |
Enforcing the Style Guide, isn’t it? Developers were told that they would make those groups keys do the same things, so it just saved them testing for the different codes… |
Rick Murray (539) 13429 posts |
Hmmm. There’s Acorn being different again. Up – go up a line |
Steve Pampling (1551) 7961 posts |
Rick, if you work on the basis that the Style Guide was to produce some uniformity then you have to consider “uniformity with what?” We’ve already got alterations in the general text input/editing area that are changed from Acorn days to something more standard. Maybe it’s heresy, but maybe the Style Guide is wrong. |
Steve Fryatt (216) 2053 posts |
At the time, uniformity between RISC OS applications. As far as I can remember, RISC OS has always paired these keys, so that takes us back to 1989 at the latest. At that time, was there a dominant other platform to standardise with? My guess is that Acorn looked back to Arthur, and beyond that back to whichever BBC Micro applications they favoured at the time. We’ve already got alterations in the general text input/editing area that are changed from Acorn days to something more standard. First, we’re talking about the original Style Guide. The modern one has changed in some areas for precisely these reasons. However, you’re forgetting that in this case Rick is taking issue with the behaviour of the Wimp Key_Pressed event. Changing the Style Guide won’t fix that, and changing the Wimp’s behaviour will break a lot of stuff that’s expecting that behaviour. The only sensible way out is to make the behaviour of these keys depend on a flag passed to Assuming that we want the change, of course. PS. Doesn’t Impression already do Shift- whatever to change the selection? If so, what does it do about the ambiguous codes? |
Steve Pampling (1551) 7961 posts |
Exactly, but now the dominant platform(s) tend to have usage at odds with our available one. Let’s make a few changes, deliberate dissimilarity doesn’t help.
and probably need more alteration. Or is that modernisation?
It might be interesting to check how much 32 bit compatible stuff does rely on such things. It may well be that the stuff using those keypress combinations actually got broken a number of years ago.
Hmm, now you’re into the realms of stuff that got broken by the 32 bit change and Impression-X isn’t finished yet. |
Rick Murray (539) 13429 posts |
Steve:
It would have originated with Arthur as Acorn tried to figure out how to bodge these additional keys (Page Up and Page Down, for instance) into the BBC-like keyboard handling. I had a hunch that Acorn just cheaped out, so I downloaded the VIEW user guide, and the proof is right there on page 5: When used with the SHIFT key […] the vertical arrow keys cause it [the cursor] to jump the height of the screen, up or down.
Actually, I’m very much NOT. I’m talking about OS_Byte 129. It’s broken at low level, I rather suspect the Wimp just copies the behaviour instead of trying to sort out the mess.
Probably not – but doesn’t it strike you as stupid that we get different keycodes from each of the two WinLogo keys, but can’t tell Shift-Up from PageUp?
Probably what I’m going to do. Look and see if Shift is held. If it is, it’s a cursor. If it isn’t, it’s Page. With a lot of dumb farting around for the various permutations. Other Steve (!):
We’re the minority and most of the world that isn’t Apple have settled on a fairly regular set of key behaviours; and Apple is broadly similar if different for the sake of it because, well, because they’re Apple… |
Steve Pampling (1551) 7961 posts |
Frankly, Apple are arrogant tossers1. When I mentioned dominant use I meant windows/Linux. In Acorn desktop use backspace opening the previous directory and insert (or perhaps ^D) to create a new directory at the current. 1 Example: Read the Apple version of the firewall ports needing to be open outbound and inbound and the IP range you need for the communication to-from Apple. Then research a little about what you really need. Apple = 2 million IP’s, reality 1 IP. Same rubbish in the ports. |
Rick Murray (539) 13429 posts |
I won’t argue that. My UK layout keyboard has the " with ’ and @ over 2. Why? What were you saying about arogant American tossers?
Not really. Ctrl held? It’s ^H. Ctrl not held? It’s Delete. Don’t get me started on Apple’s IP addresses. Something within iOS dumps cookies that end up listed with all the normal site cookies. So many flamin’ Apple addresses it isn’t funny. |
Steve Pampling (1551) 7961 posts |
It’s an old conversation, but looking at what the Americans have and use and what the UK has and uses I fail to see why the Americans retain a less optimal keyboard.
Not quite sure what you were saying there: ^H = Ctrl-H which because of the keycodes in ASCII terms is the same as that generated by the Del key. On my Filer that means that Shift-Del will cause TrapDelete to permanently delete the item and a plain Del to move it into the designated recycle-bin directory. |