简体   繁体   English

在extjs4 tbar按钮中向左对齐文本

[英]left justify text in an extjs4 tbar button

I have the following tbar items. 我有以下tbar物品。 I am trying to left-justify the text inside the buttons. 我试图将按钮内的文本左对齐。 But I am unable to do so. 但是我做不到。 Any suggestions? 有什么建议么?

                        {
                            tbar: [
                                {
                                    xtype: 'button',
                                    text: 'Home',
                                    width: 120,
                                    align:'left',   
                                    handler: function() {
                                        document.location.href = BasePath; 
                                    }
                                }                                   

                            ]
                        },
                        {
                            tbar: [
                                {
                                    xtype: 'button',
                                    text: 'View Transfer Numbers',
                                    width: 120,                                         
                                    handler: function() {
                                        document.location.href =BasePath+'transfer'; 
                                    }
                                }                                   

                            ]
                        }

textAlign : String textAlign:字符串

This is what I did above to get my solution 这就是我上面为获得解决方案所做的

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM