Skip to Content
0

resize text

Jan 30, 2017 at 04:38 PM

42

avatar image
Former Member

Hello,

I want to change the font of title text :"hello" depending on my device : desktop, tablet or iphone.

for example , when i run my app from tablet, i want small font.

How can i do this?

 sap.ui.getCore().attachInit(function() {
            	var shell =  new sap.m.Shell({
                    app: new sap.ui.core.ComponentContainer({
                    
                        name: "index"
                    }),
                    title : "hello"
                }).placeAt("content");
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Jun Wu Jan 30, 2017 at 05:18 PM
1

1.create css class for different size,

2.in the init function check the device type/size, assign the corresponding class you created in step1

Share
10 |10000 characters needed characters left characters exceeded