Issues redundancy

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Issues redundancy

Post by PB »

Seems strange to have "FixMe" and "ToDo" twice in the browser?
See in this screenshot, I think it's better if the red boxed text
should NOT appear, because it already appears in column one.

Since the browser looks for the "FixMe" and "ToDo" keywords,
I suggest those keywords get stripped out before putting the
text in column two.

Image
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
User avatar
STARGÅTE
Addict
Addict
Posts: 2227
Joined: Thu Jan 10, 2008 1:30 pm
Location: Germany, Glienicke
Contact:

Re: Issues redundancy

Post by STARGÅTE »

You can define an other regex, to hidden TODO, but highlight.

Code: Select all

\bTODO\b(?<display>.*)
PB 6.01 ― Win 10, 21H2 ― Ryzen 9 3900X, 32 GB ― NVIDIA GeForce RTX 3080 ― Vivaldi 6.0 ― www.unionbytes.de
Lizard - Script language for symbolic calculations and moreTypeface - Sprite-based font include/module
c4s
Addict
Addict
Posts: 1981
Joined: Thu Nov 01, 2007 5:37 pm
Location: Germany

Re: Issues redundancy

Post by c4s »

I already requested it here: PB 5.30b1 - Issue Browser Coloring and Redundant Text (at first posted as a bug report)

In that thread Demivec apparently also posted a workaround, but currently I'm not able to make it work. Though if I recall correctly it worked fine back then when he first posted it?! There is also a link to another thread which might contain some useful tips regarding this request.

In any way I would also suggest that by default the preinstalled "regular exression" (typo in the preference ;)) are constructed in a way so that the issue text doesn't contain the keyword.


Edit: STARGÅTE posted a solution which seems to work.
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Issues redundancy

Post by PB »

Thanks c4s, I didn't see the other threads.
But still, it should be officially fixed anyway.
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
User avatar
Demivec
Addict
Addict
Posts: 4260
Joined: Mon Jul 25, 2005 3:51 pm
Location: Utah, USA

Re: Issues redundancy

Post by Demivec »

PB wrote:Thanks c4s, I didn't see the other threads.
But still, it should be officially fixed anyway.
Here's another thread you didn't see.

Freak describes his additions to address whether or not you want something to show in the description and whether or not it is marked in the source code.

I think that qualifies as having officially fixed it (though it still has at least one bug in its implementation).
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Issues redundancy

Post by PB »

> I think that qualifies as having officially fixed it

I mean fixed as in a native setting that we don't have to
go and manually change after a fresh PureBasic install.

Anyway, this removes the text but still leaves the colon in
the text description in the browser... any way to remove
the colon too?

Code: Select all

\bTODO\b(?<display>.*)
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
c4s
Addict
Addict
Posts: 1981
Joined: Thu Nov 01, 2007 5:37 pm
Location: Germany

Re: Issues redundancy

Post by c4s »

If you always want to type and then remove the colon you can use this:

Code: Select all

 \bTODO:(?<display>.*) 
If any of you native English speakers have any suggestions for the above text, please let me know (via PM). Thanks!
User avatar
Demivec
Addict
Addict
Posts: 4260
Joined: Mon Jul 25, 2005 3:51 pm
Location: Utah, USA

Re: Issues redundancy

Post by Demivec »

Demivec wrote:Anyway, this removes the text but still leaves the colon in
the text description in the browser... any way to remove
the colon too?
This matches TODO followed by either a space or a colon.

Code: Select all

\bTODO(?>:|\b)(?<display>.*)
PB
PureBasic Expert
PureBasic Expert
Posts: 7581
Joined: Fri Apr 25, 2003 5:24 pm

Re: Issues redundancy

Post by PB »

Thanks c4s and Demivec! :)

Now this just has to be official so we don't need to
specify it with every fresh install of PureBasic. ;)
I compile using 5.31 (x86) on Win 7 Ultimate (64-bit).
"PureBasic won't be object oriented, period" - Fred.
Post Reply