aboutsummaryrefslogtreecommitdiff
path: root/todo
diff options
context:
space:
mode:
authorPetter Rodhelind <petter.rodhelind@gmail.com>2018-03-16 12:33:26 +0100
committerPetter Rodhelind <petter.rodhelind@gmail.com>2018-03-16 12:33:26 +0100
commitfea1a1adbb03d657724be9b9994ba6b11dfe625f (patch)
tree59632674ec570a8f1db6d3154ce49b255ac63b6e /todo
parent2395485d075f80117fe3ce25ef339bb1ffecf160 (diff)
downloadpoe-fea1a1adbb03d657724be9b9994ba6b11dfe625f.tar.gz
poe-fea1a1adbb03d657724be9b9994ba6b11dfe625f.tar.bz2
poe-fea1a1adbb03d657724be9b9994ba6b11dfe625f.zip
Redesign.
Diffstat (limited to 'todo')
-rw-r--r--todo27
1 files changed, 26 insertions, 1 deletions
diff --git a/todo b/todo
index d0aef98..bd8faa8 100644
--- a/todo
+++ b/todo
@@ -24,7 +24,32 @@ visual
file stats with ^G
keep tagline updated with flags
show running processes in menu
- another style for top menu
do not change CurWin on mousepressed
scroll on mpressed at bottom line
unprintableChar styling
+
+
+
+---
+
+
+slice insertion
+
+func insert(original []int, position int, value int) []int {
+ l := len(original)
+ target := original
+ if cap(original) == l {
+ target = make([]int, l+1, l+10)
+ copy(target, original[:position])
+ } else {
+ target = append(target, -1)
+ }
+ copy(target[position+1:], original[position:])
+ target[position] = value
+ return target
+}
+
+
+s = append(s, 0)
+copy(s[i+1:], s[i:])
+s[i] = x \ No newline at end of file