8000 Missing fonts in wavemon? · Issue #50 · uoaerg/wavemon · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Missing fonts in wavemon? #50

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

Closed
sliddjur opened this issue May 22, 2018 · 10 comments
Closed

Missing fonts in wavemon? #50

sliddjur opened this issue May 22, 2018 · 10 comments

Comments

@sliddjur
Copy link

Hello I am missing some fonts when I start wavemon. I am using fresh install of Ubuntu 18.04 and both gnome terminal and tilix terminal shows the same font error (I suppose).

image

@grrtrr
Copy link
Contributor
grrtrr commented May 22, 2018

Troubleshooting steps:

  • check locale settings: https://help.ubuntu.com/community/Locale
  • ncurses requires ANSI escape sequences, your $TERM should support this (known working examples are xterm and vt100)
  • try running this from xterm, after checking locale.

@grrtrr
Copy link
Contributor
grrtrr commented Jul 2, 2018

@sliddjur - has this been resolved, did you find a fix?

@sliddjur
Copy link
Author
sliddjur commented Aug 14, 2018

@grrtrr I installed xterm from apt. It still looks the same.

olof@olof-ubuntu ~> echo $TERM
xterm-256color

In xterm app, $TERM is xterm.

My locale

olof@olof-ubuntu ~> locale -a
C
C.UTF-8
en_AG
en_AG.utf8
en_AU.utf8
en_BW.utf8
en_CA.utf8
en_DK.utf8
en_GB.utf8
en_HK.utf8
en_IE.utf8
en_IL
en_IL.utf8
en_IN
en_IN.utf8
en_NG
en_NG.utf8
en_NZ.utf8
en_PH.utf8
en_SG.utf8
en_US.utf8
en_ZA.utf8
en_ZM
en_ZM.utf8
en_ZW.utf8
nb_NO.utf8
POSIX
sv_FI.utf8
sv_SE.utf8

@grrtrr
Copy link
Contributor
grrtrr commented Aug 18, 2018

Thanks for getting back. I still think that this related to locale settings, of which there are quite a few.

In the above picture the 'funny' characters appear between

  • thousand separator for RX/TX (220,293 and 226,402 respectively);
  • thousand separator for retries (number seems to be 2,904 but is cut off -- seems a lot).

The numerical setting is set via the LC_LOCALE, which is in turn affected by other settings.

In addition, instead of a dot (".") the dBm setting above uses a comma ("1,26nW"), which is unusual. This too would indicate an unusual locale setting.

Under the hood, this is all done using the setlocale() call.

All of these settings can be bypassed by setting LC_ALL.

Can you please try this: export LC_ALL=C, and then run wavemon?

Likely you will then have no thousand-separator between numbers. If that works I can take it from there, maybe the use of setlocale can be improved.

@sliddjur
Copy link
Author

yes, if I set export LC_ALL=C and run wavemon, it works.

@grrtrr
Copy link
Contributor
grrtrr commented Aug 30, 2018

Thank you. I will work on a fix that does not require setting an environment variable. The downside is that it will use US/GB numeric separator (a . between 1 and fractions of 1, and a , between groups of thousands). This may look strange in other countries, but is still better than the funny fonts - which might have to do with the ncurses library.

grrtrr pushed a commit that referenced this issue Sep 3, 2018
This caused funny fonts to appear in some locales.
Replaced by using a custom function which switches
to pseudo-scientific notation for larger counts.
@grrtrr
Copy link
Contributor
grrtrr commented Sep 3, 2018
8000

As promised - if you are able to compile from master, could you give the above a quick run?

It should resolve the locale-specific issues. It is now locale-independent.

@sliddjur
Copy link
Author
sliddjur commented Sep 4, 2018

image

It looks better now.

olof@olof-ubuntu /opt/wavemon % /usr/local/bin/wavemon -v
wavemon 0.8.2
Distributed under the terms of the GPLv3.

@grrtrr
Copy link
Contributor
grrtrr commented Sep 4, 2018

Thank you, I will integrate this into the next release.

@grrtrr
Copy link
Contributor
grrtrr commented Dec 24, 2018

Resolved in 324b151

@grrtrr grrtrr closed this as completed Dec 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0