Conversation
This new --select-and-resize option acts like the --select option, except that it is possible to move and resize rectangle once it's drawn. The action may still be canceled by pressing Escape or right-clicking. The rectangle is accepted (screenshot is taken) when pressing Enter. This feature is implemented by adding a selection state, which is, at any time, one of the following: * drawing a rectangle (equivalent to old `self.started`) * moving the rectangle * resizing using the top-right corner * resizing using the bottom-right corner * resizing using the bottom-left corner * resizing using the top-left corner * free to start one of the above Bounds checking is implemented for all actions to make sure the rectangle position/dimension do not go beyond the screen limits.
539f095 to
a22265e
Compare
|
awesome! i wanted to implement something like this, i'll take a look later |
|
Do you think that .webm recording could be added on later too? it'd be pretty awesome |
Everything is possible, but recordMyDesktop is already close to this. |
|
unfortunately recordmydesktop does not let you select a portion of the screen using your mouse or save as .webm (needed for uploading to gfycat) |
|
Which is why I wrote close: you may use One thing I'm thinking about is to split the rectangle selection code from escrotum, and create a simple app. which returns the selection's position and dimension. Then we could add the WDYT? |
|
I actually added webm recording using ffmpeg in my fork some time ago but separating it seems to make more sense. I'm using a wrapper script anyway that calls escrotum and then directly uploads the screenshot/video or other files. |
|
About video recording, i created the issue here #24 |
|
There are lots of functions in here that are essentially copypasted versions of others with very minor variations for each side, and for each corner. You really should find some other way to do this. There are
It's way too much code duplication. |
|
@eepp hey, will you try to reduce the code duplication? i'll like to have this feature merged :) |
|
What do you propose? There are four All the I guess top/left and bottom/right functions could be merged somehow. |
See commit message.