Skip to content

Commit 285b163

Browse files
committed
Fonts
* Updated Fonts * Updated Sliders to Drop Downs for Fonts * Added Outline for Fonts
1 parent c5774d8 commit 285b163

14 files changed

Lines changed: 525 additions & 228 deletions

File tree

Core.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ local DEFAULTS = {
2929
height = 400,
3030
fontSize = 11,
3131
fontMedia = nil,
32+
fontFlags = "OUTLINE",
3233
backgroundMedia = nil,
3334
minimap = { hide = false },
3435
managedWindowRestoreState = nil,

Locales/deDE.lua

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,17 @@ L["Config_ResetOrder"] = "Reihenfolge der Abschnitte zurücksetzen"
8080
L["Config_ProfessionColors"] = "Handwerksfarben"
8181
L["WIDTH"] = "BREITE"
8282
L["HEIGHT"] = "HÖHE"
83-
L["Config_FontSize"] = "SCHRIFTGRÖSSE"
84-
L["Config_SharedMedia"] = "Fenster Layout"
85-
L["Config_Font"] = "Schriftart"
86-
L["Config_BackgroundTexture"] = "Hintergrund Textur"
83+
L["Config_FontSize"] = "SCHRIFTGRÖSSE"
84+
L["Config_SharedMedia"] = "Fenster Layout"
85+
L["Config_Font"] = "Schriftart"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
93+
L["Config_BackgroundTexture"] = "Hintergrund Textur"
8794
L["BACKGROUND"] = "HINTERGRUND"
8895
L["SCALE"] = "SKALIERUNG"
8996
L["Config_HeaderColor"] = "Kopfzeilenfarbe"

Locales/enUS.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,13 @@ L["HEIGHT"] = "HEIGHT"
8282
L["Config_FontSize"] = "FONT SIZE"
8383
L["Config_SharedMedia"] = "SHARED MEDIA"
8484
L["Config_Font"] = "Font"
85+
L["Config_FontStyle"] = "Font Style"
86+
L["Config_FontStyleOutline"] = "Outline"
87+
L["Config_FontStyleNone"] = "None"
88+
L["Config_FontStyleThick"] = "Thick Outline"
89+
L["Config_FontStyleMono"] = "Monochrome"
90+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
91+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
8592
L["Config_BackgroundTexture"] = "Background Texture"
8693
L["BACKGROUND"] = "BACKGROUND"
8794
L["SCALE"] = "SCALE"

Locales/esMX.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,13 @@ L["HEIGHT"] = "ALTO"
8383
L["Config_FontSize"] = "TAMAÑO DE FUENTE"
8484
L["Config_SharedMedia"] = "Media compartido"
8585
L["Config_Font"] = "Fuente"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
8693
L["Config_BackgroundTexture"] = "Textura de fondo"
8794
L["BACKGROUND"] = "FONDO"
8895
L["SCALE"] = "ESCALA"

Locales/frFR.lua

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,10 +80,17 @@ L["Config_ResetOrder"] = "Réinitialiser l'ordre des sections"
8080
L["Config_ProfessionColors"] = "COULEURS DES MÉTIERS"
8181
L["WIDTH"] = "LARGEUR"
8282
L["HEIGHT"] = "HAUTEUR"
83-
L["Config_FontSize"] = "TAILLE DE LA POLICE"
84-
L["Config_SharedMedia"] = "MÉDIAS PARTAGÉS"
85-
L["Config_Font"] = "Police"
86-
L["Config_BackgroundTexture"] = "Texture d'arrière-plan"
83+
L["Config_FontSize"] = "TAILLE DE LA POLICE"
84+
L["Config_SharedMedia"] = "MÉDIAS PARTAGÉS"
85+
L["Config_Font"] = "Police"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
93+
L["Config_BackgroundTexture"] = "Texture d'arrière-plan"
8794
L["BACKGROUND"] = "ARRIÈRE-PLAN"
8895
L["SCALE"] = "ÉCHELLE"
8996
L["Config_HeaderColor"] = "Couleur d'en-tête"

Locales/ruRU.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,13 @@ L["HEIGHT"] = "ВЫСОТА"
8383
L["Config_FontSize"] = "РАЗМЕР ШРИФТА"
8484
L["Config_SharedMedia"] = "ОБЩИЕ МЕДИА"
8585
L["Config_Font"] = "Шрифт"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
8693
L["Config_BackgroundTexture"] = "Текстура фона"
8794
L["BACKGROUND"] = "ФОН"
8895
L["SCALE"] = "МАСШТАБ"

Locales/zhCN.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,13 @@ L["HEIGHT"] = "高度"
8383
L["Config_FontSize"] = "字体大小"
8484
L["Config_SharedMedia"] = "共享材质"
8585
L["Config_Font"] = "字体"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
8693
L["Config_BackgroundTexture"] = "背景材质"
8794
L["BACKGROUND"] = "背景"
8895
L["SCALE"] = "缩放"

Locales/zhTW.lua

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,13 @@ L["HEIGHT"] = "高度"
8383
L["Config_FontSize"] = "字體大小"
8484
L["Config_SharedMedia"] = "SHARED MEDIA"
8585
L["Config_Font"] = "字體"
86+
L["Config_FontStyle"] = "Font Style"
87+
L["Config_FontStyleOutline"] = "Outline"
88+
L["Config_FontStyleNone"] = "None"
89+
L["Config_FontStyleThick"] = "Thick Outline"
90+
L["Config_FontStyleMono"] = "Monochrome"
91+
L["Config_FontStyleMonoOutline"] = "Monochrome Outline"
92+
L["Config_FontStyleMonoThick"] = "Monochrome Thick Outline"
8693
L["Config_BackgroundTexture"] = "背景材質"
8794
L["BACKGROUND"] = "背景"
8895
L["SCALE"] = "縮放"

Modules/ProfessionKnowledge.lua

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,17 @@ local function RefreshFonts()
3737
FONT_ROWS = ns.FONT_ROWS or FONT_ROWS
3838
end
3939

40+
local function GetFontFlags()
41+
if ns.GetFontFlags then
42+
local flags = ns.GetFontFlags()
43+
if flags ~= nil then
44+
return flags
45+
end
46+
end
47+
48+
return "OUTLINE"
49+
end
50+
4051
local DEFAULT_W = 350
4152
local DEFAULT_H = 450
4253
local MIN_W = 250
@@ -525,7 +536,7 @@ local function BuildGatheringLocationsFrame(isRetry)
525536
)
526537

