MCPcopy Create free account
hub / github.com/ProgerXP/Notepad2e / RangeAddDelta

Method RangeAddDelta

scintilla/src/Partitioning.h:23–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21 ~SplitVectorWithRangeAdd() {
22 }
23 void RangeAddDelta(int start, int end, int delta) {
24 // end is 1 past end, so end-start is number of elements to change
25 int i = 0;
26 int rangeLength = end - start;
27 int range1Length = rangeLength;
28 int part1Left = part1Length - start;
29 if (range1Length > part1Left)
30 range1Length = part1Left;
31 while (i < range1Length) {
32 body[start++] += delta;
33 i++;
34 }
35 start += gapLength;
36 while (i < rangeLength) {
37 body[start++] += delta;
38 i++;
39 }
40 }
41};
42
43/// Divide an interval into multiple partitions.

Callers 2

ApplyStepMethod · 0.80
BackStepMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected