about summary refs log tree commit diff stats
path: root/src/utils
diff options
context:
space:
mode:
authorbptato <nincsnevem662@gmail.com>2023-09-18 20:14:43 +0200
committerbptato <nincsnevem662@gmail.com>2023-09-18 20:14:43 +0200
commit6f391e31a8b8298f16e1812c118616a84eb9b849 (patch)
treeafc3402955359b6526b82ce6b77fe57e9c0b20c7 /src/utils
parent0bc76d47ac558896c9027727f9de0b4b262f6e24 (diff)
downloadchawan-6f391e31a8b8298f16e1812c118616a84eb9b849.tar.gz
twtstr: remove unused functions
lineedit no longer needs these
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/twtstr.nim22
1 files changed, 0 insertions, 22 deletions
diff --git a/src/utils/twtstr.nim b/src/utils/twtstr.nim
index cd85d45c..c0b68178 100644
--- a/src/utils/twtstr.nim
+++ b/src/utils/twtstr.nim
@@ -185,11 +185,6 @@ func equalsIgnoreCase*(s1, s2: string): bool {.inline.} =
 func isDigitAscii*(r: Rune): bool =
   return int(r) < 256 and isDigit(char(r))
 
-func substr*(s: seq[Rune], i, j: int): seq[Rune] =
-  if s.len == 0:
-    return @[]
-  return s[min(high(s), i)..min(high(s), j - 1)]
-
 func stripAndCollapse*(s: string): string =
   var i = 0
   while i < s.len and s[i] in AsciiWhitespace:
@@ -1018,27 +1013,10 @@ func width*(s: string, start, len: int): int =
     fastRuneAt(s, i, r)
     result += r.twidth(result)
 
-func width*(s: seq[Rune]): int =
-  for r in s:
-    result += r.twidth(result)
-
 func notwidth*(s: string): int =
   for r in s.runes:
     result += r.width()
 
-func width*(s: seq[Rune], min, max: int): int =
-  var i = min
-  var mi = min(max, s.len)
-  while i < mi:
-    result += s[i].twidth(result)
-    inc i
-
-func width*(s: seq[Rune], min: int): int =
-  var i = min
-  while i < s.len:
-    result += s[i].twidth(result)
-    inc i
-
 func twidth*(s: string, w: int): int =
   var i = w
   for r in s.runes():