527538
local titleTxt = titleBar:CreateFontString(nil, "OVERLAY")
528-
titleTxt:SetFont(FONT_HEADERS, 10, "OUTLINE")
539+
titleTxt:SetFont(FONT_HEADERS, 10, GetFontFlags())
529540
titleTxt:SetPoint("LEFT", titleIcon, "RIGHT", 5, 0)
530541
titleTxt:SetJustifyH("LEFT")
531542
titleTxt:SetText(L["ProfKnowledge_Title"])
@@ -668,7 +679,7 @@ local function BuildGatheringLocationsFrame(isRetry)
668679
local cr, cg, cb = GetProfessionColor(profession.key)
669680
local doneSources, totalSources, kpDone, kpTotal = ProfessionStats(profession)
670681
local header = content:CreateFontString(nil, "OVERLAY")
671-
header:SetFont(FONT_ROWS, fontSize + 2, "OUTLINE")
682+
header:SetFont(FONT_ROWS, fontSize + 2, GetFontFlags())
672683
header:SetPoint("TOPLEFT", content, "TOPLEFT", 8, -yOff)
673684
header:SetTextColor(cr, cg, cb, 1.0)
674685
header:SetText(string.format(L["ProfKnowledge_HeaderFormat"], profession.label, doneSources, totalSources, kpDone, kpTotal))
@@ -678,7 +689,7 @@ local function BuildGatheringLocationsFrame(isRetry)
678689
if ShowInKnowledgeTracker(section) then
679690
local sectionDone, sectionTotal = SectionStats(section)
680691
local sectionHeader = content:CreateFontString(nil, "OVERLAY")
681-
sectionHeader:SetFont(FONT_ROWS, fontSize, "OUTLINE")
692+
sectionHeader:SetFont(FONT_ROWS, fontSize, GetFontFlags())
682693
sectionHeader:SetPoint("TOPLEFT", content, "TOPLEFT", 16, -yOff)
683694
sectionHeader:SetTextColor(0.85, 0.85, 0.88, 0.95)
684695
sectionHeader:SetText(string.format(L["ProfKnowledge_SectionFormat"], section.label, sectionDone, sectionTotal))
@@ -707,7 +718,7 @@ local function BuildGatheringLocationsFrame(isRetry)
707718
nameText:SetTextColor(done and 0.45 or 0.90, done and 0.45 or 0.90, done and 0.45 or 0.90)
708719

