+function! s:NM_show_prev(can_change_thread)
+ let info = b:nm_raw_info
+ let lnum = line('.')
+ for msg in reverse(copy(info['msgs']))
+ if lnum <= msg['start']
+ continue
+ endif
+
+ exec printf('norm %dG', msg['start'])
+ " TODO: try to fit the message on screen
+ norm zz
+ return
+ endfor
+ if !a:can_change_thread
+ return
+ endif
+ call <SID>NM_kill_this_buffer()
+ if line('.') != line('0')
+ norm k
+ call <SID>NM_search_show_thread()
+ norm G
+ call <SID>NM_show_prev(0)
+ else
+ echo 'No more messages.'
+ endif