mirror of
				git://git.code.sf.net/p/zsh/code
				synced 2025-10-31 06:00:54 +01:00 
			
		
		
		
	40037: Unicode 9 character width support.
Enable with --enable-unicode9.
This commit is contained in:
		
							parent
							
								
									110ffae9fe
								
							
						
					
					
						commit
						596ba302e6
					
				
					 5 changed files with 1351 additions and 2 deletions
				
			
		
							
								
								
									
										13
									
								
								Src/compat.c
									
										
									
									
									
								
							
							
						
						
									
										13
									
								
								Src/compat.c
									
										
									
									
									
								
							|  | @ -635,7 +635,18 @@ strtoul(nptr, endptr, base) | |||
| #endif /* HAVE_STRTOUL */ | ||||
| 
 | ||||
| /**/ | ||||
| #if defined(BROKEN_WCWIDTH) && (defined(__STDC_ISO_10646__) || defined(__APPLE__)) | ||||
| #ifdef ENABLE_UNICODE9 | ||||
| #include "./wcwidth9.h" | ||||
| int | ||||
| mk_wcwidth(wchar_t ucs) | ||||
| { | ||||
|   int w = wcwidth9(ucs); | ||||
|   if (w < -1) | ||||
|     return 1; | ||||
|   return w; | ||||
| } | ||||
| 
 | ||||
| #elif defined(BROKEN_WCWIDTH) && (defined(__STDC_ISO_10646__) || defined(__APPLE__)) | ||||
| 
 | ||||
| /*
 | ||||
|  * This is an implementation of wcwidth() and wcswidth() (defined in | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue