 |
AutoHotkey Community Let's help each other out
|
| View previous topic :: View next topic |
| Author |
Message |
jordis
Joined: 30 Jul 2004 Posts: 78
|
Posted: Fri Jul 30, 2004 9:12 pm Post subject: Replace text in real time (with no shortcut text needed) |
|
|
Hi all
i just wanted to post an idea of script that i'll be trying to create (slowly, due to lack of time & autohotkey experience), and i would appreciate any thoughs on any potential approaches.
Actually, the functionality would be similar to the topic discussed in Use shortcut text realtime. There, they were talking about typing a shortcut text and getting a predefined longer form (like typing "btw" and getting "by the way").
Very useful and surely I'll make use of that as well, but the variation I have in mind would work differently: no use of shortcut texts.
In fact, I think that I'm trying to create a Microsoft Word's AutotText kind of script...
This would be the overview:
Given a list of user-defined words (or relatively short sentences, units of 2 or 3 words), the script should be monitoring the user's input. As soon as it would detect that the user is typing a word that matches a word in the list, it would suggest such word to the user (as a tooltip for example). Then, then the user would be able to press something and the actual word would be inserted (or go on typing ignoring the suggestion)
There would be several situations to take into account (that I can think of):
- The script's suggestion probably would have to be after let's say 3 or 4 keystrokes (or user customizable?), since I guess after 1 or 2 keystrokes the matches would be too many.
- In case of several matches, the script would offer a choice of possible matches. Let's suppose you defined "backup system" and "backup file". After typing "bac", you would get a numbered choice of both of them...
There are several software applications that let you do that, such as
LetMeType, that would perfectly suit my needs if it had the possibility to add multi-word units, not only single words. Also, I wouldn't need the AutoLearn feature it has (that learns words you type, and stores the muber of occurrances, etc.)... In short, I'm not looking after too complex functionality, but rather flexibility and ease of use.
I think AutoHotkey is very much capable of fitting my goal.
The problem is that I don't really know how to approach it from scratch.
I'm not requesting anybody to write the script for me, but rather "enlighten" me on how this could be accomplished.
Any thoughts?
jordi
PS: oops I just wonder whether this is the right forum section to post this... After a second thought, I think this should be in Support... Any way to move it?
Last edited by jordis on Fri Jul 30, 2004 9:40 pm; edited 1 time in total |
|
| Back to top |
|
 |
Rajat
Joined: 28 Mar 2004 Posts: 1717
|
Posted: Fri Jul 30, 2004 9:23 pm Post subject: |
|
|
By all means you should go for it. just wanted to say that i've already coded a similar script (except for the numbered choices part it does everything u mentioned).
Its still not posted anywhere coz i was waiting for Chris to implement A_CaretX & A_CaretY so that the tooltip shows directly above the text being typed instead of a fixed position on screen.
should i post it the way it is?
| Quote: | | I think this should be in Support... Any way to move it? |
Chris can do it. _________________
 |
|
| Back to top |
|
 |
jordis
Joined: 30 Jul 2004 Posts: 78
|
Posted: Fri Jul 30, 2004 9:37 pm Post subject: |
|
|
Rajat,
I've been reading you a lot lots of helpful scripts from you around the forum...
You are more than welcome to post your script!
That way I could get an overall idea and try to adjust if to my needs (first try to understand it!)
Also, I guess that if you post it, there will be no need cfor this post to be moved to another section, right?  |
|
| Back to top |
|
 |
Rajat
Joined: 28 Mar 2004 Posts: 1717
|
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10467
|
Posted: Fri Jul 30, 2004 10:09 pm Post subject: |
|
|
| Quote: | | In case of several matches, the script would offer a choice of possible matches. Let's suppose you defined "backup system" and "backup file". After typing "bac", you would get a numbered choice of both of them... |
Interesting idea. As you said, there is a bunch of nice software out there already, some of which learns as you type, others might be based on the user's language and it will suggest common words once enough is present to detect what you're trying to type.
I guess you could present a ToolTip with a numbered list of choices, and maybe make the numbers into hotkeys or something. That might lead to problems, however. You could also have a popup menu of choices, but once again there are problems since the menu would "steal focus" from the active window.
Although overall it's a little too ambitious (for my knowledge level) to build this into AHK right away, perhaps as I get more comfortable with Rajat's Intellisense script -- and any other similar scripts that materialize over the coming months -- I'll understand the concept enough where I might start designing some kind of built-in feature.
By the way, I've moved your topic to support as you requested, though it wasn't that much off-topic in the other forum. |
|
| Back to top |
|
 |
jordis
Joined: 30 Jul 2004 Posts: 78
|
Posted: Sat Jul 31, 2004 2:15 am Post subject: |
|
|
glad you like the idea...
rajat posted his script, i'm trying to get used to looping so much
In my environment, works correctly for the first time, then stops working... |
|
| Back to top |
|
 |
Rajat
Joined: 28 Mar 2004 Posts: 1717
|
Posted: Sat Jul 31, 2004 4:56 am Post subject: |
|
|
| Quote: | | I'll understand the concept enough where I might start designing some kind of built-in feature |
why? ... i mean a script is fine but an intellisense feature built into a scripting language? _________________
 |
|
| Back to top |
|
 |
Chris Site Admin
Joined: 02 Mar 2004 Posts: 10467
|
Posted: Sat Jul 31, 2004 12:32 pm Post subject: |
|
|
| Others have asked for it, but the answer really depends on whether it can be scripted at all. If it can't be scripted, or can be but only with a clumsy interface, some kind of built in feature might be worth considering. It's just an idea, and probably at least 2 months before even being considered for going onto the to-do list, let alone implemented. |
|
| Back to top |
|
 |
|
|
You can post new topics in this forum You can reply to topics in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|