LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-19-2020, 01:12 PM   #1
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,694
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
intercepting keyboard shortcuts in an app


i am running Xubuntu 18.04.5 with a keyboard shortcut set to have the PrtSc key run a program that captures a screenshot. i ran across an app that is reacting to that. i have a text input open in an app named "Gramps" (genealogy software) to type in the name of a new family tree. then i press PrtSc. it closes the input and sets up the default name.

i thought a shortcut key press would not be received by anything else. how can it be doing this? the app runs in Python3.
 
Old 11-19-2020, 01:25 PM   #2
rtmistler
Moderator
 
Registered: Mar 2011
Location: USA
Distribution: MINT Debian, Angstrom, SUSE, Ubuntu, Debian
Posts: 9,885
Blog Entries: 13

Rep: Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931Reputation: 4931
One distro I had, print screen would result in a small widget or other which popped up and allowed me to open a more formal viewer or editor, or just open the file location where the screenshot was stored. I sort of felt that was a good/normal behavior. I guess it wasn't necessarily a whole app, nor one which specifically required python, but instead it was part of the window manager I was using.
 
Old 11-19-2020, 06:35 PM   #3
Skaperen
Senior Member
 
Registered: May 2009
Location: center of singularity
Distribution: Xubuntu, Ubuntu, Slackware, Amazon Linux, OpenBSD, LFS (on Sparc_32 and i386)
Posts: 2,694

Original Poster
Blog Entries: 31

Rep: Reputation: 176Reputation: 176
Quote:
Originally Posted by rtmistler View Post
One distro I had, print screen would result in a small widget or other which popped up and allowed me to open a more formal viewer or editor, or just open the file location where the screenshot was stored. I sort of felt that was a good/normal behavior. I guess it wasn't necessarily a whole app, nor one which specifically required python, but instead it was part of the window manager I was using.
it could have invoked some executable that did both, or one that invoked something to do one of those and did the other itself, or one that invoked something for both.

in my case, it is my own code (written in Python3) that invokes a binary executable to get the results after it determines the name to give it, creates the directory it goes in, and changes to it. i can't find any messaging in that binary.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
KDE Keyboard Shortcuts with different Keyboard Layout hellblade Linux - Software 5 04-18-2006 12:40 AM
metacity: pass keyboard shortcuts on when particular app is running Samsara Linux - Software 1 01-06-2006 11:37 AM
how to add & register filter for intercepting the packets outgoing on port 80? jayashri Programming 2 11-08-2004 01:30 PM
problem in intercepting sys_write system call appas Programming 7 09-03-2004 12:33 PM
Assigning keyboard shortcuts to keyboard keys the who Linux - Hardware 3 02-20-2004 09:36 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 10:30 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration