Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wrong width for full-width characters << >> #446

xuefer opened this issue Nov 30, 2015 · 11 comments

wrong width for full-width characters << >> #446

xuefer opened this issue Nov 30, 2015 · 11 comments


Copy link

xuefer commented Nov 30, 2015


not sure if this is the same or different problem as you guys discussing
the picture i upload is about "single/double-width character mis-handled"

left-hand side is conhost (show by ctrl+win+alt+space), which I think is correct

the right hand side is ConEmu, you acn see << >>, are not displayed fully: the lines marked with red column, 《你的灯亮着吗》
however full-width of ( and ) is displayed correctly: (法)

Copy link

Uncheck "Monospace" in font settings

Copy link

xuefer commented Nov 30, 2015

unchecked, exactly same look.
"Monospace" option can't explain why (法) is correct

Copy link

  • Show full screenshot with StatusBar visible
  • Post here a link to a file you are trying (to cat?)
  • Show screenshot of Settings/Info page (may be together with first one)
  • Show information from About/SysInfo

Copy link

xuefer commented Nov 30, 2015

use the unicode one, it should works better on default-to-non-GBK system setting

Copy link

xuefer commented Nov 30, 2015

I'm new to ConEmu. still digging into it :)




ConEmu-Maximus5 is a Windows console emulator with tabs, which represents multiple consoles and simple GUI applications as one customizable GUI window with various features.

Basic application - joint use with Far Manager (a console program for managing files and archives in Windows operating systems).

By default this program launches "Far.exe" (if exists) or "tcc.exe"/"cmd.exe".

© 2006-2008 Zoin (based on console emulator by SEt)
© 2009-2015

Online documentation:

You can show your appreciation and support future development by donating. Donate button located on project website under ConEmu sketch (upper right of page).


