AutoHotkey Homepage AutoHotkey Community
Let's help each other out
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The Clipinator

 
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions
View previous topic :: View next topic  
Author Message
Endel S. Leinfiedtz



Joined: 09 Apr 2008
Posts: 3
Location: 2-1/2 Mile Island, PA

PostPosted: Wed Apr 09, 2008 9:02 pm    Post subject: The Clipinator Reply with quote

Lifehacker recently published the source for an AHK script by one of their readers (ck). It speeds up repetitive copy-paste operations by allowing one to remain in the browser environment. The simplicity of the source just floored me.....

Code:


#c::
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{TAB}{ALTUP}
sleep, 300
Send, {CTRLDOWN}v{CTRLUP}{ENTER}{ALTDOWN}{TAB}{ALTUP}
return



....and I thought, "God Almighty, what a powerful tool!" I went and downloaded AHK, cruised the site and so far can't say a single negative thing about it. Obvious pros generously taking their time to not only help with the queries, but suggesting alternative routes to the same goal; very little of the snarky-flamey-snobby crap that plagues most "communities"; even the occasional idiotic questions handled with aplomb and restraint.

In short, AHK is the kind of thing I'll devote serious study to, and its proponents are the kind of people I'd be proud to be associated with. Consequently, I'd like to contribute my first ham-handed bloatcode, which takes ck's idea 2 steps farther. It sets up 3 hotkeys:

WIN+C copy-pastes the manually-selected text, with 2 linefeeds, a divider ( ========== ) and 2 more linefeeds.

WIN+V selects all, copy-pastes the entire page, again with linefeeds and the divider.

WIN+B inserts a date-time stamp, a linebreak, the URL from the address bar, and another linebreak.

(Obviously, you can easily substitute the editor of your choice for Notepad+.)

Code:


#c::
Send, {CTRLDOWN}c{CTRLUP}{ALTDOWN}{TAB}{ALTUP}
WinActivate, Notepad+
sleep, 300
Send, {CTRLDOWN}v{CTRLUP}{ENTER 2}=========={ENTER 2}{ALTDOWN}{TAB}{ALTUP}
return

#v::
Send, {CTRLDOWN}a{CTRLUP}{CTRLDOWN}c{CTRLUP}{ALTDOWN}{TAB}{ALTUP}
WinActivate, Notepad+
sleep, 300
Send, {CTRLDOWN}v{CTRLUP}{ENTER 2}=========={ENTER 2}{ALTDOWN}{TAB}{ALTUP}
return

#b::
Send, {F6}{CTRLDOWN}c{CTRLUP}{ALTDOWN}{TAB}{ALTUP}
WinActivate, Notepad+
sleep, 300
Send, {F5}{ENTER}{CTRLDOWN}v{CTRLUP}{ENTER 2}{ALTDOWN}{TAB}{ALTUP}
return



I've found it pretty handy for researching on the web, and humbly offer it as is. Feel free to critique/shred/crunch/howl-at-the-n00bery-of-it. I've only tested it on 98SE/Firefox2.0/Notepad+ but, from the look of it, it oughta run on about anything Win, yes?

OK, so now that I've contributed my first code, I feel entitled to contribute to the idiotic questions:

"How do you remap the ANY key???"

^o^ ROTFLMFAO ^o^
_________________
Windows Error Messages You Never See #47: "PIBKAC -- Problem Is Between Keyboard And Chair"
Back to top
View user's profile Send private message
bradchuck



Joined: 01 Apr 2008
Posts: 4

PostPosted: Thu Apr 10, 2008 2:28 am    Post subject: Looks Great Reply with quote

I will add this to my toolbox. I do a lot of copy and pasting from Firefox.

Thanks,
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    AutoHotkey Community Forum Index -> Scripts & Functions All times are GMT
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum


Powered by phpBB © 2001, 2005 phpBB Group