Author Topic: Why Code::Blocks does not support font anti aliasing?  (Read 6121 times)

Offline Alex Mercer

  • Single posting newcomer
  • *
  • Posts: 4
Why Code::Blocks does not support font anti aliasing?
« on: March 31, 2019, 05:50:20 pm »
In many sites the best font for IDEs is Inconsolata, and when it comes to Code::Blocks it does not support anti-aliasing for these type of fonts. It is the 17th version but it still doesn't support anti-aliasing. Why don't the developers of this IDE provide this facility?

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #1 on: March 31, 2019, 07:13:25 pm »
What do you mean? Which OS? How many dpis have you monitor? Screenshot comparing it to another editor where AA works?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Alex Mercer

  • Single posting newcomer
  • *
  • Posts: 4
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #2 on: April 20, 2019, 06:04:14 pm »
I am using windows. The first picture is from sublime and the other one is from the codeblocks. Both are set to Inconsolata font.
I have attached it for you.
« Last Edit: April 20, 2019, 06:07:21 pm by Alex Mercer »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #3 on: April 20, 2019, 06:06:01 pm »
The images aren't visible.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline Alex Mercer

  • Single posting newcomer
  • *
  • Posts: 4
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #4 on: April 20, 2019, 06:26:36 pm »
I couldn't put an image using the image tag, so i attached it. I need a little help with these image tags syntax. The images are in my desktop.
« Last Edit: April 20, 2019, 06:31:59 pm by Alex Mercer »

Offline stahta01

  • Lives here!
  • ****
  • Posts: 7582
    • My Best Post
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #5 on: April 20, 2019, 08:54:54 pm »
I would suggest using a larger font size in Code::Blocks and see if that improves the font appearance.

Tim S.
 
C Programmer working to learn more about C++ and Git.
On Windows 7 64 bit and Windows 10 64 bit.
--
When in doubt, read the CB WiKi FAQ. http://wiki.codeblocks.org

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #6 on: April 20, 2019, 09:03:43 pm »
Does this problem happen with all fonts? Does this font work in notepad++? CodeLite?
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Online eranif

  • Regular
  • ***
  • Posts: 256
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #7 on: April 21, 2019, 01:05:27 am »
Attached are two screenshots taken from latest CodeLite. The first uses the Inconsolata  As you can see, its smooth. The second shows the support for ligatures in wxSTC.

I am not sure if you guys are doing this for CodeBlocks, but to get the smooth look + support ligature (for Windows), you will need to change wx/setup.h a little bit:

Enable wxGCDC:

Code
#define wxUSE_GRAPHICS_CONTEXT 1

and also this is enabled:

Code
#define wxUSE_GRAPHICS_DIRECT2D 1

Now, in all wxSTC subclasses, I have this call enabled for Windows:
Code
wxStyledTextCtrl::SetTechnology(wxSTC_TECHNOLOGY_DIRECTWRITE);

Inconsolata smooth:



Fira Code (font with ligatures, IMO, the best coding font) :



HTH,
Eran

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Why Code::Blocks does not support font anti aliasing?
« Reply #8 on: April 21, 2019, 01:42:55 am »
We're not doing this yet. But I wanted to know if it is related or not.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]