Advertisement
pastamaker

nonkey

Jun 18th, 2018
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. #NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
  3. ; #Warn  ; Enable warnings to assist with detecting common errors.
  4. SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
  5.  
  6. SetWorkingDir %A_ScriptDir%
  7.  
  8.  
  9. #SingleInstance,force
  10. SetBatchLines,-1
  11. ;~ #Include,<hellbents_gdip>
  12.  
  13. gui,1:font,s15
  14. gui,1: add,edit , r1 w500 vedit1
  15. gui,1: add,button , y+1 r2 w500 gclip,nonkey::`nreturn
  16.  
  17. gui,1: add,button ,y+1 r1 w500 gremove,remove tooltip
  18. gui,1: show,,gui1
  19. gui,1: +alwaysontop
  20.  
  21.  
  22.  
  23. return
  24.  
  25. remove:
  26. ToolTip
  27. return
  28.  
  29. clip:
  30. Gui,submit,nohide
  31. Clipboard:=forward(edit1)
  32. ToolTip,% Clipboard
  33. return
  34.  
  35. forward(x){
  36.     x:=split(x)
  37.     string=
  38.     for i,value in x {
  39.         string.= value "::" "`n" "return" "`n"
  40.     }
  41.     return string
  42.    
  43. }
  44.  
  45. split(string){
  46.     string := StrSplit(string, ",",a_space)  
  47.     t:=1
  48.     while ( string.length() >= t) {
  49.         if(string[t]<>"")
  50.             t++
  51.         else
  52.             string.Remove(t)
  53.     }
  54.     return string
  55. }
  56. GuiClose:
  57. ExitApp
  58. ^x::ExitApp
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement