Lets say my app uses a StackLayout together with a TabBar on the bottom and a ToolBar on the top for the main window layout, and on top of that I have a Drawer which drags in a menu from the left side when a button in the ToolBar is pressed.
So far, so standard.
Now how would I implement the Drawer featuring several levels deep of nested menu hierarchy? In XCode I would just use a UINavigationController and push pages on it when I go down a level, and pop the page when I go a level up.
How would I do this in QML? Should I just put another StackLayout inside the Drawer?
Related
Exists any solution how to add menu or tool bar into the QWidget dialog?
I making something like ERP system. There are many windowses opening from others windowses. It's important that one (parent) window waiting for choices in children window. And in the chidren window sometimes I need toolbars and menu bars...
Problem is, that
new child QMainWindow have no exec() function. It cause that parent window no waiting for finishing choices in the child.
new child QDialog have no menu or toll bar.
Exists any solution (without events)? Solution how to add menu or tool bar to QDialog, or solution how to open new qmainwindow with waiting mode myMainWindow->exec()?
Ok. I find solution.
I used QDialog. Menu or tab bar will be added as:
anylayout->addWidget(tabbar); or anylayout->setMenuBar(tabbar);
Thx for answer by Chris Kawa:
The difference is that setMenuBar places the widget outside of the layout content, so the top margin of the layout is below the bar . With addWidget the bar is added as a layout content, so it respects the margins (controlled by setContentsMargins).
For menus and toolbars we usually want them to stick to edges without a gap, so the setMenuBar method is more appropriate for it.
I have created a drawer, which will appear after click and drag from top of the screen using mouse.I have also added a list view. But the problem is; when more list items are added in the list view, drawer height is not correct. Extra added list items are visible in the top of the screen even without dragging the drawer down. Is there any solution for this?
I am trying to have a UINavigation controller with a title view the logo for the app, and a UISegmentedControl below it, however, it is too tall to fit in the Navigation bar. Is there any way to have a toolbar with a UISegmentedControl that is under the navigation bar and doesn't move when you switch views by selecting a Segment? Thanks!
I solved this by setting animated to NO when switching views and keeping the same UIsegmentedcontrol within a toolbar under the NavigationBar on all three of my views
I'm new in QT interfaces. I would like to create sliding widget in my desktop application (no QML). Idea is to create sliding menu like facebook component on some web pages.
For example:
I have main window and I want to have small part of widget on the right window edge
When mouse move on this widget (or click on it) then this widget slide to show all its content.
I know how to create animation and handle mouse events. There is a lot of examples about it. The problem is that this menu widget should not interact with other layouts and widgets. I mean, main window has root horizontal layout and I don't know how to exclude this widget from it and place widget in front of all widgets on main window. Are exists some layers in QT?
You could accomplish similar functionality by overlaying a custom QDockWidget. This widget could then float above the other widgets in a fixed position relative to your mainwindow. Connect the main window's resize/move events to slots on your QDockWidget that keeps their positions in sync.
Some Apps (like Facebook's) have buttons in the middle of the navigation section (instead of text title). How could I support right/left, and add middle button region the navigation menu, in MonoTouch?
You need to create a view or a toolbar or basically what you want that is a subclass of UIView, and add the following code.
(don't forget that you uiviewcontroller should be embedded in uinavigationcontroller)
this.NavigationItem.TitleView = YourTitleView;