TaskWindow could do with some improvement
Pages: 1 2
Steve Pampling (1551) 8170 posts |
It’s weird that there’s an OS call to read the mouse position and button status (OS_Mouse) but there’s no matching means to write the same parameters. I think most people could put together an extensive list quite quickly. I will quote a wiser person than me “It’s missing functionality.” |
Rick Murray (539) 13840 posts |
Oh yes. Question is – if ten people made a list, would there be overlap or just a large number of irritations? |
Steve Pampling (1551) 8170 posts |
Two questions for you
|
Rick Murray (539) 13840 posts |
My big two, enough to be getting on with, are:
Depends upon the thing. Right click switcher to config, boost IIC speed, etc – yes those are source tweaks. But some stuff I’d like would require a new API (and everybody else to be using such). |
Steve Pampling (1551) 8170 posts |
Some add-ons actually utilised1 the International Keyboard elements and generated new keyboard maps in order to use some relatively simple key combinations. Others did things a little differently like DeepKeys
Read but not set, you see you are but a user and of no great importance unless you know the mystic incantations. 1 Past tense because they tend to be 26bit. |
nemo (145) 2546 posts |
Ahem Deepkeys ahem.
UTF-8 is always sent byte-by-byte. :-) Amusingly, the Wimp uses an internal UCS-32 format when operating in UTF-8 mode, so it’s forever transcoding back and forth between the two. I’m sure you would want that exposed via Wimp_Poll if you’d Initialised with an appropriate version number, but that would require fixing the keypress queuing code which, oh yes, I did just the other day… and absolutely no one was even slightly interested. However, the reality of RISC OS’s patchwork nature is that it is impossible to work entirely in UCS-32 – it’s too ambiguous. For example, a program might do the equivalent of You can arrange for something else to do the translation to and from a 32bit representation, but that has to be through separate interfaces – WrchV, InsV, RemV etc HAVE to stay resolutely non-UCS-32. UTF-8 does make some things (a little) more work… but the hard reality is that Unicode makes things a lot more work, and if people can’t cope with the first bit they’re definitely not going to do the second. |
Rick Murray (539) 13840 posts |
A third party module to patch deficiencies in the OS. Now that source is available, I’m awaiting the crowds of code warriors to ride in upon their pretty multicoloured unicorns to help fix the stuff that’s been varying degrees of facepalm for decades.
But not as separate keypress events!
Just like VB5/VB6 (UTF16 internally, calls ANSI API, WTF?).
I must have missed that. Did you submit a patch?
Do you remember the other day I wrote Wapuro Romaji with the macrons over the letters? Okay. I used MoreKeys to get access to the characters, but… Write some of the message. It’s ridiculous that keyboard handling in the Wimp is so broken that you can’t send a character code that you know the app can cope with without switching alphabet to be able to send it. Or maybe… It’s ridiculous that text handling in the Wimp is so broken that you can’t just set the system to UTF-8 and have the Wimp do something sensible for older apps. Because unfortunately UTF-8 and Latin1 are about as compatible as IPv4 and IPv6 once you leave basic English characters. But, wait, that’s another argument too. ;-)
I’d settle for UTF-8. I don’t expect miracles. |
Steve Pampling (1551) 8170 posts |
Quite a few people are interested in such things, but it’s sometimes difficult to track. I think you need to put together a diary noting what was fixed or added when. 1 Nemo standard operating mode = hyper :) |
Rick Murray (539) 13840 posts |
Am I allowed to ask……what’s the status of the BASIC assembler?
Not me – I’m losing track of it all. So many varied things – are we sure nemo isn’t an alias for a group of people? |
Steve Pampling (1551) 8170 posts |
A front for a group based in a hidden lair deep under the sea. We had no clue… |
nemo (145) 2546 posts |
I always enjoy Rick’s responses because they’re usually only one Planck’s Length from being actually right.
Well, ‘keypress’ is <waves arms about>. I have a different view because I wrote DeepKeys partially to enable the use of virtual ‘keys’, that may or may not be generated by an actual button, which may or may not be on something you’d call a keyboard. The ‘scan’ button on a scanner for example. Or conceptual buttons like “Next Album” or “Launch Web Browser” that some users would trigger via their keyboard driver, but others via a USB peripheral (remember the Optimus Maximus keyboard and associated things?). So I’m not hooked up on that event having to be an atomic character. UTF-8 was designed to go through existing 8-bit interfaces – that’s its entire point. However, it would be trivial to build a Filter that composed KeyPress events into a single Unicode event, and a Wimp_Extend so that Send_Keypress would accept such a code. Wimp ‘function keys’ and fallback characters would be mapped to the non-Unicode range. (gentle reminder folks: regardless of what’s written in any part of the RO source, Unicode is 21 bit and UTF-8 is never more than four bytes long). However, all other OS APIs would stay resolutely 8-bit UTF-8, so you’re just moving the transcoding around, which is a bit pointless. The UnicodeSupport module will make life easier for app authors. Let’s see if it’s still painful then.
Windows suffers from Early Adopter Syndrome – they jumped in at the “Unicode is 16bit!” start, before the Committee decided “We’re going to need a bigger byte” (I’m here all week folks).
Wimp Message &5327F “Styled Text” carries a string and a font ‘name’ (and hence an encoding). Wimp_KeyPress delivers characters in the current Alphabet, that’s fine. &5327F is for delivering stuff in some other Alphabet.
I’ve been pondering this with regard to the horribly broken clipboard handling. Short version (presented without evidence): RO4 ClipboardHolder is better than RO5 Clipboard; ClipboardHolder is badly designed and needs fixing with a new one that works in a different way; Underlying Clipboard Protocol is badly designed but easy to fix; We can then have a Windows-like clipboard that supports multiple formats simultaneously with auto conversion.
Well, obviously UTF-8 is 100% compatible with Latin1, and all other Acorn alphabets. Even BFont. And to facilitate that… *HELP FALLBACKALPHABET ==> Help on keyword FallbackAlphabet *FallbackAlphabet with no parameter displays the currently selected fallback alphabet, used when programs do not support UTF-8. *FallbackAlphabet <alphabet> sets the alphabet to be used by programs that do not support UTF-8. *FallbackAlphabet <country> works out the alphabet to use. *FallbackAlphabet Auto inherits the current alphabet for fallback. *FallbackAlphabet None disables fallback. Syntax: *FallbackAlphabet [<alphabet>] | <country> | Auto | None * |
nemo (145) 2546 posts |
Steve suggested
I’m embarrassed to report that I actually started doing this a few years ago… and then I forget to update it and what I’ve done, so I wrote a Sometimes I scroll through it and wonder who wrote all the entries, because I have no memory of half of this stuff. |
nemo (145) 2546 posts |
Rick enquired
Well, I wrote the proof of concept, which I’ve demonstrated. That was an old version of BASIC (because I had it lying around) and a toy assembler module. I started analysing current versions of BASIC and was horrified to discover that the NEON support is well over ten times bigger than all of the rest put together. The only passionate response was “Who cares?” so I’ve wasted no more time. It’s been demonstrated, it works, it has many benefits, no one cares. C’est la vie de RISC OS, n’est pas?
I wrote: And decided in a fit of misplaced altruism to fix it… but on the way there (in fact trying to find where “there” might be) I stumbled upon the Wimp_ProcessKey code and recalled that I’d previously complained that the UTF-8 handling of yore broke ProcessKey in annoying and exciting ways (eg WPK,&101 works fine, but WPK,&100 sends null to the focused task, and it also trampled on some of DeepKeys’ functionality)… so I’ve fixed it! It’s slightly too large to be considered a patch and I did it With The Actual Source (unusually for me), so I should probably send the diffs to someone to actually try. Volunteer? To which I got the usual response. The RISC OS world is much like some dysfunctional companies I’ve worked with – once a state of affairs has continued for long enough, those that would want it changed have moved on elsewhere, and the only people left either don’t care or just want an easy life or benefit from the dysfunction. The inertia is wearying. |
Rick Murray (539) 13840 posts |
Actually, I think you’ll find that nobody was that bothered by the size of the NEON code, but there was interest (me for a start) in the possibities provided by the assembler. |
Steve Pampling (1551) 8170 posts |
Well I got the impression you might have been talking about NEON support in BASIC, which I’m pretty clueless about. |
David J. Ruck (33) 1635 posts |
I know I’m a year late, but…
I was a bit more ambitious than that and wrote !GraphTask (http:://www.armclub.org.uk/free) which implements a graphical task window. It captures all VDU output from a taskwindow and plots it in to a sprite, so it supports the old numbered modes, palette changes and all VDU graphics output. So it’s great for old BBC B programs and early Archimedes stuff which uses lower resolution screen modes than modern monitors support. What it doesn’t support is any graphics using SWIs such as OS_ScreenMode, ColourTrans, Sprite, Font or Draw. I did intend when I wrote it 30 years ago, to extend it to do this by redirecting output to the sprite while the task window task was active, rather than just when processing the VDU stream the task window delivers to the registered handler. |
Pages: 1 2