runelite-client: add tooltip font type dropdown
This commit is contained in:
@@ -189,11 +189,22 @@ public interface RuneLiteConfig extends Config
|
|||||||
return FontType.SMALL;
|
return FontType.SMALL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ConfigItem(
|
||||||
|
keyName = "tooltipFontType",
|
||||||
|
name = "Tooltip Font",
|
||||||
|
description = "Configures what font type is used for in-game tooltips such as food stats, NPC names, etc.",
|
||||||
|
position = 31
|
||||||
|
)
|
||||||
|
default FontType tooltipFontType()
|
||||||
|
{
|
||||||
|
return FontType.SMALL;
|
||||||
|
}
|
||||||
|
|
||||||
@ConfigItem(
|
@ConfigItem(
|
||||||
keyName = "infoBoxVertical",
|
keyName = "infoBoxVertical",
|
||||||
name = "Display infoboxes vertically",
|
name = "Display infoboxes vertically",
|
||||||
description = "Toggles the infoboxes to display vertically",
|
description = "Toggles the infoboxes to display vertically",
|
||||||
position = 31
|
position = 32
|
||||||
)
|
)
|
||||||
default boolean infoBoxVertical()
|
default boolean infoBoxVertical()
|
||||||
{
|
{
|
||||||
@@ -204,7 +215,7 @@ public interface RuneLiteConfig extends Config
|
|||||||
keyName = "infoBoxWrap",
|
keyName = "infoBoxWrap",
|
||||||
name = "Infobox wrap count",
|
name = "Infobox wrap count",
|
||||||
description = "Configures the amount of infoboxes shown before wrapping",
|
description = "Configures the amount of infoboxes shown before wrapping",
|
||||||
position = 32
|
position = 33
|
||||||
)
|
)
|
||||||
default int infoBoxWrap()
|
default int infoBoxWrap()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -517,7 +517,7 @@ public class OverlayRenderer extends MouseListener implements KeyListener
|
|||||||
}
|
}
|
||||||
else if (position == OverlayPosition.TOOLTIP)
|
else if (position == OverlayPosition.TOOLTIP)
|
||||||
{
|
{
|
||||||
subGraphics.setFont(FontManager.getRunescapeSmallFont());
|
subGraphics.setFont(runeLiteConfig.tooltipFontType().getFont());
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ public class TooltipComponent implements RenderableEntity
|
|||||||
// Tooltip size
|
// Tooltip size
|
||||||
final FontMetrics metrics = graphics.getFontMetrics();
|
final FontMetrics metrics = graphics.getFontMetrics();
|
||||||
final int textDescent = metrics.getDescent();
|
final int textDescent = metrics.getDescent();
|
||||||
final int textHeight = graphics.getFontMetrics().getHeight();
|
final int textHeight = metrics.getHeight();
|
||||||
int tooltipWidth = 0;
|
int tooltipWidth = 0;
|
||||||
int tooltipHeight = 0;
|
int tooltipHeight = 0;
|
||||||
String[] lines = BR.split(text);
|
String[] lines = BR.split(text);
|
||||||
|
|||||||
Reference in New Issue
Block a user