Open Intervals Represented by Gauges

*To*: mathgroup at smc.vnet.net*Subject*: [mg132655] Open Intervals Represented by Gauges*From*: "djmpark" <djmpark at comcast.net>*Date*: Tue, 29 Apr 2014 01:34:11 -0400 (EDT)*Delivered-to*: l-mathgroup@mail-archive0.wolfram.com*Delivered-to*: l-mathgroup@wolfram.com*Delivered-to*: mathgroup-outx@smc.vnet.net*Delivered-to*: mathgroup-newsendx@smc.vnet.net

I would like to represent an open interval (on the real line) with a Horizontal or VerticalGauge. Let's say (0, 1). I can represent this in calculations by using ConditionalExpression[x, 0 < x < 1] where x might be set by a HorizontalGauge. Then the ConditionalExpression of x becomes Undefined at the endpoints. But I would also like this to be reflected in the appearance of the Gauge. For interior points I would like the Gauge marker to be a blue triangle, and at the endpoints to change to a white triangle with a black outline. The following was my attempt using the GaugeStyle option: DynamicModule[ {x = 0.5}, Row[{ "x:", HorizontalGauge[Dynamic[x], {0, 1}, GaugeStyle -> Dynamic[If[ConditionalExpression[x, 0 < x < 1] === Undefined, Directive[FaceForm[White], EdgeForm[Black]], Blue]] ], Dynamic@ConditionalExpression[x, 0 < x < 1] }] ] It appears that Mathematica rejects the entire GaugeStyle option and uses the Automatic setting. The following works slightly better in that it does pick up the blue color for the normal marker but doesn't change at the endpoints. DynamicModule[ {x = 0.5}, Row[{ "x:", HorizontalGauge[Dynamic[x], {0, 1}, GaugeStyle -> If[Dynamic[ConditionalExpression[x, 0 < x < 1]] === Undefined, Directive[FaceForm[White], EdgeForm[Black]], Blue]], Dynamic@ConditionalExpression[x, 0 < x < 1] }] ] I suppose this may have something to do with GaugeStyle not being something that is rendered in the FrontEnd. I also experimented some with the GaugeMarkers option without success. Both GaugeMarkers and GaugeStyle have a permissible option value of None but I don't understand why that would be useful unless the right hand sides could be Dynamic. I would appreciate any suggestions on producing gauge markers that would change their appearance at the endpoints. David Park djmpark at comcast.net http://home.comcast.net/~djmpark/index.html