Info request on menu's recently used list
Duncan
1i5t5.duncan at cox.net
Sun May 15 05:52:34 BST 2011
gene heskett posted on Sat, 14 May 2011 21:21:13 -0400 as excerpted:
> On Saturday, May 14, 2011 09:17:52 PM Duncan did opine:
>
>> gene heskett posted on Sat, 14 May 2011 15:59:38 -0400 as excerpted:
>> > (other than something is stealing the first few F keys from mc,
>> > forcing me to use the mouse. That sound? Its the sound of my
>> > favorite ox being gored. In the future, whatever keys mc asks for
>> > should be granted provided it has focus.
>>
>> That one... Here, I've gotten the "unshifted" set of fX to work in mc,
>> so I can
>> save(or-user-menu)/view/edit/copy/move/mkdir(find)/delete/menu-
>> activate/quit, but the "shifted" set don't reliably work. So for
>> instance, I have to repeatedly hit the f7/find and then enter keys,
>> instead of being able to hit shift-f7 for find-again.
>>
>> But I'm sort of used to the shifted row not functioning properly in
>> konsole... It was that way a lot of the time in kde3 as well,
>> unfortunately.
>>
>> Maybe one of these days I'll backup both the konsole and mc configs so
>> I won't lose the functionality I have, and try some serious
>> experimenting to try to get it all working properly. Either that, or
>> see if there's some mc list/forum I can ask on.
Actually, correcting myself, if I've any hope of getting it right, or at
least, any hope of understanding what I did to fix the problem if it
appears again, it'll be hours, perhaps days, of research, followed by
maybe an hour of tweaking and testing once I know what I'm doing.
I got thinking about it and the problem really is one of geometric
complexity, an N-way issue with just the top level N=3, with multiple
settings for parts of that, and a more accurate lower level N could well
be into the double-digits...
> If by chance, you find that magic twanger, please fwd the details, then
> print a copy or 20 and wrap them around suitable LART sized rocks to be
> lobbed in the general direction of whomever _thinks_ they are in charge
> of such. Gotta have target practice if one wants to stay proficient...
>
> ;-)
The base problem is that the Linux console and the X protocol use
different key-mappings, so an X terminal application must do some form of
remapping between the two, with some keys and functions generally reserved
for X. In particular, X's treatment of modifier keys is quite different,
as is the way it handles keypad vs main keyboard numeric and math keys.
But oh, were it that simple!
At the top level, konsole has the ability to reconfigure its mapping on
the input tab of the profile config. Similarly, mc has the ability to
configure its mapping. Meanwhile, I seem to remember reading somewhere
that mc detects the $TERM variable (I'm keeping things at the simple user-
level config, here, top level only) and adjusts accordingly. TERM=linux
<> TERM=xterm (the konsole default).
That's our three top level variables to play with. But...
mc can be built on either slang or ncurses or both, each of which has its
own terminal function detection and mapping. AFAIK ncurses is the more
popular these days, with a more current terminal mapping database, and if
one is /lucky/, it'll be used in preference to slang if they're both
compiled in and available. So, one now has to have at least a basic
understanding of how that stuff interacts.
Then there's bash (the readline library here), with its own keymapping.
Oh, and bash/readline also has both emacs and vim commandline editing
personalities, each with their own keybindings. It's quite possible one
could end up broken and the other not.
And X has its own configurable two-level keymapping. Plus with i18n,
there's multiple keylevels and keyboard layouts that could interfere.
And don't forget, if you customize say the konsole profile keymapping or X
keymapping too far, it's likely to break something else. For konsole, in
theory it's possible to setup a separate profile for mc, but that's both
inconvenient (oh, I was doing something else in this konsole tab, then
decided to run mc for something, but it's not the mc profile so the
keymapping's screwed!), and at least /some/ of the settings configured in
the profile settings apply to konsole globally (I know as I have a
dedicated profile for something else), *NOT* to the individual profile,
REGARDLESS of where they're actually set! I'm not sure if the keymapping
settings are actually per-profile or not.
Then there's the various patches the distributions may throw in, to try
and make things more "compatible", but very likely not succeeding except
in the narrow context, while breaking the documented functionality to make
it work some other way... That's on /top/ of the normal slang/ncurses
choices that apply at compile-time, mentioned above.
So... are you beginning to understand why previous airborne LART
deliveries haven't had a whole lot of effect? I just took a shower and
was thinking about all the independent (and not-so-independent) factors in
the equation. (Why is the shower such an effective place to think?) Then
I got out, and sat down to post about them. That way they'll stick in my
head better for the day I might try to do something with this.
Anyway, I suspect I'll have to read up on at least ncurses terminal
database documentation, to see how mc deals with that (I have USE=ncurses
and USE=-slang, here, so shouldn't have to worry about the latter), and
find something on the konsole choices as well, by mailing the devs and
asking if I can't find anything suitable in the konsole docs, author blogs
or commit logs. (I can try reading sources too, but don't claim to be a C
coder so would hope they're very well commented if I'm to get anything
useful out of that!) If I don't, it'll be simply shots in the dark, and
with the geometric complexity of the issue, that's about as likely to work
for me as playing the lotto.
--
Duncan - List replies preferred. No HTML msgs.
"Every nonfree program has a lord, a master --
and if you use the program, he is your master." Richard Stallman
___________________________________________________
This message is from the kde mailing list.
Account management: https://mail.kde.org/mailman/listinfo/kde.
Archives: http://lists.kde.org/.
More info: http://www.kde.org/faq.html.
More information about the kde
mailing list