Skip to content

Commit

Permalink
instrument NumberDisplay in PHMeterNode, #96
Browse files Browse the repository at this point in the history
  • Loading branch information
pixelzoom committed Feb 6, 2020
1 parent 8083ef4 commit 3e4a998
Show file tree
Hide file tree
Showing 3 changed files with 127 additions and 1 deletion.
3 changes: 2 additions & 1 deletion js/common/view/PHMeterNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,8 @@ define( require => {
backgroundFill: 'white',
backgroundStroke: 'darkGray',
xMargin: 8,
yMargin: 5
yMargin: 5,
tandem: options.tandem.createTandem( 'numberDisplay' )
} );
}

Expand Down
117 changes: 117 additions & 0 deletions js/phet-io/ph-scale-phet-io-elements-baseline.js
Original file line number Diff line number Diff line change
Expand Up @@ -8529,6 +8529,123 @@ window.phet.phetio.phetioElementsBaseline = assert &&
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<BooleanIO>"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay": {
"phetioDocumentation": "",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": false,
"phetioState": false,
"phetioStudioControl": true,
"phetioTypeName": "NumberDisplayIO"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.opacityProperty": {
"phetioDocumentation": "Opacity of the parent NodeIO, between 0 (invisible) and 1 (fully visible)",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": false,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "NumberPropertyIO"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.pickableProperty": {
"phetioDocumentation": "Sets whether the node will be pickable (and hence interactive), see the NodeIO documentation for more details",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": false,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<NullableIO<BooleanIO>>"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.valueText": {
"phetioDocumentation": "",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": true,
"phetioState": false,
"phetioStudioControl": true,
"phetioTypeName": "TextIO"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.valueText.opacityProperty": {
"phetioDocumentation": "Opacity of the parent NodeIO, between 0 (invisible) and 1 (fully visible)",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": true,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "NumberPropertyIO"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.valueText.pickableProperty": {
"phetioDocumentation": "Sets whether the node will be pickable (and hence interactive), see the NodeIO documentation for more details",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": true,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<NullableIO<BooleanIO>>"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.valueText.textProperty": {
"phetioDocumentation": "Property for the displayed text",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": true,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<StringIO>"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.valueText.visibleProperty": {
"phetioDocumentation": "Controls whether the Node will be visible (and interactive), see the NodeIO documentation for more details.",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": true,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<BooleanIO>"
},
"phScale.microScreen.view.pHMeterNode.numberDisplay.visibleProperty": {
"phetioDocumentation": "Controls whether the Node will be visible (and interactive), see the NodeIO documentation for more details.",
"phetioDynamicElement": false,
"phetioEventType": "MODEL",
"phetioFeatured": false,
"phetioHighFrequency": false,
"phetioIsArchetype": false,
"phetioPlayback": false,
"phetioReadOnly": false,
"phetioState": true,
"phetioStudioControl": true,
"phetioTypeName": "PropertyIO<BooleanIO>"
},
"phScale.microScreen.view.pHMeterNode.opacityProperty": {
"phetioDocumentation": "Opacity of the parent NodeIO, between 0 (invisible) and 1 (fully visible)",
"phetioDynamicElement": false,
Expand Down
8 changes: 8 additions & 0 deletions js/phet-io/ph-scale-phet-io-types.js
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,14 @@ window.phet.phetio.phetioTypes = assert &&
"supertype": "ObjectIO",
"typeName": "NullableIO<Vector2IO>"
},
"NumberDisplayIO": {
"documentation": "A numeric readout with a background",
"events": [],
"methodOrder": [],
"methods": {},
"supertype": "NodeIO",
"typeName": "NumberDisplayIO"
},
"NumberIO": {
"documentation": "Wrapper for the built-in JS number type (floating point, but also represents integers)",
"events": [],
Expand Down

0 comments on commit 3e4a998

Please sign in to comment.