Unaligned tab spacing

Everything else that doesn't fall into one of the other PB categories.
Amiga5k
Enthusiast
Enthusiast
Posts: 329
Joined: Fri Apr 25, 2003 8:57 pm

Unaligned tab spacing

Post by Amiga5k »

I know this is nit-picking, but it gets a little annoying after a while:

Ever notice that if you put comments after code on a line (as opposed to putting comments on their own line above or below), they don't line up exactly with each other, even if a FIXED space character set is used?

That is, if you have this:

Code: Select all

If b = a    ; Check 'b'
   c = d    ; Change 'c'
EndIf
The 'Check 'b'' line and the 'Change 'c'' line don't line up because the 'If' keyword gets bolded and therefore makes that line a few pixels longer, causing the tab spacing to misalign. (In the example above, they DO align because the 'If' is not in bold - But trust me, in the PBIDE, they don't align exactly. The longer the bolded keyword, the worse they align...)

Maybe the tab spacing could be based on the width of the bold character, rather than the unbolded one? Nah, that's the klunky solution. Maybe there could be a way to have Syntax Highlighting, but without bolding certain characters?

Unchecking the "Coloring" checkbox in the IDE prefs stopped the bolding problem, but it also turned off the other stuff.

Fred, could you put in a switch to enable\disable bolding?

Thanks!
Russell
*** Diapers and politicians need to be changed...for the same reason! ***
*** Make every vote equal: Abolish the Electoral College ***
*** www.au.org ***
User avatar
blueznl
PureBasic Expert
PureBasic Expert
Posts: 6172
Joined: Sat May 17, 2003 11:31 am
Contact:

Post by blueznl »

using fixedsys as a font, no such problem under japbe
( PB6.00 LTS Win11 x64 Asrock AB350 Pro4 Ryzen 5 3600 32GB GTX1060 6GB - upgrade incoming...)
( The path to enlightenment and the PureBasic Survival Guide right here... )
Amiga5k
Enthusiast
Enthusiast
Posts: 329
Joined: Fri Apr 25, 2003 8:57 pm

Post by Amiga5k »

Don't know what "japbe" is, but in the PB IDE, even using fixedsys, the problem is there because of the bolding of some words. I was just wishing that the bolding feature by itself could be turned off.

Thanks anyways, though!

Russell
*** Diapers and politicians need to be changed...for the same reason! ***
*** Make every vote equal: Abolish the Electoral College ***
*** www.au.org ***
GPI
PureBasic Expert
PureBasic Expert
Posts: 1394
Joined: Fri Apr 25, 2003 6:41 pm

Post by GPI »

Amiga5k wrote:Don't know what "japbe" is, but in the PB IDE
I think, you know it already: The link is in my sig.

GPI
Amiga5k
Enthusiast
Enthusiast
Posts: 329
Joined: Fri Apr 25, 2003 8:57 pm

Post by Amiga5k »

Yep, I d\l'd jaPBe, and it's great! Even with FixedSys used the tabs don't align by default. They do if you deselect bold. Perfect solution.

Thanks!
Russell
*** Diapers and politicians need to be changed...for the same reason! ***
*** Make every vote equal: Abolish the Electoral College ***
*** www.au.org ***
Pupil
Enthusiast
Enthusiast
Posts: 715
Joined: Fri Apr 25, 2003 3:56 pm

Post by Pupil »

Use the font 'Courier New' and everything should be aligned perfectly even when bold is used...
Amiga5k
Enthusiast
Enthusiast
Posts: 329
Joined: Fri Apr 25, 2003 8:57 pm

Post by Amiga5k »

Hmm...Right you are. Strange, because Courier New is not a fixed width font AFAIK. I must have had it on the 'old' Courier before...

Thanks!
Russell
*** Diapers and politicians need to be changed...for the same reason! ***
*** Make every vote equal: Abolish the Electoral College ***
*** www.au.org ***
Post Reply