MCPcopy
hub / github.com/DHTMLX/gantt / getUsefulRect

Function getUsefulRect

samples/common/codehighlight/codemirror.js:2469–2477  ·  view source on GitHub ↗
(rects, bias)

Source from the content-addressed store, hash-verified

2467 }
2468
2469 function getUsefulRect(rects, bias) {
2470 var rect = nullRect;
2471 if (bias == "left") { for (var i = 0; i < rects.length; i++) {
2472 if ((rect = rects[i]).left != rect.right) { break }
2473 } } else { for (var i$1 = rects.length - 1; i$1 >= 0; i$1--) {
2474 if ((rect = rects[i$1]).left != rect.right) { break }
2475 } }
2476 return rect
2477 }
2478
2479 function measureCharInner(cm, prepared, ch, bias) {
2480 var place = nodeAndOffsetInLineMap(prepared.map, ch, bias);

Callers 1

measureCharInnerFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected