diff --git a/API UI.txt b/API UI.txt
index 9b0ebe53c..f694b74d4 100644
--- a/API UI.txt
+++ b/API UI.txt
@@ -125,7 +125,7 @@ size = number, adjust the size of the border.
color = table, {r, g, b, a}
texture = string, edge name for SharedMedia:Fetch ("border", texture)
-instance:SetBarTextSettings (size, font, fixedcolor, leftcolorbyclass, rightcolorbyclass, leftoutline, rightoutline, customrighttextenabled, customrighttext, percentage_type, showposition, customlefttextenabled, customlefttext)
+instance:SetBarTextSettings (size, font, fixedcolor, leftcolorbyclass, rightcolorbyclass, leftoutline, rightoutline, customrighttextenabled, customrighttext, percentage_type, showposition, customlefttextenabled, customlefttext, translittest)
size = number, text size
font = string, text font, e.g "Arrial Narrow"
fixedcolor = table with {r, b, g, a} or html color string (e.g. "blue").
diff --git a/Libs/DF/fw.lua b/Libs/DF/fw.lua
index bbb046093..3d7e7dbd9 100644
--- a/Libs/DF/fw.lua
+++ b/Libs/DF/fw.lua
@@ -1,5 +1,5 @@
-local dversion = 153
+local dversion = 154
local major, minor = "DetailsFramework-1.0", dversion
local DF, oldminor = LibStub:NewLibrary (major, minor)
@@ -21,7 +21,7 @@ SMALL_NUMBER = 0.000001
ALPHA_BLEND_AMOUNT = 0.8400251
DF.AuthorInfo = {
- Name = "Tercioo",
+ Name = "Terciob",
Discord = "https://discord.gg/AGSzAZX",
}
diff --git a/Libs/libs.xml b/Libs/libs.xml
index fecf64dbb..4bc83fe17 100644
--- a/Libs/libs.xml
+++ b/Libs/libs.xml
@@ -18,4 +18,5 @@
+
diff --git a/classes/classe_damage.lua b/classes/classe_damage.lua
index 77cfa909d..f7c5036d5 100644
--- a/classes/classe_damage.lua
+++ b/classes/classe_damage.lua
@@ -1,8 +1,8 @@
-- damage object
---2672
local _detalhes = _G._detalhes
local Loc = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
+ local Translit = LibStub ("LibTranslit-1.0")
local gump = _detalhes.gump
local _
@@ -2672,6 +2672,11 @@ local InBarIconPadding = 6
bar_number = bar.colocacao .. ". "
end
+ --translate cyrillic alphabet to western alphabet by Vardex (https://github.com/Vardex May 22, 2019)
+ if (instance.row_info.textL_translit_text) then
+ self.displayName = Translit:Transliterate(self.displayName, "!")
+ end
+
if (enemy) then
if (arena_enemy) then
if (_detalhes.show_arena_role_icon) then
@@ -5158,11 +5163,7 @@ end
if (not no_refresh) then
_detalhes.refresh:r_atributo_damage (actor, shadow)
end
-
- --a refer�ncia do .owner pode ter sido apagada?
- --os 2 segmentos foram juntados por�m a refer�ncia do owner de um pet criado ali em cima deve ser nula?
- --teria que analisar se o novo objecto � de um pet e colocar a refer�ncia do owner no pet novamente, ou pelo menos verificar se a refer�ncia � valida
-
+
--> tempo decorrido (captura de dados)
local end_time = actor.end_time
if (not actor.end_time) then
diff --git a/classes/classe_instancia_include.lua b/classes/classe_instancia_include.lua
index 5e4498452..78759d1bb 100644
--- a/classes/classe_instancia_include.lua
+++ b/classes/classe_instancia_include.lua
@@ -1,4 +1,12 @@
+--default values for instances (windows)
+--if a new value is added here and it does not exists (nil) in the instance, it'll be copied into it
+--the value added can be overwritten in the skins.lua file or /run Details:GetWindow(1). =
+--or thought a new option in the options panel
+
+--values added into 'instance_skin_ignored_values' won't be passed when the user exports the profile or exports the skin individually.
+
+
local _detalhes = _G._detalhes
local SharedMedia = LibStub:GetLibrary("LibSharedMedia-3.0")
@@ -197,6 +205,8 @@ _detalhes.instance_defaults = {
textR_separator = ",",
--left text bar number
textL_show_number = true,
+ --translit text by Vardex (https://github.com/Vardex May 22, 2019)
+ textL_translit_text = false,
--if text class color are false, this color will be used
fixed_text_color = {1, 1, 1},
--left text outline effect
diff --git a/functions/skins.lua b/functions/skins.lua
index 0a9ac0cc3..9c00b9d06 100644
--- a/functions/skins.lua
+++ b/functions/skins.lua
@@ -6,13 +6,13 @@ local _
--> install skin function:
function _detalhes:InstallSkin (skin_name, skin_table)
if (not skin_name) then
- return false -- sem nome
+ return false -- skin without a name
elseif (_detalhes.skins [skin_name]) then
- return false -- ja existe
+ return false -- skin with this name already exists
end
if (not skin_table.file) then
- return false -- sem arquivo
+ return false -- no skin file
end
skin_table.author = skin_table.author or ""
diff --git a/gumps/janela_options.lua b/gumps/janela_options.lua
index ee5c0499e..d312a1839 100644
--- a/gumps/janela_options.lua
+++ b/gumps/janela_options.lua
@@ -1,4 +1,10 @@
- --[[ options panel file --]]
+--[[
+ options panel file
+ please note: this file was wrote on 2012 when Details! had only 5 options,
+ the addon got bigger but I keeped the same format, you're free to judge my decision.
+--]]
+
+
--[[
search for "~number" without the quotes to quick access the page:
@@ -6770,6 +6776,30 @@ function window:CreateFrame5()
window:CreateLineBackground2 (frame5, "PositionNumberSlider", "PositionNumberLabel", Loc ["STRING_OPTIONS_TEXT_LPOSITION_DESC"])
+ --> left translit text by Vardex (https://github.com/Vardex May 22, 2019)
+ g:NewSwitch (frame5, _, "$parentTranslitTextSlider", "TranslitTextSlider", 60, 20, _, _, instance.row_info.textL_translit_text, nil, nil, nil, nil, options_switch_template)
+ g:NewLabel (frame5, _, "$parentTranslitTextLabel", "TranslitTextLabel", Loc ["STRING_OPTIONS_TEXT_LTRANSLIT"], "GameFontHighlightLeft")
+
+ frame5.TranslitTextSlider:SetPoint ("left", frame5.TranslitTextLabel, "right", 2)
+ frame5.TranslitTextSlider:SetAsCheckBox()
+ frame5.TranslitTextSlider.OnSwitch = function (self, instance, value)
+ instance:SetBarTextSettings (nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, value)
+
+ if (_detalhes.options_group_edit and not DetailsOptionsWindow.loading_settings) then
+ for _, this_instance in ipairs (instance:GetInstanceGroup()) do
+ if (this_instance ~= instance) then
+ this_instance:SetBarTextSettings (nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, value)
+ end
+ end
+ end
+
+ _detalhes:SendOptionsModifiedEvent (DetailsOptionsWindow.instance)
+ end
+
+ window:CreateLineBackground2 (frame5, "TranslitTextSlider", "TranslitTextLabel", Loc ["STRING_OPTIONS_TEXT_LTRANSLIT_DESC"])
+
+
+
--> right outline
g:NewSwitch (frame5, _, "$parentTextRightOutlineSlider", "textRightOutlineSlider", 60, 20, _, _, instance.row_info.textR_outline, nil, nil, nil, nil, options_switch_template)
g:NewLabel (frame5, _, "$parentTextRightOutlineLabel", "textRightOutlineLabel", Loc ["STRING_OPTIONS_TEXT_LOUTILINE"], "GameFontHighlightLeft")
@@ -7284,6 +7314,7 @@ function window:CreateFrame5()
{"OutlineSmallColorLabelLeft", 2},
{"classColorsLeftTextLabel", 3},
{"PositionNumberLabel", 4},
+ {"TranslitTextLabel", 5},
{"cutomLeftTextLabel", 5, true},
{"cutomLeftTextEntryLabel", 6},
}
@@ -11530,6 +11561,9 @@ end --> if not window
_G.DetailsOptionsWindow5PositionNumberSlider.MyObject:SetFixedParameter (editing_instance)
_G.DetailsOptionsWindow5PositionNumberSlider.MyObject:SetValue (editing_instance.row_info.textL_show_number)
+ _G.DetailsOptionsWindow5TranslitTextSlider.MyObject:SetFixedParameter (editing_instance)
+ _G.DetailsOptionsWindow5TranslitTextSlider.MyObject:SetValue (editing_instance.row_info.textL_translit_text)
+
_G.DetailsOptionsWindow5BracketDropdown.MyObject:SetFixedParameter (editing_instance)
_G.DetailsOptionsWindow5SeparatorDropdown.MyObject:SetFixedParameter (editing_instance)
_G.DetailsOptionsWindow5RightTextShowTotalSlider.MyObject:SetFixedParameter (editing_instance)
diff --git a/gumps/janela_principal.lua b/gumps/janela_principal.lua
index 52eb8df1c..e74731be1 100644
--- a/gumps/janela_principal.lua
+++ b/gumps/janela_principal.lua
@@ -4135,7 +4135,7 @@ function gump:CriaNovaBarra (instancia, index)
return new_row
end
-function _detalhes:SetBarTextSettings (size, font, fixedcolor, leftcolorbyclass, rightcolorbyclass, leftoutline, rightoutline, customrighttextenabled, customrighttext, percentage_type, showposition, customlefttextenabled, customlefttext, smalloutline_left, smalloutlinecolor_left, smalloutline_right, smalloutlinecolor_right)
+function _detalhes:SetBarTextSettings (size, font, fixedcolor, leftcolorbyclass, rightcolorbyclass, leftoutline, rightoutline, customrighttextenabled, customrighttext, percentage_type, showposition, customlefttextenabled, customlefttext, smalloutline_left, smalloutlinecolor_left, smalloutline_right, smalloutlinecolor_right, translittext)
--> size
if (size) then
@@ -4219,6 +4219,11 @@ function _detalhes:SetBarTextSettings (size, font, fixedcolor, leftcolorbyclass,
if (type (showposition) == "boolean") then
self.row_info.textL_show_number = showposition
end
+
+ --> translit text by Vardex (https://github.com/Vardex May 22, 2019)
+ if (type (translittext) == "boolean") then
+ self.row_info.textL_translit_text = translittext
+ end
self:InstanceReset()
self:InstanceRefreshRows()