Bug 446710 - --clipboard commandline argument not recognised
Summary: --clipboard commandline argument not recognised
Status: RESOLVED FIXED
Alias: None
Product: Spectacle
Classification: Applications
Component: General (show other bugs)
Version: 21.08.3
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Boudhayan Gupta
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-12-09 04:25 UTC by Dave
Modified: 2021-12-13 23:33 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In: 22.04
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dave 2021-12-09 04:25:22 UTC
SUMMARY
I wanted to make a shortcut as obvious as possible when reading it and the man page for spectacle says:

       -c, --clipboard
           In background mode, copy screenshot to clipboard.

however, invoking `spectacle --region --clipboard --background` results in:

spectacle: Unknown option 'clipboard'

STEPS TO REPRODUCE
1. run `spectacle --region --clipboard --background`
2. see error about unknown option 'clipboard'


OBSERVED RESULT
spectacle doesn't launch in capture mode & prints an error

EXPECTED RESULT
spectacle should launch in capture mode

SOFTWARE/OS VERSIONS
Operating System: Gentoo Linux
KDE Plasma Version: 5.22.5
KDE Frameworks Version: 5.85.0
Qt Version: 5.15.2
Kernel Version: 5.14.15-gentoo-x86_64 (64-bit)
Graphics Platform: X11
Processors: 16 × 11th Gen Intel® Core™ i9-11900KF @ 3.50GHz
Memory: 62.7 GiB of RAM
Graphics Processor: AMD Radeon RX 5700
Comment 1 Nate Graham 2021-12-09 19:28:42 UTC
Can confirm.
Comment 2 Antonio Prcela 2021-12-09 21:31:37 UTC
Confirmed here too
Interesting that it works when -c used instead of --clipboard. Will take a look as soon as I have more time
Comment 3 Bug Janitor Service 2021-12-09 22:08:19 UTC
A possibly relevant merge request was started @ https://invent.kde.org/graphics/spectacle/-/merge_requests/110
Comment 4 Nate Graham 2021-12-13 23:28:02 UTC
Git commit 8630dbcc173cdb96b2a6ba02bedb75880db73a92 by Nate Graham, on behalf of Antonio Prcela.
Committed on 13/12/2021 at 23:26.
Pushed by ngraham into branch 'master'.

Inconsistency between man page and actual available command line options

Man page mentions `--clipboard` but in `SpectacleCore.cpp` it actually expects `--copy-image`.
Also, `--copy-path` is not mentioned at all in the man page.
Change man page to reflect codee and add `--copy-path` to man page.

M  +8    -1    doc/man-spectacle.1.docbook
M  +1    -1    src/SpectacleCore.cpp

https://invent.kde.org/graphics/spectacle/commit/8630dbcc173cdb96b2a6ba02bedb75880db73a92