Hamburger menu and app bar - layout

I want to achieve layout simmilar to Groove application, where hamburger menu is on the left and appbar on the bottom. However, not all pages contains appbar.
I have an usercontrol called MainFrame which contains the hamburger menu and a navigation frame.
When page is loaded into the navigation frame, the AppBar overlays the HamburgerMenu. I could just offset the HamburgerMenu, but not all pages contains the AppBar, or the AppBar's height is different.
Is it possible to show the hamburger on top of appbar? Or do you have any other ideas?

Use CommandBar instead of Page.BottomAppBar. Also, it is the recommended way for UWP by Microsoft.
You should use the AppBar only when you are upgrading a Universal
Windows 8 app that uses the AppBar, and need to minimize changes. For
new apps in Windows 10, we recommend using the CommandBar control
instead.
Set the CommandBar in the content Grid of HamburgerMenu
Here is a sample code:
<controls:HamburgerMenu>
<!-- Items -->
<controls:HamburgerMenu.ItemsSource>
</controls:HamburgerMenu.ItemsSource>
<!-- Options -->
<controls:HamburgerMenu.OptionsItemsSource>
</controls:HamburgerMenu.OptionsItemsSource>
<!-- Content -->
<Grid x:Name="ContentGrid">
<Frame Name="MainFrame"/>
<CommandBar VerticalAlignment="Bottom"/>
</Grid>
</controls:HamburgerMenu>

Related

Default PXRichTextEdit to Plain Text

When viewing a PXRichTextEdit field in Acumatica, there is a dropdown at the top left of the control to change from Visual to Plain Text. Is there any way to have that control automatically default to the Plain Text option for new records?
I did not find any property to do so.
The only property targeting this menu is AllowSourceMode which can hide the HTML menu item:
<px:PXRichTextEdit ID="edDescription" runat="server" DataField="Description"
AllowSourceMode="False">

Can i creatte a form in a shape specified in the image link below?

I wants to create a form in a specified format where main window area will have some common links or buttons to all pages and the page area is where all the pages will be shown. Is this possible in wpf ?
Yes you can do that by using tab item and frames. You can have an idea using:
<TabItem Header="about" Name="aboutTab">
<TabControl>
<TabItem Header="REGISTRATION" Name="subTabRegistration">
<Grid>
<Frame NavigationUIVisibility="Hidden" VerticalAlignment="Top" HorizontalContentAlignment="Stretch" ClipToBounds="True" JournalOwnership="Automatic" Source="Pages/register-activate.xaml" x:Name="frameRegistration" />
</Grid>
</TabItem>
</TabControl>
</TabItem>

Selected vs Selection in Xpages application layout control

This is SO confusing. I have an Xpage application built with the application layout control. I have 2 Title Bars which each have a navigation element in them with two views each.
I want the selected Title Bar and view to be highlighted. I understand that somehow this involves the Navigation Path and the use of the selected and/or selection properties,, but I do not understand how they work or interact.
Can these answers help you? How do you use the Selected property of the navigator?
You need to set the navigationPath property on each XPage and this must match the selection property (using regex) on the navigation control.
Updated with answer to the comment below
Here's an example XPage for the Home tab and the navigation control for Home:
<xc:layout navigationPath="/Home/XPage1">
<xp:this.facets>
<xc:layout_menu_home xp:key="facetLeft"></xc:layout_menu_home>
<xc:content_xpage1 xp:key="facetMiddle"></xc:content_xpage1>
</xp:this.facets>
</xc:layout>
The layout custom control uses the xe:applicationLayout to control the layout. In this case it has a custom property called navigationPath which is used in the example XPage above. The corresponding navigationPath property of the xe:applicationLayout must be set to this custom property:
<xe:applicationLayout id="applicationLayout">
...
<xe:this.configuration>
<xe:oneuiApplication
navigationPath="${javascript:compositeData.navigationPath}">
Here's part of xe:applicationLayout for handling the two tabs in your layout custom control:
<xe:this.titleBarTabs>
<xe:pageTreeNode page="/xpage1.xsp" label="Home" selection="/Home/.*"></xe:pageTreeNode>
<xe:pageTreeNode page="/xpage3.xsp" label="Tips" selection="/Tips/.*"></xe:pageTreeNode>
</xe:this.titleBarTabs>
Here's an example navigation control for Home:
<xe:navigator id="navigator1" >
<xe:this.treeNodes>
<xe:pageTreeNode page="/xpage1.xsp" label="XPage 1" selection="/Home/XPage1"></xe:pageTreeNode>
<xe:pageTreeNode page="/xpage2.xsp" label="XPage 2" selection="/Home/XPage2"></xe:pageTreeNode>
</xe:this.treeNodes>
</xe:navigator>

How to set <aui:button> icon in Liferay without using Javascript?

I'm trying to set icon to <aui:button> like on this tutorial.
But solution described there doesn't work well in my case, because I have a table and on each row I have a button with different resourceUrl. Like this:
<portlet:resourceURL id="saveReport" var="saveReportURL">
<portlet:param name="reportId" value="${report.reportId}" />
</portlet:resourceURL>
<aui:button onclick="location.href = '${saveReportURL}'">
Is it possible to set icon in <aui:button> without using JavaScript as described in tutorial?
Thanks
You can write this below code for setting icon in liferay alloy button
<aui:button type="cancel" cssClass="btn-info" icon="icon-upload-alt" iconAlign="right" value="upload" />
you need to use the icon attribute for this setting "Icon glyphs"
you need to use cssClass for adding extra design button class for the designing
you need to set iconAlign attribute for left or right side of the button text value
You should be able to add an icon to a button without using JavaScript by adding one of these Icon CSS classes to your button. For example, if you wanted to create a button with a calendar icon, your code should look something like this:
<aui:button class="icon-calendar" ... />

WPF ListBox ScrollView does not refresh

in our WPF application we have and Listbox with a few items. We temporary need to hide some of the items but since we need to keep the item order we don't remove them. We just set the visibility to collapsed.
This works fine so far but the ScrollViewer of the ListView does not refresh. It is still as long as before and shows some very strange behavior when you try to scroll.
Is there any way to refresh the ScrollViewer when items are collapsed? Or any other was to archive what we have done? Removing the items from the ListView is not an option.
Have you set the ItemContainerStyle? Just like:
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
<Setter Property="Visibility" Value="{Binding Visibility}" />
</Style>
</ListBox.ItemContainerStyle>

Resources