Startup info
OsVer: 6.3.9600.x64, Product: 1, SP: 0.0, Suite: 0x100, SM_SERVERR2: 0
CSDVersion: , ReactOS: 0 (), Rsrv: 0
DBCS: 1, WINE: 0, PE: 0, Remote: 0, ACP: 936, OEMCP: 936, Admin: 0
Desktop: Winsta0\Default; BPP: 32
Title: C:\Users\Xuefer\AppData\Roaming\Microsoft\Internet Explorer\Quick Launch\User Pinned\TaskBar\Console Emulator (x64).lnk
Size: {0,0},{0,0}
Flags: 0x00000C01, ShowWindow: 1, ConHWnd: 0x00000000
char: 1, short: 2, int: 4, long: 4, u64: 8
Handles: 0x00000000, 0x00010003, 0x00000000
Active HKL: 0x0000000004090409
GetKeyboardLayoutList: 0x0000000004090409 0x0000000008040804
CmdLine: "C:\app\system\ConEmu\ConEmu64.exe"
ExecMod: C:\app\system\ConEmu\ConEmu64.exe
WorkDir: C:\app\system\ConEmu
PathEnv: c:\app\batch;C:\ProgramData\Oracle\Java\javapath;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;c:\app\cygwin\bin;c:\app\wintools;c:\app\dev\Android\android-sdk\platform-tools;C:\app\dev\Android\android-sdk\tools;c:\app\dev\Android\android-sdk\sdk\platform-tools;C:\Program Files (x86)\Windows Kits\8.0\Windows Performance Toolkit
ConFont: 932 *MS ゴシック 949 *굴림체 00 Consolas 0 Lucida Console 950 *細明體 936 *新宋体
CMD's AutoRuns: {not defined}
Foreground: x005907D0 {2060,410}-{2916,1126} 'VirtualConsoleClass' - cmd
MouseCursor: {2365,849} MouseMonitor: 00010003 StartMonitor: 00010003
Display: bpp=32, planes=1, align=1, vrefr=60, shade=x00000000, rast=x00007E99, dpi=96x96, per-mon-dpi=1
Monitors (dpi: WholeDesktop, Effective, Angular, RAW):
00010001: {0,0}-{1920,1200} (1920x1200), Working: {0,0}-{1920,1170} (1920x1170), dpi: {96,96};{96,96};{93,93};{94,94} \\.\DISPLAY1 <<== Primary
00010003: {1920,176}-{3200,1200} (1280x1024), Working: {1920,176}-{3200,1170} (1280x994), dpi: {96,96};{96,96};{96,96};{96,96} \\.\DISPLAY2
0000000140000000-0000000140259FFF 25A000 C:\app\system\ConEmu\ConEmu64.exe
00007FFC5D460000-00007FFC5D60BFFF 1AC000 C:\WINDOWS\SYSTEM32\ntdll.dll
00007FFC5C710000-00007FFC5C84DFFF 13E000 C:\WINDOWS\system32\KERNEL32.DLL
00007FFC5A780000-00007FFC5A894FFF 115000 C:\WINDOWS\system32\KERNELBASE.dll
00007FFC5C390000-00007FFC5C506FFF 177000 C:\WINDOWS\system32\USER32.dll
00007FFC5CBC0000-00007FFC5CC69FFF AA000 C:\WINDOWS\system32\ADVAPI32.dll
00007FFC5AE50000-00007FFC5C37AFFF 152B000 C:\WINDOWS\system32\SHELL32.dll
00007FFC5D0A0000-00007FFC5D233FFF 194000 C:\WINDOWS\system32\ole32.dll
00007FFC5CC70000-00007FFC5CDBEFFF 14F000 C:\WINDOWS\system32\GDI32.dll
00007FFC57AD0000-00007FFC57AD9FFF A000 C:\WINDOWS\SYSTEM32\VERSION.dll
00007FFC5D240000-00007FFC5D293FFF 54000 C:\WINDOWS\system32\SHLWAPI.dll
00007FFC58080000-00007FFC582FAFFF 27B000 C:\WINDOWS\WinSxS\\COMCTL32.dll
00007FFC5ABB0000-00007FFC5AC65FFF B6000 C:\WINDOWS\system32\COMDLG32.dll
00007FFC57700000-00007FFC57721FFF 22000 C:\WINDOWS\SYSTEM32\WINMM.dll
00007FFC5C630000-00007FFC5C6F0FFF C1000 C:\WINDOWS\system32\OLEAUT32.dll
00007FFC57FF0000-00007FFC58005FFF 16000 C:\WINDOWS\SYSTEM32\NETAPI32.dll
00007FFC5C520000-00007FFC5C5C9FFF AA000 C:\WINDOWS\system32\msvcrt.dll
00007FFC5CDD0000-00007FFC5CE28FFF 59000 C:\WINDOWS\SYSTEM32\sechost.dll
00007FFC5CA70000-00007FFC5CBB0FFF 141000 C:\WINDOWS\system32\RPCRT4.dll
00007FFC5C850000-00007FFC5CA60FFF 211000 C:\WINDOWS\SYSTEM32\combase.dll
00007FFC574E0000-00007FFC57509FFF 2A000 C:\WINDOWS\SYSTEM32\WINMMBASE.dll
00007FFC597F0000-00007FFC597FBFFF C000 C:\WINDOWS\SYSTEM32\netutils.dll
00007FFC5A210000-00007FFC5A235FFF 26000 C:\WINDOWS\SYSTEM32\srvcli.dll
00007FFC57FB0000-00007FFC57FC6FFF 17000 C:\WINDOWS\SYSTEM32\wkscli.dll
00007FFC5A680000-00007FFC5A6CEFFF 4F000 C:\WINDOWS\SYSTEM32\cfgmgr32.dll
00007FFC593D0000-00007FFC593F7FFF 28000 C:\WINDOWS\SYSTEM32\DEVOBJ.dll
00007FFC58970000-00007FFC58A21FFF B2000 C:\WINDOWS\SYSTEM32\SHCORE.DLL
00007FFC53D80000-00007FFC53D96FFF 17000 C:\WINDOWS\SYSTEM32\SAMCLI.DLL
00007FFC5AAE0000-00007FFC5AB15FFF 36000 C:\WINDOWS\system32\IMM32.DLL
00007FFC5D300000-00007FFC5D451FFF 152000 C:\WINDOWS\system32\MSCTF.dll
00007FFC59220000-00007FFC59348FFF 129000 C:\WINDOWS\system32\uxtheme.dll
00007FFC58770000-00007FFC58790FFF 21000 C:\WINDOWS\SYSTEM32\dwmapi.dll
00007FFC5A5B0000-00007FFC5A5C4FFF 15000 C:\WINDOWS\SYSTEM32\profapi.dll
00007FFC59350000-00007FFC5935AFFF B000 C:\WINDOWS\SYSTEM32\kernel.appcore.dll
00007FFC5A480000-00007FFC5A4E2FFF 63000 C:\WINDOWS\SYSTEM32\bcryptPrimitives.dll
00007FFC5CE30000-00007FFC5CEE5FFF B6000 C:\WINDOWS\SYSTEM32\clbcatq.dll
00007FFC4B920000-00007FFC4BB60FFF 241000 C:\WINDOWS\System32\msxml3.dll
00007FFC5A0D0000-00007FFC5A0F5FFF 26000 C:\WINDOWS\System32\bcrypt.dll
00007FFC4F200000-00007FFC4F4FAFFF 2FB000 C:\WINDOWS\system32\explorerframe.dll
00007FFC572E0000-00007FFC57383FFF A4000 C:\WINDOWS\system32\DUser.dll
00007FFC587A0000-00007FFC58960FFF 1C1000 C:\WINDOWS\system32\DUI70.dll
0000000054610000-00000000546CBFFF BC000 C:\app\system\ConEmu\ConEmu\ConEmuCD64.dll
00007FFC59E20000-00007FFC59E3FFFF 20000 C:\WINDOWS\SYSTEM32\CRYPTSP.dll
00007FFC59A40000-00007FFC59A75FFF 36000 C:\WINDOWS\system32\rsaenh.dll
00007FFC57E30000-00007FFC57FAEFFF 17F000 C:\WINDOWS\SYSTEM32\PROPSYS.dll
00007FFC578A0000-00007FFC578AEFFF F000 C:\WINDOWS\SYSTEM32\atlthunk.dll

