vivelin / superscrot Goto Github PK
View Code? Open in Web Editor NEWA better screenshot uploader.
License: MIT License
A better screenshot uploader.
License: MIT License
Add setting to make Superscrot autostart with windows.
Try/catch everywhere is not the way to go, and also async
/await
does weird things
Suspend/resume isn't that useful if it still owns the hook, and it's not like Superscrot is too slow that you can't simply quit it and start it again later.
Instead, act like the preview dialogue is disabled, but queue the screenshot somewhere instead of uploading immediately. Won't work without a UI (#30) for uploading afterwards, though. Disable region captures since the "overlay" is really just a Windows Form which won't work in situations where suspending is useful (e.g. fullscreen games).
A file named "rav.png" would match a file named "twitteravatar2.png"
As private keys with pass phrase are not supported, generate an OpenSSH private key without a pass phrase.
Store it in %AppData%\Superscrot next to the config file.
Also show the public key or a button to copy the public key to the clipboard, in a format accepted by ~/.ssh/authorized_keys.
Manager.GetUploader
into a property that returns the current instance instead of a new one every timeManager.Uploader
-derived classes a constructor instead of making a session in Upload
Manager.uploader
when configuration changesAt least present the issue to the user. While it could be hard to find why this happens, leaving the user completely in the dark (besides from the log) when it crashes is not a good thing.
System.ArgumentException: Ongeldige parameter.
bij System.Drawing.Image.FromStream(Stream stream, Boolean useEmbeddedColorManagement, Boolean validateImageData)
bij Superscrot.Screenshot.FromFile(String path)
System.ArgumentNullException: Waarde kan niet null zijn.
Parameternaam: screenshot
bij Superscrot.Manager.<UploadScreenshot>d__15.MoveNext()
--- Einde van stacktracering vanaf vorige locatie waar uitzondering is opgetreden ---
bij System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
bij System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
bij Superscrot.Manager.<UploadClipboard>d__17.MoveNext()
--- Einde van stacktracering vanaf vorige locatie waar uitzondering is opgetreden ---
bij System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
bij System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
bij Superscrot.Manager.<KeyPressed>d__28.MoveNext()
Allow saving multiple naming patterns and be able to select between them in the upload dialog.
Maybe even chose between multiple upload paths and servers?
Some (although older) screenshots had file names encoded as ISO-8859-1 despite the server's locale being set to UTF-8. Since all my screenshots are from Superscrot, it might be worth investigating if Superscrot uploads the files with weird encoding for the name.
SSH.NET supports public key authentication, but Superscrot does not. There is an unofficial patch to support Pageant, but I can't seem to apply to patch to the SSH.NET source code, as if it were for a different version.
Pageant support is pretty much a requirement, you don't want to enter your key file passphrase for every upload, nor would you want to store it in settings.
Happened a second time.
Stacktrace:
System.Runtime.InteropServices.ExternalException (0x800401D0): Requested Clipboard operation did not succeed.
at System.Windows.Forms.Clipboard.ThrowIfFailed(Int32 hr)
at System.Windows.Forms.Clipboard.SetDataObject(Object data, Boolean copy, Int32 retryTimes, Int32 retryDelay)
at System.Windows.Forms.Clipboard.SetText(String text, TextDataFormat format)
at Superscrot.Manager.d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Superscrot.Manager.d__1c.MoveNext()
/<Year>/<Month>/filename.png
are possible, also Unix timestampIn the dialog that shows up after you've taken a screenshot/selected an image for uploading, you should be able to see how big the image is (in kb/mb).
Might not be possible for screenshots but at least show it for images that are already files.
Superscrot currently doesn't have an icon. Having an icon is important not only because it's show on the application itself and the ClickOnce installer (provided I'll keep using it), but also because it's shown in the tray.
Roughly, it should do exactly what the Manager
class (and to some extent, Program
) currently does: own the hotkey hook, start uploads and report on successes and errors.
As a result of this, the user interface itself would probably be mostly empty. However, it would be a nice place to show the list of taken screenshots (History
) that can be deleted. Additionally, failed screenshots could be added to that list with the option to re-upload them.
e.g. save an image at 50% size on 200% DPI screens.
Do a quick check if the image is already found on the server when uploading an already existing image. Considering it will still contain the original filename, just look for that.
Warn the user if a match is found and ask if he wants to cancel, overwrite, or keep both files.
With a possible Dropbox-style sync thing. Set a local screenshot folder, then monitor the folder, do the SteamScreenshotManager thing and then upload them.
Two options:
x
minutes, do a two-way sync;It's time for the console to go. We should move all the console writelines to tracing and disable tracing by default. Only trace errors and warnings.
Add a balloon tip (or something similar) to notify visually that an image is uploaded
In the pre2 release at least.
If you suspend and then resume an upload, the tray icon no longer shows that its uploading. It's reset to be blank.
Create a user interface that shows screenshots that were taken during this session, whether uploaded (history) or not (queue).
The ability to suppress uploading screenshots and to upload all queued screenshots at once would be nice to have.
Requested by @Fearswe who's probably too lazy to do this himself.
Get a directory listing and check if any file names contain the name of the file to upload.
ClickOnce is more trouble than it's worth.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.