Messages - kunkel321 [ switch to compact view ]

Pages: prev1 ... 14 15 16 17 18 [19] 20 21 22 23 24 ... 118next
91
N.A.N.Y. 2021 / Re: N.A.N.Y. 2021: RaptureReplica by KodeZwerg
« on: August 31, 2020, 09:11 AM »
Hey this is great!  I've needed this for years and never even knew it!  Hundreds of times, I've made a screenshot, then opened the image in Screenshot Captor in a floating window off to the side.  Your solution makes way more sense.  Thanks for sharing! 

I was going to suggest auto-saving opacity, but I see that it is already planned.   :Thmbsup:

92
Screenshot Captor / Re: [SUGGESTION] Bendy Arrows
« on: August 29, 2020, 10:05 AM »
Agreed!

Something like this would do:
https://cubic-bezier.com/#.92,.15,.23,.96

93
Google Boomerang / Re: Boomerang still not working
« on: August 12, 2020, 10:51 AM »
What available alternatives are there? I tried looking and I couldn't find a program that does exactly what Boomerang does

You can try this if you're comfortable with AHK:

I actually used Boomerang at work to check the validity of things that I converted to Spanish.  My theory is that if it still makes sense when it's converted back to English, then the grammar must be pretty close.  When Boomerang stopped working I found this:
https://www.autohotkey.com/boards/viewtopic.php?f=5&t=40876
You can see my correspondence with Teadrinker, who wrote the actual working parts of the code.  It's actually Java code, but I use it inside of AHK. 


