mirror of
				git://git.code.sf.net/p/cdesktopenv/code
				synced 2025-03-09 15:50:02 +00:00 
			
		
		
		
	Handle the escape sequence for the End key (#75)
Many terminals (xterm being one example) give the Home and End keys the escape sequences '^[[H' and '^[[F'. The first sequence is handled in both editing modes by moving the cursor to start of line, but ksh ignored the second sequence. src/cmd/ksh93/edit/emacs.c, src/cmd/ksh93/edit/vi.c: - Add case labels for '^[[F' so that in both editing modes the End key moves the cursor to the end of the line.
This commit is contained in:
		
							parent
							
								
									1fbbeaa19d
								
							
						
					
					
						commit
						01145a48dd
					
				
					 3 changed files with 6 additions and 0 deletions
				
			
		|  | @ -1105,6 +1105,7 @@ static int escape(register Emacs_t* ep,register genchar *out,int count) | |||
| 			    case 'H': | ||||
| 				ed_ungetchar(ep->ed,cntl('A')); | ||||
| 				return(-1); | ||||
| 			    case 'F': | ||||
| 			    case 'Y': | ||||
| 				ed_ungetchar(ep->ed,cntl('E')); | ||||
| 				return(-1); | ||||
|  |  | |||
|  | @ -1669,6 +1669,7 @@ static int mvcursor(register Vi_t* vp,register int motion) | |||
| 		    case 'H': | ||||
| 			tcur_virt = 0; | ||||
| 			break; | ||||
| 		    case 'F': | ||||
| 		    case 'Y': | ||||
| 			tcur_virt = last_virt; | ||||
| 			break; | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue