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 

Gmail HTML, RTF, CSS formated signature. GREAT for me!

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



Joined: 30 Apr 2008
Posts: 1
Location: The Netherlands, Kosova

PostPosted: Wed Apr 30, 2008 6:32 pm    Post subject: Gmail HTML, RTF, CSS formated signature. GREAT for me! Reply with quote

Finally I found a way to make my own rich text formated signature in Gmail or any other application you need/wish to.
You dont need any tweaks/plugins at all: all you need is this AutoHotkey script. Once you save any content to a file, you can use that anytimes. It is quick and very good for my needs. Hope it works for you too.
USAGE:
Script is in two portions.
1st one to save the content to a file,
2nd one to load the saved clipboard file and paste to the application

So here is the 1st script to save the Clipboard to a file:

Code:

;
; Author:         Arber/Beni Dhomi, www.dhomi.com, <opera@dhomi.com>
;
; Script Function:
;   Copy a formated content to the Clipboard, then Save it to a file
;       Then Load this file anytime to the Clipboard and paste it to Gmail or any other application you wish
;

; SAVE file2clipboard
 FileAppend, %ClipboardAll%, filename.rtf ;put here any filename you wish
return


The 2st script to load the file to the Clipboard and paste it:
Code:

;
; Author:         Arber/Beni Dhomi, www.dhomi.com, <opera@dhomi.com>
;
; Script Function:
;   Copy a formated content to the Clipboard, then Save it to a file
;       Then Load this file anytime to the Clipboard and paste it to Gmail or any other application you wish
;

#a:: ;Windows+a is the trigger

; ---
; LOAD file2clipboard
FileRead, Clipboard, *c filename.rtf ; look for the use of *c  before the filename.rtf. so dont change that

; ---
; paste
Send ^v
return



Well, have a lot of fun and tell me if you liked this script from me.[/code]
_________________
Arber Beni DHOMI | http://www.dhomi.com
chef d'Orchestre, conductor, opera, www.dhomi.com, Linux,

http://www.dhomi.com
Back to top
View user's profile Send private message
Rhys



Joined: 17 Apr 2007
Posts: 701
Location: Florida

PostPosted: Wed Apr 30, 2008 9:22 pm    Post subject: Reply with quote

Code:
---------------------------
scratch.ahk
---------------------------
Error: Out of memory.

   Line#
   010: Return
--->   014: FileRead,Clipboard,*c richtext.rtf
   018: Send,^v
   019: Return
   020: Exit
   020: Exit

---------------------------
OK   
---------------------------
Sad

Edit - Ah, I see my mistake... I tried using the second script only (with an existing rtf file)... The first script is necessary for this to work... I'd suggest a different extension since there's not really a valid .rtf file involved... Cool script!
_________________
[Join IRC!]


Last edited by Rhys on Wed Apr 30, 2008 9:31 pm; edited 1 time in total
Back to top
View user's profile Send private message
SomeGuy



Joined: 21 Apr 2008
Posts: 94
Location: somewhere

PostPosted: Wed Apr 30, 2008 9:25 pm    Post subject: Reply with quote

use the maxmem directive to increase the memory of the script
Back to top
View user's profile Send private message
AnthonyDavidAdams
Guest





PostPosted: Tue May 20, 2008 3:43 pm    Post subject: Reply with quote

genius. love this. will be using it a TON!

wonder if we can make a right click menu that has a selection of sigs to insert.
Back to top
Some.NET(Guy)
Guest





PostPosted: Wed May 21, 2008 10:22 pm    Post subject: Reply with quote

this is pretty much the functionality i require, but i can't get it to work. i'm relatively new to AHK. how do you trigger the first script?

basically what i'd like to do is copy a form letter and paste it into gmail with links and everything. if there was a way i could fill in fields too, that would be amazing, but for now i'd be ok with just copying a file and pasting it in.

can anyone help me?

thanks Smile
Back to top
PurloinedHeart



Joined: 04 Apr 2008
Posts: 108
Location: Canada

PostPosted: Thu May 22, 2008 1:37 am    Post subject: Reply with quote

@Some.NET(Guy)

Make your signature, then copy it and run the first script.
Run the second script, and whenever you press Windows Key + A, your signature will be loaded to your current clipboard.
Back to top
View user's profile Send private message
Some.NET(Guy)



Joined: 21 May 2008
Posts: 2

PostPosted: Thu May 22, 2008 1:17 pm    Post subject: Reply with quote

@purloined

thanks, but how do you run the first script? there's no trigger... just by putting it in a file and clicking on it?
Back to top
View user's profile Send private message
Rhys



Joined: 17 Apr 2007
Posts: 701
Location: Florida

PostPosted: Thu May 22, 2008 1:55 pm    Post subject: Reply with quote

Copy some rich text into your clipboard, then run the 1st script. It will save the file that the second one uses. If you don't already have AHK installed, you'll need it to run the script. Just save it as 'something'.ahk
_________________
[Join IRC!]
Back to top
View user's profile Send private message
Some.NET(Guy)



Joined: 21 May 2008
Posts: 2

PostPosted: Thu May 22, 2008 2:07 pm    Post subject: Reply with quote

thanks much... works like a dream Smile
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