709720
local statusText = row:CreateFontString(nil, "OVERLAY")
710-
statusText:SetFont(FONT_ROWS, fontSize - 1, "OUTLINE")
721+
statusText:SetFont(FONT_ROWS, fontSize - 1, GetFontFlags())
711722
statusText:SetPoint("RIGHT", row, "RIGHT", -2, 0)
712723
statusText:SetWidth(78)
713724
statusText:SetJustifyH("RIGHT")
@@ -772,7 +783,7 @@ local function BuildGatheringLocationsFrame(isRetry)
772783

773784
if yOff == 0 then
774785
local emptyText = content:CreateFontString(nil, "OVERLAY")
775-
emptyText:SetFont(FONT_ROWS, fontSize, "OUTLINE")
786+
emptyText:SetFont(FONT_ROWS, fontSize, GetFontFlags())
776787
emptyText:SetPoint("TOPLEFT", content, "TOPLEFT", 10, -10)
777788
emptyText:SetPoint("TOPRIGHT", content, "TOPRIGHT", -10, -10)
778789
emptyText:SetJustifyH("LEFT")
@@ -940,7 +951,7 @@ local function BuildGatheringConfigFrame()
940951
tbar:SetScript("OnDragStart", function() frame:StartMoving() end)
941952
tbar:SetScript("OnDragStop", function() frame:StopMovingOrSizing() end)
942953
local ttitle = tbar:CreateFontString(nil, "OVERLAY")
943-
ttitle:SetFont(FONT_HEADERS, 10, "OUTLINE")
954+
ttitle:SetFont(FONT_HEADERS, 10, GetFontFlags())
944955
ttitle:SetText(L["ProfKnowledge_Config_Title"])
945956
ttitle:SetPoint("LEFT", tbar, "LEFT", 8, 0)
946957
CloseButton(tbar, function() frame:Hide() end)
@@ -1001,7 +1012,7 @@ PopulateGatheringConfig = function(frame)
10011012
btn:SetBackdropBorderColor(isActive and 0.22 or 0.16, isActive and 0.82 or 0.28, isActive and 0.70 or 0.36, 1)
10021013

10031014
local lbl = btn:CreateFontString(nil, "OVERLAY")
1004-
lbl:SetFont(FONT_ROWS, cfgFs, "OUTLINE")
1015+
lbl:SetFont(FONT_ROWS, cfgFs, GetFontFlags())
10051016
lbl:SetPoint("CENTER")
10061017
lbl:SetText(tab.label)
10071018
lbl:SetTextColor(isActive and 0.85 or 0.62, isActive and 1.0 or 0.75, isActive and 0.92 or 0.70)
@@ -1085,7 +1096,7 @@ PopulateGatheringConfig = function(frame)
10851096
end, profession.label .. L["Color_Reset_Hint"])
10861097
swatch:SetPoint("RIGHT", row, "RIGHT", 0, 0)
10871098
nameLbl = row:CreateFontString(nil, "OVERLAY")
1088-
nameLbl:SetFont(FONT_ROWS, 10, "OUTLINE")
1099+
nameLbl:SetFont(FONT_ROWS, 10, GetFontFlags())
10891100
nameLbl:SetPoint("LEFT", row, "LEFT", 0, 0)
10901101
nameLbl:SetPoint("RIGHT", swatch, "LEFT", -4, 0)
10911102
nameLbl:SetJustifyH("LEFT")

