Module:MOS degrees: Difference between revisions

Ganaram inukshuk (talk | contribs)
No edit summary
Ganaram inukshuk (talk | contribs)
Changed color for accidental highlighting (blue was better), clarified comments
Line 352: Line 352:
-- Add new row, with coloring
-- Add new row, with coloring
if not is_nominal then
if not is_nominal then
result = result .. '|- bgcolor="#c8ccd1"\n'
result = result .. '|- bgcolor="#b0c4de"\n'
else
else
result = result .. "|-\n"
result = result .. "|-\n"
Line 358: Line 358:
-- Is the row for a period?
-- Is the row for a period?
-- Check whether it's a period for the first step ratio, since it'll be
-- Check whether it's a period only for the using the cent value for the
-- a period for any of the other step ratios
-- first step ratio, since it'll be a period for the other ratios
local is_period = steps_and_cents[1][i][1] % (steps_in_ets[1] / periods_per_equave) == 0
local cent_value = steps_and_cents[1][i][1] -- First set of cells, current row, first column is current cent value
local is_period = cent_value % (steps_in_ets[1] / periods_per_equave) == 0
-- Add cells for degree and note name
-- Add cells for degree and note name