Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
ania_roh
Helper III
Helper III

theme json for visuals (fontfamily)

Hi

I´m creating my json code for all visualizations, but I have a problem with fontfamily. I put "Segoe (Bold) in the title of the table, this is my json code.

 
 
 

codigo.JPG

 

When I import my json code to the desktop, it seems it works: 

options.JPG

 

 

But the problem is that I can see it visually, it puts other font: 

font.JPG

 

And it should be like that:

 

titulo.JPG

 

It happens with all elements.

How could I solve it?

Thank you. 

1 ACCEPTED SOLUTION

Hi @ania_roh ,

 

Modify " Segoe (Bold)" as "Segoe UI Bold",as tested here,it seems that "Segoe (Bold)" in json code is "Segoe UI Bold",pls see below:

 

{"name":"Custom","textClasses":
{"title":
{"fontFace":"'Segoe UI Bold', wf_segoe-ui_bold, helvetica, arial, sans-serif"}
}
}

 

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!

View solution in original post

10 REPLIES 10
Anonymous
Not applicable

Hi there, I tried Segoe UI Black 

in my json script and it works just fine. I had the same issue you have. Hope it helps you

Anonymous
Not applicable

Hi

The issue is in the font family. Try this one and it should work

"fontFamily":"wf_segoe-ui_bold"

Best regards,

Mijalis

v-kelly-msft
Community Support
Community Support

Hi  @ania_roh ,

 

Try to move 'fontfamily' properties to global place,pls refer to :

https://community.powerbi.com/t5/Desktop/Change-fontfamily-power-bi-report/td-p/562284

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!

Thank you  @v-kelly-msft 

Ok, I will try it, but how could I do this, if I would like have everything Segoe Bold apart of values in the table and matrix (which is Segoe UI), header in slicer (which is Segoe UI)  and labels in card (which is DIN)? The all rest is Segoe Bold.

Also, I noticed the problem only appears with Segoe Bold and DIN.

I tried to change my original code for Times New Roman, and it works.

Thanks

Hi @ania_roh ,

 

Modify " Segoe (Bold)" as "Segoe UI Bold",as tested here,it seems that "Segoe (Bold)" in json code is "Segoe UI Bold",pls see below:

 

{"name":"Custom","textClasses":
{"title":
{"fontFace":"'Segoe UI Bold', wf_segoe-ui_bold, helvetica, arial, sans-serif"}
}
}

 

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!

Thank you for this discussion.  I am having the same problem with a Google font Quattrocento Sans.  It has a bold variant that I have brought into my font folder.  I have been able to get the regular font to work in Power BI but not the bold.  Does anyone know what the below code would be for this font?

 

{"fontFace":"'Segoe UI Bold', wf_segoe-ui_bold, helvetica, arial, sans-serif"}

 

Thank you in Advance!

Thank you @v-kelly-msft, it worked 🙂 

v-kelly-msft
Community Support
Community Support

Hi @ania_roh ,

 

It should be set under "Column header",not title,so modify the body of your json as below:

1.pngAnnotation 2020-04-21 143702.png

 

Hope it would help.

 

Best Regards,
Kelly
Did I answer your question? Mark my post as a solution!

 

Hello @v-kelly-msft. Thank you for your reply. However, the problem appears not only in column header but in values,  legend, total, etc, in all visualizations (cards, columnchart, pivottable, slicer), everything that includes fontFamily (for Din and for segoe bold) Also, I have json code not only for title, but for columnheader too, because I wanted to put fontfamily for two of them.

Thank you in advance

"tableEx": {
            "*": {
                "general": [
                    {
                        "responsive": true
                    }
                ],
                "title": [
                    {
                        "show": true,
                        "text": "MODIFICA EL TÍTULO",
                        "titleWrap": true,
                        "fontColor": {
                            "solid": {
                                "color": "#0078AB"
                            }
                        },
                        "alignment": "Left",
                        "fontSize": 11,
                        "fontFamily": "Segoe (Bold)"
                    }
                ],
                "background": [
                    {
                        "show": true,
                        "color": {
                            "solid": {
                                "color": "#F1F3F5"
                            }
                        },
                        "transparency": 0
                    }
                ],
                "border": [
                    {
                        "show": true,
                        "color": {
                            "solid": {
                                "color": "#02253A"
                            }
                        },
                        "radius": 4
                    }
                ],
                "total": [
                    {
                        "totals": true,
                        "fontColor": {
                            "solid": {
                                "color": "#0078ab"
                            }
                        },
                        "backColor": {
                            "solid": {
                                "color": "#F1F3F5"
                            }
                        },
                        "outline": "Up",
                        "fontFamily": "Segoe (Bold)",
                        "fontSize": 10
                    }
                ],
                "grid": [
                    {
                        "gridVertical": true,
                        "gridVerticalColor": {
                            "solid": {
                                "color": "#FFFFFF"
                            }
                        },
                        "gridVerticalWeight": 2,
                        "gridHorizontal": true,
                        "gridHorizontalColor": {
                            "solid": {
                                "color": "#FFFFFF"
                            }
                        },
                        "gridHorizontalWeight": 2,
                        "rowPadding": 2,
                        "outlineColor": {
                            "solid": {
                                "color": "#02253a"
                            }
                        },
                        "outlineWeight": 1,
                        "textSize": 8,
                        "imageHeight": 75
                    }
                ],
                "columnHeaders": [
                    {
                        "fontColor": {
                            "solid": {
                                "color": "#02253a"
                            }
                        },
                        "backColor": {
                            "solid": {
                                "color": "#B2B2B2"
                            }
                        },
                        "outline": "Frame",
                        "autoSizeColumnWidth": true,
                        "fontFamily": "Segoe (Bold)",
                        "fontSize": 10,
                        "alignment": "Left",
                        "wordWrap": true
                    }
                ],
                "values": [
                    {
                        "fontColorPrimary": {
                            "solid": {
                                "color": "#02253A"
                            }
                        },
                        "backColorPrimary": {
                            "solid": {
                                "color": "#FFFFFF"
                            }
                        },
                        "fontColorSecondary": {
                            "solid": {
                                "color": "#02253A"
                            }
                        },
                        "backColorSecondary": {
                            "solid": {
                                "color": "#E6E6E6"
                            }
                        },
                        "outline": "none",
                        "urlIcon": true,
                        "wordWrap": true,
                        "fontFamily": "Segoe UI",
                        "fontSize": 8
                    }
                ]
            }

 

Greg_Deckler
Super User
Super User

Likely the best person to ask is @Mike_Carlo 


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.