Skip to content

Commit

Permalink
Merge pull request #768 from AntlerForce/master
Browse files Browse the repository at this point in the history
Make chat tabs a little bigger
  • Loading branch information
AntlerForce authored Sep 18, 2024
2 parents 307f372 + dea6ae0 commit ac0f008
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions LuaMenu/widgets/chobby/components/chat_windows.lua
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ function ChatWindows:init()
y = 0,
bottom = 9,
padding = {0, 0, 0, 0},
minTabWidth = 90,
tabs = {
[1] = (Configuration.debugMode and { name = "debug", caption = i18n("debug"), children = {
self.debugConsole.panel}, objectOverrideFont = WG.Chobby.Configuration:GetFont(1)}) or nil,
Expand Down Expand Up @@ -571,9 +572,9 @@ function ChatWindows:SetTabBadge(tabName, text)
local badge = ctrl._badge
if not ctrl._badge then
ctrl._badge = Label:New {
x = 30,
y = -20,
width = 14,
y = -36,
right = 5,
width = 14,
height = 12,
caption = text,
objectOverrideFont = WG.Chobby.Configuration:GetFont(8, "chat_badge_black", {
Expand Down Expand Up @@ -769,8 +770,8 @@ function ChatWindows:UpdateChannels(channelsArray)
end

function ChatWindows:UpdateJoinPosition()
self.joinButton:SetPos(#self.tabPanel.tabBar.children * 70 + 10)
self.tabBarFudgeHolder:SetPos(nil, nil, #self.tabPanel.tabBar.children * 70 + 5)
self.joinButton:SetPos(#self.tabPanel.tabBar.children * 90 + 10)
self.tabBarFudgeHolder:SetPos(nil, nil, #self.tabPanel.tabBar.children * 90 + 5)
end

function ChatWindows:GetChannelConsole(chanName)
Expand Down Expand Up @@ -807,7 +808,7 @@ function ChatWindows:GetChannelConsole(chanName)
local tooltip = nil
local origCaption = caption
local fontSize = 1
caption = StringUtilities.GetTruncatedStringWithDotDot(caption, Configuration:GetFont(fontSize), 70)
caption = StringUtilities.GetTruncatedStringWithDotDot(caption, Configuration:GetFont(fontSize), 86)
if origCaption ~= caption then
tooltip = origCaption
end
Expand Down Expand Up @@ -915,7 +916,7 @@ function ChatWindows:GetPrivateChatConsole(userName, switchTo)
local tooltip = nil
local origCaption = caption
local fontSize = 1
caption = StringUtilities.GetTruncatedStringWithDotDot(caption, Configuration:GetFont(fontSize), 70)
caption = StringUtilities.GetTruncatedStringWithDotDot(caption, Configuration:GetFont(fontSize), 86)
if origCaption ~= caption then
tooltip = origCaption
end
Expand Down

0 comments on commit ac0f008

Please sign in to comment.