Using Geany on Ubuntu Budgie 20.04 testing system. The underscore character does not show up. Work fine in gedit, etc.
Closed #2466.
Duplicate of #2386, #2353, #2287, and #1387 at least. All found within the top matches when searching issues, and also identified by the duplicate detector when submitting a new issue.
@codebrainz all of these issues are closed. The bug still occurs. The documented workaround (line_height in filetypes.common) does not work.
Confirmed on debian/sid amd64 with DejaVu Sans Mono Book size 12 from fonts-dejavu-core 2.37-1, antialiasing with full hinting and no subpixels, 96 dpi, and `FREETYPE_PROPERTIES=truetype:interpreter-version=35` under Xfce4.
This font works fine in xfce4-terminal, firefox, thunderbird, and every other editor I have tried, including intellij and godot. Only geany seems affected. This bug makes geany unusable for code and configuration files.
@bencaradocdavies you provide lots of information about your font setup, but nothing about your Geany version, GTK version etc so can't help you.
Also what did you set line_height to, my crystal ball has gone hazy, it must have COVIDS?
And just for the record with the default setup DejaVu Sans Mono Book 12 works just fine on my Linux Mint with line_height `0;0;` (ie default) on Geany 1.37 (git >= 82590af4), en_AU.UTF-8 GTK 3.22.30, GLib 2.56.4.
@bencaradocdavies they're closed because the bug is not a Geany bug, which this issue tracker is for. If you look at the [google search](https://www.google.com/search?q=dejavu%20font%20underscore) I mentioned in [a comment](https://github.com/geany/geany/issues/2287#issuecomment-529129845), you'll see lots of bugs on various projects related to this font. If you have a reason to believe this is in fact a bug specific to Geany (ie. not the font itself or something in the text rendering stack; Freetype2, Pango, Gtk, Scintilla), we can re-open the original bug.
Thanks @codebrainz, I have updated my comment above with my geany, gtk, and glib details for the record, but I just got the `line_height` workaround to work with excellent results.
For the benefit of other users, the `line_height` setting can be found in "Tools" > "Configuration Files" > "filetypes.common". To change this setting from its default `line_height=0;0;` there are two things to note:
* "#~" lines are commented and have no effect. * The file format is an [INI file](https://en.wikipedia.org/wiki/INI_file) so uncommenting the `line_height` line is insufficient because the `[styling]` section is also required; either uncomment this line or add a new `[styling]` section at the end.
The only uncommented lines in my `filetypes.common` are now:
``` [styling] line_height=0;2; ```
With this setting and DejaVu Sans Mono Book size 12, underscores are visible. Using "line_height=0;1;" also works, but "line_height=0;2;" gives me, for the first time ever, exact agreement (as far as I can tell) with the line height in xfce4-terminal.
I am going to to paste my solution into the other bugs for make benefit glorious nation of geany.
Sigh. Apologies for the spam, but, given the number of users, myself included, unable to implement the documented fix, I thought circulating this recipe might do more good than harm. Thanks for your patience! And for geany, of course. :-)
Well, ```ctrl +``` (font size change) is the way I do it till those appear
Who knew i would comment on Crotter inc. property in this lifetim
Well, `ctrl +` (font size change) is the way I do it till those appear
i was trying all kinds of colorschemes and the underscores seem to appear in encapsed strings and remarks in geany (for what i use it on linux mint 20 ) so i tried your suggestion here and it seems from zoom-zero the underscore appears after clickinc ctrl-+ respectively , 3, 6 , 10 , 13 and up times in intervals, the zoomlevels in between dont display it . I know these sites tend to have endless discussions on how to phrase questions and what not instead of providing solutions but if the issue is not geany but appears in geany and so far (as far as i can see) nowere else in whatever i use in linux mint i would dare be so bold and preposterous as to say maybe team geany could work around this instead of shoving the blame like good politicians would (i assume this answer will be flagged and censored for 'irrelevant' and what not as if this were stackoverlords) ... but putting the font in elefants sizes does work ... at certain intervals , fyi
Is this fixed yet?
No it's not fixed.
my previous comment turned out to be disruptive content including a solution but nevermind, i should know better than to speak in tbhe middle of professionals on a shite owned by Crotter inc.
Any update on this issue?
Increasing the default font size to 16 **and** changing `#~ line_height=0;2;` in Tools > Configuration Files > filetypes.common works
Works by increasing the default font size to 16 **and** making `#~ line_height=0;2;` in Tools > Configuration Files > filetypes.common
can confirm this works. It would still show underscore up to size 12, anything less than that the underscore would be invisible.
I would make line_height=0;2; the default
There has been a change to upstream Scintilla which should improve this, should be in next release.
Awesome, thank you!
Thanks @elextr and @codebrainz, I have updated my comment above with my geany, gtk, and glib details for the record, but I just got the `line_height` workaround to work with excellent results.
For the benefit of other users, the `line_height` setting can be found in "Tools" > "Configuration Files" > "filetypes.common". To change this setting from its default `line_height=0;0;` there are two things to note:
- `#~` lines are commented and have no effect.
- The file format is an [INI file](https://en.wikipedia.org/wiki/INI_file) so uncommenting the `line_height` line is insufficient because the `[styling]` section is also required; either uncomment this line or add a new `[styling]` section at the end.
The only uncommented lines in my filetypes.common are now:
[styling] line_height=0;2;
With this setting and DejaVu Sans Mono Book size 12, underscores are visible. Using `line_height=0;1;` also works, but `line_height=0;2;` gives me, for the first time ever, exact agreement (as far as I can tell) with the line height in xfce4-terminal.
Thanks for the workaround. I can confirm it works. This is December, 2021, just installed Debian 11 which ships with Geany 1.37.1 which has the "bug". Using `line_height=0;1;` + uncommenting [styling], works fine for me. Display was quite troublesome without being able to see underscores. Thanks again.
I can confirm @bencaradocdavies workaround works. This is December, 2021, just installed Debian 11 which ships with Geany 1.37.1 which has the "bug". Using line_height=0;1; + uncommenting [styling] as per workaround, above and works fine for me. Display was quite troublesome without being able to see underscores. Thanks very much for providing it.
Note there is a fix which should improve the situation which will be available in whichever the version after 1.38 is (1.39/2.0).
if you decide to stay at an older ver.of geany, one option is to install another code font like courier prime code
Another excellent code font is [Hack](https://sourcefoundry.org/hack/) (GitHub: [source-foundry/Hack](https://github.com/source-foundry/Hack)), which has its roots in DejaVu Sans Mono / Bitstream Vera Sans Mono.
Hack has a higher underscore position and so may not be affected by this geany bug.
I have released [HackSlash](https://github.com/ashjoubert/HackSlash), a variant of the Hack typeface with forward slashed zero alternate glyphs from the [alt-hack](https://github.com/source-foundry/alt-hack) library of alternative glyphs for Hack.
After using courier for a while, i found it a bit distracting. Hack looks definitely better. Great to know!
[Hack](https://sourcefoundry.org/hack/) has a higher underscore position and so may not be affected by this geany bug.
Thanks @ashjoubert that did the trick.
Here's a quick easy guide:
`sudo apt install fonts-hack-ttf` Open Geany. ``` Edit > Preferences > Interface Fonts, Editor, "Hack Regular" Apply, OK. ```
if you decide to stay at an older ver.of geany
@xzhh it's not "if you" it's what the distribution ships as stable from there repos. For things like this it highlights that model is flawed but unfortunately that's how it is (if you stick with stock standard stuff for security support).
"Hack Regular" is good trick. Issue can be closed.
github-comments@lists.geany.org