anchor.diff:      undefined.
   
   gr_add_cur({Next,_CurI,_CurP,Gs}, Pid, Shell) ->
  -    {Next+1,Next,Pid,append(Gs, [{Next,Pid,Shell}])}.
  +    {Next+1,Next,Pid,lists:append(Gs, [{Next,Pid,Shell}])}.
   
   gr_set_cur({Next,_CurI,_CurP,Gs}, I) ->
       case gr_get_num1(Gs, I) of
  
positive.code: 		 {put_chars, unicode,"  r [node [shell]]  - start remote shell\n"}] ++
  		QuitReq ++
  		[{put_chars, unicode,"  ? | h             - this message\n"}],
  		Iport, Oport).
  
  get_line({done,Line,_Rest,Rs}, Iport, Oport) ->
      io_requests(Rs, Iport, Oport),
      Line;
  get_line({undefined,_Char,Cs,Cont,Rs}, Iport, Oport) ->
      io_requests(Rs, Iport, Oport),
      io_request(beep, Iport, Oport),
      get_line(edlin:edit_line(Cs, Cont), Iport, Oport);
  get_line({What,Cont0,Rs}, Iport, Oport) ->
      io_requests(Rs, Iport, Oport),
      receive
  	{Iport,{data,Cs}} ->
  	    get_line(edlin:edit_line(Cs, Cont0), Iport, Oport);
  	{Iport,eof} ->
  	    get_line(edlin:edit_line(eof, Cont0), Iport, Oport)
      after
  	get_line_timeout(What) ->
  	    get_line(edlin:edit_line([], Cont0), Iport, Oport)
      end.
  
  get_line_timeout(blink) -> 1000;
  get_line_timeout(more_chars) -> infinity.
  
  % Let driver report window geometry,
  % definitely outside of the common interface
  get_tty_geometry(Iport) ->
      case (catch port_control(Iport,?CTRL_OP_GET_WINSIZE,[])) of
  	List when length(List) =:= 8 -> 
  	    <<W:32/native,H:32/native>> = list_to_binary(List),
  	    {W,H};
  	_ ->
  	    error
      end.
  get_unicode_state(Iport) ->
      case (catch port_control(Iport,?CTRL_OP_GET_UNICODE_STATE,[])) of
  	[Int] when Int > 0 -> 
  	    true;
  	[Int] when Int =:= 0 ->
  
negative.code: 	    error
      end.
  
  set_unicode_state(Port, Bool) ->
      Data = case Bool of
  	       true -> [1];
  	       false -> [0]
  	   end,
      case (catch port_control(Port,?CTRL_OP_SET_UNICODE_STATE,Data)) of
  	[Int] when Int > 0 -> 
  	    true;
  	[Int] when Int =:= 0 ->
  	    false;
  	_ ->
  	    error
      end.
  