Merge pull request #5796 from Nightfirecat/revert-loot-manager-layout-change
Revert "Truncate NPC name instead of subtitle in Loot Tracker (#5740)"
This commit is contained in:
@@ -28,7 +28,6 @@ package net.runelite.client.plugins.loottracker;
|
|||||||
import com.google.common.base.Strings;
|
import com.google.common.base.Strings;
|
||||||
import java.awt.BorderLayout;
|
import java.awt.BorderLayout;
|
||||||
import java.awt.Color;
|
import java.awt.Color;
|
||||||
import java.awt.FlowLayout;
|
|
||||||
import java.awt.GridLayout;
|
import java.awt.GridLayout;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
@@ -67,24 +66,19 @@ class LootTrackerBox extends JPanel
|
|||||||
setLayout(new BorderLayout(0, 1));
|
setLayout(new BorderLayout(0, 1));
|
||||||
setBorder(new EmptyBorder(5, 0, 0, 0));
|
setBorder(new EmptyBorder(5, 0, 0, 0));
|
||||||
|
|
||||||
int gap = 5;
|
final JPanel logTitle = new JPanel(new BorderLayout(5, 0));
|
||||||
final JPanel logTitle = new JPanel(new BorderLayout(gap, 0));
|
|
||||||
logTitle.setBorder(new EmptyBorder(7, 7, 7, 7));
|
logTitle.setBorder(new EmptyBorder(7, 7, 7, 7));
|
||||||
logTitle.setBackground(ColorScheme.DARKER_GRAY_COLOR.darker());
|
logTitle.setBackground(ColorScheme.DARKER_GRAY_COLOR.darker());
|
||||||
|
|
||||||
final JLabel titleLabel = new JLabel(id);
|
final JLabel titleLabel = new JLabel(id);
|
||||||
titleLabel.setFont(FontManager.getRunescapeSmallFont());
|
titleLabel.setFont(FontManager.getRunescapeSmallFont());
|
||||||
titleLabel.setForeground(Color.WHITE);
|
titleLabel.setForeground(Color.WHITE);
|
||||||
titleLabel.setToolTipText(id);
|
|
||||||
logTitle.add(titleLabel, BorderLayout.CENTER);
|
|
||||||
|
|
||||||
final JPanel logSubtitleAndPrice = new JPanel(new FlowLayout(FlowLayout.CENTER, 0, 0));
|
logTitle.add(titleLabel, BorderLayout.WEST);
|
||||||
logSubtitleAndPrice.setBackground(ColorScheme.DARKER_GRAY_COLOR.darker());
|
|
||||||
|
|
||||||
subTitleLabel.setFont(FontManager.getRunescapeSmallFont());
|
subTitleLabel.setFont(FontManager.getRunescapeSmallFont());
|
||||||
subTitleLabel.setForeground(ColorScheme.LIGHT_GRAY_COLOR);
|
subTitleLabel.setForeground(ColorScheme.LIGHT_GRAY_COLOR);
|
||||||
subTitleLabel.setBorder(new EmptyBorder(0, 0, 0, gap));
|
logTitle.add(subTitleLabel, BorderLayout.CENTER);
|
||||||
logSubtitleAndPrice.add(subTitleLabel);
|
|
||||||
|
|
||||||
if (!Strings.isNullOrEmpty(subtitle))
|
if (!Strings.isNullOrEmpty(subtitle))
|
||||||
{
|
{
|
||||||
@@ -93,9 +87,7 @@ class LootTrackerBox extends JPanel
|
|||||||
|
|
||||||
priceLabel.setFont(FontManager.getRunescapeSmallFont());
|
priceLabel.setFont(FontManager.getRunescapeSmallFont());
|
||||||
priceLabel.setForeground(ColorScheme.LIGHT_GRAY_COLOR);
|
priceLabel.setForeground(ColorScheme.LIGHT_GRAY_COLOR);
|
||||||
logSubtitleAndPrice.add(priceLabel);
|
logTitle.add(priceLabel, BorderLayout.EAST);
|
||||||
|
|
||||||
logTitle.add(logSubtitleAndPrice, BorderLayout.EAST);
|
|
||||||
|
|
||||||
add(logTitle, BorderLayout.NORTH);
|
add(logTitle, BorderLayout.NORTH);
|
||||||
add(itemContainer, BorderLayout.CENTER);
|
add(itemContainer, BorderLayout.CENTER);
|
||||||
|
|||||||
Reference in New Issue
Block a user