Hey, I am creating a calculator program, with some small buttons, I want one of the buttons to have "Ans" on them, but whenever I make the JButton smaller then 50, 50, it will show three dots. "...", how can I remove these dots and show the normal text given?
Probably this because margin of your button is too big.
Try this:
myButton.setMargin(new Insets(0, 0, 0, 0));
You can also turn off border:
button.setBorder(null);