func NickSelectorFromList(nickList string) *NickSelector {
	ns := NewNickSelector()
	var nickBuffer string

	nickMap := make(map[string]bool)

	for _, char := range nickList {
		if len(strings.TrimSpace(string(char))) == 0 || char == '\r' || char == '\n' {
			if 0 < len(nickBuffer) {
				nickMap[nickBuffer] = true
				nickBuffer = ""
			}
			continue
		} else if strings.IndexRune("#~&@%+", char) != -1 {
			// skip channel chars
			continue
		}
		nickBuffer += string(char)
	}
	if 0 < len(nickBuffer) {
		nickMap[nickBuffer] = true
	}

	// add nicks to our list
	for name := range nickMap {
		ns.nicks = append(ns.nicks, name)
	}

	return ns
}
// NickSelectorFromList takes a list of nicks and returns a NickSelector.
NickSelectorFromList takes a list of nicks and returns a NickSelector.
// NickSelectorFromList takes a list of nicks and returns a NickSelector .
func NickSelectorFromList(nickList string) *NickSelector {
	ns := NewNickSelector()
	var nickBuffer string
	nickMap := make(map[string]bool)
	for _, char := range nickList {
		if len(strings.TrimSpace(string(char))) == 0 || char == '\r' || char == '\n' {
			if 0 < len(nickBuffer) {
				nickMap[nickBuffer] = true
				nickBuffer = ""
			}
			continue
		} else if strings.IndexRune("#~&@%+", char) != -1 {
			continue
		}
		nickBuffer += string(char)
	}
	if 0 < len(nickBuffer) {
		nickMap[nickBuffer] = true
	}
	for name := range nickMap {
		ns.nicks = append(ns.nicks, name)
	}
	return ns
}
func NickSelectorFromList ( nickList string ) * NickSelector { ns := NewNickSelector ( ) var nickBuffer string nickMap := make ( map [ string ] bool ) for _ , char := range nickList { if len ( strings . TrimSpace ( string ( char ) ) ) == 0 || char == '\r' || char == '\n' { if 0 < len ( nickBuffer ) { nickMap [ nickBuffer ] = true nickBuffer = " " } continue } else if strings . IndexRune ( " " , char ) != - 1 { continue } nickBuffer += string ( char ) } if 0 < len ( nickBuffer ) { nickMap [ nickBuffer ] = true } for name := range nickMap { ns . nicks = append ( ns . nicks , name ) } return ns }
NickSelectorFromList takes a list of nicks and returns a NickSelector.
NickSelectorFromList takes a list of nicks and returns a NickSelector .
// skip channel chars // add nicks to our list