{"action":"opened","issue":{"url":"https://api.github.com/repos/gdamore/tcell/issues/250","repository_url":"https://api.github.com/repos/gdamore/tcell","labels_url":"https://api.github.com/repos/gdamore/tcell/issues/250/labels{/name}","comments_url":"https://api.github.com/repos/gdamore/tcell/issues/250/comments","events_url":"https://api.github.com/repos/gdamore/tcell/issues/250/events","html_url":"https://github.com/gdamore/tcell/issues/250","id":394230353,"node_id":"MDU6SXNzdWUzOTQyMzAzNTM=","number":250,"title":"Some characters disappear on Windwos","user":{"login":"rivo","id":480930,"node_id":"MDQ6VXNlcjQ4MDkzMA==","avatar_url":"https://avatars0.githubusercontent.com/u/480930?v=4","gravatar_id":"","url":"https://api.github.com/users/rivo","html_url":"https://github.com/rivo","followers_url":"https://api.github.com/users/rivo/followers","following_url":"https://api.github.com/users/rivo/following{/other_user}","gists_url":"https://api.github.com/users/rivo/gists{/gist_id}","starred_url":"https://api.github.com/users/rivo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rivo/subscriptions","organizations_url":"https://api.github.com/users/rivo/orgs","repos_url":"https://api.github.com/users/rivo/repos","events_url":"https://api.github.com/users/rivo/events{/privacy}","received_events_url":"https://api.github.com/users/rivo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-12-26T19:47:34Z","updated_at":"2018-12-26T19:47:34Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"This came up in https://github.com/rivo/tview/issues/212 where Chinese characters disappear in some situations on Windows. I was able to write a `tcell`-only program that reproduces this:\r\n\r\n```go\r\npackage main\r\n\r\nimport (\r\n\t\"time\"\r\n\r\n\t\"github.com/gdamore/tcell\"\r\n)\r\n\r\nfunc main() {\r\n\t// Set up screen.\r\n\ts, e := tcell.NewScreen()\r\n\tif e != nil {\r\n\t\tpanic(e)\r\n\t}\r\n\tif e = s.Init(); e != nil {\r\n\t\tpanic(e)\r\n\t}\r\n\tstyle := tcell.StyleDefault.Foreground(tcell.ColorWhite)\r\n\r\n\t// Draw character.\r\n\ts.Clear()\r\n\trunes := []rune(\"先\")\r\n\ts.SetContent(0, 0, runes[0], runes[1:], style)\r\n\ts.Show()\r\n\ttime.Sleep(2 * time.Second)\r\n\r\n\t// The character now disappears on Windows.\r\n\ts.Show()\r\n\r\n\ttime.Sleep(2 * time.Second)\r\n\ts.Fini()\r\n}\r\n```\r\n\r\nOn Windows, when I call `Screen.Show()` a second time, the Chinese character disappears although no changes are made to the screen buffer.\r\n\r\nAny ideas what causes this?"}}
{"actor":{"display_login":"rivo"}}