Forum Discussion
Font Size Property Unit Issue in Custom Visual
- 8 years ago
Hello saviourofdp
The fontSize is predefined Power BI capabilities name.
You might try to rename the second fontSize property to textSize, titleFontSize, secFontSize, secTitleFontSize.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
Hello saviourofdp
The fontSize is predefined Power BI capabilities name.
You might try to rename the second fontSize property to textSize, titleFontSize, secFontSize, secTitleFontSize.
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
ok, thanks Ignat that works. To conclude, I have to use one of
- fontSize
- textSize
- titleFontSize
- secFontSize
- secTitleFontSize
to get the absolute value slider. Otherwise, I get a percentage slider.
This then begs further questions:
- Are there any other predefined capabilities names? For example there might be one to get at the Font Family enumeration. Documentation for these would be great and very useful.
- Why not have a configuration property that allows us to specify which control to use without relying on undocumented hardcoded names?
- Why does creating a capabilities property without using a name from the aforementioned list create a percentage slider? Of what value is the percentage meant to be?
Thanks for the help
- v-viig8 years agoCommunity Champion
Regarding your questions:
- Power BI API doesn't suppor this. This is in our backlog
- This is related to historical reasons
- Percentage slicer is a fallback for all of slider if the predefined name isn't used
Ignat Vilesov,
Software Engineer
Microsoft Power BI Custom Visuals
- nagendramishr8 years agoNew Member
using secFontSize results in errors:
info JSON change detected. Rebuilding...
error JSON capabilities.json : instance.objects.dataPoint.properties.d1FontSize2.type.formatting additionalProperty "secFontSize" exists in instance when not allowed
error JSON capabilities.json : instance.objects.dataPoint.properties.d1FontSize2.type.formatting is not exactly one from [subschema 0],[subschema 1],[subschema 2]
error JSON capabilities.json : instance.objects.dataPoint.properties.fontSize.type.formatting additionalProperty "textSize" exists in instance when not allowed
error JSON capabilities.json : instance.objects.dataPoint.properties.fontSize.type.formatting is not exactly one from [subschema 0],[subschema 1],[subschema 2]