forked from EllesmereGaming/EllesmereUI
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathEUI__General_Options.lua
More file actions
5739 lines (5232 loc) · 284 KB
/
Copy pathEUI__General_Options.lua
File metadata and controls
5739 lines (5232 loc) · 284 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
-------------------------------------------------------------------------------
-- EUI__General_Options.lua
-- Registers the Global Settings module with EllesmereUI
-- CVar-based settings that apply to all EllesmereUI addons
--
-- Default-application policy:
-- We use C_CVar.GetCVarInfo(name) to get both the current value and
-- Blizzard's built-in default. Our preferred defaults are only applied
-- when the CVar is still sitting at Blizzard's default -- meaning
-- neither the player nor another addon has touched it. If the value
-- differs from the Blizzard default in any way, we leave it alone.
-- Widgets always read the live CVar value so they stay in sync
-- regardless of who set it.
-------------------------------------------------------------------------------
local ADDON_NAME = ...
-------------------------------------------------------------------------------
-- Page / section names
-------------------------------------------------------------------------------
local PAGE_GENERAL = "General"
local PAGE_COLORS = "Fonts & Colors"
local PAGE_PROFILES = "Profiles"
local PAGE_WHATSNEW = "Patch Notes"
-- Standalone single-module builds rename the host addon to contain "Standalone".
-- The What's New tab is suite-only, so it is never added to the page list there.
local IS_STANDALONE = type(ADDON_NAME) == "string" and ADDON_NAME:find("Standalone") ~= nil
-------------------------------------------------------------------------------
-- What's New? page -- interactive patch notes in three tiers of importance:
-- 1) hero cards (two per row), 2) small clickable listings, 3) fix lines.
-- Content lives in EllesmereUI._WHATSNEW_PATCHES (newest patch first). A
-- hero/listing entry with a `nav` deep-links to the setting it changed via
-- EllesmereUI:NavigateToElementSettings (opens the page + green-pulses the
-- control); an entry with NO `nav` renders as a static, non-clickable card
-- (for automatic behavior that has no setting to open). Defined at file scope
-- (namespace function) so it adds no locals or upvalues to the deferred
-- options closure below.
-------------------------------------------------------------------------------
function EllesmereUI._BuildWhatsNewPage(pageName, parent, yOffset)
local PP = EllesmereUI.PanelPP
local EG = EllesmereUI.ELLESMERE_GREEN
local PAD = EllesmereUI.CONTENT_PAD
local W = EllesmereUI.Widgets
local MakeFont = EllesmereUI.MakeFont
local MakeBorder = EllesmereUI.MakeBorder
-- This page is a free-form feed, not a DualRow split layout.
parent._showRowDivider = nil
local y = yOffset
local totalW = parent:GetWidth() - PAD * 2
local CARD_GAP = 14
-- Display title: "Module: Title" -- the module name is prepended to every entry.
local function TitleOf(e)
return ((e.module and e.module .. ": ") or "") .. (e.title or "")
end
-- Stable sort by module display name so same-module entries group together
-- (preserves authored order within a module).
local function SortByModule(list)
local idx = {}
for i, e in ipairs(list) do idx[i] = { e, i } end
table.sort(idx, function(a, b)
local am, bm = a[1].module or "", b[1].module or ""
if am ~= bm then return am < bm end
return a[2] < b[2]
end)
local out = {}
for i = 1, #idx do out[i] = idx[i][1] end
return out
end
-- Deep-link to a setting (opens the page; highlights the control if mapped).
local function GoTo(nav)
if nav and nav.module then
EllesmereUI:NavigateToElementSettings(nav.module, nav.page, nav.section, nav.preSelect, nav.highlight)
end
end
-- Tier 1: a clickable hero card -- dark fill, faint border, green top accent,
-- title + wrapping description, uniform hover lift.
local function MakeHeroCard(x, cy, w, hgt, entry)
local card = CreateFrame("Button", nil, parent)
PP.Size(card, w, hgt)
PP.Point(card, "TOPLEFT", parent, "TOPLEFT", x, cy)
card:SetFrameLevel(parent:GetFrameLevel() + 2)
local bg = card:CreateTexture(nil, "BACKGROUND")
bg:SetAllPoints()
bg:SetColorTexture(0.06, 0.08, 0.10, 0.50)
local brd = MakeBorder(card, 1, 1, 1, 0.12, PP)
local accent = card:CreateTexture(nil, "ARTWORK", nil, 7)
accent:SetColorTexture(EG.r, EG.g, EG.b, 0.6)
PP.Point(accent, "TOPLEFT", card, "TOPLEFT", 1, -1)
PP.Point(accent, "TOPRIGHT", card, "TOPRIGHT", -1, -1)
accent:SetHeight(2)
if PP.DisablePixelSnap then PP.DisablePixelSnap(accent) end
local titleFs = MakeFont(card, 14, nil, EG.r, EG.g, EG.b, 0.9)
PP.Point(titleFs, "TOPLEFT", card, "TOPLEFT", 16, -14)
PP.Point(titleFs, "RIGHT", card, "RIGHT", -16, 0)
titleFs:SetJustifyH("LEFT"); titleFs:SetWordWrap(false)
titleFs:SetText(TitleOf(entry))
local descFs = MakeFont(card, 12, nil, 1, 1, 1, 0.45)
PP.Point(descFs, "TOPLEFT", titleFs, "BOTTOMLEFT", 0, -7)
PP.Point(descFs, "RIGHT", card, "RIGHT", -16, 0)
descFs:SetJustifyH("LEFT"); descFs:SetJustifyV("TOP"); descFs:SetWordWrap(true)
descFs:SetText(entry.desc or "")
-- Clickable only when the entry has a nav target. An entry with no nav
-- (automatic behavior with no setting to open -- e.g. party frames in
-- arena) renders as a static card: no hover lift, no click, and mouse
-- disabled so nothing invites a click that would go nowhere.
if entry.nav and entry.nav.module then
card:SetScript("OnEnter", function()
bg:SetColorTexture(0.11, 0.13, 0.15, 0.50); brd:SetColor(1, 1, 1, 0.22)
titleFs:SetAlpha(1)
end)
card:SetScript("OnLeave", function()
bg:SetColorTexture(0.06, 0.08, 0.10, 0.50); brd:SetColor(1, 1, 1, 0.12)
titleFs:SetAlpha(0.9)
end)
card:SetScript("OnClick", function() GoTo(entry.nav) end)
else
card:EnableMouse(false)
end
end
-- Tier 2: a clickable small listing -- title + subtitle, no card chrome, a
-- faint row highlight on hover.
local function MakeListing(cy, w, entry)
local ROW_H = 48
local row = CreateFrame("Button", nil, parent)
PP.Size(row, w, ROW_H)
PP.Point(row, "TOPLEFT", parent, "TOPLEFT", PAD, cy)
local hov = row:CreateTexture(nil, "BACKGROUND")
hov:SetAllPoints()
hov:SetColorTexture(1, 1, 1, 0.07)
hov:SetAlpha(0)
local titleFs = MakeFont(row, 13, nil, 1, 1, 1, 0.9)
PP.Point(titleFs, "TOPLEFT", row, "TOPLEFT", 6, -5)
titleFs:SetJustifyH("LEFT"); titleFs:SetWordWrap(false)
titleFs:SetText(TitleOf(entry))
local subFs = MakeFont(row, 11, nil, 1, 1, 1, 0.4)
PP.Point(subFs, "TOPLEFT", titleFs, "BOTTOMLEFT", 0, -4)
PP.Point(subFs, "RIGHT", row, "RIGHT", -10, 0)
subFs:SetJustifyH("LEFT"); subFs:SetWordWrap(false)
subFs:SetText(entry.desc or "")
-- Clickable only when the entry has a nav target (see MakeHeroCard); a
-- nav-less listing renders static with no hover or click.
if entry.nav and entry.nav.module then
row:SetScript("OnEnter", function()
hov:SetAlpha(1); titleFs:SetAlpha(1)
end)
row:SetScript("OnLeave", function()
hov:SetAlpha(0); titleFs:SetAlpha(0.9)
end)
row:SetScript("OnClick", function() GoTo(entry.nav) end)
else
row:EnableMouse(false)
end
return ROW_H
end
-- Tier 3: a plain bug-fix line (bullet + wrapping text, not clickable).
local function MakeFixLine(cy, text)
local dot = MakeFont(parent, 12, nil, EG.r, EG.g, EG.b, 0.55)
PP.Point(dot, "TOPLEFT", parent, "TOPLEFT", PAD + 2, cy - 1)
dot:SetText("\226\128\162") -- bullet glyph (ASCII-safe UTF-8 escape)
local fs = MakeFont(parent, 12, nil, 1, 1, 1, 0.5)
PP.Point(fs, "TOPLEFT", parent, "TOPLEFT", PAD + 18, cy)
PP.Point(fs, "RIGHT", parent, "RIGHT", -PAD, 0)
fs:SetJustifyH("LEFT"); fs:SetWordWrap(true)
fs:SetText(text or "")
local th = fs:GetStringHeight() or 14
return math.max(22, math.ceil(th) + 8)
end
local patches = EllesmereUI._WHATSNEW_PATCHES
if not patches or #patches == 0 then
local none = MakeFont(parent, 13, nil, 1, 1, 1, 0.5)
PP.Point(none, "TOPLEFT", parent, "TOPLEFT", PAD, y - 20)
none:SetText("No patch notes yet.")
return math.abs(y) + 60
end
-- Intro hint: centered, with 20px of breathing room above and below.
y = y - 20
local hint = MakeFont(parent, 14, nil, 1, 1, 1, 0.5)
PP.Point(hint, "TOP", parent, "TOP", 0, y)
hint:SetJustifyH("CENTER")
hint:SetText("Click any new feature to go directly to the setting")
y = y - math.ceil(hint:GetStringHeight() or 14) - 20
for pi, patch in ipairs(patches) do
-- Version header: large title + a full-width neutral divider (not accent).
local ver = MakeFont(parent, 20, nil, 1, 1, 1, 0.95)
PP.Point(ver, "TOPLEFT", parent, "TOPLEFT", PAD, y)
ver:SetText("EllesmereUI " .. (patch.version or ""))
local uline = parent:CreateTexture(nil, "ARTWORK")
uline:SetColorTexture(1, 1, 1, 0.12)
PP.Size(uline, totalW, 1)
PP.Point(uline, "TOPLEFT", parent, "TOPLEFT", PAD, y - 32)
if PP.DisablePixelSnap then PP.DisablePixelSnap(uline) end
y = y - 48
-- Tier 1: hero cards, two per row. Heroes render in AUTHORED order (the
-- order they appear in the patch's `heroes` table) -- NOT module-sorted
-- like features/fixes -- so each patch can headline whatever matters most
-- first. Reorder the entries in _WHATSNEW_PATCHES to reorder the cards.
local heroes = patch.heroes or {}
if #heroes > 0 then
local cardW = math.floor((totalW - CARD_GAP) / 2)
local CARD_H = 96
local rows = math.ceil(#heroes / 2)
for i, hero in ipairs(heroes) do
local col = (i - 1) % 2
local rw = math.floor((i - 1) / 2)
local cx = PAD + col * (cardW + CARD_GAP)
local cy = y - rw * (CARD_H + CARD_GAP)
MakeHeroCard(cx, cy, cardW, CARD_H, hero)
end
local consumed = rows * CARD_H + (rows - 1) * CARD_GAP
y = y - consumed - 18
end
-- Tier 2: small listings.
local feats = SortByModule(patch.features or {})
if #feats > 0 then
local _, sh = W:SectionHeader(parent, "ADDITIONAL FEATURES", y); y = y - sh
y = y - 5 -- extra spacing below the divider
for _, f in ipairs(feats) do
local rh = MakeListing(y, totalW, f); y = y - rh
end
y = y - 6
end
-- Tier 3: bug-fix lines.
local fixes = SortByModule(patch.fixes or {})
if #fixes > 0 then
local _, sh = W:SectionHeader(parent, "BUG FIXES", y); y = y - sh
y = y - 10 -- extra spacing below the divider
for _, fx in ipairs(fixes) do
local fh = MakeFixLine(y, ((fx.module and fx.module .. ": ") or "") .. (fx.text or "")); y = y - fh
end
end
if pi < #patches then
local _, gap = W:Spacer(parent, y, 24); y = y - gap
end
end
return math.abs(y) + 20
end
-------------------------------------------------------------------------------
-- Patch-notes content for the What's New page (newest patch first). Each hero
-- and listing entry's `nav` deep-links to the setting it changed via
-- EllesmereUI:NavigateToElementSettings(module, page, section, preSelect, highlight).
-------------------------------------------------------------------------------
EllesmereUI._WHATSNEW_PATCHES = {
{
version = "8.2.1",
heroes = {
{
module = "Cooldown Manager",
title = "Always Show Buffs, Now Per-Bar",
desc = "Always Show Buffs is now a per-bar toggle, so each buff bar can independently keep its tracked buffs on screen even when they are off cooldown, with its own option to grey out the inactive ones.",
nav = { module = "EllesmereUICooldownManager", page = "CDM Bars", section = "Icon Display", highlight = "Always Show Buffs",
preSelect = function()
if EllesmereUI._setCDMBar then EllesmereUI._setCDMBar("buffs") end
end },
},
{
module = "Action Bars",
title = "Two New Action Bars",
desc = "Action Bars has two new bars (9 + 10) for all of you demons that need more than 96 slots. Each has its own keybinds and stays hidden until you set its Visibility.",
nav = { module = "EllesmereUIActionBars", page = "Bar Display", section = "VISIBILITY", highlight = "Visibility" },
},
{
module = "Unit Frames",
title = "Heal Absorb Overhaul",
desc = "New heal absorb and absorb textures for Unit and Raid Frames: Large Stripes and Outlined Stripes. Unit Frames got a live preview toggle for heal absorbs, and Right/Left edge placement fixes.",
nav = { module = "EllesmereUIUnitFrames", page = "Main Frames", section = "ABSORBS", highlight = "Heal Absorb Style",
preSelect = function()
if EllesmereUI._setUnitFrameUnit then EllesmereUI._setUnitFrameUnit("player") end
EllesmereUI._pendingUnitSelect = "player"
end },
},
{
module = "Character Sheet",
title = "Mastery Tooltip",
desc = "Hovering Mastery on the character sheet now shows your spec's real mastery (its name and effect, e.g. Mastery: Razor Claws) instead of a generic line.",
nav = { module = "EllesmereUIBlizzardSkin", page = "Character Sheet", section = "CORE OPTIONS", highlight = "Enable Character Sheet" },
},
},
features = {
{
module = "Action Bars",
title = "Menu, Bags & XP Bars Tab",
desc = "Micro Menu, Bag Bar, and XP and Reputation bar settings now live on their own dedicated options tab.",
nav = { module = "EllesmereUIActionBars", page = "Menu, Bags & XP Bars", section = "MICRO MENU & BAGS", highlight = "Micro Menu Visibility" },
},
{
module = "Cooldown Manager",
title = "Customizable Pixel Glow",
desc = "CD and Utility bars get a Pixel Glow Thickness slider plus a cog for Lines and Speed, and the Buff Glow's Pixel Glow gets a matching Lines, Thickness, and Speed cog.",
nav = { module = "EllesmereUICooldownManager", page = "CDM Bars", section = "Icon Display", highlight = "Pixel Glow Thickness" },
},
{
module = "Cooldown Manager",
title = "Charge & Stack Text Positioning",
desc = "Place the charge or stack count in any corner or the center, and preset potions and healthstones now show a sample count in the preview.",
nav = { module = "EllesmereUICooldownManager", page = "CDM Bars", section = "Icon Display", highlight = "Charge/Stack Size" },
},
{
module = "Raid Frames",
title = "Max Name Length",
desc = "A new cog on Name Size caps how many characters of a long unit name show on raid frames.",
nav = { module = "EllesmereUIRaidFrames", page = "Frames", section = "TEXT DISPLAY", highlight = "Name Size" },
},
{
module = "Resource Bars",
title = "Extra Shift Offset",
desc = "The Shift Elements if No Resource and No Power settings get a cog with an Extra Y Offset slider to fine-tune how far anchored elements move.",
nav = { module = "EllesmereUIResourceBars", page = "Class, Power and Health Bars", section = "BAR DISPLAY", highlight = "Shift Elements if No Resource" },
},
},
fixes = {
{ module = "Cooldown Manager", text = "Adding a tracked buff to a custom buff bar no longer shows a duplicate or a generic icon for talent transformed spells." },
{ module = "Action Bars", text = "A mouseover bar no longer vanishes the instant you drop a spell onto it while your cursor is still over it." },
{ module = "Action Bars", text = "The main bar's page-swap arrows now follow its mouseover fade and visibility settings." },
{ module = "Action Bars", text = "The Pet Bar no longer stays visible after exiting Quick Keybind mode." },
{ module = "Nameplates", text = "Cast bar spell text is no longer hidden behind the border, the unit name sits above aura icons, and raid and elite markers sit beneath them." },
{ module = "Nameplates", text = "Top Left and Top Right auras, raid markers, and classification icons now sit flush against the plate edge." },
{ module = "Aura Reminders", text = "The GCD, Modern, and Classic glow styles now render at the correct size." },
{ module = "Bags", text = "Shift-right-clicking a stack inside a category now shows the split-in-OneBag hint." },
{ module = "Profiles", text = "The profile sync popup now closes when you close the options window." },
},
},
{
version = "8.2.0",
heroes = {
{
module = "Raid Frames",
title = "Party Frames in Arena",
desc = "Your party frames now show in arenas instead of raid frames, so small-group styling applies and addons that anchor to party frames keep working.",
-- No nav: automatic behavior with no setting to open (static card).
},
{
module = "Cooldown Manager",
title = "Tracking Bar Size-Matching",
desc = "Cooldown tracking bars can now match the width and height of other interface elements in Unlock Mode.",
-- No nav: Unlock Mode action with no setting to open (static card).
},
{
module = "Cooldown Manager",
title = "Group Tracking Bars",
desc = "Pick which tracking bars chain together and share width and height, with a per-bar checklist.",
nav = { module = "EllesmereUICooldownManager", page = "Tracking Bars", section = "Bar Grouping", highlight = "Group Tracking" },
},
{
module = "Nameplates",
title = "Cropped Icons",
desc = "Make debuff, buff, and crowd-control aura icons rectangular instead of square.",
nav = { module = "EllesmereUINameplates", page = "Display", section = "CORE POSITIONS", highlight = "" },
},
},
features = {
{
module = "Cooldown Manager",
title = "Bloodlust & Heroism Bars",
desc = "Add Bloodlust or Heroism to a Custom Auras bar as a self-timed 40-second icon.",
nav = { module = "EllesmereUICooldownManager", page = "CDM Bars", section = "Bar Layout", highlight = "" },
},
{
module = "Nameplates",
title = "Boss & Neutral Colors",
desc = "Bosses get their own color, split from mini-bosses, and neutral enemies get a custom one.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "ENEMY COLORS", highlight = "Enemy Types" },
},
{
module = "Nameplates",
title = "DPS \"No Aggro\" Color",
desc = "Highlight enemies you do not have threat on while in a group.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "THREAT COLORS (INSTANCES ONLY)", highlight = "No Aggro" },
},
{
module = "Resource Bars",
title = "Player Cast Bar Background",
desc = "Set the Player cast bar's background color and opacity.",
nav = { module = "EllesmereUIResourceBars", page = "Cast Bar", section = "DISPLAY", highlight = "Background" },
},
{
module = "Nameplates",
title = "Cast Bar Borders",
desc = "Outline enemy cast bars with an adjustable-thickness border in your own color.",
nav = { module = "EllesmereUINameplates", page = "Display", section = "BARS", highlight = "Cast Bar Border" },
},
},
fixes = {
{ module = "Nameplates", text = "Raid target markers now show behind aura icons instead of overlapping them." },
{ module = "Nameplates", text = "Neutral units now show in the enemy-in-combat color while actively in combat." },
{ module = "Nameplates", text = "Aggro color toggles are now clearly labeled \"Tank:\" and \"DPS:\"." },
{ module = "Unit Frames", text = "Cropped aura icons in the options preview now show at the correct height." },
{ module = "Unit Frames", text = "Clicking a buff or debuff icon in the preview to jump to its setting now works after turning buffs on or changing the debuff count." },
{ module = "Unlock Mode", text = "Movers for deleted or hidden elements no longer reappear as ghosts when opening Unlock Mode or after combat." },
{ module = "Unlock Mode", text = "Size-matching to an element that cannot be matched now shows a clear message instead of doing nothing." },
{ module = "Cooldown Manager", text = "Fixed a phantom 40-second Bloodlust bar appearing in the open world after leaving a dungeon while Sated." },
{ module = "Damage Meters", text = "Bars reserve more space for the amount text so numbers stay readable next to long names." },
{ module = "Bloodlust", text = "Fixed the active-buff overlay falsely reappearing when zoning or logging in while Sated." },
{ module = "Raid Frames", text = "Nicknames from raid-tracker addons now show in the standalone build." },
},
},
{
version = "8.1.9",
heroes = {},
features = {
{
module = "Bags",
title = "Quest Item Highlight",
desc = "Quest items get a gold border; items that start a quest get a corner marker.",
nav = { module = "EllesmereUIBags", page = "Bags", section = "DISPLAY", highlight = "" },
},
{
module = "Minimap",
title = "Omnium Folio Button",
desc = "Adds the expansion landing page (Omnium Folio) button to the minimap, with scale and position controls.",
nav = { module = "EllesmereUIMinimap", page = "Minimap", section = "ICONS AND BUTTONS", highlight = "Show Omnium Folio" },
},
{
module = "Nameplates",
title = "Friendly Names Not Clickable",
desc = "Make friendly player and NPC nameplates click-through so their names never block your mouse or cause accidental targeting.",
nav = { module = "EllesmereUINameplates", page = "General", section = "OTHER NAMEPLATES", highlight = "Friendly Names Not Clickable" },
},
},
fixes = {
{ module = "Action Bars", text = "Spells with charges and on-use trinkets now desaturate correctly while on cooldown." },
{ module = "Bags", text = "Dragging items no longer drops them in the wrong slot when the window scale isn't 100%." },
{ module = "Raid Frames", text = "Boss debuff countdown text now scales consistently with the icon size." },
{ module = "Raid Frames", text = "Non-Left Click bindings work for Targeting players via Hovercast again after the 12.0.7 change." },
{ module = "Nameplates", text = "Scale Target Nameplate is now the only control that resizes your target's plate; at 100% it no longer changes size." },
{ module = "Nameplates", text = "Full-height cast bar spell icon stays flush with the bars as nameplates move." },
{ module = "Auto Logging", text = "Auto combat logging now triggers for current Mythic (Flexible) raids." },
{ module = "Context Menu", text = "Fixed a Lua error when setting focus directly from the right-click menu." },
{ module = "Shifter", text = "Fixed an error sometimes thrown after leaving a group you joined via Group Finder." },
},
},
{
version = "8.1.7",
heroes = {
{
module = "Raid Frames",
title = "New Shield & Heal Absorb Styles",
desc = "Blizzard's modern layered shield and overshield spark for both damage and heal absorbs.",
nav = { module = "EllesmereUIRaidFrames", page = "Frames", section = "ABSORBS", highlight = "Absorb Style" },
},
{
module = "Bags",
title = "MultiBag View",
desc = "Shows one section per equipped bag, with a Default Bag Type dropdown for how bags and the bank open.",
nav = { module = "EllesmereUIBags", page = "Bags", section = "DISPLAY", highlight = "Default Bag Type" },
},
{
module = "Nameplates",
title = "Interrupt-Ready Cast Highlight",
desc = "Enemy cast bars shade the moment your interrupt comes off cooldown.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "CAST BAR", highlight = "Cast Color" },
},
{
module = "Bags",
title = "Auto-Size to Fit",
desc = "Grows the bag window so the active tab's slots fit without scrolling, then resets on close.",
nav = { module = "EllesmereUIBags", page = "Bags", section = "DISPLAY", highlight = "Auto-Size to Fit" },
},
{
module = "Cooldown Manager",
title = "Hide Items if Missing",
desc = "Hide a bar's consumables entirely when you have none, instead of dimming them.",
nav = { module = "EllesmereUICooldownManager", page = "CDM Bars", section = "Extras", highlight = "Hide Items if Missing" },
},
{
module = "Resource Bars",
title = "Shift Elements if No Power",
desc = "Shift power-bar-anchored elements to close the gap when the Power Bar is hidden.",
nav = { module = "EllesmereUIResourceBars", page = "Class, Power and Health Bars", section = "BAR DISPLAY", highlight = "Shift Elements if No Power" },
},
},
features = {
{
module = "Nameplates",
title = "Cast Bar Spell Icon Placement",
desc = "Move the enemy cast icon to the right, or show it full-height across the bars.",
nav = { module = "EllesmereUINameplates", page = "Display", section = "BARS", highlight = "Spell Icon" },
},
{
module = "Nameplates",
title = "Quest Objective on Quest Mobs",
desc = "Replace the quest crosshair on world quest mobs with the live objective count.",
nav = { module = "EllesmereUINameplates", page = "General", section = "EXTRAS", highlight = "Replace Quest Icon with Objective" },
},
{
module = "Nameplates",
title = "Uninterruptible Cast & Shield",
desc = "Give uninterruptible casts their own color, with an optional shield icon.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "CAST BAR", highlight = "Uninterruptible Cast" },
},
{
module = "Nameplates",
title = "Aura Stacks Text Styling",
desc = "Position, color, and size/offset controls for stack text, matching Aura Duration.",
nav = { module = "EllesmereUINameplates", page = "Display", section = "GENERAL TEXT", highlight = "Aura Stacks" },
},
{
module = "Nameplates",
title = "Important Cast Color",
desc = "Tint the cast bar for spells the game flags as important.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "CAST BAR", highlight = "Cast Color" },
},
{
module = "Nameplates",
title = "Darken Enemies Out of Combat",
desc = "Dim enemy nameplate colors until they are in combat.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "ENEMY COLORS", highlight = "Darken Enemies Out of Combat" },
},
{
module = "Nameplates",
title = "Interrupted Cast Flash",
desc = "Flash an enemy's cast bar and show \"Interrupted\" when you kick it.",
nav = { module = "EllesmereUINameplates", page = "Colors", section = "CAST BAR", highlight = "Show Interrupted Flash Effect" },
},
{
module = "Nameplates",
title = "Per-Element Aura Spacing",
desc = "Separate icon spacing for debuffs, buffs, and crowd control.",
nav = { module = "EllesmereUINameplates", page = "Display", section = "CORE POSITIONS", highlight = "" },
},
{
module = "Unit Frames",
title = "Aura Max Per Row",
desc = "Cap how many buff and debuff icons show per row and wrap the rest onto new rows.",
nav = { module = "EllesmereUIUnitFrames", page = "Main Frames", section = "BUFFS AND DEBUFFS", highlight = "Buff Display",
preSelect = function()
if EllesmereUI._setUnitFrameUnit then EllesmereUI._setUnitFrameUnit("player") end
EllesmereUI._pendingUnitSelect = "player"
end },
},
{
module = "Unit Frames",
title = "Interrupt-Ready Mid-Cast Bar",
desc = "Tint the part of a cast where your interrupt comes off cooldown.",
nav = { module = "EllesmereUIUnitFrames", page = "Main Frames", section = "CAST BAR", highlight = "Show Cast Bar",
preSelect = function()
if EllesmereUI._setUnitFrameUnit then EllesmereUI._setUnitFrameUnit("target") end
EllesmereUI._pendingUnitSelect = "target"
end },
},
{
module = "Unit Frames",
title = "Cast Bar Background",
desc = "Set the cast bar's background color and opacity per frame.",
nav = { module = "EllesmereUIUnitFrames", page = "Main Frames", section = "CAST BAR", highlight = "Bar Background",
preSelect = function()
if EllesmereUI._setUnitFrameUnit then EllesmereUI._setUnitFrameUnit("player") end
EllesmereUI._pendingUnitSelect = "player"
end },
},
{
module = "Unit Frames",
title = "Boss Simple Debuff Display",
desc = "Stack boss debuffs into one large left- or right-anchored column.",
nav = { module = "EllesmereUIUnitFrames", page = "Boss Frames", section = "Buffs and Debuffs", highlight = "Simple Debuff Display" },
},
{
module = "Unit Frames",
title = "Absorb Short Health Text",
desc = "Show absorbs in compact form (e.g. 230k).",
nav = { module = "EllesmereUIUnitFrames", page = "Main Frames", section = "HEALTH BAR", highlight = "Left Text",
preSelect = function()
if EllesmereUI._setUnitFrameUnit then EllesmereUI._setUnitFrameUnit("player") end
EllesmereUI._pendingUnitSelect = "player"
end },
},
{
module = "Raid Frames",
title = "Targeted Spells: When Healing",
desc = "Auto-enable targeted spells only when you are a healer.",
nav = { module = "EllesmereUIRaidFrames", page = "Frames", section = "TARGETED SPELLS", highlight = "Show Targeted Spells" },
},
{
module = "Raid Frames",
title = "Hide Empty Groups",
desc = "Collapse empty raid subgroups so the rest close ranks.",
nav = { module = "EllesmereUIRaidFrames", page = "Frames", section = "LAYOUT", highlight = "Show Groups" },
},
{
module = "General",
title = "Expanded Font Controls",
desc = "Apply your font to all game text, outline icon text, and set Raid Frame and Bag fonts.",
nav = { module = "_EUIGlobal", page = "Fonts & Colors", section = "GLOBAL FONT", highlight = "Apply to All Game Text" },
},
{
module = "General",
title = "Font Picker for CJK/Cyrillic",
desc = "A working font dropdown for glyph-restricted locales.",
nav = { module = "_EUIGlobal", page = "Fonts & Colors", section = "GLOBAL FONT", highlight = "Global Font" },
},
},
fixes = {
{ module = "Nameplates", text = "Health percent text can now show one decimal place (e.g. 72.4%)." },
{ module = "Nameplates", text = "Fixed the interrupt tick and interrupt-ready marker flickering during your rotation." },
{ module = "Nameplates", text = "Fixed the interrupt tick jittering by a pixel as a cast progressed." },
{ module = "Cooldown Manager", text = "Now shows the real spell's keybind when both a macro and the spell are bound." },
{ module = "Cooldown Manager", text = "Racial tracking simplified to a single entry that follows your character's race." },
{ module = "General", text = "Profile and preset import failures now show a specific reason instead of a generic error." },
{ module = "General", text = "Right-click unit and raid menus work again after the 12.0.7 change that suppressed them." },
{ module = "General", text = "Text drop shadows render again across the UI after 12.0.7 stopped showing them." },
{ module = "General", text = "The sync icon no longer silently skips a unit when reopened." },
{ module = "Chat", text = "New option to keep chat clamped on-screen, or release it to drag off-screen." },
{ module = "Damage Meters", text = "Combat timer no longer gets stuck or blanks on chain pulls, wipes, reloads, or when leaving an instance." },
{ module = "Raid Frames", text = "HoverCast \"Context Menu\" and \"Target\" bindings now actually fire." },
{ module = "Raid Frames", text = "Custom dispel border colors now show on other players' debuffs inside instances." },
{ module = "Raid Frames", text = "Hid nuisance debuffs (Arcane Empowerment and Time Trial Practice)." },
{ module = "Resource Bars", text = "Totem timer text now uses your chosen font instead of the default." },
{ module = "Unit Frames", text = "Options now keep your scroll position when switching the previewed unit." },
{ module = "Quality of Life", text = "Secondary Stat Display keeps its custom size when dragged." },
{ module = "Minimap", text = "Vault and tracker tooltips now use your Minimap font." },
{ module = "Blizzard Skin", text = "Great Vault now uses your Blizzard Skin font." },
{ module = "Buff Reminders", text = "Talent Reminders now follow the Aura/Buff Reminders font settings." },
},
},
}
-------------------------------------------------------------------------------
-- FCT font -- handled by EllesmereUI_Startup.lua which runs earlier.
-------------------------------------------------------------------------------
-- Wait for EllesmereUI to exist
local initFrame = CreateFrame("Frame")
initFrame:RegisterEvent("PLAYER_LOGIN")
initFrame:SetScript("OnEvent", function(self)
self:UnregisterEvent("PLAYER_LOGIN")
-- Re-apply combat text font at login -- handled by EllesmereUI_Startup.lua.
if not EllesmereUI or not EllesmereUI.RegisterModule then return end
local PP = EllesmereUI.PanelPP
local GLOBAL_KEY = EllesmereUI.GLOBAL_KEY or "_EUIGlobal"
local floor = math.floor
local ceil = math.ceil
local max = math.max
---------------------------------------------------------------------------
-- CVar helpers
---------------------------------------------------------------------------
local function GetCVarNum(cvar)
return tonumber(GetCVar(cvar)) or 0
end
local function GetCVarBool(cvar)
return GetCVar(cvar) == "1"
end
local function SetCVarSafe(cvar, value)
if InCombatLockdown() then return end
SetCVar(cvar, value)
end
--- Returns current, default as strings (nil-safe)
local function CVarInfo(cvar)
local cur, def = C_CVar.GetCVarInfo(cvar)
return cur or "", def or ""
end
--- Returns true when the CVar is still at Blizzard's built-in default,
--- meaning no addon or player has changed it.
local function IsAtBlizzardDefault(cvar)
local cur, def = CVarInfo(cvar)
return cur == def
end
---------------------------------------------------------------------------
-- EUI preferred defaults -- only applied when CVar == Blizzard default
--
-- { cvarName, euiPreferred }
---------------------------------------------------------------------------
local EUI_DEFAULTS = {
{ "cameraDistanceMaxZoomFactor", "2.6" },
{ "ActionButtonUseKeyDown", "1" },
{ "floatingCombatTextCombatHealing_v2", "1" },
{ "floatingCombatTextCombatDamage_v2", "1" },
}
--- Walk the table once at login and apply only where safe.
local function ApplySmartDefaults()
for _, entry in ipairs(EUI_DEFAULTS) do
local cvar, preferred = entry[1], entry[2]
if IsAtBlizzardDefault(cvar) then
SetCVarSafe(cvar, preferred)
end
end
end
ApplySmartDefaults()
-- Apply suppress lua errors on login (default: ON)
if not EllesmereUIDB or EllesmereUIDB.suppressErrors ~= false then
SetCVarSafe("scriptErrors", "0")
end
-- NOTE: Optimized graphics settings are NOT re-applied on login.
-- SetCVar already persists to WoW's config, so re-applying would override
-- any manual adjustments the user makes in WoW's graphics settings panel.
---------------------------------------------------------------------------
-- General page
---------------------------------------------------------------------------
local function BuildGeneralPage(pageName, parent, yOffset)
local W = EllesmereUI.Widgets
local y = yOffset
local _, h
parent._showRowDivider = true
_, h = W:Spacer(parent, y, 20); y = y - h
-------------------------------------------------------------------
-- Optimized graphics CVar table + buttons (above all sections)
-------------------------------------------------------------------
local OPTIMIZED_CVARS = {
{ "graphicsShadowQuality", "1" },
{ "graphicsLiquidDetail", "0" },
{ "graphicsParticleDensity", "5" },
{ "graphicsSSAO", "0" },
{ "graphicsDepthEffects", "0" },
{ "graphicsComputeEffects", "0" },
{ "graphicsOutlineMode", "0" },
{ "graphicsTextureResolution", "2" },
{ "graphicsSpellDensity", "1" },
{ "graphicsProjectedTextures", "1" },
{ "graphicsViewDistance", "1" },
{ "graphicsEnvironmentDetail", "1" },
{ "graphicsGroundClutter", "1" },
{ "RAIDsettingsEnabled", "0" },
{ "ResampleAlwaysSharpen", "1" },
}
local function ApplyOptimizedGfx()
if not EllesmereUIDB then EllesmereUIDB = {} end
-- One-time store: only snapshot if no backup exists yet
if not EllesmereUIDB.gfxBackup then
local backup = {}
for _, entry in ipairs(OPTIMIZED_CVARS) do
backup[entry[1]] = GetCVar(entry[1])
end
backup["Contrast"] = GetCVar("Contrast")
EllesmereUIDB.gfxBackup = backup
end
-- Apply optimized CVars
for _, entry in ipairs(OPTIMIZED_CVARS) do
SetCVarSafe(entry[1], entry[2])
end
-- Contrast boost: if current contrast <= 55, add 10
local curContrast = tonumber(GetCVar("Contrast")) or 50
if curContrast <= 55 then
SetCVarSafe("Contrast", curContrast + 10)
end
local rl = EllesmereUI._widgetRefreshList
if rl then for i = 1, #rl do rl[i]() end end
end
local function RestoreGfxSettings()
if not EllesmereUIDB or not EllesmereUIDB.gfxBackup then return end
local backup = EllesmereUIDB.gfxBackup
for _, entry in ipairs(OPTIMIZED_CVARS) do
local saved = backup[entry[1]]
if saved then SetCVarSafe(entry[1], saved) end
end
if backup["Contrast"] then SetCVarSafe("Contrast", backup["Contrast"]) end
EllesmereUIDB.gfxBackup = nil
local rl2 = EllesmereUI._widgetRefreshList
if rl2 then for i = 1, #rl2 do rl2[i]() end end
end
do
local ROW_H = 52
local gfxFrame = CreateFrame("Frame", nil, parent)
local totalW = parent:GetWidth() - EllesmereUI.CONTENT_PAD * 2
PP.Size(gfxFrame, totalW, ROW_H)
PP.Point(gfxFrame, "TOPLEFT", parent, "TOPLEFT", EllesmereUI.CONTENT_PAD, y)
-- Optimize button (always visible)
local optBtn = CreateFrame("Button", nil, gfxFrame)
local OPT_W = 300
PP.Size(optBtn, OPT_W, 42)
PP.Point(optBtn, "TOP", gfxFrame, "TOP", 0, 0)
optBtn:SetFrameLevel(gfxFrame:GetFrameLevel() + 1)
EllesmereUI.MakeStyledButton(optBtn, "Optimize My FPS and Graphics", 14,
EllesmereUI.WB_COLOURS, ApplyOptimizedGfx)
optBtn:HookScript("OnEnter", function()
EllesmereUI.ShowWidgetTooltip(optBtn, "Optimizes your graphics settings for maximum FPS and visual clarity.")
end)
optBtn:HookScript("OnLeave", function() EllesmereUI.HideWidgetTooltip() end)
-- Restore button (only visible when backup exists)
local restBtn = CreateFrame("Button", nil, gfxFrame)
local REST_W = 128
PP.Size(restBtn, REST_W, 29)
PP.Point(restBtn, "LEFT", optBtn, "RIGHT", 30, 0)
restBtn:SetFrameLevel(gfxFrame:GetFrameLevel() + 1)
restBtn:SetAlpha(0.7)
local _, _, restLbl = EllesmereUI.MakeStyledButton(restBtn, "Restore My Settings", 10,
EllesmereUI.RB_COLOURS, RestoreGfxSettings)
restBtn:HookScript("OnEnter", function() restBtn:SetAlpha(1) end)
restBtn:HookScript("OnLeave", function() restBtn:SetAlpha(0.7) end)
local function RefreshRestoreVisibility()
if EllesmereUIDB and EllesmereUIDB.gfxBackup then
restBtn:Show()
-- Shift optimize button left to make room
optBtn:ClearAllPoints()
PP.Point(optBtn, "TOP", gfxFrame, "TOP", -(REST_W / 2 + 15), 0)
else
restBtn:Hide()
optBtn:ClearAllPoints()
PP.Point(optBtn, "TOP", gfxFrame, "TOP", 0, 0)
end
end
RefreshRestoreVisibility()
EllesmereUI.RegisterWidgetRefresh(RefreshRestoreVisibility)
-- "More Information" accent-colored clickable text
local infoBtn = CreateFrame("Button", nil, gfxFrame)
infoBtn:SetFrameLevel(gfxFrame:GetFrameLevel() + 1)
local EG = EllesmereUI.ELLESMERE_GREEN
local infoFS = infoBtn:CreateFontString(nil, "OVERLAY")
infoFS:SetFont(EllesmereUI.EXPRESSWAY, 12, EllesmereUI.GetFontOutlineFlag())
infoFS:SetTextColor(EG.r, EG.g, EG.b, 0.70)
infoFS:SetText(EllesmereUI.L("More Information"))
infoFS:SetPoint("CENTER")
infoBtn:SetSize(infoFS:GetStringWidth() + 10, 18)
PP.Point(infoBtn, "TOP", optBtn, "BOTTOM", 0, -4)
infoBtn:SetScript("OnEnter", function() infoFS:SetTextColor(EG.r, EG.g, EG.b, 1) end)
infoBtn:SetScript("OnLeave", function() infoFS:SetTextColor(EG.r, EG.g, EG.b, 0.70) end)
infoBtn:SetScript("OnClick", function()
EllesmereUI:ShowInfoPopup({
title = "FPS & Graphics Optimization",
content = "This feature optimizes your in-game graphics settings to give you the best combination of high FPS and visual clarity.\n\nYou can revert all changes at any time by clicking \"Restore My Settings\" which will appear after optimizing.\n\n\nWhat we change:\n\n"
.. "Shadow Quality - Fair (balanced quality/FPS)\n"
.. "Liquid Detail - Disabled\n"
.. "Particle Density - Set to Ultra (keeps important spell effects)\n"
.. "SSAO (Ambient Occlusion) - Disabled\n"
.. "Depth Effects - Disabled\n"
.. "Compute Effects - Disabled\n"
.. "Outline Mode - Disabled\n"
.. "Texture Resolution - Set to High\n"
.. "Spell Density - Set to Essential\n"
.. "Projected Textures - Enabled (needed for ground effects)\n"
.. "View Distance - Reduced to 1\n"
.. "Environment Detail - Reduced to 1\n"
.. "Ground Clutter - Reduced to 1\n"
.. "Raid/Dungeon Settings - Uses same settings everywhere\n"
.. "Resample Sharpening - Enabled (crisper image)\n"
.. "Contrast - Boosted by +10 (if currently 55 or below)\n\n"
.. "These settings prioritize frame rate and visual clarity over environmental detail. Textures stay high quality so your character and the world still look perfect.",
})
end)
y = y - ROW_H
end
-------------------------------------------------------------------
-- DISPLAY
-------------------------------------------------------------------
_, h = W:SectionHeader(parent, "DISPLAY", y); y = y - h
-- Build dropdown values table from THEME_ORDER
local themeValues = {}
for _, name in ipairs(EllesmereUI.THEME_ORDER) do
themeValues[name] = name
end
-- Row 1: UI Accent Color | EUI Options Theme
local themeRow
themeRow, h = W:DualRow(parent, y,
{ type="multiSwatch", text="UI Accent Color",
tooltip="Sets the accent color used across all EllesmereUI elements (tabs, glows, highlights, borders). Defaults to your theme color.",
swatches = {
{ tooltip = "Class Color",
getValue = function()
local cr, cg, cb = EllesmereUI.GetPlayerClassColor()
return cr, cg, cb, 1
end,
setValue = function() end,
onClick = function()
-- Per-profile: set use-class on the active profile, then
-- re-resolve + apply live (resolves to the class color).
EllesmereUI.SetActiveProfileAccent(nil, true)
EllesmereUI.RefreshAccent()
EllesmereUI:RefreshPage()
end,
refreshAlpha = function()
return (select(1, EllesmereUI.GetActiveAccentState())) and 1 or 0.3
end },
{ tooltip = "Custom Color",
hasAlpha = false,
getValue = function()
local _, ca = EllesmereUI.GetActiveAccentState()
if ca then return ca.r, ca.g, ca.b, 1 end
return EllesmereUI.DEFAULT_ACCENT_R, EllesmereUI.DEFAULT_ACCENT_G, EllesmereUI.DEFAULT_ACCENT_B, 1
end,
setValue = function(r, g, b)
-- SetAccentColor persists per-profile (custom + useClass=false)
-- and applies live.
EllesmereUI.SetAccentColor(r, g, b)
end,
onClick = function(self)
if select(1, EllesmereUI.GetActiveAccentState()) then
-- Switch class -> custom: clear the per-profile class
-- flag and re-resolve (profile custom -> global -> theme).
EllesmereUI.SetActiveProfileAccent(nil, false)
EllesmereUI.RefreshAccent()
EllesmereUI:RefreshPage()
return
end
if self._eabOrigClick then self._eabOrigClick(self) end
end,
refreshAlpha = function()
return (select(1, EllesmereUI.GetActiveAccentState())) and 0.3 or 1
end },
} },
{ type="dropdown", text="EUI Options Theme",
values=themeValues,
order=EllesmereUI.THEME_ORDER,
getValue=function()
return EllesmereUI.GetActiveTheme()
end,
setValue=function(v)
EllesmereUI.SetActiveTheme(v)
EllesmereUI:RefreshPage()
end }
); y = y - h
-- Inline color swatch on EUI Options Theme (right region)
do
local rightRgn = themeRow._rightRegion
local function isCustomColorOff()
return EllesmereUI.GetActiveTheme() ~= "Custom Color"
end
local tcGet = function()
local db = EllesmereUIDB
local sa = db and db.accentColor
if sa then return sa.r, sa.g, sa.b, 1 end
return EllesmereUI.GetAccentColor()
end
local tcSet = function(r, g, b)
if not EllesmereUIDB then EllesmereUIDB = {} end
EllesmereUIDB.accentColor = { r = r, g = g, b = b }
-- Only update the window background, not the accent color
if EllesmereUI._applyBgTint then
EllesmereUI._applyBgTint(r, g, b)
end
end
local tcSwatch, tcUpdateSwatch = EllesmereUI.BuildColorSwatch(rightRgn, rightRgn:GetFrameLevel() + 5, tcGet, tcSet, nil, 20)
PP.Point(tcSwatch, "RIGHT", rightRgn._control, "LEFT", -12, 0)
rightRgn._lastInline = tcSwatch
EllesmereUI.RegisterWidgetRefresh(function()
local off = isCustomColorOff()
tcSwatch:SetAlpha(off and 0.15 or 1)
tcSwatch:EnableMouse(not off)
tcUpdateSwatch()
end)
tcSwatch:SetAlpha(isCustomColorOff() and 0.15 or 1)
tcSwatch:EnableMouse(not isCustomColorOff())
tcSwatch:SetScript("OnEnter", function(self)
if isCustomColorOff() then
EllesmereUI.ShowWidgetTooltip(self, "This option is only available for the Custom Color Theme")
end
end)
tcSwatch:SetScript("OnLeave", function()
EllesmereUI.HideWidgetTooltip()
end)
end
-- Row 2: UI Scale (with cog: "Set UI Scale to 0.5333")
local uiScaleRow
uiScaleRow, h = W:DualRow(parent, y,
{ type="slider", text="UI Scale",
min=0.40, max=1.00, step=0.01,