GUI: fixed wrong font sizes in table's and feedback panel popup hints

This commit is contained in:
Oleg Agafonov 2024-05-07 15:33:40 +04:00
parent d3437c9b1e
commit d138e33b04
2 changed files with 2 additions and 2 deletions

View file

@ -67,7 +67,7 @@ public class MageTextArea extends MageEditorPane {
if (panelWidth > 0 && MageTextArea.this.getPreferredSize().getWidth() > panelWidth) {
String tooltip = "<html><center><body style='font-family:Dialog;font-size:"
+ GUISizeHelper.gameDialogAreaFontSizeBig
+ ";color: #FFFFFF'><p width='500'>" + basicText + "</p></body></html>";
+ "pt;color: #FFFFFF'><p width='500'>" + basicText + "</p></body></html>";
MageTextArea.super.setToolTipText(tooltip);
} else {
MageTextArea.super.setToolTipText(null);

View file

@ -107,7 +107,7 @@ public class MageTable extends JTable {
public static String textToHtmlWithSize(String text, Font font) {
if (text != null && !text.toLowerCase(Locale.ENGLISH).startsWith("<html>")) {
return "<html><p style=\"font-size: " + font.getSize() + ";\">" + text + "</p>";
return "<html><p style=\"font-size: " + font.getSize() + "pt;\">" + text + "</p>";
}
return text;
}