Code Monkey home page Code Monkey logo

Comments (28)

itchyny avatar itchyny commented on April 28, 2024 2

See jroimartin/gocui#74.

from lazygit.

ponsfrilus avatar ponsfrilus commented on April 28, 2024 1

screenshot from 2018-08-08 12-00-59

Can't reproduce it in Ubuntu, maybe this is Windows-1252 related ?

from lazygit.

TGhoul avatar TGhoul commented on April 28, 2024 1

@ponsfrilus @jesseduffield This issue may be related to gocui, I tested it in macOS.

image

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024 1

If I change the code page to chcp 936, which is simplified Chinese, then the character width issue look OK, but there are other layout issues, see the screen shot below:

Chinese_font_error3

from lazygit.

TGhoul avatar TGhoul commented on April 28, 2024

Chinese character have some problems.

1533697357 1

from lazygit.

spin6lock avatar spin6lock commented on April 28, 2024

It seems that the display is wrong... Some chinese character shows up and eat up following ascii character. Maybe I should raise an issue on gocui ?

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

@TGhoul do those same characters have a fixed-width in regular use? It may be that your font isn't monospaced. I tried testing how the app behaved with some mandarin characters but they didn't even render:
image

I'm thinking it may be configurable via cmd, but I'm not well versed in windows

from lazygit.

TGhoul avatar TGhoul commented on April 28, 2024

@jesseduffield I think those characters is fixed-width, my problems appear in the "Commits" window,
can you do something commit and write comment with Chinese simplified characters?

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

This should (or could) be fixed by #231
Looks like there are some little glitches that still occur but this is a good step in the right direction. Please let me know how the rendering works for you all :)

@OdaDaisuke @TGhoul

from lazygit.

TGhoul avatar TGhoul commented on April 28, 2024

@jesseduffield Thank you for all your effort with i18n.

from lazygit.

OdaDaisuke avatar OdaDaisuke commented on April 28, 2024

@jesseduffield Thank youuuu!

from lazygit.

glvr182 avatar glvr182 commented on April 28, 2024

@jesseduffield @OdaDaisuke is this issue fixed?

from lazygit.

hello-liu avatar hello-liu commented on April 28, 2024

windos 有问题,ubuntu没得问题,头大

from lazygit.

hello-liu avatar hello-liu commented on April 28, 2024

This should (or could) be fixed by #231
Looks like there are some little glitches that still occur but this is a good step in the right direction. Please let me know how the rendering works for you all :)

@OdaDaisuke @TGhoul

Chinese character have some problems.

hi,解决了么?,好像在ubuntu下没问题

from lazygit.

faimin avatar faimin commented on April 28, 2024

@hello-liu It's OK on Mac OS.

from lazygit.

hello-liu avatar hello-liu commented on April 28, 2024

change cmd GBK to UTF-8,it work

from lazygit.

hello-liu avatar hello-liu commented on April 28, 2024

@hello-liu It's OK on Mac OS.

can you input chinese in the view ,half char no see

from lazygit.

bushnerd avatar bushnerd commented on April 28, 2024

image

The filename is chinese, but it's crashed. But the content in chinese is OK.

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

@scutxd could you provide some steps to reproduce that issue? I'm not able to reproduce locally on the latest lazygit master branch

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024

@scutxd could you provide some steps to reproduce that issue? I'm not able to reproduce locally on the latest lazygit master branch

I have the same issue here, if you add a file which has a Chinese name, than it will shown some \xxx like text in the commit message, let me give your a screen shot.

Chinese_font_error

There are two issues here:
1, see the arrow pointed as "1", the Chinese text is too width, I mean normally, one Chinese character's width equals two English character's width, but from the screen shot, it looks like it has 3 times of the English character's width.

2, the second issue the the same as the scutxd mentioned one.

Update
It looks like the Chinese character's width = 3 * English character's width.
Is it because that I set the font page as: chcp 65001, which means it is UTF8 format, and a Chinese character normally need 3 bytes.

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024

Bad view title drawing with unicode characters. · Issue #157 · jroimartin/gocui
Maybe, this is some related.

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

@asmwarrior I'm still struggling to replicate. Is there a public repo you could point me to which I could pull down to verify the issue?

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024

@asmwarrior I'm still struggling to replicate. Is there a public repo you could point me to which I could pull down to verify the issue?

I create a sample git repo for you to test the Chinese font issue, see here: https://github.com/asmwarrior/lazygit_issue24

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

Thanks for making the sample repo :)

I'm not able to replicate on lazygit's latest master branch, on the iterm2 terminal in OSX:
image

This may be a windows specific issue. With that said it's possible that the fault lies with termbox, one of our dependencies. There's a branch I'm working on called tcell-again which switches to tcell which is better for various reasons. Are you able to see if you still get the same issue if you're using lazygit from the tcell-again branch? You'll need to clone the lazygit repo and do a go install from within the repo's root directory but otherwise it should run the same as normal lazygit

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024

This may be a windows specific issue. With that said it's possible that the fault lies with termbox, one of our dependencies. There's a branch I'm working on called tcell-again which switches to tcell which is better for various reasons. Are you able to see if you still get the same issue if you're using lazygit from the tcell-again branch? You'll need to clone the lazygit repo and do a go install from within the repo's root directory but otherwise it should run the same as normal lazygit.

I have no experience of programming in go language. I mainly use C/C++. So for me, it may be hard to build the lazygit from the source under Windows.
If you can create a simple executable file from this new branch, I can happily test it.

from lazygit.

jesseduffield avatar jesseduffield commented on April 28, 2024

@asmwarrior I've just compiled this from my windows PC. Does it work for you?
lazygit.zip

from lazygit.

asmwarrior avatar asmwarrior commented on April 28, 2024

@asmwarrior I've just compiled this from my windows PC. Does it work for you?
lazygit.zip

I tested this new binary under ComEmu, and here is the result.

With chcp 65001 setting, which means the UTF8 code page, I see still some errors, see the two images below:

chcp65001-error1

and

chcp65001-error2

Sometimes, the unwanted characters are shown.

With chcp 936, which is Chinese GB2312 code page, I see the frame border is not continued, but I don't see unwanted characters, see image below.

chcp936-good

In both of the code page settings, the Chinese character width issue is fixed! This is good!

But there are still same issues that the file path is still shown as a raw hex string, as the arrow 2 pointed in comment: the #24 (comment)

from lazygit.

diartyz avatar diartyz commented on April 28, 2024

Git will quote "unusual" characters in the pathname.
Try git config --global core.quotepath false

from lazygit.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.