PR #1071 again - highlighting critical HP

Update the documentation for
OPTIONS=status_hilite:hitpoints/criticalhp/<color&attributes>
A criticalhp rule now overrides up/down/changed rules as well as
absolute/percentage/always rules.
This commit is contained in:
PatR
2023-08-05 11:05:07 -07:00
parent 70791271dd
commit c7865f7588
2 changed files with 14 additions and 10 deletions
+7 -5
View File
@@ -37,7 +37,7 @@
.ds f0 "\*(vr .ds f0 "\*(vr
.ds f1 .ds f1
.\"DO NOT REMOVE NH_DATESUB .ds f2 "DATE(%B %-d, %Y) .\"DO NOT REMOVE NH_DATESUB .ds f2 "DATE(%B %-d, %Y)
.ds f2 "July 31, 2023 .ds f2 "August 5, 2023
. .
.\" A note on some special characters: .\" A note on some special characters:
.\" \(lq = left double quote .\" \(lq = left double quote
@@ -5432,7 +5432,7 @@ Allowed behaviors are \(lqalways\(rq, \(lqup\(rq, \(lqdown\(rq,
text to match against. text to match against.
For the \fIhitpoints\fP field, the additional behavior \(lqcriticalhp\(rq For the \fIhitpoints\fP field, the additional behavior \(lqcriticalhp\(rq
is available. is available.
It overrides always, percentage threshold, and absolute threshold if It overrides other behavior rules if
hit points are at or below the \fImajor problem\fP threshold hit points are at or below the \fImajor problem\fP threshold
(which varies depending upon maximum hit points and experience level). (which varies depending upon maximum hit points and experience level).
.si .si
@@ -5490,9 +5490,11 @@ it also matches when value is below or above.
If the prefix is \(oq<\(cq or \(oq>\(cq, only match when strictly If the prefix is \(oq<\(cq or \(oq>\(cq, only match when strictly
above or below. above or below.
.lp "*" .lp "*"
criticalhp only applies to the hitpoints field and when defined criticalhp only applies to the hitpoints field and only
it takes precedence over other hitpints rules except \fIchanged\fP, when current hit points are below a threshold (which varies by maximum
\fIup\fP, or \fIdown\fP. hit points and experience level).
When the threshold is met, a criticalhp rule takes precedence over all
other hitpoints rules.
.lp "*" .lp "*"
text match sets the attribute when the field value text match sets the attribute when the field value
matches the text. matches the text.
+7 -5
View File
@@ -46,7 +46,7 @@
\author{Original version - Eric S. Raymond\\ \author{Original version - Eric S. Raymond\\
(Edited and expanded for 3.7.0 by Mike Stephenson and others)} (Edited and expanded for 3.7.0 by Mike Stephenson and others)}
%DO NOT REMOVE NH_DATESUB \date{DATE(%B %-d, %Y)} %DO NOT REMOVE NH_DATESUB \date{DATE(%B %-d, %Y)}
\date{July 31, 2023} \date{August 5, 2023}
\maketitle \maketitle
@@ -6018,7 +6018,7 @@ Allowed behaviors are ``always'', ``up'', ``down'', ``changed'', a
percentage or absolute number threshold, or text to match against. percentage or absolute number threshold, or text to match against.
For the {\it hitpoints\/} field, the additional behavior ``criticalhp'' For the {\it hitpoints\/} field, the additional behavior ``criticalhp''
is available. is available.
It overrides always, percentage threshold, and absolute threshold if It overrides other behavior rules if
hit points are at or below the {\it major problem\/} threshold hit points are at or below the {\it major problem\/} threshold
(which varies depending upon maximum hit points and experience level). (which varies depending upon maximum hit points and experience level).
@@ -6073,9 +6073,11 @@ it also matches when value is below or above.
If the prefix is `{\tt <}' or `{\tt >}', only match when strictly If the prefix is `{\tt <}' or `{\tt >}', only match when strictly
above or below. above or below.
%.lp "*" %.lp "*"
\item[{\tt criticalhp}] only applies to the hitpoints field and when defined \item[{\tt criticalhp}] only applies to the hitpoints field and only
it takes precedence over other hitpints rules except {\it changed\/}, when current hit points are below a threshold (which varies by maximum
{\it up\/}, or {\it down\/}. hit points and experience level).
When the threshold is met, a criticalhp rule takes precedence over all
other hitpoints rules.
%.lp "*" %.lp "*"
\item[{\tt text}] match sets the attribute when the field value \item[{\tt text}] match sets the attribute when the field value
matches the text. matches the text.