ExtJS4: How to make a horizontal menu?

I am trying to implement a simple dropdown menu in ExtJS4.

By default, it is displayed vertically, and it seems that there is no (obvious) way to make it horizontal.

Any help would be appreciated.

+4
source share
2 answers

What do you mean by horizontal menu? You can add a bunch of toolbar buttons ... http://docs.sencha.com/ext-js/4-0/#!/example/menu/menus.html

+1
source

There is no easy way to do this. The menu ignores layout configuration and always uses vbox . To display it horizontally, you must override initComponent to make it possible to switch between hbox and vbox . When you select hbox , the items will be displayed horizontally, but the size will remain the same as in vbox. Thus, you also need to do something with calibration - for this you must override the doConstrain method.

+1
source

Source: https://habr.com/ru/post/1393531/


All Articles