How to have a toolbar on left and right?

46 views
Skip to first unread message

Gareth Murfin

unread,
Mar 17, 2016, 5:48:57 PM3/17/16
to CodenameOne Discussions
Im adding a toolbar but it always appears on the left, is there a way to choose? and also to have one on the right too?

Shai Almog

unread,
Mar 18, 2016, 12:14:44 AM3/18/16
to CodenameOne Discussions
Do you mean the sidemenu in the toolbar?
Currently the Toolbar doesn't support the right side menu. You can add commands to the right though.

Gareth Murfin

unread,
Mar 18, 2016, 1:15:46 AM3/18/16
to codenameone...@googlegroups.com
I was unable to get the sidemenu to work, was confused how it is meant to work and never got it to appear (simplest example would be good, I found your demo code confusing). So I went with the toolbar, seems a bit weird that it can only go on one side to me.

On 18 March 2016 at 12:14, Shai Almog <shai....@gmail.com> wrote:
Do you mean the sidemenu in the toolbar?
Currently the Toolbar doesn't support the right side menu. You can add commands to the right though.

--
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/rdy0QXEBqPI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discu...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit https://groups.google.com/d/msgid/codenameone-discussions/3dd54c78-8d4f-4b11-b71e-4281d4643b54%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Gareth Murfin
(Android Freelancer - www.garethmurfin.co.uk)

Shai Almog

unread,
Mar 19, 2016, 1:35:43 AM3/19/16
to CodenameOne Discussions
The old side menu bar allowed that https://www.codenameone.com/blog/on-the-side-up-on-top.html

However this was somewhat flaky so we never added official support for it in the Toolbar.

Gareth Murfin

unread,
Mar 20, 2016, 11:11:16 AM3/20/16
to codenameone...@googlegroups.com
OK so for now its best to stick with toolbar on left ?

On 19 March 2016 at 13:35, Shai Almog <shai....@gmail.com> wrote:
The old side menu bar allowed that https://www.codenameone.com/blog/on-the-side-up-on-top.html

However this was somewhat flaky so we never added official support for it in the Toolbar.

--
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/rdy0QXEBqPI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discu...@googlegroups.com.
Visit this group at https://groups.google.com/group/codenameone-discussions.

For more options, visit https://groups.google.com/d/optout.

Gareth Murfin

unread,
Mar 20, 2016, 1:04:46 PM3/20/16
to CodenameOne Discussions
Also is there a way to make it take more space than a 3rd of the screen? The sidemenu that is.. love the smoothness.


On Sunday, March 20, 2016 at 11:11:16 PM UTC+8, Gareth Murfin wrote:
OK so for now its best to stick with toolbar on left ?
On 19 March 2016 at 13:35, Shai Almog <shai....@gmail.com> wrote:
The old side menu bar allowed that https://www.codenameone.com/blog/on-the-side-up-on-top.html

However this was somewhat flaky so we never added official support for it in the Toolbar.

--
You received this message because you are subscribed to a topic in the Google Groups "CodenameOne Discussions" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codenameone-discussions/rdy0QXEBqPI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codenameone-discussions+unsub...@googlegroups.com.

Shai Almog

unread,
Mar 20, 2016, 11:46:32 PM3/20/16
to CodenameOne Discussions
Yes see the theme constants from here: https://www.codenameone.com/manual/advanced-theming.html

sideMenuSizeTabPortraitInt

The size of the side menu when expanded in a tablet in portrait mode

sideMenuSizePortraitInt

The size of the side menu when expanded in a phone in portrait mode

sideMenuSizeTabLandscapeInt

The size of the side menu when expanded in a tablet in landscape mode

sideMenuSizeLandscapeInt

The size of the side menu when expanded in a phone in landscape mode


Gareth Murfin

unread,
Jul 18, 2016, 3:54:01 AM7/18/16
to CodenameOne Discussions
What units do these use? is it a percentage ?

Gareth Murfin

unread,
Jul 18, 2016, 4:08:26 AM7/18/16
to CodenameOne Discussions
Also how do I specify the width of the toolbar's side menu ? Like so it takes up only 50% when its pulled out?

Shai Almog

unread,
Jul 19, 2016, 12:14:59 AM7/19/16
to CodenameOne Discussions
This is only about the side menu both for the side menu bar and the toolbar. The unit is in percentage.
Reply all
Reply to author
Forward
0 new messages