10 |
var child = childs[i]; |
var child = childs[i]; |
11 |
if (child.nodeType != 1) continue; |
if (child.nodeType != 1) continue; |
12 |
if (child.nodeName == 'DT') { |
if (child.nodeName == 'DT') { |
13 |
var text = child.textContent || child.innerText; |
line = parseInt (child.getAttribute ('data-line') || 0); |
14 |
var m; |
column = parseInt (child.getAttribute ('data-column') || 0); |
|
if (m = text.match (/Line (\d+)(?: column (\d+))?/)) { |
|
|
line = parseInt (m[1]); |
|
|
column = parseInt (m[2] || 0); |
|
|
} else { |
|
|
line = 0; |
|
|
column = 0; |
|
|
} |
|
15 |
} else if (child.nodeName == 'DD') { |
} else if (child.nodeName == 'DD') { |
16 |
if (line > 0) { |
if (line > 0) { |
17 |
var lineEl = document.getElementById (idPrefix + 'line-' + line); |
var lineEl = document.getElementById (idPrefix + 'line-' + line); |