Code: Autohotkey [Select]
  1. ;############## https://autohotkey.com/boards/viewtopic.php?f=5&t=40876
  2.  
  3. Send, ^c
  4. {
  5.     MsgBox, There is nothing on the clipboard to translate.  Please select some text with the mouse, then try again.
  6.     return
  7. }
  8.  
  9. asEsp := GoogleTranslate(Clipboard, "en", "es")
  10. asEng := GoogleTranslate(asEsp, "es", "en")
  11.  
  12. MsgBox, ~~~~~~~~ As Spanish ~~~~~~~~`n%asEsp%`n`n`~~~~~~~ Back to English ~~~~~~~`n%asEng%`n`n~~~~~~~~~~~~~~~~~~~~~~~~~`n[Esc] to Cancel.`n[OK] to send translation to clipboard; then paste as needed via Ctrl+v
  13. Clipboard := asEsp
  14.  
  15. GoogleTranslate(str, from := "auto", to := "es")  {
  16.    static JS := GetJScripObject(), _ := JS.( GetJScript() ) := JS.("delete ActiveXObject; delete GetObject;")
  17.    
  18.    json := SendRequest(JS, str, to, from, proxy := "")
  19.    oJSON := JS.("(" . json . ")")
  20.  
  21.    if !IsObject(oJSON[1])  {
  22.       Loop % oJSON[0].length
  23.          trans .= oJSON[0][A_Index - 1][0]
  24.    }
  25.    else  {
  26.       MainTransText := oJSON[0][0][0]
  27.       Loop % oJSON[1].length  {
  28.          trans .= "`n+"
  29.          obj := oJSON[1][A_Index-1][1]
  30.          Loop % obj.length  {
  31.             txt := obj[A_Index - 1]
  32.             trans .= (MainTransText = txt ? "" : "`n" txt)
  33.          }
  34.       }
  35.    }
  36.    if !IsObject(oJSON[1])
  37.       MainTransText := trans := Trim(trans, ",+`n ")
  38.    else
  39.       trans := MainTransText . "`n+`n" . Trim(trans, ",+`n ")
  40.  
  41.    from := oJSON[2]
  42.    trans := Trim(trans, ",+`n ")
  43.    Return trans
  44. }
  45.  
  46. SendRequest(JS, str, tl, sl, proxy) {
  47.    ComObjError(false)
  48.    http := ComObjCreate("WinHttp.WinHttpRequest.5.1")
  49.    ( proxy && http.SetProxy(2, proxy) )
  50.    http.open( "POST", "https://translate.google.com/translate_a/single?client=t&sl="
  51.       . sl . "&tl=" . tl . "&hl=" . tl
  52.       . "&dt=at&dt=bd&dt=ex&dt=ld&dt=md&dt=qca&dt=rw&dt=rm&dt=ss&dt=t&ie=UTF-8&oe=UTF-8&otf=1&ssel=3&tsel=3&pc=1&kc=2"
  53.       . "&tk=" . JS.("tk").(str), 1 )
  54.  
  55.    http.SetRequestHeader("Content-Type", "application/x-www-form-urlencoded;charset=utf-8")
  56.    http.SetRequestHeader("User-Agent", "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:47.0) Gecko/20100101 Firefox/47.0")
  57.    http.send("q=" . URIEncode(str))
  58.    http.WaitForResponse(-1)
  59.    Return http.responsetext
  60. }
  61.  
  62. URIEncode(str, encoding := "UTF-8")  {
  63.    VarSetCapacity(var, StrPut(str, encoding))
  64.    StrPut(str, &var, encoding)
  65.  
  66.    While code := NumGet(Var, A_Index - 1, "UChar")  {
  67.       bool := (code > 0x7F || code < 0x30 || code = 0x3D)
  68.       UrlStr .= bool ? "%" . Format("{:02X}", code) : Chr(code)
  69.    }
  70.    Return UrlStr
  71. }
  72.  
  73. GetJScript()
  74. {
  75.    script =
  76.    (
  77.       var TKK = ((function() {
  78.         var a = 561666268;
  79.         var b = 1526272306;
  80.         return 406398 + '.' + (a + b);
  81.       })());
  82.  
  83.       function b(a, b) {
  84.         for (var d = 0; d < b.length - 2; d += 3) {
  85.             var c = b.charAt(d + 2),
  86.                 c = "a" <= c ? c.charCodeAt(0) - 87 : Number(c),
  87.                 c = "+" == b.charAt(d + 1) ? a >>> c : a << c;
  88.             a = "+" == b.charAt(d) ? a + c & 4294967295 : a ^ c
  89.         }
  90.         return a
  91.       }
  92.  
  93.       function tk(a) {
  94.           for (var e = TKK.split("."), h = Number(e[0]) || 0, g = [], d = 0, f = 0; f < a.length; f++) {
  95.               var c = a.charCodeAt(f);
  96.               128 > c ? g[d++] = c : (2048 > c ? g[d++] = c >> 6 | 192 : (55296 == (c & 64512) && f + 1 < a.length && 56320 == (a.charCodeAt(f + 1) & 64512) ?
  97.               (c = 65536 + ((c & 1023) << 10) + (a.charCodeAt(++f) & 1023), g[d++] = c >> 18 | 240,
  98.               g[d++] = c >> 12 & 63 | 128) : g[d++] = c >> 12 | 224, g[d++] = c >> 6 & 63 | 128), g[d++] = c & 63 | 128)
  99.           }
  100.           a = h;
  101.           for (d = 0; d < g.length; d++) a += g[d], a = b(a, "+-a^+6");
  102.           a = b(a, "+-3^+b+-f");
  103.           a ^= Number(e[1]) || 0;
  104.           0 > a && (a = (a & 2147483647) + 2147483648);
  105.           a `%= 1E6;
  106.           return a.toString() + "." + (a ^ h)
  107.       }
  108.    )
  109.    Return script
  110. }
  111.  
  112. GetJScripObject()  {
  113.    VarSetCapacity(tmpFile, (MAX_PATH := 260) << !!A_IsUnicode, 0)
  114.    DllCall("GetTempFileName", Str, A_Temp, Str, "AHK", UInt, 0, Str, tmpFile)
  115.    
  116.    (
  117.    <component>
  118.    <public><method name='eval'/></public>
  119.    <script language='JScript'></script>
  120.    </component>
  121.    ), % tmpFile
  122.    
  123.    JS := ObjBindMethod( ComObjGet("script:" . tmpFile), "eval" )
  124.    FileDelete, % tmpFile
  125.    Return JS
  126. }

Set it to a hotkey.  Once it's running, select some text, then use the hotkey.  It shows the text as Spanish, then converted back to English. 

Here is what it shows for the above top post.

---------------------------
Transpan.ahk
---------------------------
~~~~~~~~ As Spanish ~~~~~~~~
Mouser está cada vez va a arreglar esto? Fue un programa muy divertido y útil, pero debido a la nueva API cambia se rompió. Tengo buenos recuerdos de esta pieza de software y es un dolor de traducir de forma manual a través de un montón de idiomas.

~~~~~~~ Back to English ~~~~~~~
Mouser is ever going to fix this? It was a fun and useful program, but because of the new API changes broke. I have fond memories of this piece of software and it is a pain to translate manually through a lot of languages.

~~~~~~~~~~~~~~~~~~~~~~~~~
[Esc] to Cancel.
[OK] to send translation to clipboard; then paste as needed via Ctrl+v
---------------------------
OK   
---------------------------

Hopefully I'm not jinxing to whole darn thing by sharing, but [fingers crossed] it's worked flawlessly for 5 years! 

94
Screenshot Captor / Re: SC - smart screenshot folder
« on: August 01, 2020, 09:03 AM »
Another possibility might be to keep \SS on the Desktop, but change its "Hidden" property.  (?)

EDIT:  Also be sure to check some of the dangers of using Desktop for storage.
https://www.google.com/search?q=are+there+downsides+to+using+desktop+folder+as+storage&rlz=1C1CHBF_enUS907US907&oq=are+there+downsides+to+using+desktop+folder+as+storage&aqs=chrome..69i57.18006j0j8&sourceid=chrome&ie=UTF-8

EDIT again:
It looks like you should be able to monitor the folder and change its attributes with DropIt
http://www.dropitproject.com/
I can't get it to work though. 
I think maybe you can eight monitor OR change a folder, but not both??  Not sure. 

95
Clipboard Help+Spell / Re: Cannot move or delete clips
« on: July 30, 2020, 09:54 AM »
I find that things sometimes get locked if they're nor "Running As Administrator."  Maybe try that?

Pages: prev1 ... 14 15 16 17 18 [19] 20 21 22 23 24 ... 118next
Go to full version