Forum Discussion
Different Font Sizes to Customised Theme
Hi all,
I’ve customized a theme in Power BI using the interface to match our brand guidelines, and one of the requirements is to use size 12 Arial font consistently throughout the report. I set this up in the custom theme, but I’ve noticed that:
- The chart titles default to size 14.
- The data labels sometimes default to 10.8.
I’ve attached my theme’s JSON file for reference. Since I don’t have much experience coding in JSON, I created the custom theme using Power BI’s interface.
My question is:
- Do I need to modify the JSON directly to ensure that all fonts, including titles and labels, default to size 12 Arial?
- Is there a way to resolve this within Power BI without advanced coding?
Any guidance would be appreciated!
- Anonymous1 year ago
Hi, Anonymous
I am glad to help you.
It is indeed possible to set the font and size of chart titles and data labels in Power BI.
Unless the visuals are the same type of visual, in which case you can use Ctrl+A to select all the visuals and then set the font to Arial and the size to 12 for both the chart titles and the data labels:
However, in an entire report, there will generally be multiple different types of visuals, so you can use any text editor (such as Notepad or Visual Studio Code) to create or edit the JSON file:{ "name": "Custom Theme", "visualStyles": { "*": { "*": { "title": [{ "fontSize": 12, "fontFamily": "Arial" }], "labels": [{ "fontSize": 12, "fontFamily": "Arial" }] } } } }
After saving the JSON file, in Power BI click View, then click Browse for themes, select the JSON file you just saved and apply it, you will find that all the fonts and sizes of the different types of visuals have been changed to the results you need:I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Fen Ling,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
3 Replies
- amitchandakSuper User
Anonymous , Check out theme generators can help
https://community.fabric.microsoft.com/t5/Community-Blog/Power-BI-Theme-Generators/ba-p/2265899
- AnonymousNot applicable
Hi, Anonymous
I am glad to help you.
It is indeed possible to set the font and size of chart titles and data labels in Power BI.
Unless the visuals are the same type of visual, in which case you can use Ctrl+A to select all the visuals and then set the font to Arial and the size to 12 for both the chart titles and the data labels:
However, in an entire report, there will generally be multiple different types of visuals, so you can use any text editor (such as Notepad or Visual Studio Code) to create or edit the JSON file:{ "name": "Custom Theme", "visualStyles": { "*": { "*": { "title": [{ "fontSize": 12, "fontFamily": "Arial" }], "labels": [{ "fontSize": 12, "fontFamily": "Arial" }] } } } }
After saving the JSON file, in Power BI click View, then click Browse for themes, select the JSON file you just saved and apply it, you will find that all the fonts and sizes of the different types of visuals have been changed to the results you need:I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Fen Ling,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.- AnonymousNot applicable
Hi Fen,
Sorry for the delay. Thank you for this!
I continued with your solution and also utilised this gitub repositry