Re: Last requests before feature freeze
Posted: Mon Jun 22, 2009 9:11 am
This feature is already included. Chose the logical and trigger option and set line delta to 0. The trigger will only match if all conditions on the list are true on the same line.Ryan wrote:An option for multiline/AND triggers to require conditions to match on different lines. For instance, if I have a multi-line trigger with A as pattern 1 and B as pattern 2, the option would make it so the trigger won't fire on a single line that contains both A and B.
This feature is also included. Substring and begin of line substring patterns always pass the pattern itself as matches[1] as there is no way in the pattern syntax to specify capture groups.Ryan wrote:An option to choose which capture groups will be passed to a filter's children would be nice, too, but this one hasn't caused as many problems for me so far.
Color triggers always pass all characters that have the specified trigger color as capture groups.
Consequently, you want to use perl regex patterns. If you use a pattern like this:
(?:cobble) (?:stone) (road) you define 3 capture groups, but the ?: at the beginning of capture group #1 and #2 indicates that these capture groups are not supposed to capture anything. As a result capture group #3 i. e. (road) will be passed as the only capture group to the table matches or pass the filter if you use the trigger as a filter.
This is actually something I'd like to do myself very much, but so far I couldn't find a suitable graphical representation of the problem that would be efficient enough for the user to be useful without being utterly confusing. If you have a good idea of how exactly this should look like, please let me know.Ryan wrote:And a way to combine AND and OR conditions in a single trigger would be well-received (at least by me).
Right now you have to resort to using more complex regex patterns to solve this sort of problem.