Skip to content

Question: distance units customization #7782

Answered by hl662
JoanaSmit asked this question in Q&A
Discussion options

You must be logged in to vote

I see that the formatSpecs from MeasurementSelectionSet.global.measurements come from IModelApp.quantityFormatter.getFormatterSpecByQuantityType. If that's the case, you could customize within your app to utilize setOverrideFormat. This code example at the bottom of the page is one example - A user retrieves the formatProps for a QuantityType, adds a property to the props, and overrides the format inside of iModelApp's quantityFormatter. The formatter will emit a onChange event, which should tell MeasurementSelectionSet to also update things.

Problem with the above is you would need to know the QuantityType to override, which I don't think MeasurementSelectionSet.global.measurements provi…

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

JoanaSmit
Mar 3, 2025
Collaborator Author

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by JoanaSmit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants