get_last_col {
;Usage: $get_last_col(<text>)
; returns colour last colour codes contained in string (minus colour control code itself)
; .pos property returns position of first number
; .lpos property returns position of last number
var %re = /(\d{1,2}(?:,\d{1,2})*)(?:[^]*)$/
!.echo -q $regex(get_last,$$1,%re)
if ($prop == pos) return $iif($regml(get_last,1).pos,$ifmatch,0)
elseif ($prop == lpos) return $iif($regml(get_last,1).pos,$calc($ifmatch + $len($regml(get_last,1)) - 1),0)
return $iif($regml(get_last,1),$ifmatch,$null)
}