* xmodmap
@ 2003-01-22 0:53 Paul O'Donnell
2003-01-22 8:27 ` xmodmap Kai Großjohann
0 siblings, 1 reply; 6+ messages in thread
From: Paul O'Donnell @ 2003-01-22 0:53 UTC (permalink / raw)
Hi All,
I am trying to use the xmodmap untility to reconfigure my keyboard, but
I am not having success. As it is
keycode 115 = Super_L
keycode 117 = Menu
I want to changes these to be Alt_L and Alt_R respectively. So I did the
following at the command prompt.
[paul@cpe024350002546 paul]$ xmodmap -e "keycode 115 = Alt_L"
[paul@cpe024350002546 paul]$ xmodmap -e "keycode 117 = Alt_R"
When I test these changes with xmodmap -pk I can see that it has been
changed. Below is the relevant output from xmodmap -pk
KeyCode Keysym (Keysym) ...
Value Value (Name) ...
115 0xffe9 (Alt_L)
117 0xffea (Alt_R)
Then I go into emacs to test by trying M-v but it does not work. I have
been trying to solve this on my own by reading man xmodmap, but I am
confused. I think the problem is that I don't know how to interpret the
output of xmodmap -pm which is as follows:
[paul@cpe024350002546 paul]$ xmodmap -pm
xmodmap: up to 2 keys per modifier, (keycodes in parentheses):
shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25), Control_R (0x6d)
mod1 Alt_L (0x40), Alt_R (0x71)
mod2 Num_Lock (0x4d)
mod3
mod4 Alt_L (0x73), Super_R (0x74)
mod5 Scroll_Lock (0x4e)
[paul@cpe024350002546 paul]$
Any help pointing me in the right direction is appreciated.
Thanks,
Paul
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: xmodmap
2003-01-22 0:53 xmodmap Paul O'Donnell
@ 2003-01-22 8:27 ` Kai Großjohann
2003-01-22 11:52 ` xmodmap Paul O'Donnell
` (2 more replies)
0 siblings, 3 replies; 6+ messages in thread
From: Kai Großjohann @ 2003-01-22 8:27 UTC (permalink / raw)
Paul O'Donnell <odonnellp@rogers.com> writes:
> I am trying to use the xmodmap untility to reconfigure my keyboard,
> but I am not having success. As it is
>
> keycode 115 = Super_L
> keycode 117 = Menu
>
> I want to changes these to be Alt_L and Alt_R respectively. So I did
> the following at the command prompt.
>
> [paul@cpe024350002546 paul]$ xmodmap -e "keycode 115 = Alt_L"
>
> [paul@cpe024350002546 paul]$ xmodmap -e "keycode 117 = Alt_R"
Before these two commands, you should do "xmodmap -pm" and look for
the keysyms Super_L and Menu. Do xmodmap -e "clear mod3" if one of
them is on mod3, and similar for other modifiers. Then do the
keycode assignments. Then do xmodmap -e "add mod3 = sym1 sym2" to
add the previous keysyms back to the modifier (except for Super_L and
Menu, of course).
--
Ambibibentists unite!
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: xmodmap
2003-01-22 8:27 ` xmodmap Kai Großjohann
@ 2003-01-22 11:52 ` Paul O'Donnell
2003-01-22 16:01 ` xmodmap Kai Großjohann
2003-01-28 4:59 ` Scaling JPEG images Greg Hill
[not found] ` <mailman.1064.1043729992.21513.help-gnu-emacs@gnu.org>
2 siblings, 1 reply; 6+ messages in thread
From: Paul O'Donnell @ 2003-01-22 11:52 UTC (permalink / raw)
Kai Großjohann wrote:
> Paul O'Donnell <odonnellp@rogers.com> writes:
>
>
>>I am trying to use the xmodmap untility to reconfigure my keyboard,
>>but I am not having success. As it is
>>
>>keycode 115 = Super_L
>>keycode 117 = Menu
>>
>>I want to changes these to be Alt_L and Alt_R respectively. So I did
>>the following at the command prompt.
>>
>>[paul@cpe024350002546 paul]$ xmodmap -e "keycode 115 = Alt_L"
>>
>>[paul@cpe024350002546 paul]$ xmodmap -e "keycode 117 = Alt_R"
>
>
> Before these two commands, you should do "xmodmap -pm" and look for
> the keysyms Super_L and Menu. Do xmodmap -e "clear mod3" if one of
> them is on mod3, and similar for other modifiers. Then do the
> keycode assignments. Then do xmodmap -e "add mod3 = sym1 sym2" to
> add the previous keysyms back to the modifier (except for Super_L and
> Menu, of course).
Thanks Kai,
It works!
However I am curious about what I actually did. I followed your
instructions, modifying it to match my system. My goal was to disable
the Alt keys and make the Left Window Key an Alt Key and make the Right
Menu key an Alt Key. What actually happened was the Alt Keys remained as
Alt Keys and the Window and Menu keys became Alt Keys as well. I am
happy with that, in fact I prefer it. With my Alt Keys still intact it
will still work for someone else who needs to use my keyboard. I would
like to know why my changes did not do what I intended though and I am
curious about the out put of the xmodmap -mp command.
I accomplished the change by creating a .xmodmaprc file which I invoke
in my .bash_profile file. (Perhaps I should invoke it elswehere like in
the .bashrc file, but my understanding of how these files actually work
is shaky and at least I got it to work.Changes to my .bash_profile file
are permanent because I always use a login shell.) Below are the
contents of my .xmodmaprc file and the output of $xmonmap -pm
[paul: /home/paul]$ xmodmap -pm
xmodmap: up to 4 keys per modifier, (keycodes in parentheses):
shift Shift_L (0x32), Shift_R (0x3e)
lock Caps_Lock (0x42)
control Control_L (0x25), Control_R (0x6d)
mod1
mod2 Num_Lock (0x4d)
mod3
mod4 Alt_L (0x40), Alt_L (0x73), Alt_R (0x71), Alt_R (0x75)
mod5 Scroll_Lock (0x4e)
[paul: /home/paul]$
I am curious about the mod4 line. Why are there 4 entries there?
And the rc file that accomplished the changes.
[paul: /home/paul]$ cat .xmodmaprc
clear mod1
clear mod4
keycode 115 = Alt_L
keycode 117 = Alt_R
add mod4 = Alt_L Alt_R
[paul: /home/paul]$
Any hints to help me understand this are appreciated. The man pages for
xmodman are not really clear to me and the online sources I have found
on xmodmap are very brief. It would be nice to find some better docs on
this subject.
Thanks,
Paul
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: xmodmap
2003-01-22 11:52 ` xmodmap Paul O'Donnell
@ 2003-01-22 16:01 ` Kai Großjohann
0 siblings, 0 replies; 6+ messages in thread
From: Kai Großjohann @ 2003-01-22 16:01 UTC (permalink / raw)
Paul O'Donnell <odonnellp@rogers.com> writes:
> I am curious about the mod4 line. Why are there 4 entries there?
That's because you have four Alt keys :-)
> Any hints to help me understand this are appreciated. The man pages
> for xmodman are not really clear to me and the online sources I have
> found on xmodmap are very brief. It would be nice to find some better
> docs on this subject.
I wish it was that simple. The thing is that different programs do
different things. For example, Netscape (at least up to version 4)
looked at mod1 (in the output of xmodmap -pm, or the programmatic
equivalent) and called that Alt (even if the keysyms there were Meta_L
and Meta_R!). Emacs, however, looks for Meta_L and/or Meta_R (in the
output of xmodmap -pm) and uses whatever modifier it finds as meta.
If there are no Meta_L or Meta_R keysyms, then Emacs looks for Alt_L
and Alt_R and uses that modifier.
KDE programs look for Alt_L and Alt_R.
xterm looks for Meta_L/R (and, unlike Emacs, does not have an Alt_L/R
fallback).
A funny consequence is that you can't have xterm and Emacs and konsole
(what KDE has instead of xterm) working properly at the same time!
I think They have infiltrated the community of X developers, trying
to drive this fine window system into oblivion.
--
Ambibibentists unite!
^ permalink raw reply [flat|nested] 6+ messages in thread
* Scaling JPEG images
2003-01-22 8:27 ` xmodmap Kai Großjohann
2003-01-22 11:52 ` xmodmap Paul O'Donnell
@ 2003-01-28 4:59 ` Greg Hill
[not found] ` <mailman.1064.1043729992.21513.help-gnu-emacs@gnu.org>
2 siblings, 0 replies; 6+ messages in thread
From: Greg Hill @ 2003-01-28 4:59 UTC (permalink / raw)
In emacs-21 (running on a unix system) it's a piece of cake to
display a jpeg image in the current buffer:
(insert-image (create-image "rms.jpeg") (point))
But I would also like to be able to automatically scale it, e.g. to
25% or 200% of the original size. Anyone know a quick and easy way
to do that?
Thanks in advance.
--Greg
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Scaling JPEG images
[not found] ` <mailman.1064.1043729992.21513.help-gnu-emacs@gnu.org>
@ 2003-01-28 10:48 ` Kester Clegg
0 siblings, 0 replies; 6+ messages in thread
From: Kester Clegg @ 2003-01-28 10:48 UTC (permalink / raw)
Greg Hill <ghill@synergymicro.com> writes:
> (insert-image (create-image "rms.jpeg") (point))
>
> But I would also like to be able to automatically scale it, e.g. to
> 25% or 200% of the original size. Anyone know a quick and easy way to
> do that?
I know just what you mean - I get emails with big photos in them all the
time and I just can't view them in a tall narrow set up. I'm not sure
you can scale them within emacs.
--
************************************************************************
Kester Clegg Dept. of Computer Science,
Research Assistant (UTC) University of York,
Tel (01904) 43 27 49 email: kester at cs.york.ac.uk
************************************************************************
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2003-01-28 10:48 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-01-22 0:53 xmodmap Paul O'Donnell
2003-01-22 8:27 ` xmodmap Kai Großjohann
2003-01-22 11:52 ` xmodmap Paul O'Donnell
2003-01-22 16:01 ` xmodmap Kai Großjohann
2003-01-28 4:59 ` Scaling JPEG images Greg Hill
[not found] ` <mailman.1064.1043729992.21513.help-gnu-emacs@gnu.org>
2003-01-28 10:48 ` Kester Clegg
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.