I am new to SAPUI5 and I am having trouble creating a layout which should be responsive, I tried responsive layout, responsive grid layout but with no luck, also to mention below every label a textbox should be there.
Are you aware of the example pages from SAP?
https://openui5.hana.ondemand.com/test-resources/sap/ui/layout/demokit/ResponsiveGridLayout.html
Klick on "show source" to see how they did it.
Related
I'm trying to learn Kendo Unite UX. The design handed over from figma includes an input box with an icon in it. Specifically a design for Hover with an error Icon. There is also a hover with no icon (Which matches to the Hover Component).
I am trying to figure out how I can extend the component set - that is the second image above.
I'm building my first Universal Windows Platform (UWP) App and am trying to implement the popular "Hamburger Menu" using the SplitView class.
Inspired by many samples, the items hosted on the SplitView pane are re-styled RadioButton controls, with a vertical highlight-rectangle, an icon and a text. The appearance is similar to that of the Groove app.
I'm now trying to implement navigation and selection using the keyboard, and this now bring a little focus-rect around the items in the SplitView pane. However, since the pane clips its contents when its DisplayMode is either CompactInline or CompactOverlay, the focus rectangle is also clipped, which is not the behavior a user would expect.
Please, can anyone advise on how to property display the focus rectangle in this situation ?
Just an idea, what if you set the width of all radio button's to be same as the CompactPaneLength property of SplitView. The default is 48 DIPs.
I'm looking at different variations of login screens which have material design elements.
I found the Inbox app quite interesting.
The toolbar (action bar) appears to be mid screen. And the (action bar) snaps up to the right position when editing text.
Questions:
Is this a standard behaviour across 5.0?
How do they achieve this?
The UI element you are seeing on the top, playing the role of an ActionBar is actually the Toolbar widget.
A Toolbar is a generalization of action bars for use within application layouts. While an action bar is traditionally part of an Activity's opaque window decor controlled by the framework, a Toolbar may be placed at any arbitrary level of nesting within a view hierarchy. An application may choose to designate a Toolbar as the action bar for an Activity using the setActionBar() method.
You can have multiple toolbars in an Activity. The toolbars can have different heights. The standard height of the toolbar in portrait is 56dp.
Update:
Default height:
Mobile Landscape: 48dp
Mobile Portrait: 56dp
Tablet/Desktop: 64dp
For extended app bars, the height is equal to the default height plus content increment(s).
You can read more from the Material design specification.
For implementing it you just set the layout_height attribute in the layout file. Of course extracting the number as a dimension resource is always a good idea.
While exploring the basic concepts of JavaFX, the following question arose:
Is there a way to customize the layout of composite controls (such as TreeView or Accordion)?
For example, to achieve a horizontal arrangement of child elements or to introduce animations.
Some controls include API for controlling their layout. For example, you can set the orientation of a ListView to Horizontal or Vertical or switch animation on or off in a TitledPane.
You can write your own skins to apply to existing controls and modify their layout.
Public API for control skinning is provided in Java 8.
Use the -fx-skin attribute to change a skin via css.
More details are in the JavaFX wiki control skinning section.
Using custom skins you can completely change the layout and animations for a control. See for instance this carousel skin of a TreeView.
I am quite new in JavaFX and I have a question about the design. I am creating my main menu in FXML using Scene Builder. I have various menu buttons and each of these have a sub-menu. These sub-menu options will open new windows. Is it possible to declare these submenu choices so they do not dissapear after I click on them? If so, can I declare it in my fxml or I have to do it programatically?
Also, is it possible to detach it from the menu button? I would like to have my menu choices around 1 cm away from the menu button itself.
Thank you
Suggested Alternate Solution
If you want more flexibility in positioning a popup menu after a button click as well as fine control over when the menu shows and hides, try using a Button + a ContextMenu rather than a MenuButton.
The relevant methods are:
contextMenu.show(anchorNode, side, dx, dy)
contextMenu.hide()
There is sample code for triggering a context menu on a button press button in the ContextMenu javadoc.
You might also need to monitor the context menu's showingProperty and in a listener show the menu again if the JavaFX system has decided to try and hide it after some user action and you still want the menu visible.
Answers to additional unrelated comments
OK It sounds logical, yet since Im not really good in JavaFX yet, your Idea is quite challenging.
It's not that hard to implement, but from your subsequent comments it sounds like it's probably not the user interface you want for your users anyway (which makes sense to me because the interface you describe in your question seems a little strange).
I thought If it would be easier to have a static xml that have various menu choices, lets say aligned to the right and then whenever I click one of the choices, a new FXML would be loaded in the middle of the screen holding buttons for a submenu?
That seems logical. Sounds like a JavaFX version of a traditional web page layout with a navigation menu on the side controlling a content pane in the center.
A Java only version of that is: How to have menus in java desktop application. You could adapt that to a FXML based version without too much difficulty.
You might also be interested in Managing Multiple Screens in JavaFX.
Also, any tutorial for beginners would be greatly appreciated. These Oracle ones dont make too much sense for me
If you are beginning JavaFX, I recommend using just the Java API portions of JavaFX until you become familiar with them, and then use FXML only after you are comfortable with the Java API.
Personally, I think the Oracle JavaFX Tutorials are excellent. The difficulty for beginners is that the tutorials are also part reference material, which complicates portions of them (especially the deployment related pieces).
If you prefer a different tutorial style see:
Makery JavaFX tutorial (good for beginners)
zenjava tutorials (more advanced)