Project

General

Profile

Actions

Bug #1782

closed

Highlights regex doesn't work

Added by Per Amundsen over 9 years ago. Updated about 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Interface
Target version:
Start date:
12/14/2014
Due date:
% Done:

0%

Estimated time:
Operative System:
All
Regression:
No

Description

Highlights regex doesn't work

Actions #1

Updated by Per Amundsen over 9 years ago

  • Status changed from Resolved to Closed
Actions #2

Updated by Andreas vb about 9 years ago

Would it be possible to test the highlight?
I can't seem to get it to work except $me

Actions #3

Updated by Per Amundsen about 9 years ago

It's the same regular expressions as $regex/$regsub/$regsubex, you can use these to test.

//if ($regex(text, pattern)) { /echo -ag match was found }

Actions #4

Updated by Andreas vb about 9 years ago

Seems the match are working but not the actual Highlightning.
It seems to be case sensitive, even though the option isn't checked.

I have match on Message and the Highlight on a partial nickname and Regex is on.
What I want is:

Highlight: andreas
If someone types Andreasvb anywhere in a text, it should Highlight with a green color and show a notification.

Now it only seem to work if someone write andreas / andreasvb, without capital.
Do I need to use: andreas/gi or something as Highlight?
Does the order matter?

//$regex(Andreasvb:,/andreas/gi)
> 1
//$regex(Andreasvb:,/andreas)
> 0


I have a $me with purple color, which it triggered instead, I removed it after 08:30 on the screenshot.
First I had andreas/gi but changed it to only andreas after 08:32, that's when it started to trigger.
(I also tried move it to bottom of the list, same issue).

Actions #5

Updated by Per Amundsen about 9 years ago

Oh I see.

/ /i should not be necessary in the highlight regex, I have fixed this for next beta, thanks.

Actions #6

Updated by Per Amundsen about 9 years ago

Also order matter, the first match in the highlight order will be used.

Actions

Also available in: Atom PDF