Module:Infobox ET: Difference between revisions

Fredg999 (talk | contribs)
m Bug fixing
Fredg999 (talk | contribs)
m Bug fixing
Line 10: Line 10:
end
end
local step_size = i._backslash_ratio('1\\' .. tuning)
local step_size = i._backslash_ratio('1\\' .. tuning)
local fifth = math.log(1.5)/math.log(equave)*size
local fifth = u._round(math.log(1.5)/math.log(equave)*size, 0)
return '<div style="\n' ..
return '<div style="\n' ..
'border: 1px solid #999;\n' ..
'border: 1px solid #999;\n' ..
Line 31: Line 31:
'|-\n' ..
'|-\n' ..
'| style="text-align:right; padding-right: 0.25em" | Fifth\n' ..
'| style="text-align:right; padding-right: 0.25em" | Fifth\n' ..
'| style="background-color: white; padding-left: 0.25em; font-weight: bold" | ' .. u._round(fifth, 0) .. '\\' .. tuning .. ' (' .. i._to_cents(fifth, 6) .. '{{cent}})\n' ..
'| style="background-color: white; padding-left: 0.25em; font-weight: bold" | ' .. fifth .. '\\' .. tuning .. ' (' .. i._to_cents(i._backslash_ratio(fifth .. '\\' .. tuning), 6) .. '{{cent}})\n' ..
'|}</div>'
'|}</div>'
end
end


return p
return p