Skip to Content
0

Use custom fonts in SAPUI5 applications

Mar 02 at 09:13 AM

45

avatar image

Hi,

I know this question was asked before. But I couldn't find a way to do it. Is there a way to use your custom fonts in SAPUI5 applications by configuring it in the Theme Designer?

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

3 Answers

Stefan Siemes yesterday
1

I think SAP Theme Designer does not support changing the font right now (see the endless discussions on SCN ...)

We use the following workaround in our applications:

  1. Make a custom CSS in your project folder, e.g. css\style.css
  2. Include the CSS in your manifest.json

    <code>"resources": {
        "css": [
            {
            uri": "css/style.css"
            }
        ]
    }
    

  3. Set the font-family property in the CSS (in this case "Candara"), the selector excludes all SAP-Standard icons and their special fonts

    :not(.sapUiIcon) {
         font-family: Candara;
    }

Share
10 |10000 characters needed characters left characters exceeded
Dharmendra Kumar
Mar 06 at 07:38 AM
0

Hi,

Custom font is not supported by SAP UI5. The parameter 'sapUiFontSize' is has no public access.

Regards,

Dharmendra Kumar

Share
10 |10000 characters needed characters left characters exceeded
avatar image
Former Member Mar 06 at 09:05 AM
0

Hi,

You can refer this blog.

https://blogs.sap.com/2015/11/02/enhance-ui5-app-with-custom-icon-fonts/

Regards,

Kanwarmeet Kaur

Share
10 |10000 characters needed characters left characters exceeded