Can i disable hamburger in shell - xaml

if you can help me please answer this post please
I Use shell in my xaml page but i dont need hamburger in tittle view
if you know how to disable this please answer me
Photo

You can set Flyout behavior in Shell to disable the hamburger in shell.
The flyout can be accessed through the hamburger icon or by swiping from the side of the screen. However, this behavior can be changed by setting the Shell.FlyoutBehavior attached property to one of the FlyoutBehavior enumeration members:
Disabled – indicates that the flyout can't be opened by the user.
The following example shows how to disable the flyout:
<Shell ...
FlyoutBehavior="Disabled">
...
</Shell>
Note:
The FlyoutBehavior attached property can be set on Shell, FlyoutItem, ShellContent, and page objects, to override the default flyout behavior.

thank For Junior Jiang - MSFT
I Following his anser
and i forget up date Xamarin form 4.2 to 4.3
https://www.youtube.com/watch?v=BqSlfrsJEns
and add
<Shell ...
FlyoutBehavior="Disabled">
...
</Shell>

Related

Custom widget designer renders in a modal offscreen

I am developing a custom widget on a new Sitefinity 12.2 instance. When I define some public properties on my controller as described here, my widget designer works as expected. Clicking the edit button on an instance of my widget opens up a full page editor where I can edit my properties.
However, when I define my own widget designer view (following this documentation), the result when I click the edit button is a modal that appears outside of the window above and to the left. Inspecting the element and adjusting the styles through the browser console, I am able to move the modal onscreen where it should be. The css source for the modal's position is [myDomain]/Frontend-Assembly/Telerik.Sitefinity.Frontend/assets/dist/css/sitefinity-backend.min.css?package=[myProject], which seems to be coming from Sitefinity's default code.
My questions: Is it possible for my default designer views to use the full screen editor that the auto-generated designer uses? If not, what am I doing wrong that's causing my modal to render offscreen? Surely that's not out-of-the-box behavior?
DesignerView.Default.cshtml:
<div class="form-group">
<label>This is a custom designer view</label>
</div>
DesignerView.Default.json:
{
"priority": 1
}
Turns out our custom CSS included its own definition for a .modal CSS class, which was interfering with the Bootstrap CSS class with the same name used by Sitefinity. This style was the culprit:
transform: translateY(-50%);
Removing/renaming our custom class has fixed the issue of the designer modal loading offscreen. I'd still be interested to hear if anyone has an answer for this question though: Is it possible for my default designer views to use the full screen editor that the auto-generated designer uses?

Use an Icon Font in Xamarin Forms TabBar

I am just getting started with Xamarin Forms, so please excuse what may well be a rookie question...
I started out with a new Shell Forms App in Visual Studio, so some code was generated for me.
There is an AppShell page which contains a TabBar control. Inside this are Tab controls were I can set my ShellContent pages.
Each Tab has an Icon property, but this apparently only accepts PNG icons.
How can I use an icon font (which is already hooked up to display icons correctly as I am using them in the content of another page) for my Tab icons in Xaml?
I am using Xamarin.Forms 4.0.0.497661
You have to use FontImageSource to do that.
<Tab Title="MyTitle">
<Tab.Icon>
<FontImageSource FontFamily="{StaticResource IconFont}" Glyph="" Size="Small"/>
</Tab.Icon>
...
</Tab>
The solution below worked for me.
Copied the files from fontawesome inside Assets folder
fa-brands-400.ttf
fa-regular-400.ttf
fa-solid-900.ttf
Important the reference "Font Awesome 5 Brands" according to icon needed
<Tab.Icon>
<FontImageSource FontFamily="fa-brands-400.ttf#Font Awesome 5 Brands" Glyph=""/>
</Tab.Icon>
That's a great question. You can't use the tab icon property in a straight forward way to accept the icon font, unless you convert it into a PNG.
If you want to go that route, you can try this, you might have to deal with permissions for saving images. Worth a try!
You can do that with custom renderers as a workaround. Check this example on GitHub here: https://github.com/winstongubantes/Xamarin.Forms/tree/master/CustomIconizeFont

Flyout Theme Bug When Using Custom RequestedTheme On Any Element

I have the following situation in Windows Phone 8.1:
Emulator with Dark theme
A Page Flyout
An element with RequestedTheme="Light" (inside a DataTemplate, in many pages)
This happens:
Open a flyout: it is Dark (as the app theme). Ok.
Navigate to a page that there is the element with RequestedTheme="Light". Ok.
Open a flyout: it is Light! Not ok!
Now all my Flyouts are Light. But my ApplicationTheme is still Dark.
It seems to be a bug.
Does anybody see if I am doing anything wrong?
--
Additional info: Flyouts doesn't have a RequestedTheme property, so I think it use the ApplicationTheme. But maybe there is something else.

