aviaryan / Clipjump

:clipboard: Clipboard Manager for Windows, built in AutoHotkey
http://clipjump.sourceforge.net/
381 stars 61 forks source link

[Question] How disable images in clipboard? #133

Open Kristinita opened 7 years ago

Kristinita commented 7 years ago

1. Briefly

I don't want images in my clipboard. I want only link to images, that I can paste it.

2. Detail

I use ShareX program for my screenshots. I make screenshot → my screenshot add to remote server → I get link to screenshot in my clipboard. When I use Clipjump, sometimes I get links, but sometimes I get images, for example:

Image

It is unexpected behavior for me. Expected:

Expected

3. Did not help

4. Environment

Operating system and version: Windows 10 Enterprise LTSB 64-bit EN Clipjump: v12.5

Thanks.

aviaryan commented 7 years ago

When I use Clipjump, sometimes I get link, but sometimes I get images, for example:

When you get images, do you get just image or both link + image.

Kristinita commented 7 years ago

When you get images, do you get just image or both link + image.

Is it a question? I get image, not link. I can not quickly paste link to image.

Thanks.

aviaryan commented 7 years ago

Is it a question? I get image, not link. I can not quickly paste link to image.

If you are always using "add to remote server" option when using ShareX, I guess it will always upload to imgur and copy the link to Clipjump. But behind the scenes, what ShareX does it is that it first copies screenshot to clipboard and then uploads it to imgur. So there are two clipboard changes here and because of race condition, one or the other sustains.

However, if you completely want to disable images in clipboard, you will have to change code files. https://github.com/aviaryan/Clipjump/blob/master/Clipjump.ahk#L517

Change it as follows and then restart Clipjump.

else If CErrorlevel = 2
    {
                        setTimer, TooltipOff, 500
                        LASTCLIP := ""
                        return
            CURSAVE += 1 , TEMPSAVE := CURSAVE , LASTCLIP := ""

Let me know if this works. I am surprised why I didn't give an option to disable image in clipboard so far.

Kristinita commented 7 years ago

@aviaryan , so far it works for me. I get in clipboard link + image (but it would be nice, if would be possible disable images). Thank you!

Kristinita commented 7 years ago

Problem is reproduced for me 3 times.

I apply your changes → I restart Windows → I make first screenshot via ShareX → I can get no image and link:

Image and link

The preview/path can not be loaded

If I make the second and subsequents screenshots, I get expected behavior.

Thanks.

Kristinita commented 7 years ago

@aviaryan , maybe you add this changes in new release?

Thanks.