Skip to content

Commit

Permalink
remove dead code
Browse files Browse the repository at this point in the history
  • Loading branch information
jedib0t committed Oct 3, 2024
1 parent 82dc7ea commit cf86164
Showing 1 changed file with 0 additions and 34 deletions.
34 changes: 0 additions & 34 deletions text/wrap.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,40 +85,6 @@ func WrapText(str string, wrapLen int) string {
}

return out.String()

//if wrapLen <= 0 {
// return ""
//}
//
//var out strings.Builder
//sLen := utf8.RuneCountInString(str)
//out.Grow(sLen + (sLen / wrapLen))
//
//esp := escSeqParser{}
//lineIdx, isEscSeq, lastEscSeq := 0, false, ""
//for _, char := range str {
// if char == EscapeStartRune {
// isEscSeq = true
// lastEscSeq = ""
// }
// if isEscSeq {
// lastEscSeq += string(char)
// }
//
// appendChar(char, wrapLen, &lineIdx, isEscSeq, lastEscSeq, &out)
//
// if isEscSeq && char == EscapeStopRune {
// isEscSeq = false
// esp.Parse(lastEscSeq)
// }
// if lastEscSeq == EscapeReset {
// lastEscSeq = ""
// }
//}
//if lastEscSeq != "" && lastEscSeq != EscapeReset {
// out.WriteString(EscapeReset)
//}
//return out.String()
}

func appendChar(char rune, wrapLen int, lineLen *int, inEscSeq bool, lastSeenEscSeq string, out *strings.Builder) {
Expand Down

0 comments on commit cf86164

Please sign in to comment.