Modules/Rares.lua

Lines changed: 21 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,17 @@ local function RefreshFonts()
3131
FONT_ROWS = ns.FONT_ROWS or FONT_ROWS
3232
end
3333

34+
local function GetFontFlags()
35+
if ns.GetFontFlags then
36+
local flags = ns.GetFontFlags()
37+
if flags ~= nil then
38+
return flags
39+
end
40+
end
41+
42+
return "OUTLINE"
43+
end
44+
3445
local MAP_TO_ZONE_KEY = {
3546
[2395] = "eversong",
3647
[2393] = "eversong",
@@ -428,14 +439,14 @@ BuildRaresFrame = function()
428439
UpdateMinBtn()
429440

430441
local totalDoneLabel = titleBar:CreateFontString(nil, "OVERLAY")
431-
totalDoneLabel:SetFont(FONT_ROWS, 9, "OUTLINE")
442+
totalDoneLabel:SetFont(FONT_ROWS, 9, GetFontFlags())
432443
totalDoneLabel:SetTextColor(0.45, 0.45, 0.55)
433444
totalDoneLabel:SetPoint("RIGHT", minBtn, "LEFT", -6, 0)
434445
totalDoneLabel:SetWordWrap(false)
435446
f.totalDoneLabel = totalDoneLabel
436447

437448
local titleTxt = titleBar:CreateFontString(nil, "OVERLAY")
438-
titleTxt:SetFont(FONT_HEADERS, 10, "OUTLINE")
449+
titleTxt:SetFont(FONT_HEADERS, 10, GetFontFlags())
439450
titleTxt:SetPoint("LEFT", titleIcon, "RIGHT", 5, 0)
440451
titleTxt:SetPoint("RIGHT", totalDoneLabel, "LEFT", -6, 0)
441452
titleTxt:SetJustifyH("LEFT")
@@ -654,18 +665,18 @@ BuildRaresFrame = function()
654665
stripe:SetColorTexture(cr, cg, cb, 1)
655666

656667
local arrow = zHdr:CreateFontString(nil, "OVERLAY")
657-
arrow:SetFont(FONT_ROWS, 9, "OUTLINE")
668+
arrow:SetFont(FONT_ROWS, 9, GetFontFlags())
658669
arrow:SetPoint("LEFT", zHdr, "LEFT", 10, 1)
659670
arrow:SetText(isCollapsed and "|cff555555+|r" or "|cff777777-|r")
660671

661672
local zName = zHdr:CreateFontString(nil, "OVERLAY")
662-
zName:SetFont(FONT_HEADERS, 10, "OUTLINE")
673+
zName:SetFont(FONT_HEADERS, 10, GetFontFlags())
663674
zName:SetPoint("LEFT", arrow, "RIGHT", 5, 0)
664675
zName:SetTextColor(cr, cg, cb)
665676
zName:SetText(zone.label)
666677

667678
local zCount = zHdr:CreateFontString(nil, "OVERLAY")
668-
zCount:SetFont(FONT_ROWS, 9, "OUTLINE")
679+
zCount:SetFont(FONT_ROWS, 9, GetFontFlags())
669680
zCount:SetPoint("RIGHT", zHdr, "RIGHT", -8, 0)
670681
zCount:SetTextColor(0.5, 0.5, 0.5)
671682

@@ -756,7 +767,7 @@ BuildRaresFrame = function()
756767
dot:SetColorTexture(0.28, 0.28, 0.28, 1)
757768

758769
local lbl = body:CreateFontString(nil, "OVERLAY")
759-
lbl:SetFont(FONT_ROWS, db.raresFontSize or 9, "OUTLINE")
770+
lbl:SetFont(FONT_ROWS, db.raresFontSize or 9, GetFontFlags())
760771
lbl:SetPoint("TOPLEFT", body, "TOPLEFT", xPos + DOT_SIZE + 5, yPos)
761772
lbl:SetWidth(colW - DOT_SIZE - 10)
762773
lbl:SetHeight(ROW_H)
@@ -981,7 +992,7 @@ local function BuildRaresConfigFrame()
981992
tbar:SetScript("OnDragStop", function() f:StopMovingOrSizing() end)
982993

983994
local ttitle = tbar:CreateFontString(nil, "OVERLAY")
984-
ttitle:SetFont(FONT_HEADERS, 10, "OUTLINE")
995+
ttitle:SetFont(FONT_HEADERS, 10, GetFontFlags())
985996
ttitle:SetText(L["Rares_Config_Title"])
986997
ttitle:SetPoint("LEFT", tbar, "LEFT", 8, 0)
987998

@@ -1047,7 +1058,7 @@ PopulateRaresConfig = function(f)
10471058
btn:SetBackdropBorderColor(isActive and 0.22 or 0.16, isActive and 0.82 or 0.28, isActive and 0.70 or 0.36, 1)
10481059

10491060
local lbl = btn:CreateFontString(nil, "OVERLAY")
1050-
lbl:SetFont(FONT_ROWS, cfgFs, "OUTLINE")
1061+
lbl:SetFont(FONT_ROWS, cfgFs, GetFontFlags())
10511062
lbl:SetPoint("CENTER")
10521063
lbl:SetText(tab.label)
10531064
lbl:SetTextColor(isActive and 0.85 or 0.62, isActive and 1.0 or 0.75, isActive and 0.92 or 0.70)
@@ -1141,7 +1152,7 @@ PopulateRaresConfig = function(f)
11411152
pb:SetBackdropColor(isActive and 0.12 or 0.05, isActive and 0.35 or 0.10, isActive and 0.32 or 0.18, syncFs and 0.4 or 1)
11421153
pb:SetBackdropBorderColor(isActive and 0.25 or 0.18, isActive and 0.85 or 0.40, isActive and 0.70 or 0.45, syncFs and 0.4 or 1)
11431154
local pfs = pb:CreateFontString(nil, "OVERLAY")
1144-
pfs:SetFont(FONT_ROWS, cfgFs, "OUTLINE")
1155+
pfs:SetFont(FONT_ROWS, cfgFs, GetFontFlags())
11451156
pfs:SetPoint("CENTER")
11461157
pfs:SetText(p[1])
11471158
pfs:SetTextColor(syncFs and 0.35 or (isActive and 0.2 or 0.6), syncFs and 0.35 or (isActive and 0.95 or 0.75), syncFs and 0.35 or (isActive and 0.75 or 0.65))
@@ -1220,7 +1231,7 @@ PopulateRaresConfig = function(f)
12201231
swatch:SetPoint("RIGHT", rowFr, "RIGHT", 0, 0)
12211232

12221233
nameLbl = rowFr:CreateFontString(nil, "OVERLAY")
1223-
nameLbl:SetFont(FONT_ROWS, 10, "OUTLINE")
1234+
nameLbl:SetFont(FONT_ROWS, 10, GetFontFlags())
12241235
nameLbl:SetPoint("LEFT", rowFr, "LEFT", 0, 0)
12251236
nameLbl:SetPoint("RIGHT", swatch, "LEFT", -4, 0)
12261237
nameLbl:SetText(zone.label)

0 commit comments

Comments
 (0)