|
|
|
date: Tue, 02 Sep 2008 07:57:02 +0100,
group: uk.comp.os.linux
back
Key macro program ?
I'm really missing Keytext. :-(
Entering common things like your telephone number, e-mail and postal
addresses was so easy, each being assigned to a different key combination.
I've gone with the FF password feature which had eliminated many of the
requirements but is there anyway of entering the above more easily than
typing them out in full ?
Cheers
date: Tue, 02 Sep 2008 07:57:02 +0100
author: Andy Cap
|
Re: Key macro program ?
On Tue, 02 Sep 2008 07:57:02 +0100, Andy Cap wrote:
> I'm really missing Keytext. :-(
>
> Entering common things like your telephone number, e-mail and postal
> addresses was so easy, each being assigned to a different key
> combination.
>
> I've gone with the FF password feature which had eliminated many of the
> requirements but is there anyway of entering the above more easily than
> typing them out in full ?
>
There's a checkbox on the Privacy Preferences page (its off by default)
that causes FF to remember stuff you type into boxes.
Or, you can try using Opera, which allows you to put this stuff in as
part of its configuration. Opera is my usual browser, though (unusually),
9.52 has such crappy page rendering that I'm using FF 3.0.1 until the
next Opera release appears. IMO FF isn't nearly in the same class as
Opera and this interlude of using it just reinforces that opinion.
--
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |
date: Tue, 2 Sep 2008 11:09:39 +0000 (UTC)
author: Martin Gregorie lid
|
Re: Key macro program ?
Thanks for the suggestion.
Having just got FF how I like it with Flash and AD block, along with all
the bookmark tags I can't be doing with starting over. The advantage of
Keytext was that you could have numerous strings and stick them where
you wanted at any time. I suppose I could try Wine buy that another
complication I don't need.
Oh well.
date: Wed, 03 Sep 2008 07:29:24 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap wrote:
> Thanks for the suggestion.
>
> Having just got FF how I like it with Flash and AD block, along with all
> the bookmark tags I can't be doing with starting over. The advantage of
> Keytext was that you could have numerous strings and stick them where
> you wanted at any time. I suppose I could try Wine buy that another
> complication I don't need.
>
> Oh well.
Have you looked at Firefox extensions? This one may do what you want:
https://addons.mozilla.org/en-US/firefox/addon/4775
date: Wed, 03 Sep 2008 09:26:30 +0100
author: chris
|
Re: Key macro program ?
On Wed, 03 Sep 2008 07:29:24 +0100, Andy Cap wrote:
> The advantage of
> Keytext was that you could have numerous strings and stick them where
> you wanted at any time.
>
Wasn't that part of the old DOS Sidekick thing?
--
martin@ | Martin Gregorie
gregorie. | Essex, UK
org |
date: Wed, 3 Sep 2008 10:03:32 +0000 (UTC)
author: Martin Gregorie lid
|
Re: Key macro program ?
I don't know it's origin. I've used it for quite a few years and only
known it as a standalone program. You used to be able to raise issues
with the author. I tried to persuade them to port it but no such luck.
date: Wed, 03 Sep 2008 11:33:38 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap writes:
> I'm really missing Keytext. :-(
I don't know it so a replacement is hard to determine.
> Entering common things like your telephone number, e-mail and postal
> addresses was so easy, each being assigned to a different key
> combination.
There are lots of ways to bind key events to programs. You don't say
which desktop/window manager you are using, but in all those that I've
seen you can take a key combo (I like to use Super+X with Super being
the otherwise unused Windows Key) to a program. If you install the X
automation package, you get a program called xte that can simulate
keystrokes and this "type" text into any program.
I have also had good results with one of the many hotkey programs.
erouter can catch and map keystrokes using rules that depend on the
program, but the config format is a bit fiddly. There are several
other "hotkey" programs, but I'd go with what my desktop system uses
first.
--
Ben.
date: Wed, 03 Sep 2008 16:34:28 +0100
author: Ben Bacarisse
|
Re: Key macro program ?
On Wed, 03 Sep 2008 16:34:28 +0100, Ben Bacarisse wrote:
>There are lots of ways to bind key events to programs. You don't say
>which desktop/window manager you are using, but in all those that I've
>seen you can take a key combo (I like to use Super+X with Super being
>the otherwise unused Windows Key) to a program. If you install the X
>automation package, you get a program called xte that can simulate
>keystrokes and this "type" text into any program.
>
>I have also had good results with one of the many hotkey programs.
>erouter can catch and map keystrokes using rules that depend on the
>program, but the config format is a bit fiddly. There are several
>other "hotkey" programs, but I'd go with what my desktop system uses
>first.
Right, I've installed xautomation after adding several devel packages, so I'm
now embarking on understanding a bit more about it. Thanks for the help.
Incidentally, I'm using Gnome on Fedora 9.
date: Wed, 03 Sep 2008 19:00:51 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap writes:
> On Wed, 03 Sep 2008 16:34:28 +0100, Ben Bacarisse wrote:
>
>
>>There are lots of ways to bind key events to programs. You don't say
>>which desktop/window manager you are using, but in all those that I've
>>seen you can take a key combo (I like to use Super+X with Super being
>>the otherwise unused Windows Key) to a program. If you install the X
>>automation package, you get a program called xte that can simulate
>>keystrokes and this "type" text into any program.
>>
>>I have also had good results with one of the many hotkey programs.
>>erouter can catch and map keystrokes using rules that depend on the
>>program, but the config format is a bit fiddly. There are several
>>other "hotkey" programs, but I'd go with what my desktop system uses
>>first.
>
> Right, I've installed xautomation after adding several devel packages, so I'm
> now embarking on understanding a bit more about it. Thanks for the help.
> Incidentally, I'm using Gnome on Fedora 9.
One way to do this, then, is to use metacity's key bindings. You need
gconf-editor (or gconftool) to define some of the commands in:
/apps/metacity/keybinding_commands
The commands would be things like this:
xte 'str B Bacarisse'
and then you define the keys to run these in
/apps/metacity/global_keybindings
A more flexible alternative is to bind just one key combination to a
script like this:
---------
#!/bin/bash
while read string; do STRINGS+=("$string"); done <<EOF
Edit these lines
to contain the strings
you use the most.
EOF
STR=$(zenity --list --column "Select text" "${STRINGS[@]}")
if [[ $? > 0 ]]; then exit 0; fi
xte "str $STR"
---------
Of course the strings can be a separate easy-to edit file (rather than
the "here" document above) if that helps. Even strings with newlines
can be accommodated with a little more work.
--
Ben.
date: Wed, 03 Sep 2008 22:30:09 +0100
author: Ben Bacarisse
|
Re: Key macro program ?
Hi Ben
Thanks a lot for the suggestions. I love the idea of a table. :-)
This is as I have the script. First time I've played with these.
> #!/bin/bash
>
> while read string;do STRINGS+=("$string");done<<EOF
> EOF
>
> STR=$(zenity --list --column "Select text""${STRINGS[@]}")
> if[[$?>0]];then exit 0;fi
> xte "str $STR"
It produces the table, both via the Key selection and when run in
Terminal but there is no entry in the table. I'm assuming there should
at least be the word "string", yes ??
If I/we ;-) can get this sorted, it will actually be a much better
solution than Keytext.
Cheers Andy
date: Thu, 04 Sep 2008 17:14:33 +0100
author: Andy Cap
|
Re: Key macro program ?
Whoops !
I understand what I should have been doing now.
Thanks a lot. I'll see how things go.
Andy
date: Thu, 04 Sep 2008 18:39:09 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap writes:
> Thanks a lot for the suggestions. I love the idea of a table. :-)
> This is as I have the script. First time I've played with these.
You spotted one problem in your edit but just to avoid any more...
>> #!/bin/bash
>>
>> while read string;do STRINGS+=("$string");done<<EOF
put the strings in here, or make the loop read from a file
>> EOF
>>
>> STR=$(zenity --list --column "Select text""${STRINGS[@]}")
Spaces matter! I think you have taken too many out.
>> if[[$?>0]];then exit 0;fi
>> xte "str $STR"
--
Ben.
date: Thu, 04 Sep 2008 19:40:21 +0100
author: Ben Bacarisse
|
Re: Key macro program ?
On Thu, 04 Sep 2008 19:40:21 +0100, Ben Bacarisse wrote:
>Andy Cap writes:
>
>> Thanks a lot for the suggestions. I love the idea of a table. :-)
>> This is as I have the script. First time I've played with these.
>
>You spotted one problem in your edit but just to avoid any more...
>
>>> #!/bin/bash
>>>
>>> while read string;do STRINGS+=("$string");done<<EOF
>
>put the strings in here, or make the loop read from a file
>
>>> EOF
>>>
>>> STR=$(zenity --list --column "Select text""${STRINGS[@]}")
>
>Spaces matter! I think you have taken too many out.
>
>>> if[[$?>0]];then exit 0;fi
>>> xte "str $STR"
It now produces the table of options just fine.
What I can't do is get the selection to appear in a text editor for example.
I experimented by replacing the final line with
xte "key k" and that doesn't work either so it's not a problem with the $STR
part.
If I enter # xte "str ABC" on a command line it simply reproduces the ABC but
how does it get tranferred into an open document ?
I hope I'm not pushing my luck here !
date: Thu, 04 Sep 2008 19:53:03 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap writes:
> On Thu, 04 Sep 2008 19:40:21 +0100, Ben Bacarisse wrote:
>
>>Andy Cap writes:
>>
>>> Thanks a lot for the suggestions. I love the idea of a table. :-)
>>> This is as I have the script. First time I've played with these.
>>
>>You spotted one problem in your edit but just to avoid any more...
>>
>>>> #!/bin/bash
>>>>
>>>> while read string;do STRINGS+=("$string");done<<EOF
>>
>>put the strings in here, or make the loop read from a file
>>
>>>> EOF
>>>>
>>>> STR=$(zenity --list --column "Select text""${STRINGS[@]}")
>>
>>Spaces matter! I think you have taken too many out.
>>
>>>> if[[$?>0]];then exit 0;fi
>>>> xte "str $STR"
>
> It now produces the table of options just fine.
>
> What I can't do is get the selection to appear in a text editor for
> example.
Do you have it bound to a key stroke? The idea relies on the fact
that once the list window is dismissed (you can just double-click a
selection) X windows reverts the keyboard focus to the previous
window, so you can only use "as you type" so to speak.
> I experimented by replacing the final line with
>
> xte "key k" and that doesn't work either so it's not a problem with the $STR
> part.
>
> If I enter # xte "str ABC" on a command line it simply reproduces the ABC but
> how does it get tranferred into an open document ?
You have to be focused in the input field in question as if you were
about to type. The string gets sent to whatever window had the focus
before you hit the key-combo that runs the script.
It works for me in every context I have tried so far but there may be
situations that fool it.
--
Ben.
date: Thu, 04 Sep 2008 22:27:42 +0100
author: Ben Bacarisse
|
Re: Key macro program ?
On Thu, 04 Sep 2008 22:27:42 +0100, Ben Bacarisse wrote:
>>>Spaces matter! I think you have taken too many out.
>You have to be focused in the input field in question as if you were
>about to type. The string gets sent to whatever window had the focus
>before you hit the key-combo that runs the script.
>
>It works for me in every context I have tried so far but there may be
>situations that fool it.
Hi Ben
The problem was the spacing in [[ $? > 0 ]]
It's now working as you suggested and is BRILLIANT. Just what I wanted.
Thanks a lot for taking the trouble.
Andy
date: Fri, 05 Sep 2008 08:43:35 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap wrote:
> On Thu, 04 Sep 2008 22:27:42 +0100, Ben Bacarisse wrote:
>
>>>> Spaces matter! I think you have taken too many out.
>
>> You have to be focused in the input field in question as if you were
>> about to type. The string gets sent to whatever window had the focus
>> before you hit the key-combo that runs the script.
>>
>> It works for me in every context I have tried so far but there may be
>> situations that fool it.
>
> Hi Ben
>
> The problem was the spacing in [[ $? > 0 ]]
>
> It's now working as you suggested and is BRILLIANT. Just what I wanted.
This is xautomation? This thread's got a bit drawn out, would you mind
summarising what you did to get it working? It sounds useful.
--
http://SnapAndScribble.com
date: Fri, 05 Sep 2008 17:26:42 +0100
author: Will Kemp
|
Re: Key macro program ?
On Fri, 05 Sep 2008 17:26:42 +0100, Will Kemp wrote:
>Andy Cap wrote:
>> On Thu, 04 Sep 2008 22:27:42 +0100, Ben Bacarisse wrote:
>>
>>>>> Spaces matter! I think you have taken too many out.
>>
>>> You have to be focused in the input field in question as if you were
>>> about to type. The string gets sent to whatever window had the focus
>>> before you hit the key-combo that runs the script.
>>>
>>> It works for me in every context I have tried so far but there may be
>>> situations that fool it.
>>
>> Hi Ben
>>
>> The problem was the spacing in [[ $? > 0 ]]
>>
>> It's now working as you suggested and is BRILLIANT. Just what I wanted.
>
>This is xautomation? This thread's got a bit drawn out, would you mind
>summarising what you did to get it working? It sounds useful.
Keytest replacement suggested by Ben Bacarisse
Get xautomation from http://hoopajoo.net/projects/xautomation.html
To install you require :-
Some xorg package which I can't remember but the 'make' fails without it.
libxtst-devel
libpng-devel
Get gconf-editor
Create Script directory in /home/User directory Ensure it's in PATH
Create following script and save as keystrings.sh
----------------------------------------------------------------
#!/bin/bash
while read string;do STRINGS+=("$string");done<<EOF
)
)
)
) Place strings on these lines i.e. e-mail address, telephone no
)
)
EOF
STR=$(zenity --list --column "Select text" "${STRINGS[@]}")
if [[ $? > 0 ]];then exit 0;fi
xte "str $STR"
-----------------------------------------------------------------
Use gconf-editor to amend metacity configuration
In kebindings_commands add /home/User/Scripts/keystrings.sh
to say run_command 1
In global_keybiding add required key i.e. <Alt>F3 to run_command 1
<Alt>F3 will then produce a table of your required strings and when you
select one it will be inserted into any focussed document.
date: Fri, 05 Sep 2008 18:38:37 +0100
author: Andy Cap
|
Re: Key macro program ?
Andy Cap wrote:
> On Fri, 05 Sep 2008 17:26:42 +0100, Will Kemp wrote:
>
>> Andy Cap wrote:
>>> On Thu, 04 Sep 2008 22:27:42 +0100, Ben Bacarisse wrote:
>>>
>>>>>> Spaces matter! I think you have taken too many out.
>>>> You have to be focused in the input field in question as if you were
>>>> about to type. The string gets sent to whatever window had the focus
>>>> before you hit the key-combo that runs the script.
>>>>
>>>> It works for me in every context I have tried so far but there may be
>>>> situations that fool it.
>>> Hi Ben
>>>
>>> The problem was the spacing in [[ $? > 0 ]]
>>>
>>> It's now working as you suggested and is BRILLIANT. Just what I wanted.
>> This is xautomation? This thread's got a bit drawn out, would you mind
>> summarising what you did to get it working? It sounds useful.
>
> Keytest replacement suggested by Ben Bacarisse
>
> Get xautomation from http://hoopajoo.net/projects/xautomation.html
>
> To install you require :-
>
> Some xorg package which I can't remember but the 'make' fails without it.
> libxtst-devel
> libpng-devel
>
> Get gconf-editor
>
> Create Script directory in /home/User directory Ensure it's in PATH
>
> Create following script and save as keystrings.sh
>
> ----------------------------------------------------------------
> #!/bin/bash
>
> while read string;do STRINGS+=("$string");done<<EOF
> )
> )
> )
> ) Place strings on these lines i.e. e-mail address, telephone no
> )
> )
> EOF
>
> STR=$(zenity --list --column "Select text" "${STRINGS[@]}")
> if [[ $? > 0 ]];then exit 0;fi
> xte "str $STR"
> -----------------------------------------------------------------
>
>
> Use gconf-editor to amend metacity configuration
>
> In kebindings_commands add /home/User/Scripts/keystrings.sh
> to say run_command 1
>
> In global_keybiding add required key i.e. <Alt>F3 to run_command 1
>
> <Alt>F3 will then produce a table of your required strings and when you
> select one it will be inserted into any focussed document.
Thanks for that!
--
http://SnapAndScribble.com
date: Fri, 05 Sep 2008 18:46:04 +0100
author: Will Kemp
|
Re: Key macro program ?
Andy Cap writes:
> On Thu, 04 Sep 2008 22:27:42 +0100, Ben Bacarisse wrote:
>
>>>>Spaces matter! I think you have taken too many out.
>
>>You have to be focused in the input field in question as if you were
>>about to type. The string gets sent to whatever window had the focus
>>before you hit the key-combo that runs the script.
>>
>>It works for me in every context I have tried so far but there may be
>>situations that fool it.
>
> Hi Ben
>
> The problem was the spacing in [[ $? > 0 ]]
>
> It's now working as you suggested and is BRILLIANT. Just what I
> wanted.
I am very pleased it works for you. This is what Linux is all about.
> Thanks a lot for taking the trouble.
No problem. I'd already written an almost identical script for a
friend.
--
Ben.
date: Sat, 06 Sep 2008 02:26:46 +0100
author: Ben Bacarisse
|
|
|