This question already has answers here:
Disable Screenshot of my Swing Window
(5 answers)
Closed 9 years ago.
Can I disable the print screen button, while my application is on? Can we use the print screen button as one of the coded keyboard inputs, and equal it to do nothing?
There's no way to do this without affecting the Operating System settings via registry edits, etc.
A user can always unfocus your application, and press print screen taking a capture of the whole screen otherwise.
Related
This question already has answers here:
Disable keyboard on EditText
(18 answers)
Closed 1 year ago.
I am trying to create calculator application in Android Studio using Java, I have EditText for showing result. When I focus this input Keyboard is showing. But I don't want to see keyboard in focus event as in normal calculator. Is there any way to solve this, or can I use other element either than EditText, I have used getWindow().setSoftInputMode(WindowManager.LayoutParams.SOFT_INPUT_STATE_ALWAYS_HIDDEN); in OnCreate method, but it doesn't work
EditText is desired to.. edit text. do you want to allow user for editing result?
if not just replace EditText with TextView and then any keyboard won't show up
if you still want this field to be editable then take a look a THIS QA, you will find there plenty of methods for blocking keyboard pop up automatically
This question already has answers here:
Disable JButton focus border
(5 answers)
Closed 4 years ago.
i'm new there. My first issue:
When i start my GUI java swing application in Window Builder, first object is always selected
and when i click anything (button or anything) it's show like it's clicked and i don't want it to show. What command for this?
You should use this:
button.setFocusPainted(false);
java, swing, awt, remove focus from all objects
This question already has answers here:
Best way to store data between program runs in java?
(11 answers)
How can I save the state of my program and then load it?
(2 answers)
Closed 5 years ago.
For example, if I had checked a JCheckBox when I opened the program, how would I make the it remember the status of the checkbox so that the next time I open up the JFrame, the box stays checked.
I would also like to extend this question to other swing components like radiobuttons, color chooser, etc.
Attempted solution: The only way I can think of it is possibly making a new file so that the program can update and read the status of it and adjust the swing components when opened. However, this is too inefficient. I read online something about cookies but I am not too sure.
This question already has an answer here:
Using transparent window in both Java 6 and Java 7
(1 answer)
Closed 9 years ago.
I have a JDialog which gets open once you click on a Button. I wanted to show an arrow indicator towards the button when the JDialog gets opened. For this I require extreme portion of JDialog (towards the Button) to be transparent so that I can paint or add an Image of arrow.
How can I make the JDialog a transparent Dialog with some portion as transparent.
Setting JDialog opacity by Timer
this might help you. In general method setOpacity() is the one you want
This question already exists:
Closed 10 years ago.
Possible Duplicate:
How to click at a certain location that fits for all phones?
So basically I want it so I tap on my certain area and when I tap it it will zoom into a certain area in the background picture
This is my image
Basically if you click on the playground it will zoom into that area.
How can I do this?
Might I simply suggest the classes GestureDetector and MotionEvent?