Copy link

Actually, it's good to have proper reports from CJK users. Appreciated, will dig it.

Copy link

xuefer commented Dec 8, 2015

retried with 151207 and find different issue, relative to this one i guess so post as comment

when start 1 tab, tab1: conemu-cyg-64.exe bash --login -l, any chinese become half-width (width=single-english-letter)
it won't reset to double-width even if i toggle "monospace" setting

but it will reset if i open up another tab2 of bash.exe without conemu-cyg-64.exe AND toggle "monospace" setting, now tab1 is showing chinese as double-width correctly

it took me multiple times to confirm it relative to conemu-cyg-64.exe as it seemed ramdom at first to me

Copy link

Maximus5 commented Dec 8, 2015

True. Connector switches console to UTF8 codepage, that dusables DBCS marks in turn. And this also brings double-width craziness back.
I'm not sure, how we can deal with double-width characters... Console application may expect the line would fit 80 symbols, and what must happens if there are 80 double-width symbols? Have to check other terminals behavior... in Unix/Mac also.

Copy link

xuefer commented Dec 8, 2015

in *nix world when double width characters is handled correctly, the terminal app (and vim) calculate character width correctly, regardless of what encoding/locale is used for bash/vim/ls/echo/cat

some cjk symbol like quotes/comma may be display'ed as single in some case (with specified font?), maybe with rxvt/mrxvt. so there's an option in vim, set ambiwidth=double, or set ambiwidth=single. it affect those

at least let's say mintty. set mintty to UTF-8 mode, let vim/ls output GBK characters, every English is single-width while every Chinese is Double width
set mintty to GBK mode and let vim/ls output UTF-8 characters. ditto
80 english letter or 40 chinese character can be fit in single line, both vim and mintty thinks so. while "ls/cat/echo" just don't care. readline/screen/tmux etc however care because it has to move between character/calculate the width of it so handle it correctly after cursor move across the end of line going to the begin of next line

and sorry i don't have any idea of the behavior of conhost UTF-8 mode

Copy link

How about latest builds?

Copy link

xuefer commented Dec 23, 2015

looks good

@xuefer xuefer closed this as completed Dec 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
None yet

No branches or pull requests

2 participants