> Is there much of a difference to a user of a UI between those three states?
Good question. In CS-Studio, the display builder uses a very similar variant of purple for both the invalid and undefined severity, and also a very similar dash-dotted vs. dotted border style. So even color-vision-impaired users can tell a difference if they
want to, but it's a small difference because either case basically means: Ignore what you see, it's not valid data. If it's clearly disconnected, text-type widgets show "<PV Name>" instead of the last value, to make it more obvious that we can't connect to
the PV and at the same time indicate what PV that is.
But that still leaves the question of when you'd get invalid vs. undefined. Not sure if that's fully defined and consistently implemented in all the PVA servers (QSRV, custom C++/python server, ...). CS-Studio for example does this:
If there is no 'alarm' found in the PVA data, assume that it was simply not provided (custom server...) and the alarm severity is OK.
If there is an 'alarm' structure, but it fails to contain a 'severity', assume undefinedAlarm, else use the severity as received.