Add CSS to individual tab in tab panel Sencha Touch

I'm trying to change the color of a tab in a tabpanel I have when my app goes online or offline. I have the online and offline events already setup but now I need to be able to change the color of the tab from these events.
How do I go about accessing an individual tab and setting it's CSS?
you could use ext component query to get the handle of the component and then add/remove class
Ext.ComponentQuery.query('yourselector')[0].addCls('yourclass')
You can get the individual tab from tabpanel by referring it as following inside the controller class (inside the refs):
myDesiredTab: '#myTabPanelId container[title=myDesiredTabTitle]'
and afterward you can try:
this.getMyDesiredTab().tab.setCls('myDesiredCssClass');
This idea hasn't been tested but might just work as the tabbar does have cls config and we have a way to access the individual tab.

Windows 8 App. Back Button not working

I'm using a new item Basic Template with the app name and back button.
It is being used inside of a "Blank" project.
However, the back button is not responding to touch events.
This following is code that was generated. The back button just disappears.
<Button x:Name="backButton" IsEnabled="{Binding Frame.CanGoBack, ElementName=pageRoot}" Style="{StaticResource BackButtonStyle}" Click="GoBack"/>
I even tried making my own Click Handle and tried navigating myself with.
this.Frame.Navigate(typeof(MainPage));
However that isn't working either. Probably due to something that auto generated because I can create a button myself and wire it up for that (so I'm really trying to stick with the Templates).
Any ideas please?
Edit:
I found it really odd none of the Navigation is working. After drilling some more it appears to be something with LayoutAwarePage. I'm missing something here. Will post updates.
Edit: Sorry about that. I added the event click listeners back in (I must have removed that copying around). However that still does not fix my issue. I tried setting the back button to the "GoBack" function and when you hit the back button it just disappears. I also tried creating my own method and trying to navigate myself and still did not work.
You need an Click event handler on the button. Click="GoBack"
<Button x:Name="backButton" Click="GoBack" IsEnabled="{Binding Frame.CanGoBack, ElementName=pageRoot}" Style="{StaticResource BackButtonStyle}"/>
GoBack function is available in LayoutAwarePage which is most likely the base class of your page, if not make sure it is. LayoutAwarePage class resides inside Project\Common
You should not need to write any of your own code to enable the back button, as it ties into the underlying navigation framework automatically. If there is a page in the back stack to navigate to, the back button will be enabled.
What you are missing, from what I can see, is that if you start your app on the Basic page that you added, there's nothing in the back stack of the navigation framework for you to navigate to.
I tested your scenario using the following steps:
I created a new C#/XAML Windows Store app using the Blank App template.
Then added a new Basic page (BasicPage1.xaml).
Opened MainPage.xaml, and added a Button to the page.
Double-clicked the button, and added the following code to the click event handler:
this.Frame.Navigate(typeof(BasicPage1));
Ran the project, and the back button worked as expected.
From the XAML markup that I see, there is no Click event handler tied to the button, so no action is taken unless you hook it to one.
Well, this approach appears to take code from the Basic page. Could you confirm that you are inheriting from LayoutAwarePage and not from Page? Otherwise GoBack is not implemented in this way. Also, you cannot GoBack if you have not navigated from this page in the first place, from another. And, finally (just brainstorming here), you cannot GoBack if you got to this page by setting the Frame itself and not the page (in the previous location). This would clear the navigation history.
And, also, can you confirm this does not work?
this.Frame.GoBack();
Best of luck!
Im making my back buttons like this:
XAML code. In this case LoginPage.xaml.
<Button x:Name="ButtonGoBack" Click="ButtonGoBack_OnClick" Style="{StaticResource NavigationBackButtonNormalStyle}"/>
C# code in LoginPage.xaml.cs
private void ButtonGoBack_OnClick(object sender, RoutedEventArgs e)
{
this.Frame.GoBack();
}
I've just had the same issue as Frank. I found my problem to be that I overrided the OnNavigatedTo handler without calling the base class's (LayoutAwarePage) handler also. This meant LayoutAwarePage wasn't setting its _pageKey member variable which it uses in its OnNavigatedFrom handler.
Hope this helps others with the same issue.
This happened to me too. I know nothing could've changed in my code so I checked the project properties. In Common Properties->References I noticed an anomaly, there have been some resources that was never there, ( all I should have in that project is SQLite for Windows RunTime). I then deleted the unwanted resource and fixed the navigation problem.
If you used
Frame.SetNavigationState("1,0");
you removed the back stack entry , so the back button will not working .