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
Related
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:
How to make JTextArea Stick to the window
(2 answers)
Closed 8 years ago.
I am designing a frame in java swing, which has 2 buttons on the end as I resize the window the gap between buttons are spread and they go far.
Please provide me solution as i want buttons to be in the bottom corner and the frame is resized the spaces should not increase.
Put the buttons in a right aligned flow layout, then add the flow layout (the panel) to the page end of a border layout.
This question already has answers here:
Hovering over JButtons and displaying a message
(3 answers)
Closed 8 years ago.
I would like to find out how I can link a JLabel to a JButton, so that when ever the button is hovered over, a piece of text appears. Sort of like a tool tip, indicating what this button does before it's clicked.
Why ask for something "sort of like a tool tip" when you can use just that, a tool tip? Simply set the JButton's tool tip text via the JComponent setToolTipText(...) method (which JButton inherits) and you're there!
myButton.setToolTipText("Foo");
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.
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?