[PB5.30] IDE : Comments start by - and Issues

Just starting out? Need help? Post your questions and find answers here.
User avatar
Le Soldat Inconnu
Enthusiast
Enthusiast
Posts: 306
Joined: Wed Jul 09, 2003 11:33 am
Location: France

[PB5.30] IDE : Comments start by - and Issues

Post by Le Soldat Inconnu »

Edit : Look Post 4, thanks

Hi

When a comment start by a "-", comment is consider as a "title" in procedure list

But in this code, comment is not a title

Code: Select all

;{- Title
If Truc = Bidule
  Truc + 1
EndIf
;}
Another point, i want use note to set backgroud color on comment Title.
So i set this regular expression "^{?-.*"
here, i get color on first line

Code: Select all

;{- Title
If Truc = Bidule
  Truc + 1
EndIf
;}
But here no

Code: Select all

;- Title
If Truc = Bidule
  Truc + 1
EndIf
;
Last edited by Le Soldat Inconnu on Tue Aug 12, 2014 10:23 am, edited 4 times in total.
LSI
User avatar
Demivec
Addict
Addict
Posts: 4260
Joined: Mon Jul 25, 2005 3:51 pm
Location: Utah, USA

Re: [PB5.30] IDE : Comments start by -

Post by Demivec »

Sounds similar to this.
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: [PB5.30] IDE : Comments start by -

Post by PB »

> When a comment start by a "-", comment is consider as a "title" in procedure list

Correct. Been that way forever.

> But in this code, comment is not a title
> ;{- Title

Are you serious? The comment doesn't start with "-" but with "{", as you just noted.
So how can this be considered a bug? You know the rules but call it a bug anyway? :shock:
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
User avatar
Danilo
Addict
Addict
Posts: 3036
Joined: Sat Apr 26, 2003 8:26 am
Location: Planet Earth

Re: [PB5.30] IDE : Comments start by -

Post by Danilo »

It does not work!

Code: Select all

;__-=[ Comment ]=-__
:wink: :D
User avatar
Le Soldat Inconnu
Enthusiast
Enthusiast
Posts: 306
Joined: Wed Jul 09, 2003 11:33 am
Location: France

Re: [PB5.30] IDE : Comments start by -

Post by Le Soldat Inconnu »

PB wrote:> When a comment start by a "-", comment is consider as a "title" in procedure list

Correct. Been that way forever.

> But in this code, comment is not a title
> ;{- Title

Are you serious? The comment doesn't start with "-" but with "{", as you just noted.
So how can this be considered a bug? You know the rules but call it a bug anyway? :shock:
";{" and ";}" are in Folding Keyword. May be i add it, i don't reminds if it's a default folding option. I come from jaPBe and it's done like this on jaPBe ...

So i try something else. I set ";{", ";-{" and ";}" in Folding Keyword.

Code: Select all

;-{ Title
If Truc = Bidule
  Truc + 1
EndIf
;}
So now, i get Title. OK, it' a way.

But i get problem with issues list

Code: Select all

;-> Création des pages
;> toto
Second line get color with regular expression "^{?>.*" but first not. My comment start by ">" or "->"

Code: Select all

; Toto
;- Toto
The same, with regular expression "Toto", second line don't take background color
LSI
Post Reply