Перенос.

This commit is contained in:
2023-09-17 22:13:42 +03:00
parent dd2e0ca7e0
commit 629d8b8477
1239 changed files with 61161 additions and 1 deletions

View File

@@ -0,0 +1,15 @@
package Common.UI.Label;
import javax.swing.*;
public class ShortLabel extends JLabel {
int max = 0;
public ShortLabel(int max_in) {
max = max_in;
}
@Override
public void setText(String text_in) {
if ((max > 0) && (text_in.length() > max)) {
super.setText(text_in.substring(0, max - 1) + "...");
} else super.setText(text_in);
setToolTipText(text_in);
}
}