The Pokégear uses the standard command list class
Window_CommandPokemon. You know what else uses that? The commands in battle, and conveniently those commands are arranged in a 2x2 grid which is roughly what you want here. Therefore you can look to see what makes it multi-column and try it out for yourself.
Throw this line into the mix and see what happens:
Code:
@sprites["command_window"].columns=3
The next part, of course, is the placement of each button, but that's fairly simple. You can come up with a few calculations to decide each button's coordinates depending on its index number (i). Remember that options go across first and then down, in typewriter style.
That's the simple solution. It'd require a slight redesign, though, such that there are the same number of buttons in each row (ignoring the last row) - currently your second row has only 2 buttons in it.
The more complicated solution is to forego using
Window_CommandPokemon and instead make a custom command list yourself. Once again, there are existing examples to help you. The party screen is basically a 2x3 grid of buttons, but there are one or two extra buttons at the bottom which makes its navigational layout unconventional, and thus it requires a custom navigation system. Have a look at def
pbChangeSelection in
PokemonParty and you'll see a bunch of calculations which decide how to move the cursor when you press a direction key - you can do the same here. All you need to do is change a value (the currently selected index) depending on the key pressed.
This approach will let you have any layout you want, but on the downside, you'll have to design the navigation for it yourself. Again, you'll have to reposition the buttons as well.